|
|
A092693
|
|
Sum of iterated phi(n).
|
|
27
|
|
|
0, 1, 3, 3, 7, 3, 9, 7, 9, 7, 17, 7, 19, 9, 15, 15, 31, 9, 27, 15, 19, 17, 39, 15, 35, 19, 27, 19, 47, 15, 45, 31, 35, 31, 39, 19, 55, 27, 39, 31, 71, 19, 61, 35, 39, 39, 85, 31, 61, 35, 63, 39, 91, 27, 71, 39, 55, 47, 105, 31, 91, 45, 55, 63, 79, 35, 101, 63, 79, 39, 109, 39, 111
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,3
|
|
COMMENTS
|
Iannucci, Moujie and Cohen examine perfect totient numbers: n such that a(n) = n.
|
|
LINKS
|
P. Erdos and M. V. Subbarao, On the iterates of some arithmetic functions, The theory of arithmetic functions (Proc. Conf., Western Michigan Univ., Kalamazoo, Mich. 1971), Lecture Notes in Math., 251 , pp. 119-125, Springer, Berlin, 1972. [alternate link]
|
|
FORMULA
|
a(1) = 0, a(n) = phi(n) + a(phi(n))
Erdős & Subbarao prove that a(n) ~ phi(n) for almost all n. In particular, a(n) < n for almost all n. The proportion of numbers up to N for which a(n) > n is at most 1/log log log log N. - Charles R Greathouse IV, Mar 22 2012
|
|
EXAMPLE
|
a(100) = 71 because the iterations of phi (40, 16, 8, 4, 2, 1) sum to 71.
|
|
MATHEMATICA
|
nMax=100; a=Table[0, {nMax}]; Do[e=EulerPhi[n]; a[[n]]=e+a[[e]], {n, 2, nMax}]; a (* T. D. Noe *)
Table[Plus @@ FixedPointList[EulerPhi, n] - (n + 1), {n, 72}] (* Alonso del Arte, Jan 29 2007 *)
|
|
PROG
|
(Haskell)
a092693 1 = 0
a092693 n = (+ 1) $ sum $ takeWhile (/= 1) $ iterate a000010 $ a000010 n
(Python)
from sympy import totient
from math import prod
def f(n):
m = n
while m > 1:
m = totient(m)
yield m
|
|
CROSSREFS
|
Cf. A003434 (iterations of phi(n) needed to reach 1), A092694 (iterated phi product).
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|