OFFSET
1,1
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000 (terms 1..1000 from T. D. Noe)
Max Alekseyev, PARI/GP Scripts for Miscellaneous Math Problems (invphi.gp).
David M. Bressoud, A Course in Computational Number Theory (webpage), CNT.m, Computational Number Theory Mathematica package.
EXAMPLE
For p = 97: x = {97, 119, 153, 194, 195, 208, 224, 238, 260, 280, 288, 306, 312, 336, 360, 390, 420} is the set of 17 solutions such that phi(x) + 1 = 97.
MATHEMATICA
Table[Do[s=1+EulerPhi[n]; If[Equal[s, Prime[k]], Print[{n, s}]], {n, 1, 4*Prime[k]^2}], {k, 1, 100}]
Needs["CNT`"]; Table[Solve[EulerPhi[x] == Prime[n] - 1, x][[-1, -1, -1]], {n, 100}] (* T. D. Noe, Nov 07 2011 *)
PROG
(PARI) a(n) = invphiMax(prime(n)-1); \\ Amiram Eldar, Dec 16 2024, using Max Alekseyev's invphi.gp
CROSSREFS
KEYWORD
nonn
AUTHOR
Labos Elemer, Dec 03 2001
STATUS
approved