OFFSET
1,3
COMMENTS
The original name was: "Prime preceding phi(n)". However, this is true only for n >= 7 from which onward phi(n) is guaranteed to get only composite values. For n = 3, 4 and 6 for which phi(n) = 2, a(n) = 2 also.
LINKS
Antti Karttunen, Table of n, a(n) for n = 1..16384
FORMULA
a(1) = a(2) = 0 (by convention), and for n >= 3, a(n) = A007917(A000010(n)). - Antti Karttunen, Dec 05 2017
EXAMPLE
phi(10)=4, hence a(10)=3.
MATHEMATICA
If[#<0, 0, #]&/@Table[NextPrime[EulerPhi[n]+1, -1], {n, 80}] (* Harvey P. Dale, Aug 10 2012 *)
PROG
(PARI) for (n=1, 100, print1(precprime(eulerphi(n))", "))
CROSSREFS
KEYWORD
nonn
AUTHOR
Jon Perry, Jan 09 2003
EXTENSIONS
Name changed by Antti Karttunen, Dec 05 2017
STATUS
approved