9

Let $p$ be a prime number. Find all $p$'s such that $p^4 + p^3 + p^2 + p +1$ is a perfect square.

I tried rewriting the expression as $p^4 + p^3 + p^2 + p +1 = x^2 \iff (p^2 + p)(p^2 + 1)=(x - 1)(x + 1)$. Then I think I need to bound this using $x$ but am not sure how to.

user19405892
  • 15,592
  • I think I've seen this question before, is it from some contest? In any case, notice that $x$ has to be odd, so you can write it as $2x'+1$. Also, I think it can be helpful to look at the possible values of $p$ and/or $x$ modulo $4$ or $5$. – Arnaud D. Jan 20 '16 at 19:17
  • 2
    http://math.stackexchange.com/questions/372367/1x-ldotsxn-perfect-square –  Jan 20 '16 at 19:19
  • This question was linked to the one given by Byron, and it seems to adress the same problem : http://math.stackexchange.com/questions/1270599/determining-all-the-positive-integers-n-such-that-n4n3n2n1-is-a-perfe?lq=1 – Arnaud D. Jan 20 '16 at 19:23
  • from the question Byron links, $$ (2x^2 + x)^2 < 4(x^4 + x^3 + x^2 + x + 1) < (2x^2 + x + 1)^2 $$ for $x$ bigger than something explicit. – Will Jagy Jan 20 '16 at 19:24
  • yes, both inequalities strict for $x > 3.$ The right hand side minus the middle term is $x^2 - 2x-3,$ roots $-1$ and $3.$ – Will Jagy Jan 20 '16 at 19:32

1 Answers1

5

Note that $p^2=q^4+q^3+q^2+q+1$ has solutions only for $p=11$ and $q=3$.

Indeed we can write $$\left(q^2+\frac{q}{2}\right)^2={q^4+q^3}+\frac{q^2}{4}<{q^4+q^3}+q^2+q+1 \\ \frac{q^2}{4}<q^2+q+1 $$ and on the other hand $$ \left(q^2+\frac{q+2}{2}\right)^2=q^4+q^3+2q^2+\frac{q^2+4q+4}{4}>q^4+q^3+q^2+q+1 \\ {q^4+q^3}+\frac{9}{4}q^2{+q+1}>{q^4+q^3}+q^2{+q+1} \\ \frac{9}{4}q^2>q^2.$$ From here, $q$ cannot be even, and for some odd $q$ we must have $$\left(q^2+\frac{q+1}{2}\right)^2={q^4+q^3+q^2}+\frac{q^2+2q+1}{4}={q^4+q^3+q^2}+q+1 \\ q^2+2q+1=4q+4 \\ q^2-2q-3=(q-3)(q+1)=0,$$ from here $q=3$. In particular, $$3^4+3^3+3^2+3+1=11^2$$ therefore the only solutions are $p=11$, $q=3$