PrimitiveRootList

PrimitiveRootList[n]
gives a list of primitive roots of n.

DetailsDetails

  • A primitive root is a generator for the multiplicative group of integers modulo n relatively prime to n.
  • PrimitiveRootList[n] returns an empty list if n is not , an odd prime power, or twice an odd prime power.

ExamplesExamplesopen allclose all

Basic Examples  (1)Basic Examples  (1)

List of primitive roots of 9:

In[1]:=
Click for copyable input
Out[1]=

Primitive roots generate all integers modulo 9 that are relatively prime to 9:

In[2]:=
Click for copyable input
Out[2]=
In[3]:=
Click for copyable input
Out[3]=
Introduced in 2014
(10.0)