# Show that there are infinitely many primes $p$ such that $p = 1 (\mod q)$ in a very specific way

I friend of mine has shown the following:

Let $n \in \mathbb{N}$, and $q$ an odd prime number. Any $p$ dividing $1 + n + \cdots + n^{q-1}$ satisfies $p \equiv 1 (\mod q)$, whenever $n \not \equiv 1 (\mod p)$ .

I have to use this result to show that there are infinitely many primes $p$ such that $p = 1 (\mod q)$.

Given $q \in \mathcal{P} \setminus \{ 2 \}$, we have to show that the set of primes dividing one of the numbers $\{ 1 + n + \cdots + n^{q-1} \ : \ n \in \mathbb{Z}\}$ is not bounded.

For $n=1$ we take $m_n=1$.

We describe $$P_n \quad = \quad \{ \ p \in \mathcal{P} \quad : \quad \ p \ | \ 1 + m_n + \cdots + m_n^{q-1} \}$$ And we define $$m_{n+1} \ = \ \prod_{p \in A_n}p \quad \text{ where } \quad A_n \ = \ P_1 \cup \cdots \cup P_n$$

Repeating this helps us to make the set of numbers dividing $1 + n + \cdots + n^{q-1}$ as big as we need. It only remains to avoid that there are not "too many" cases where $m_k = 1 (\mod p)$ where $p$ is one of the primes dividing $1 + m_{k-1} + \cdots + m_{k-1}^{q-1}$. I'd say that it must be all right for very big $n$, but I find it hard to astablish it.

I hope that you can help me to put an end on this approach, or find a better one. Thanks.

Here's another approach: suppose there are finitely many $p_1,p_2,\dots,p_k$, and take $n=qp_1p_2 \cdots p_k$ (if there are no such primes, we follow the usual convention that a product of $0$ things is $1$). Let $p$ be a prime divisor of $1+n+\cdots+n^{q-1}$. Then according to your friend, $p$ is a prime that is $1$ mod $q$ or else $n=1$ mod $p$. If $n=1$ mod $p$, then $q=1+n+\cdots+n^{q-1}=0$ mod $p$ so $p$ must be $q$, contradicting $n=0$ mod $q$. Thus $p=1$ mod $q$, and $p$ is not one of $p_1,\dots,p_k$, contradiction.
• I still don't understand your answer. I see now that $(1+n+\cdots + n^{q-1}) (\mod p) \equiv 1$ for each prime of those primes $p$, but what do you deduce from that? – Koenraad van Duin Sep 25 '14 at 20:30