login
A253630
Number of iterations of A253629 needed for n to reach 2.
1
0, 2, 1, 3, 2, 3, 2, 4, 3, 4, 3, 4, 3, 5, 3, 5, 4, 5, 4, 5, 4, 5, 4, 6, 4, 6, 4, 6, 5, 5, 4, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 6, 5, 7, 5, 6, 5, 6, 6, 7, 5, 7, 6, 7, 5, 7, 6, 7, 6, 6, 5, 7, 5, 7, 6, 7, 6, 7, 6, 7, 6, 7, 6, 8, 6, 7, 6, 7, 6, 8, 6, 7, 6, 8, 6, 8, 6
OFFSET
2,2
COMMENTS
If x or y is odd, then a(xy) = a(x) + a(y).
If x and y are both even, then a(xy) = a(x) + a(y) + 1.
Equivalently, if we define a function D by D(x) = a(x) if x is odd and D(x) = a(x) + 1 if x is even, then D is completely additive.
MATHEMATICA
L[n_] := If[EvenQ[n], (1/3) If[n > 1, n Times @@ (1 + 1/(Select[Divisors[n], PrimeQ])), 1], If[n > 1, n Times @@ (1 + 1/(Select[Divisors[n], PrimeQ])), 1]]; Table[Length@NestWhileList[L, n, # != 1 &] - 2, {n, 2, 260}]
PROG
(PARI) a253629(n) = my(f=factor(n)); prod(i=1, #f~, f[i, 1]^(f[i, 2]-1)*if(f[i, 1]>2, f[i, 1]+1, 1)) ;
a(n) = my(nb = 0); my(m = n); while(m != 2, m = a253629(m); nb++); nb; \\ Michel Marcus, Jan 21 2015
CROSSREFS
Cf. A253629.
Sequence in context: A070804 A303429 A303656 * A362938 A104481 A078709
KEYWORD
nonn
AUTHOR
Colin Defant, Jan 06 2015
STATUS
approved