A257669 Number of terms in the sigma(x) -> x subtree whose root is n.
1, 1, 2, 3, 1, 2, 4, 5, 1, 1, 1, 4, 2, 3, 6, 1, 1, 3, 1, 2, 1, 1, 1, 11, 1, 1, 1, 5, 1, 2, 3, 5, 1, 1, 1, 2, 1, 2, 4, 2, 1, 5, 1, 2, 1, 1, 1, 4, 1, 1, 1, 1, 1, 3, 1, 10, 2, 1, 1, 15, 1, 2, 6, 1, 1, 1, 1, 2, 1, 1, 1, 7, 1, 2, 1, 1, 1, 2, 1, 4, 1, 1, 1, 5, 1, 1
Offset: 1
Keywords
Examples
For n = 2, a(2) = 1, since there is no x such that sigma(x) = 2, so the subtree with root 2 is reduced to a single node: 2. For n = 3, since sigma(2) = 3, the tree with root 3 has 2 nodes: 2 and 3, hence a(3) = 2.
Links
- M. F. Hasler, Table of n, a(n) for n = 1..10000, Nov 20 2019
- M. Alekseyev, PARI/GP Scripts for Miscellaneous Math Problems: invsigma.gp, Oct. 2005
- G. L. Cohen and H. J. J. te Riele, Iterating the sum-of-divisors function, Experimental Mathematics, 5 (1996), pp. 91-100.
Crossrefs
Programs
-
PARI
A257669_vec(N)={my(C=Map(),s,c); vector(N,n,mapput(C,s=sigma(n), if(mapisdefined(C,s), mapget(C,s))+ c=if(mapisdefined(C,n), mapget(C,n) + mapdelete(C,n))+1);c)} \\ M. F. Hasler, Nov 20 2019
-
PARI
apply( A257669(n)=if(n>1,vecsum(apply(self,invsigma(n))))+1, [1..99]) \\ See Alekseyev-link for invsigma(). - M. F. Hasler, Nov 20 2019, replacing earlier code from Michel Marcus
Formula
a(A007369(n)) = 1.
Comments