# Find all solutions of $1/x+1/y+1/z=1$, where $x$, $y$ and $z$ are positive integers

Find all solutions of $1/x+1/y+1/z=1$ , where $x,y,z$ are positive integers.

Found ten solutions $(x,y,z)$ as ${(3,3,3),(2,4,4),(4,2,4),(4,4,2),(2,3,6),(2,6,3),(3,6,2),(3,2,6),(6,2,3),(6,3,2)}$. Are these the only 10 solutions? First, none of $x$, $y$ or $z$ can be $1$ ($x$, $y$ and $z$ are positive integers)

If I let $x=2$, then finding all solutions to $1/y+1/z = 1/2$ leads to $(4,4), (3,6)$ and $(6,3)$ which gives me $(x,y,z)$ as $(2,4,4), (2,3,6), (2,6,3)$ but this also means $(4,4,2), (4,2,4), (3,2,6), (3,6,2), (6,2,3), (6,3,2)$ are all valid triples for this equation. If I let $x=3$, the only different values of $y$ and $z$ are $(3,3)$ How do I prove these are the only ten solutions? (without using any programming)

Known result: If we denote $d(n^2)$ as the number of divisors of $n^2$, then the number of solutions of $1/x+1/y = 1/n$ = $d(n^2)$ (For positive $x$, $y$)

For $1/x+1/y+1/z=1$

$z = \frac{xy}{y(x-1)-x}$ where $xy \neq 0$
What happens after that?

Question is: how do we sho there are the only ten solutions? I'm not asking for a solution.

Assuming $x \le y \le z$

$1 \le y \le \frac{xy}{y(x-1)-x}$

$\Longrightarrow 1 \le x \le y \le \frac{2x}{x-1}$

Got the answer. I'll probably call @mathlove's answer. (Any additional answers I'll view later)

-
And by extension, how many solutions are there for $n$ variables to the equation $\frac 1{x_1}+\frac 1{x_2}+\frac 1{x_3}+\cdots+\frac 1{x_n}=1$ where $\forall i,x_i\in\Bbb Z^+$... –  abiessu Dec 23 '13 at 16:51
This equation Markov. Formulas in General gives a rational decision. Integers are a special case of the solutions of this equation. –  individ Jan 28 at 16:17

They are the only possible solution. Proof is as follows:

Suppose that $d = gcd(x,y)$ and $x=d ~ x0$, $y=d ~y_0$ where $x_0$ and $y_0$ are co-prime. Substituting in the original equation we get $$1/x + 1/y + 1/z=1 \Rightarrow -d\,x_0\,y_0\,z+y_0\,z+x_0\,z+d\,x_0\,y_0 =0$$ Solving for $d$: $$d=\frac{\left( y_0+x_0\right) \,z}{x_0\,y_0\,\left( z-1\right) }$$ Since $x_0$ and $y_0$ are co-prime, for $d$ to be an integer, $x_0\,y_0$ should divide $z$. Hence we require $$z= k ~x_0 ~y_0$$ Substituting in the equation for $d$ and solving for $k$: $$k=\frac{d}{d\,x_0\,y_0-y_0-x_0}$$ This shows that $d$ is a multiple of $k$. Let $$d= \mu k$$. Then $$k=\frac{k\,\mu}{k\,\mu\,x_0\,y_0-y_0-x_0}$$ Solving for $k$: $$k=\frac{1}{x_0\,y_0}+\frac{1}{\mu\,y_0}+\frac{1}{\mu\,x_0}$$ This implies that $1 \le x_0 \le 3$, $1 \le y_0 \le 3$, $1 \le \mu\le 3$

It is possible to eliminate some of the 27 possible values since $k$ has to be an integers this will result in 12 possible values for $(x_0,y_0,\mu)$ and two of the solutions are repetitions giving the 10 solutions mentioned in the problem.

-
Thanks @user44197. I got 10 possible values for which k is integer actually by your approach. $(x_0,y_0,\mu)$ as ${(1,1,1),(1,2,1),(2,1,1),(2,3,1),(3,2,1),(1,1,2),(1,3,2),(3,1,2),(1,2,3),(2,1,3‌​)}$ –  Kirthi Raman Dec 24 '13 at 15:07
Thanks for validating. Actually, by looking at divisibility, one can reduce the search to less than 27 possibilities. –  user44197 Dec 24 '13 at 23:43

HINT : You may suppose that $1\le x\le y\le z.$ This will make it easier to find the solutions.

-
they have to be less than 1 isn't it? How can x,y,z be greater than 1? –  Kirthi Raman Dec 23 '13 at 17:05
What? you mean $x\lt 1$? Notice if $x\lt 1$, then $1/x\gt 1$. This means there is no solution of your equation. –  mathlove Dec 23 '13 at 17:08
Yes that was a mistake (I can't believe I said that - looks so stupid of me) –  Kirthi Raman Dec 23 '13 at 17:10

Hint: Deduce that none of $x, y, z \in \mathbb{N}$ exceeds $7$. This can be done by mathlove's hint above.

Additionally, you can show that there is only one $(a, 2, 2)$-tuple and thus use $(a, 2, 3)$ to bound the solutions.

-
But some solutions like (2,3,6) (3,2,6) does not say none should exceed 5 –  Kirthi Raman Dec 23 '13 at 17:17
You probably mean cannot exceed 6 –  Kirthi Raman Dec 23 '13 at 17:17
So basically you are same thing as @mathlove –  Kirthi Raman Dec 23 '13 at 17:22
If you edit your answer, make a comment in this chain of question for some users who might look at this later –  Kirthi Raman Dec 23 '13 at 17:23

We may as well assume $x\le y\le z$ (and then count rearrangements of the variables as appropriate). The smallest variable, $x$, cannot be greater than $3$ (or else $1/x+1/y+1/z\lt1/3+1/3+1/3=1$), nor can it be equal to $1$ (or else $1/x+1/y+1/z=1+1/y+1/z\gt1$). So either $x=2$ or $x=3$.

If $x=3$, then $y=z=3$ as well (for the same reason as before), which gives the solution $(x,y,z)=(3,3,3)$.

If $x=2$, then $1/2+1/y+1/z=1$ implies

$${1\over2}={1\over y}+{1\over z}$$

Applying the inequality $y\le z$ to this equation, we see that $y$ must be greater than $2$ but cannot be greater than $4$, so $y=3$ or $y=4$. Each of these gives a solution, $(x,y,z)=(2,3,6)$ and $(2,4,4)$.

Counting rearrangements, we get the OP's $10$ solutions and no others.

-