Find all (n,m,p) such that $n^{2}-5p^{m}=1$

96 Views Asked by At

We have to find all solutions to $n^{2}-5p^{m}=1$ where m, n are naturals and p is prime. So far we have found 3 solutions: n=4,m=1,p=3; n=6,m=1,p=7; n=9,m=4,p=2

Not sure how to proceed. Are there any more solutions? Perhaps there are some restrictions applicable to m,n,p?

1

There are 1 best solutions below

2
On BEST ANSWER

An important special case: assume $p$ is odd.

Write your equation as $$n^2-1=5p^m\implies (n-1)(n+1)=5p^m$$

Then, $n$ is even, $\gcd(n-1,n+1)=1$, and we must have that $p^m$ divides one or the other of $n\pm 1$. But in that case the other factor must be either $5$ or $1$. Thus $n=6$ or $n=4$.

Now say $p=2$. Then $n$ must be odd, $\gcd(n-1,n+1)=2$, and $2^{m-1}$ must divide one of $n\pm 1$. Again we get that the other factor must be $2$ or $2\times 5$.