TITLE: Solving the following Diophantine equation: $m^2=n^5-5$
QUESTION [19 upvotes]: I need to find all integer solutions to $m^2=n^5-5$, yet I can't seem to find a good strategy. Here what I attempted:
Taking mod 5, we see that $n^5-5\equiv n\pmod{5}$ using Fermat's little theorem. We see that $m^2\equiv 0, 1, 4\pmod{5}$ for any $m$, so $n\equiv 0, 1, 4\pmod{5}$. We also see by mod 4, $n^5-5\equiv n-1\pmod{4}$, so and since $m^2\equiv 0, 1\pmod{4}$, we see that $n\equiv 1, 2\pmod{4}$. However, I don't even know where to go from here. I'm also relatively new to diophantine equations, so I don't even know if I am on the right path. Can anyone please help or give me a hint?

REPLY [8 votes]: If $(m,n)$ is an integral solution to the equation then
$$n^5=m^2+5=(m+\sqrt{-5})(m-\sqrt{-5}),$$
where the two factors on the right hand side are coprime. Then the ideals they generate in $\Bbb{Z}[\sqrt{-5}]$ are both fifth powers of ideals, and as the class number of $\Bbb{Z}[\sqrt{-5}]$ equals $2$, these are again principal ideals. It follows that
$$m+\sqrt{-5}=(a+b\sqrt{-5})^5=(a^5-50a^3b^2+125ab^4)+(5a^4b-50a^2b^3+25b^5)\sqrt{-5},$$
for some intgers $a$ and $b$, and comparing the coefficients of $\sqrt{-5}$ then shows that $5$ divides $1$, a contradiction. Hence the original equation has no integral solutions.