# Math Help - prove

1. ## prove

prove that if a+ b/a - 1/b is an integer then it is a perfect square for integers a, b.

2. Originally Posted by nh149
prove that if a+ b/a - 1/b is an integer then it is a perfect square for integers a, b.
By setting a=-1, b=1 you can see the statement does not hold.

But let's try to fix it: "if a+ b/a - 1/b is an integer then it is a perfect square for positive integers a, b."

So let $a+\frac{b}{a}-\frac{1}{b} = a+\frac{b^2-a}{ab}$ be an integer for positive integers $a,b$. Then $b^2-a=kab$ for some integer $k$. We get $b^2=a(kb+1)$.
We see this implies $k \ge 0$.
If $k=0$ we immediately see that our statement holds.
We'll finish the proof by showing that we cannot have $k>0$. If it is, then $b^2=a(kb+1)$ implies $a. After dividing $b^2=a(kb+1)$ by $b$ we get $b=ak+\frac{a}{b}$. This means that $b$ divides $a$, so we cannot have $a, which is a contradiction.