Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).
%I #7 May 09 2020 18:03:09
%S 1,2,1,3,2,1,4,2,1,5,4,2,3,2,1,6,2,1,7,6,2,3,2,1,8,4,2,3,2,1,9,6,2,3,
%T 2,1,10,4,2,3,2,1,11,10,4,7,6,2,3,2,1,12,4,2,3,2,1,13,12,4,7,6,2,3,2,
%U 1,14,6,2,3,2,1,15,8,4,7,6,2,3,2,1,16,8,4,7,6,2,3,2,1
%N Irregular table read by row: the n-th row gives values of successively iterating phi, phi and sigma, starting with the initial value n, until the value 1 is reached. If 1 is never reached, row n contains n, -1.
%H L. Alaoglu and P. Erdős, <a href="http://dx.doi.org/10.1090/S0002-9904-1944-08257-8">A conjecture in elementary number theory</a>, Bull. Amer. Math. Soc. 50 (1944), 881-882.
%e Table begins:
%e 1
%e 2, 1
%e 3, 2, 1
%e 4, 2, 1
%e 5, 4, 2, 3, 2, 1
%e 6, 2, 1
%e 7, 6, 2, 3, 2, 1
%e 8, 4, 2, 3, 2, 1
%e ...
%e For n = 5, phi(5) = 4, phi(4) = 2, sigma(2) = 3, phi(3) = 2, and phi(2) = 1, therefore the 5th row is 5, 4, 2, 3, 2, 1.
%t f[n_, i_] := If[Mod[i, 3] == 0, DivisorSigma[1, n], EulerPhi[n]]; g[n_] := Module[{i = 1, k = n, s = {}}, While[AppendTo[s, k]; k > 1, k = f[k, i++]]; s]; Array[g, 16] // Flatten
%Y For other versions, see A032452, A334523.
%Y Cf. A000010 (phi), A000203 (sigma), A334685, A334686.
%K nonn,tabf
%O 1,2
%A _Amiram Eldar_, May 09 2020