3527 Lecture 26 Primitive Roots
3527 Lecture 26 Primitive Roots
Lecture #26
Primitive Roots:
Primitive Roots (In General)
Primitive Roots in Finite Fields
Primitive Roots in Z/mZ
This material represents §4.3.3 from the course notes.
Primitive Roots, I
Examples:
If R is the ring F2 [x] modulo x 2 + x + 1, which we have
previously established is a field, the elements x and x + 1 are
primitive roots in R, since R has 3 units and each element has
order 3 (their orders divide 3 by Euler’s theorem, and neither
element has order 1).
If R is the ring F3 [x] modulo x 2 + 1, which is also a field,
then the element x + 1 is a primitive root in R, since R has 8
units and x + 1 has order 8 (its order divides 8 by Euler’s
4
theorem, and x + 1 = 2 so its order does not divide 4).
Primitive Roots, III
Example: If R is the ring F7 [x] modulo x 2 , show that the element
x + 3 is a primitive root in R.
Primitive Roots, III
Example: If R is the ring F7 [x] modulo x 2 , show that the element
x + 3 is a primitive root in R.
Note that R is not a field because x 2 is not irreducible.
Indeed, the units in R are the elements that are relatively
prime to x, which have the form ax + b where b 6= 0.
To be a unit, there are 7 possible choices for a and 6 choices
for b, so there are 7 · 6 = 42 total units in R.
Thus to show x + 3 is a primitive root, we need to show it has
order 42.
By Euler’s theorem, we know its order divides 42.
Furthermore, by successive squaring, we can compute
21 14 6
x + 3 = 6, x + 3 = 2, and x + 3 = 2x + 1.
This means that the order of x + 3 cannot divide 21, 14, or 6,
so it must be 42: it is therefore a primitive root.
Primitive Roots in Finite Fields, I
Our next goal is to prove that every finite field has a primitive root.
We first recall some basic properties of orders:
Proposition (Properties of Orders)
Suppose R is a commutative ring with 1 and u is a unit in R.
1 If u n ≡ 1 (mod m) for some n > 0, then the order of u is
finite and divides n.
2 If u has order k, then u n has order k/ gcd(n, k). In particular,
if n and k are relatively prime, then u n also has order k.
3 If u n ≡ 1 (mod m) and u n/p 6= 1 (mod m) for any prime
divisor p of n, then u has order n.
4 If u has order k and w has order l, where k and l are
relatively prime, then uw has order kl.
Proof:
Suppose u has order M and let w be a unit of order k.
If k does not divide M, there is some prime q which occurs to
a higher power q f in the factorization of k than the
corresponding power q e dividing M.
f e
Then u q has order M/q f while w k/q has order q e .
Since these two orders are relatively prime, the element
f e
u q · w k/q has order M · q f −e , which is a contradiction
because this is larger than M. Hence k divides M as claimed.
Primitive Roots in Finite Fields, III
Proof:
Suppose M is the maximal order among all units in F , and let
|F | denote the number of elements in F .
Then by the finite-field version of Euler’s theorem, we know
that M ≤ |F | − 1, since a|F |−1 = 1 in F for every unit a ∈ F .
By our preliminary Proposition, all units in F then have order
dividing M.
This means that the polynomial x M − 1 has |F | − 1 roots in F .
But this is impossible unless M ≥ |F | − 1, since a polynomial
of degree M can only have at most M roots in F .
Hence we conclude M = |F | − 1, meaning that some element
has order |F | − 1: this element is a primitive root.
Primitive Roots Modulo p d , I
Proof (continued):
We want to show that a cannot have order p d−1 (p − 1).
By Euler’s theorem, ap−1 ≡ 1 (mod p) so we can write
ap−1 = 1 + kp for some integer k.
Then, since a is a primitive root modulo p 2 , we also know
that k is not divisible by p (as otherwise a would have order
p − 1 modulo p 2 ).
Expanding with the binomial theorem yields
d−1 d−1
(ap−1 )p = (1+kp)p = 1+p d−1 ·kp +p d+1 ·[other terms].
But this is 6≡ 1 modulo p d+1 , since k is not divisible by p.
d−1
Hence ap (p−1) 6≡ 1 (mod p d+1 ), so a must have order
p d (p − 1) = ϕ(p d+1 ), meaning a is in fact a primitive root.
Primitive Roots Modulo p d , VII
Proof:
d
If a is odd, then a, a2 , ... , aϕ(p ) are odd and distinct modulo
p d , so they remain invertible and distinct modulo 2p d .
d
But since ϕ(2p d ) = ϕ(p d ), the elements a, a2 , ... , aϕ(p )
exhaust all of the distinct unit residue classes modulo 2p d .
Thus, a is a primitive root modulo 2p d .
If a is even, then a + p d is odd, and so by the argument
above, we see a + p d is a primitive root modulo 2p d .
Primitive Roots Modulo m, II
Examples:
Since 27 = 33 is an odd prime power, there is a primitive root
modulo 27.
Since 33 = 3 · 11 is not of the required form, there is no
primitive root modulo 33.
Since 64 = 26 is not of the required form, there is no primitive
root modulo 64.
Since 2662 = 2 · 113 is twice an odd prime power, there is a
primitive root modulo 2662.
Primitive Roots Modulo m, IV
We have already shown the existence of primitive roots in all of the
listed cases except m = 1, 2, 4 (but these cases are trivial). All we
have left to do is show that a primitive root cannot exist for other
m. Before giving the proof, we establish a simple Lemma:
Lemma
If there exists a primitive root r modulo m, then the congruence
u 2 ≡ 1 (mod m) has only the two solutions u = ±1 (mod m).
Proof:
If u 2 ≡ 1 (mod m) then u is a unit, so since r is a primitive
root, we can write u = r d for some 0 ≤ d < ϕ(m).
Then u 2 ≡ r 2d ≡ 1 mod m, so since r has order ϕ(m) there
are only two possible d, namely d = 0 and d = ϕ(m)/2.
Thus there are only two possible u (namely u = ±1).
Primitive Roots Modulo m, V
Proof (of main Theorem):
We will show that if m is not of the given form, then there are
more than two solutions to u 2 ≡ 1 (mod m), which by the
Lemma will show that m cannot have a primitive root.
First, suppose m = 4p for some prime p (including p = 2).
Then x ≡ ±1 and x ≡ ±(2p − 1) have x 2 ≡ 1 (mod 4p).
Second, suppose m = pq for some distinct primes p and q: by
the Chinese Remainder Theorem, there are four solutions to
x 2 ≡ 1 (mod pq), obtained by solving the congruences
x ≡ ±1 (mod p) and x ≡ ±1 (mod q) simultaneously.
To finish the argument, note that if r is a primitive root
modulo m and d|m, then r is a primitive root modulo d.
Running this backwards, we see that if m is divisible by 4p or
by pq, then m has no primitive root.
This encompasses all of our required cases, so we are done.
Primitive Roots Modulo m, VI
For completeness, we restate a result we showed previously about
the number of primitive roots modulo m:
Proposition (Number of Primitive Roots)
If there exists a primitive root modulo m, then there are precisely
ϕ(ϕ(m)) primitive roots modulo m.
Proof:
Suppose that there is a primitive root u modulo m.
The units modulo m are represented by u 1 , . . . , u ϕ(m) , so it
suffices to determine which of these have order ϕ(m).
Since the order of u k is ϕ(m)/ gcd(k, ϕ(m)), we see that u k is
a primitive root if and only if k is relatively prime to ϕ(m).
There are ϕ(ϕ(m)) such k, so there are ϕ(ϕ(m)) primitive
roots modulo m.
Primitive Roots Modulo m, VII
Examples:
The number of primitive roots modulo 41 is equal to
ϕ(ϕ(41)) = 16 since 41 is a prime number, hence there are
primitive roots mod 41.
The number of primitive roots modulo 232020 is equal to
ϕ(ϕ(232020 ) = 10 · 22 · 232018 , since 232020 is an odd prime
power.
The number of primitive roots modulo 2662 is equal to
ϕ(ϕ(2662)) = 440 since 2662 = 2 · 113 is twice an odd prime
power, hence there are primitive roots mod 2662.
The number of primitive roots modulo 242020 is equal to 0,
because 242020 = 26060 32020 is not of the correct form.
Summary