OFFSET
1,5
COMMENTS
If n has a primitive root, then it has exactly phi(phi(n)) of them (Burton 1989, p. 188), which means that if p is a prime number, then there are exactly phi(p-1) incongruent primitive roots of p (Burton 1989). - Jonathan Vos Post, Sep 10 2010
See A046144 for the number of primitive roots mod n. - Wolfdieter Lang, Mar 09 2012
REFERENCES
M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964 (and various reprintings), p. 840.
Burton, D. M. "The Order of an Integer Modulo n," "Primitive Roots for Primes," and "Composite Numbers Having Primitive Roots." Sections 8.1-8.3 in Elementary Number Theory, 4th ed. Dubuque, IA: William C. Brown Publishers, pp. 184-205, 1989.
LINKS
T. D. Noe, Table of n, a(n) for n = 1..10000
M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards, Applied Math. Series 55, Tenth Printing, 1972 [alternative scanned copy].
Paul Erdős, Andrew Granville, Carl Pomerance and Claudia Spiro, On the normal behavior of the iterates of some arithmetic functions, Analytic number theory, Birkhäuser Boston, 1990, pp. 165-204.
Paul Erdos, Andrew Granville, Carl Pomerance and Claudia Spiro, On the normal behavior of the iterates of some arithmetic functions, Analytic number theory, Birkhäuser Boston, 1990, pp. 165-204. [Annotated copy with A-numbers]
S. R. Finch, Idempotents and Nilpotents Modulo n (arXiv:math.NT/0605019)
Boris Putievskiy, Transformations [Of] Integer Sequences And Pairing Functions, arXiv preprint arXiv:1212.2732 [math.CO], 2012.
Eric Weisstein's World of Mathematics, Primitive Root.
MAPLE
with(numtheory): f := n->phi(phi(n));
MATHEMATICA
Table[EulerPhi[EulerPhi[n]], {n, 0, 200}] (* Vladimir Joseph Stephan Orlovsky, Nov 10 2009 *)
Nest[EulerPhi[#]&, Range[100], 2] (* Harvey P. Dale, Jan 13 2024 *)
PROG
(Haskell)
a010554 = a000010 . a000010 -- Reinhard Zumkeller, Dec 26 2012
(PARI) a(n)=eulerphi(eulerphi(n)) \\ Charles R Greathouse IV, Feb 06 2017
(Magma) [EulerPhi(EulerPhi(n)): n in [1..100]]; // Vincenzo Librandi, Feb 24 2018
CROSSREFS
KEYWORD
nonn,nice
AUTHOR
STATUS
approved