login
a(n) is the number of steps to reach 0 or the start of a cycle using the iteration x -> |sigma(x)-2*x| starting from x=n.
0

%I #60 Mar 01 2026 13:59:46

%S 0,1,2,1,2,1,2,1,3,2,3,2,3,2,2,1,2,3,4,2,3,2,3,3,5,3,3,1,2,3,4,1,4,3,

%T 3,5,6,2,3,3,4,3,4,2,3,3,4,2,5,3,4,2,3,3,3,2,4,4,5,3,4,2,3,1,4,3,4,3,

%U 4,2,3,5,6,4,4,3,5,3,4,4,5,3,4,3,3,4,4,2,3,4,3,2,5

%N a(n) is the number of steps to reach 0 or the start of a cycle using the iteration x -> |sigma(x)-2*x| starting from x=n.

%C Every number's next step in its path is abs(A033879) or abs(A033880), which is its aliquot difference.

%C The only 2-cycle loop known is between 45840 and 51168. Since they are in a loop already and take 0 steps to reach the loop, a(45840)=a(51168)=0. Higher loop sizes exist as well in A371921.

%F a(p) = a(p-1) + 1.

%F a(2^n) = 1.

%F a(perfect) = 1.

%F a(2p) = a(p-3) + 1.

%F a(triperfect) = 0.

%e a(9)=3: iteration 9 -> 5 -> 4 -> 1 (-> 1).

%e a(60)=3: iteration 60 -> 48 -> 28 -> 0.

%e a(45840)=0: iteration 45840 (-> 51168 -> 45840).

%t a[0] = a[1] = 0; a[n_] := a[n] = 1 + a[Abs[DivisorSigma[1, n] - 2*n]]; Array[a, 100] (* _Amiram Eldar_, Jan 29 2026 *)

%o (PARI) a(n) = my(c=0, M=Map()); while(n && !mapisdefined(M,n), mapput(M,n,c); c++; n=abs(sigma(n)-2*n)); if(n,mapget(M,n),c) \\ _Andrew Howroyd_, Jan 20 2026

%Y Cf. A033879, A033880.

%Y Cf. A068403, A371921.

%Y Cf. A098007, A098008.

%Y Cf. A113285.

%Y Cf. A000396, A005820.

%K nonn

%O 1,3

%A _Miles Reed_, Jan 13 2026