# Primes p Such That 2 is a Primitive Root Modulo p

Raymond Fuller 20 October 2008

1

Introduction

Let a and m be integers, m > 1, and gcd(a, m)=1. We say that a is a primitive root modulo m if (Z/mZ)∗ is cyclic and a is a generator of (Z/mZ)∗ . The Primitive Root Theorem characterizes those moduli m such that (Z/mZ)∗ is cyclic. Of course, if p is a prime, then (Z/pZ)∗ is cyclic, and so there always exists a primitive root modulo p. In this paper we present some elementary results about primes p such that 2 is a primitive root modulo p. In what follows we will make use of an equivalent though more convenient deﬁnition for a primitive root modulo m. As before, let a, m ∈ Z, m > 1, gcd(a, m) = 1. Let ordm (a) (the order of a modulo m) be the smallest positive integer k such that ak ≡ 1 (mod m). Such an integer k always exists, since by Euler’s Theorem, we know that aφ(m) ≡ 1 (mod m), where φ(n) denotes the Euler phi-function. Then a is a primitive root modulo m if and only if ordm (a) = φ(m). If p is a prime, then φ(p) = p − 1, so a is a primitive root modulo p if and only if ordp (a) = p − 1. We now collect some elementary classical results to be used later. Recall that ordm (a) | φ(m), so in particular ordp (2) | p − 1 when p is prime (note that ordp (2) = 1). These two properties of the Legendre Symbol will also be used: If p is an odd prime, then 2 p 2 p = (−1)(p ≡ 2(p−1)/2 (mod p) 1, if p ≡ 1, 7 (mod 8) -1, if p ≡ 3, 5 (mod 8) (1)

2 −1)/8

=

(2)

2

Elementary Results

Proposition 1: Let p be an odd prime. If 2 is a primitive root modulo p then 2 is a quadratic nonresidue modulo p. 1

but no higher power of 2 can appear. p = 1. This fact together with Proposition 1 gives the desired result. 5 (mod 8). Proof: The smallest prime of this form is p = 13. Proposition 2: Let p be an odd prime. Proof: By (2). and 2 | p − 1. A Mersenne prime is deﬁned to be a prime of the form 2p − 1 with p prime. ordp (2) = 2q . But then 1 ordp (2) ≤ p− < p − 1 = ordp (2). it may be veriﬁed that 2 is not a primitive root modulo 43. Proposition 2 tells us that 2 is not a primitive root modulo p whenever p is a Fermat prime greater than 5 and whenever p is a Mersenne prime greater than 3. 2 is not a primitive root modulo p. since p ≥ 7). 5 (mod 8). and it can be veriﬁed directly that 2 is a primitive root modulo 13. then by Proposition 2. then p ≡ 3. Proposition 3: Let p be an odd prime. 5 (mod 8). Then by (1). If 8 | p − 1 then 2 is not a primitive root modulo p. For every other prime of this form. and Mersenne primes greater than 3 are congruent to 7 (mod 8). The converse of Proposition 2 does not hold in general. Conversely. Proof: If 8 | p − 1 then p ≡ 1 (mod 8). 5 (mod 8).Proof: Since 2 is a primitive root modulo p. If 2 is a primitive root modulo p. n A Fermat prime is deﬁned to be a prime of the form 22 + 1. then 2 is a primitive root modulo p if and only if q ≡ 1. Then 2q ≡ 1 (mod p). p ≡ 3. Proof: If 2 is a primitive root modulo p. Proposition 5: If p is a prime of the form p = 4q + 1 for some odd prime q . we must have p ≡ 3 (mod 8). then p − 1 is even. But by (2). let q ≡ 1. Now ordp (2) is either q or 2q (it cannot be 2. 7 (mod 8). a contradiction. For example. then 2 is a primitive root modulo p. Proposition 3 tells us that if 2 is a primitive root modulo p. a contradiction. and so by Proposition 2. this means that p ≡ 1. 2 is a quadratic nonresidue modulo an odd prime p if and only if p ≡ 3. 2(p−1)/2 ≡ 1 (mod p). So. We see at once that we must have q ≡ 1. Proposition 4: If p is a prime of the form p = 2q + 1 for some odd prime q . 5 (mod 8). 2 or 4 appear in the prime factorization of p − 1. Fermat primes greater than 5 are congruent to 1 (mod 8). 2 Assume ordp (2) = q . Assume p is a quadratic residue modulo p. So 2 is a quadratic nonresidue 2 modulo p. 5 (mod 8). If p is an odd prime. 5 (mod 8). ordp (2) 2 . ordp (2) = p − 1. and 2 is a primitive root modulo p. But since q ≡ 1. and so by (1).

7 (mod 8). If p is a prime of this form. So. this limit converges trivially if there are only ﬁnitely many primes p such that ν (p − 1) = 2. p ≡ 1. then ordp (2) is one of {4q. But since p is of the given form. But since p is of the given form. p = 1. and by Proposition 3 we know that no greater power of 2 can appear in the prime factorization of p − 1. . . . 2q . then p − 1 has exactly two prime divisors (i. ν (p − 1) = 2). we must have p ≡ 1. 4q. Proposition 5 says that this limit is 1 and for ﬁxed k . 7 (mod 8). . we deﬁne two functions. Primes of this form are the “most likely” to have ordp (2) = 4q k . 13 is the smallest prime of this form. . For all other primes of this form. Proposition 6: If p is a prime of the form p = 4q k + 1 for some odd prime q and some positive integer k . Then 2 = 1 by (1). and so by (2). and 2 is a primitive root modulo p. . I wish to add as a ﬁnal remark that for small values of k . ordp (2) is one of {2q. 4q 2 . k Notice that for a prime of the form p = 4q k + 1. . a contradiction.is one of q . Then by (1).. so the statement holds. 4q 2 . 4q k }. ordp (2) = 4q . p ≡ 5 (mod 8). 22q ≡ 1 (mod p). implying 2 is a primitive root modulo p. we have eliminated more than half of the possible orders for 2 modulo p. . What is the behavior of this limit as k varies? Of course. and therefore ordp (2) is one of {4q. examine limx→∞ C k ( x) for k = 1. . p ≡ 5 (mod 8). the overwhelming majority of primes of the form p = 4q k + 1 have ordp (2) = 4q k . and so p (2). By 22q ≡ 1 (mod p). or 4q . So. . 2q 2 . The cases ordp (2) = q and ordp (2) = 2q both imply that 2 22q ≡ 1 (mod p). In an attempt to do so. .e. 4q 2 . in the sense that primes of this form have the fewest possible orders for 2 modulo p. a contradiction. and ord13 (2) = 12. I F k ( x) plan to examine limx→∞ C for small values of k in section 3 of this paper (not k (x) yet completed). 4q k }. as follows: Fk (x) := #{p < x | p = 4q k +1 is a prime for some odd prime q and ordp (2) = 4q k } Ck (x) := #{p < x | p = 4q k + 1 is a prime for some odd prime q } F k ( x) . Do there exist inﬁnitely many primes p such that ν (p − 1) = 2? Do there exist inﬁnitely many primes of the form p = 4q k + 1? I realize these are all diﬃcult unsolved questions (and I certainly do not claim to be able to answer them). Assume ordp (2) = 2q for some 1 ≤ ≤ k . . Therefore. 4q k }. Proof: As before. 2q k . ordp (2) = 2q for any 1 ≤ ≤ k . 3 . It would be preferable to make this notion more precise.