Generators
A unit is called a generator or primitive root of if for every we have for some integer . In other words, if we start with , and keep multiplying by eventually we will see every element, which explains the term “generator”.
Example: is a generator of since are the units of .
Example: is a generator of . From before the powers of are which are the units of .
Example: is not a generator of since the powers of are which is only half of .
Theorem: Let be a prime. Then contains exactly generators. In general, for every divisor , contains elements of order .
Proof: by Fermat's Theorem we know the equation has distinct solutions, namely every element of . Let be a prime power dividing . Then we can factorize the above where is some degree polynomial. From before we know that has at most roots and has at most roots, and since their product has different roots, we see that there are exactly distinct solutions to Any solution must have order dividing . Suppose such an has order less than . Then its order must divide , and is a solution of .
By a similar argument (which is a factor of ) has exactly distinct roots, so there must be exactly roots of that are not roots of and hence are of order . Recall .
Factorize into primes: For each we find an element with order . Since the orders of each are coprime, [[order.xhtml][the order of their product is equal to the product of their orders]], that is has order and thus is a generator.
We have choices for each thus we have exactly different generators.
A similar argument proves the theorem for the divisors of .
Alternative Proof: We can use a counting argument and basic facts about cyclic groups instead.
Any element must have order dividing (by Fermat). Then if has order , the solutions of are precisely and there are no other elements of order since has at most roots.
It is easy to show that has order if and only if , thus either there are no elements of order or there are exactly elements of order .
Now (which we can prove using multiplicative functions or cyclic groups) and if any of the were replaced with on the left-hand side, the equality would fail. Hence there must be exactly elements of order for each (since each one of the elements of must have some order).
What about powers of primes, or composite numbers in general?