In fact, the number of elements of each order can be obtained simply from the knowledge of the existence of a primitive root. For let
be a primitive root; we will calculate the order of
for any integer
. To do this, just note that
is the smallest number
such that
. But
iff
; letting
, this is equivalent to
. Since
and
are relatively prime, the smallest value of
is
. Thus, we have shown that the order of
is
for each
. In particular, the various primitive roots are the numbers
, where
is relatively prime to
.
Another consideration is
th powers. Since the nonzero elements of
are
, the
th powers are
. But these may not all be different. How many distinct
th powers do we have? Well,
iff
. Letting
, this is the same as having
; equivalently (by coprimality),
. Since
range from
to
, it is evident that, for any fixed
, there are exactly
possible values of
satisfying
. Thus, in our list
, each number occurs
times. Dividing out, we then see that there are exactly
nonzero
th powers in
(other than zero, which we still disdain). Moreover, each such
th power has exactly
th roots.
Lest this get too abstract, let's take an example:
. With some experimentation, we can find that
is a primitive root modulo
; its successive powers are
In group-theoretic terms (which may make all these considerations clearer), we've shown that the group of nonzero elements of
under multiplication is isomorphic to the group of integers modulo
under addition. Taking
th powers in
corresponds to multiplying by
in the additive formulation.
Let's look at some other exciting implications. For example, there's the ever-famous
Theorem. (Wilson's Theorem) If
is an odd prime,
.
Proof. Let
be a primitive root. Then,
are equal, in some order, to
. So,
is congruent to
. Now,
, but
since
is not divisible by
(what with
being odd). However, the equation
can only have two solutions in
, so these must be
and
. We conclude
, proving Wilson's theorem. depth-1pt height7pt width6pt
That was a little cheesy since Wilson's theorem can be proven in a better way. In fact, consider the polynomial
. It has
roots in
, namely
. By our earlier observations concerning the factorization of polynomials, we can completely factor
. Now Wilson's theorem -- along with, indeed, the values of all the elementary symmetric polynomials in the elements of
-- falls out by comparing coefficients. More generally, we can use this technique to compute the elementary symmetric polynomials in the
th roots of
, for each
.
This next result should look familiar.
Fact. Let
be an odd prime. A nonzero element
is a square iff
.
Proof. Let
with
a primitive root. Then
is a square iff
is even (this doesn't depend on the choice of
, since the possible values of
for a given
all differ from each other by multiples of the even number
). But
is even
. Since
, we are done. depth-1pt height7pt width6pt
More generally, if
, the same argument shows that
is a
th power iff
.
Fact. Let
be an odd prime. Then
is a square modulo
iff
.
Proof. Use the above and the fact that
if
,
if
. depth-1pt height7pt width6pt
Another application of the theory we've developed is to the solution of Diophantine equations (over the integers, not
!). The following illustrates the general technique.
Problem. (IMO proposal, 1985) For
, let
be positive integers such that
Solution. First note that if
for any
, then
(or
if
) must divide
, so
also. Proceeding by induction shows that all the
are
in this case. Thus, we see that either none of the
are equal to
or all of them are. We will assume the former and obtain a contradiction.
Let
be the smallest prime factor of
, for each
. By cyclic rotation, we may assume
. In particular,
. Furthermore,
, since
, which is odd. Now, if
is the order of
modulo
, we have
, so in particular
. But also
, since
. However, all the prime factors of
are greater than
; consequently, we are forced to have
. This means that
, an impossibility. This is the desired contradiction. depth-1pt height7pt width6pt
See the exercises for more examples of this sort.