# The diophantine equations $x^2-y^5=\pm2$

Update: It only remains to handle Equation $$x^2-y^5=2$$ (see edit below).

Question 1. What are the integer solutions to the equations $$x^2-y^5=\pm2$$?

I know that these diophantine equations have only finitely many solutions, but I don't understand the subject well enough to give a good argument. I suspect this follows from Siegel's Theorem and involves the notion of genus, but I'm not sure, so let me ask the question:

Question 2. What would be a nice way to see (possibly using known results) this finiteness result?

(I'm not planning to accept an answer solving only Question 2.)

Equation $$x^2-y^5=2$$ has the solutions $$(\pm1,-1)$$. I don't know any other solution, and I don't know any solution to $$x^2-y^5=-2$$.

To find the non trivial solutions (if any) we can clearly assume $$x,y\ge3$$.

The only thing I've been able to show is that any non trivial solution satisfies $$y>593825$$.

To verify this I use this answer of Max Alekseyev. Indeed, $$x^2$$ and $$y^5$$ are two powerful numbers which differ by $$2$$. The first $$13$$ such pairs of powerful numbers are given in this OEIS entry, and it is easy that check that none of them works. The largest number occurring in these $$13$$ pairs is $$73840550964522899559001927225$$ and the integer part of its fifth root is $$593825$$.

I think it would be easy for somebody who (unlike me) knows how to use the appropriate softwares to improve this bound, and I hope some users will do that if answering Question 1 turns out to be hard.

EDIT. Thank you to Dietrich Burde who pointed out in a comment that Ljunggren proved that Equation $$x^2-y^5=-2$$ has no integer solution. Dietrich linked to the article

Abu Muriefah, Fadwa S., and Yann Bugeaud. The diophantine equation $$x^2+c=y^n$$: a brief overview. Revista Colombiana de Matemáticas 40.1 (2006): 31-37.

The article mentions also subsequent papers of Nagell and Sury which also prove the result (Sury's approach being more elementary).

As indicated at the beginning of the post, it only remains to handle Equation $$x^2-y^5=2$$.

UPDATE. I just noticed that the article

Samir Siksek. "The modular approach to Diophantine equations." Number Theory: Volume II: Analytic and Modern Tools (2007): 495-527, PDF,

contains an answer to the question. More precisely, it shows that the only solutions to $$x^2-2=y^p$$, with $$p$$ an odd prime, are $$(x,y,p)=(\pm1,-1,p)$$ if $$p$$ is not in the range $$41\le p\le 1231.$$ There are a little more details at the end of this answer.

• 1. See here for $c=\pm 2$. For example: "Then, Ljunggren [22] established that equation (4) with $c = 2$ has only the solution $5^2 + 2 = 3^3$. " In other words, $x^2+2=y^5$ has no integer solution. Commented Feb 22, 2023 at 19:18
• You can remark that you cannot have couple of even number solution noting that $x$ and $y$ are of same parity.
– EDX
Commented Feb 22, 2023 at 19:24
• I don't think it is necessary to cite a paper to solve $x^2 - y^5 = -2$; namely, one can rewrite it as $(x + \sqrt{-2})(x - \sqrt{-2}) = y^5$; arithmetic in $\mathbb{Z}[\sqrt{-2}]$ will readily yield all solutions using the standard techniques. This approach is not quite as easy for the problem that is still open, as $\mathbb{Z}[\sqrt{2}]$ has infinitely many units Commented Feb 22, 2023 at 20:59
• @MikeDaas To expand on the 'standard techniques' you mention: The factors on the right hand side of$$y^5=(x+\sqrt{-2})(x-\sqrt{-2}),$$are coprime because $x$ and $y$ are odd, e.g. by reducing mod $4$. Then both factors are fifth powers as $\Bbb{Z}[\sqrt{-2}]$ is a UFD with unit group $\pm1$, so all units are fifth powers. Then$$x+\sqrt{2}=(a+b\sqrt{2})^5,$$and expanding the right hand side and comparing coefficients of $\sqrt{2}$ yields$$1=5a^4b+20a^2b^3+4b^5=b(5a^4+20a^2b^2+4).$$Then $b=\pm1$ and reducing mod $5$ shows that $b=-1$. But then $a^4+4a^2+1=0$, which has no integral solutions. Commented Feb 23, 2023 at 0:32
• @Pierre-YvesGaillard Oops, you're right! The exact same argument still works of course, changing a few signs here and there. Commented Feb 23, 2023 at 14:55

Let $$x$$ and $$y$$ be integers such that $$x^2-y^5=2.$$ Then in the ring $$\mathbb{Z}[\sqrt{2}]$$, which is a UFD with unit group $$\langle-1,1+\sqrt{2}\rangle$$, we have the identity $$y^5=x^2-2=(x+\sqrt{2})(x-\sqrt{2}).$$ The two factors on the right hand side are coprime because $$x$$ is odd, and so both factors are fifth powers, up to units. That is to say, we have $$x+\sqrt{2}=\pm(1+\sqrt{2})^k(a+b\sqrt{2})^5,$$ for some $$k\in\{0,1,2,3,4\}$$. Note that $$-1$$ is a fifth power, so we may omit the $$\pm$$-sign. We have $$(a+b\sqrt{2})^5=a(a^4+20a^2b^2+20b^4)+b(5a^4+20a^2b^2+4b^4)\sqrt{2},$$ so for $$k=0$$ we immediately see that $$b=\pm1$$ and so $$5a^4+20a^2+4=b=\pm1,$$ reducing mod $$5$$ shows that $$b=-1$$, but this does not yield any integer solutions for $$a$$.

By a similar calculation, for $$k=1$$ we find that $$1 =a^5+5a^4b+20a^3b^2+20a^2b^3+20ab^4+4b^5.$$ This is a Thue equation, for which effective methods to solve them exist. PARI/GP tells me that the only solution is the trivial solution $$(a,b)=(1,0)$$, corresponding to $$(x,y)=(1,-1)$$.

The exact same can be done for $$k=2,3,4$$. Each time you will find a quintic Thue equation, and a solver will list all integral solutions. There are guaranteed to be only finitely many in each case. For $$k=2,3,4$$ I find $$\begin{eqnarray} 1&=&2a^5+15a^4b+40a^3b^2+60a^2b^3+40ab^4+12b^5,\\ 1&=&5a^5+35a^4b+100a^3b^2+140a^2b^3+100ab^4+28b^5,\\ 1&=&12a^5+85a^4b+240a^3b^2+340a^2b^3+240ab^4+68b^5. \end{eqnarray}$$ Only the latter has an integral solution, which is $$(a,b)=(-1,1)$$. This corresponds to the trivial solution $$(x,y)=(-1,-1)$$.

This method is guaranteed to give all finitely many solutions within a reasonable amount of time though.

• Of course the exact same argument works for $$x^2-y^5=-2,$$ but here the unit group is trivial, so you are done immediately. Commented Feb 23, 2023 at 0:55
• I'll make 2 edits. I think you'll agree with the first one. If you don't like the second one, you can roll back. I verified your calculations. (2nd edit in a few minutes) Commented Feb 23, 2023 at 14:46
• I'm not sure your second edit is an improvement, but it's fine by me either way. Commented Feb 23, 2023 at 14:59

For the general result: this is a hyperelliptic curve and thus we know from the degree that it has genus $$2$$.

Therefore Siegel's theorem applies and tells us that there are only finitely many integral points.

In fact, since the genus is larger than $$1$$, it even follows that there are only finitely many rational points - this is Falting's theorem.

• Thanks! This is exactly what I needed! +1 Commented Feb 23, 2023 at 12:14

I present an elementary argument to deal with the equation $$x^2 - y^5 = -2, \quad \text{or} \quad x^2 + 2 = y^5.$$ We will work over the ring $$R = \mathbb{Z}[\sqrt{-2}]$$, in which we may factor the equation: $$(x + \sqrt{-2})(x - \sqrt{-2}) = y^5.$$ It is routine to verify that $$R$$ is a Dedekind domain and that its class number is $$1$$, meaning that it is a unique factorisation domain. We will exploit this in the forthcoming. I must stress once more that this is a standard technique and that no ingenuity of my part was needed in writing up this argument. If you have never heard some of these terms before and are curious to learn more, I would recommend these course notes, which is where I first learnt these ideas from: https://websites.math.leidenuniv.nl/algebra/ant.pdf.

Continuing with the proof, I claim that $$x + \sqrt{-2}$$ and $$x - \sqrt{-2}$$ are coprime elements. Indeed, any element dividing them must also divide their difference $$-2\sqrt{-2} = \sqrt{-2}^3$$. It thus suffices to show that $$\sqrt{-2}$$ does not divide $$x + \sqrt{-2}$$, or alternatively, that it does not divide $$x$$. To this end, we note that $$x$$ must be odd. Indeed, if it were even, then so must $$y$$ have been, but then both $$x^2$$ and $$y^5$$ would have been divisible by $$4$$, contradicting the given equation. Hence $$x$$ must be odd, and from this, it follows very easily that $$\sqrt{-2}$$ does not divide $$x$$.

The product of two coprime elements being a fifth power implies that up to units, they must be fifth powers themselves. Since $$R^{\times} = \{ \pm 1 \}$$, this yields certain $$a, b \in \mathbb{Z}$$ such that $$x + \sqrt{-2} = ( a + b\sqrt{-2})^5.$$ When expanding the right hand side, one notices that every term containing $$\sqrt{-2}$$ will contain a factor of $$b$$. However, this coefficient must equal $$1$$, and as such, $$b = \pm 1$$. Now we must explicitly write out $$(a \pm \sqrt{-2})^5 = (a^5 - 20a^3 + 20a) \pm (5a^4-20a^2+4)\sqrt{-2}.$$ One quickly checks that $$5a^4 - 20a^2 + 4 \neq \pm 1$$ for $$a \in \mathbb{Z}$$. This is a contradiction, showing that there can be no solutions, completely solving the equation.

The difficulty of trying to generalise this argument to the equation $$x^2 - y^5 = 2$$ is that in that case, one must factor over the ring $$\mathbb{Z}[\sqrt{2}]$$, but this ring has infinitely many units, as $$\sqrt{2}+1$$ has infinite order in $$\mathbb{Z}[\sqrt{2}]^{\times}$$. So even though the first part of the argument works fine, we would reduce to having to solve $$x + \sqrt{2} = (\sqrt{2}+1)^k (a + b\sqrt{2})^5,$$ which seems rather tricky at first sight, considering we have an extra factor whose explicit coefficients might be controllable to some extent, but which certainly complicate matters considerably.

Let me end with a remark regarding one of the other comments, identifying the solution $$(\pm 5)^2 + 2 = 3^3$$ had the exponent in the question been $$3$$ instead of $$5$$. The argument above completely solves that case as well, but this time, has the added satisfying step of actually finding the non-trivial solution. Indeed, the argument proceeds identically, until we have reduced to solving $$x + \sqrt{-2} = (a \pm \sqrt{-2})^3 = (a^3 - 6a) \pm (3a^2 - 2)\sqrt{-2}.$$ Indeed, the equation $$3a^2 - 2 = \pm 1$$ has the solution $$a = \pm 1$$. This yields $$x = a^3 - 6a = \pm 5$$, recovering our non-trivial solution and showing its uniqueness.