# Find all pairs of integers $(x,y)$ such that $x^{2}+y^{2}=(x-y)^{3}$.

Find all pairs of integers $$(x,y)$$ such that $$x^{2}+y^{2}=(x-y)^{3}$$.

I think that $$(0,0)$$ , $$(1,0)$$ and $$(0,-1)$$ are the only solutions to the above equation, but I'm unable to prove it. I tried all sorts of things like working $$\mod 9$$ (but there are just too many cases ), a little bit of algebraic manipulations, tried to determine the parity of $$x$$ and $$y$$ etc. But they were to no avail for me. I tried working modulo $$9$$ because $$a^{3}\equiv 0,1$$ or $$-1 \pmod 9$$.

The manipulations done by me were as follows:- $$x^2 + y^2 =(x-y)^3$$ implies that by adding and subtracting $$2xy$$ on LHS we can rewrite the above equation as $$(x-y)^2 +2xy=(x-y)^3$$ . This can be rewritten as $$2xy=(x-y)^3 -(x-y)^2$$. This is all I could achieve here. One thing I did here was substitute $$x-y=a$$ and $$x=a+y$$ and rewrite the last equation as $$2y^2 +2ay+a^2 -a^3=0$$ and then I tried to find the roots of this quadratic in $$y$$ but this didn't work for me(I think there is something wrong with this approach, do tell me if you see it).That is all I could do. Another question I would like to ask is do there exist integers $$a,b$$ and $$c$$, with none of them equal to zero, which satisfy $$a^2 + b^2=c^3$$ ? Thank you .

• For your last question, $(a, b, c) = (2, 2, 2)$. – Theo Bendit Sep 29 at 11:12
• For the different question, you should try to ask it separately. – YiFan Sep 29 at 11:12
• Theo Bendit , can we find a solution to the last question if we impose another restriction ,that of them being unequal, on $a,b$ and $c$ . – user655800 Sep 29 at 11:15

To extend your existing approach, multiply by $$2$$ to obtain :$$0=4y^2+4ay+2a^2-2a^3=(2y+a)^2+a^2(1-2a)$$

To obtain a factorisation with integer coefficients you need $$2a-1=b^2$$. For convenience, multiply through by $$4$$ to get $$0=(4y+2a)^2+4a^2(1-2a)=(4y+b^2+1)^2-(b^2+1)^2b^2$$ And the roots are $$4y=-(b^2+1)\pm b(b^2+1)=-(1\pm b)(1+b^2)$$

Now $$b$$ is odd, so the right-hand side is the product of two even numbers, and any odd value of $$b$$ will lead to a solution.

For example $$b=3$$ gives $$x=10, y=5$$.

• Thank you Mark. – user655800 Sep 29 at 11:42
• Note that you can work further on this - setting $b=2c+1$ and separating the choice of signs to get fully parametric solutions. This will also show why $x$ and $y$ typically come with a common factor. – Mark Bennet Sep 29 at 11:44
• You also get "mirror image solutions" if you allow both values of the $\pm$ sign. Thus $b=3$ gives both $(x_1,y_1)=(10,5)$ and $(x_2,y_2)=(-y_1,-x_1)=(-5,-10)$. – Oscar Lanzi Sep 29 at 12:08

Using a computer , you can find some solutions like :

$$(0 ,-1),(0,0),(1,0),(10,5) , (39,26) , (100,75) , (205,164),(366,305), (595,510),(904,791),(1305,1160),(1810 ,1629)$$

So , it means that your assumption that $$(0,0),(1,0)and(0,-1)$$ is wrong as their exist infinitely many solutions to the equation.

Also to your second part of question , there also exist infinitely many solutions to: $$a^2 + b^2 = c^3$$

like $$(2,2,2) , (2,11,5) ,(5,10,5) , (9,46,13) , (10,30,10),(10,198,34)$$etc.

Letting $$x=y+k$$, we are looking for the solutions of $$2y^2+2yk+k^2 = k^3$$ $$(2y+k)^2+k^2 = 2k^3$$ which depend on the integer points on the elliptic curve $$w^2=2z^3-z^2=z^2(2z-1)$$.
We may assume that $$z=\frac{q^2+1}{2}$$, leading to the solution $$k=\frac{q^2+1}{2},w=q\frac{q^2+1}{2},y=(q-1)\frac{q^2+1}{4},x=(q+1)\frac{q^2+1}{4}$$.
Of course, in order to have $$\frac{q^2+1}{4}\in\mathbb{Z}$$ $$q$$ must be odd, $$q=(2t+1)$$. These leads to the solutions

$$\boxed{ x = 2t^3+4t^2+3t+1,\qquad y= 2t^3+2t^2+t. }$$