I need to find all primes of the form: $n^{5}-1$.

My attempt: First I have denoted $q=n^5-1$. It appears that $n$ is even, otherwise, if $n$ is odd then $n^5$ is odd too, which means that $n^5-1$ is an even number bigger than 2. Therefore, suppose that $n=2k,\mathbb{N}\ni k >0$. Thus, we have that: $n^5-1=(2k)^5-1=32k^5-1$. If $k=1$, then we have $32-1=31$ and we get a prime number. Now I know that I can proceed and get all 32's multiples, but I don't see how to negate that there are no more prime of the given form. Thanks!

  • $\begingroup$ Hint: for $k>1$, $2k-1>1$ and $2k-1\mid (2k)^5-1$ (Edit: As I finished typing this, I discovered that Servaes gives the same hint as an answer.) $\endgroup$ Feb 13, 2021 at 19:09
  • $\begingroup$ @KeithBackman Can you explain to me why is that? $\endgroup$
    – Anon142
    Feb 13, 2021 at 19:16
  • $\begingroup$ @KeithBackman If I want to proceed in my way, since in test I was going on this way, and not on the creative way. How do I proceed proving that there is no such prime number $\neq 31$ $\endgroup$
    – Anon142
    Feb 13, 2021 at 19:17
  • $\begingroup$ Look at the factors in Servaes answer. A prime number can only have factors of $1$ and itself. Thus, if $n^5-1$ is prime, one of the factors in that answer must be $1$. It's easy to see which factor must be smaller, so the only solution is $n-1=1 \Rightarrow n=2$. Once you fix that, the other factor can only take on the value $31$. You are done. $\endgroup$ Feb 13, 2021 at 21:31

1 Answer 1


Hint: Expand the product $$(n-1)(n^4+n^3+n^2+n+1).$$

In general, when asked to find all primes of the form $P(n)$ for some polynomial with integer coefficients, it is very likely that there are only finitely many, and that they can be found by factoring the polynomial. It turns out that showing that there exist infinitely many primes of the form $P(n)$ is usually extremely difficult if $\deg P>1$, so you are unlikely to be given such an exercise.

  • 1
    $\begingroup$ thanks! I guess I missed this expansion. Now it's easier since q can be divided only by one factor of the product, while the other equals to 1. so we get $n=2$ or $n=0$, so we have only 31. Thanks a lot $\endgroup$
    – Anon142
    Feb 13, 2021 at 19:14
  • $\begingroup$ For completeness sake; you can find this expansion by noting that the polynomial $P(n)=n^5-1$ has the obvious root $n=1$, and hence a factor $n-1$. $\endgroup$
    – Servaes
    Feb 13, 2021 at 19:22
  • $\begingroup$ Got it. However, I will be glad to see if you can show me how do I proceed with my way, where I wanted to prove that there is no such another prime difference from 31. $\endgroup$
    – Anon142
    Feb 13, 2021 at 19:24
  • $\begingroup$ @Anon142 I do not see a way to proceed with your approach; you will need to show that $n^5-1$ is composite for all $n>2$. Using modular arithmetic you can exclude ever more residue classes (like your consideration mod 2), but never all integers $n>2$. $\endgroup$
    – Servaes
    Feb 13, 2021 at 19:26
  • $\begingroup$ Got you. Well, thank you! $\endgroup$
    – Anon142
    Feb 13, 2021 at 19:27

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .