[Math] Show there are infinitely many primes that are equivalent to 1 mod 8.

number theoryproof-writing

Show there are infinitely many primes that are equivalent to $1 \pmod{8}$.

Hello there!
I have been trying to do this problem for a pretty long time with no avail.

I noticed that this is really similar to Euclid's proof that there are infinitely many primes. However, I can't find a way to use that here. Can anyone help me?

Best Answer

Suppose that there are only finitely many such primes $p_1,\ldots,p_k \equiv 1 \pmod 8$. Then consider the following number $$ (2p_1\cdots p_k)^4+1, $$ which is coprime with each $p_i$, and has remainder $1$ modulo $8$. Since it is odd and greater than $1$, it has to be divisible by an odd prime $p$. Then $$ \mathrm{ord}_p(2p_1\cdots p_k)=8 $$ which divides $\varphi(p)=p-1$ by Fermat's theorem. Therefore $p$ is another prime $\equiv 1\pmod{8}$.