Nothing Special   »   [go: up one dir, main page]

login
A098202
a(n) is the length of the iteration trajectory when the cototient function (A051953) is applied to the n-th primorial number (A002110(n)).
2
3, 5, 8, 12, 18, 20, 31, 32, 41, 43, 61, 65, 80, 77, 95, 125, 131, 125, 157, 173, 140, 192, 195, 221, 213, 212, 261, 269, 277, 300, 296, 321, 336, 329, 358, 367, 379, 405, 428, 439, 438, 464, 477, 493, 506, 454, 491, 542, 564, 588, 543, 600, 639, 660
OFFSET
1,1
FORMULA
a(n) = A053475(A002110(n)). - Robert G. Wilson v, Sep 22 2004
EXAMPLE
For n = 3: list = {30,22,12,8,4,2,1,0}, a(4) = 8.
MATHEMATICA
g[x_] := x - EulerPhi[x]; f[x_] := Length[ FixedPointList[g, x]] - 1; q[x_] := Product[ Prime[j], {j, x}]; Table[ f[ q[n]], {n, 33}]
a[n_] := Length@ NestWhileList[(# - EulerPhi[#])&, Times @@ Prime[Range[n]], # > 0 &]; Array[a, 30] (* Amiram Eldar, Nov 19 2024 *)
PROG
(PARI) a(n) = {my(p = prod(i=1, n, prime(i)), c = 1); while(p > 0, c++; p -= eulerphi(p)); c; } \\ Amiram Eldar, Nov 19 2024
CROSSREFS
KEYWORD
nonn,more
AUTHOR
Labos Elemer, Sep 22 2004
EXTENSIONS
More terms from Robert G. Wilson v, Sep 22 2004
a(37)-a(54) from Amiram Eldar, Nov 19 2024
STATUS
approved