cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-5 of 5 results.

A007497 a(1) = 2, a(n) = sigma(a(n-1)).

Original entry on oeis.org

2, 3, 4, 7, 8, 15, 24, 60, 168, 480, 1512, 4800, 15748, 28672, 65528, 122880, 393192, 1098240, 4124736, 15605760, 50328576, 149873152, 371226240, 1710858240, 7926750720, 33463001088, 109760857440, 384120963072, 1468475386560, 7157589626880, 33151875434496
Offset: 1

Views

Author

Keywords

Comments

Note that a(32) = 125038913126400 = 11182080^2. - Zak Seidov, Aug 29 2012

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A000203, A175877 (positions of odd terms), A175878 (odd terms).
See also the similarly defined A051572 which has a(1) = 5 instead.
See also A257348.

Programs

  • Haskell
    a007497 n = a007497_list !! (n-1)
    a007497_list = iterate a000203 2  -- Reinhard Zumkeller, Feb 27 2014
    
  • Maple
    A007497 := proc(n) options remember; if n <= 0 then RETURN(2) else numtheory[sigma](procname(n-1)); fi; end proc:
  • Mathematica
    a[1] = 2; a[n_] := a[n] = DivisorSigma[1, a[n-1]]; Table[a[n], {n, 30}]
    NestList[ DivisorSigma[1, # ] &, 2, 27] (* Robert G. Wilson v, Oct 08 2010 *)
  • PARI
    normalize(M)={
        my(P=Set(M[,1]),f=concat(Mat(P),vector(#P))~);
        for(i=1,#M~,
            f[setsearch(P,M[i,1]),2] += M[i,2]
        );
        f
    };
    addhelp(normalize, "normalize(M): Given a factorization matrix M, combine all like factors and order.");
    sf(f)=my(v=vector(#f~,i,(f[i,1]^(f[i,2]+1)-1)/(f[i,1]-1)), g=factor(v[1])~);for(i=2,#v,g=concat(g,factor(v[i])~));normalize(g~)
    v=vector(100);v[1]=2;f=factor(2);for(i=2,#v,print1(i" "); v[i]= factorback(f=sf(f))); v \\ Charles R Greathouse IV, Mar 27 2014
    
  • Python
    from itertools import accumulate, repeat # requires Python 3.2 or higher
    from sympy import divisor_sigma
    A007497_list = list(accumulate(repeat(2,100), lambda x, _: divisor_sigma(x)))
    # Chai Wah Wu, May 02 2015

Formula

Conjecture: (1/2)*log(n) < a(n+1)/a(n) < 2*log(n). - Benoit Cloitre, May 08 2003
Conjecture: a(n) == 0 mod 9 for n > 34. - Ivan N. Ianakiev, Mar 27 2014
Checked up to n = 1000. Similar statements hold for other small primes. For example, a(n) seems to be divisible by 2^22 * 3^5 * 5 * 7 = 35672555520 for all n > 99. - Charles R Greathouse IV, Mar 27 2014

Extensions

Changed the cross-reference from the tau to the sigma-function - R. J. Mathar, Feb 17 2010

A051572 a(1) = 5, a(n) = sigma(a(n-1)).

Original entry on oeis.org

5, 6, 12, 28, 56, 120, 360, 1170, 3276, 10192, 24738, 61440, 196584, 491520, 1572840, 5433480, 20180160, 94859856, 355532800, 1040179456, 2143289344, 4966055344, 10092086208, 31800637440, 137371852800, 641012414823
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    NestList[Plus@@Divisors[#] &, 5, 25] (* Alonso del Arte, Apr 28 2011 *)
  • PARI
    a=[5];for(i=2,10,a=concat(a,sigma(a[#a]))); a \\ Charles R Greathouse IV, Oct 03 2011
    
  • Python
    from itertools import accumulate, repeat # requires Python 3.2 or higher
    from sympy import divisor_sigma
    A051572_list = list(accumulate(repeat(5,100), lambda x, _: divisor_sigma(x)))
    # Chai Wah Wu, May 02 2015

A257670 Minimum term in the sigma(x) -> x subtree whose root is n.

Original entry on oeis.org

1, 2, 2, 2, 5, 5, 2, 2, 9, 10, 11, 5, 9, 9, 2, 16, 17, 10, 19, 19, 21, 22, 23, 2, 25, 26, 27, 5, 29, 29, 16, 16, 33, 34, 35, 22, 37, 37, 10, 27, 41, 19, 43, 43, 45, 46, 47, 33, 49, 50, 51, 52, 53, 34, 55, 5, 49, 58, 59, 2, 61, 61, 16, 64, 65, 66, 67, 67, 69
Offset: 1

Views

Author

Michel Marcus, May 03 2015

Keywords

Examples

			We have the following trees (a <- b means sigma(a) = b):
  2 <-- 3 <-- 4 <-- 7 <-- 8 <-- 15 <-- 24 <-- 60 <-- ...
                    9 <-- 13 <-- 14 <-’
  5 <-- 6 <-- 12 <-- 28 <-- 56 <-- 120 <-- ...
        11 <-’             /
       10 <-- 18 <-- 39 <-’
The number 1 has strictly speaking an arrow to itself, so it is not part of a tree. (For all n > 1, sigma(n) > n, so no other fixed point or longer "cycle" can exist.) But actually we rather consider connected components, and let a(1) = 1 as the smallest element of this connected component.
a(2) = 2, since there is no smaller x such that sigma(x) = 2: the subtree with root 2 is reduced to a single node: 2. Similarly, a(m) = m for all m in A007369.
For n=3, since sigma(2) = 3, the tree whose root is 3 has 2 nodes: 2 and 3, and the smallest one is 2, hence a(3) = 2.
Similarly, although 24 occurs directly first at sigma(14), it is also reached from 15 which is in turn reached, via intermediate steps, from 2. Thus, the subtree with root 24 has as 2 as smallest element, whence a(24) = 2.
		

Crossrefs

Cf. A000203 (sigma), A007369 (sigma(x) = n has no solution).
Cf. A216200 (number of disjoint trees), A257348 (minimal node of all trees).
Cf. A257669 (number of terms in current tree).

Programs

  • PARI
    lista(nn) = {my(v = vector(nn)); v[1] = 1; for (i=2, nn, my(s = i); while (s <= nn, if (v[s] == 0, v[s] = i); s = sigma(s););); for (i=1, nn, if (v[i] == 0, v[i] = i);); v;} \\ Michel Marcus, Nov 19 2019
    
  • PARI
    A257670(n)=if(n>2,vecmin(concat(apply(self,invsigma(n)),n)),n) \\ See Alekseyev-link for invsigma(). - David A. Corneth and M. F. Hasler, Nov 20 2019

Formula

a(m) = m for m in A007369: sigma(x) = m has no solution. [Corrected by M. F. Hasler, Nov 19 2019]
a(A007497(n)) = 2; a(A051572(n)) = 5; a(A257349(n)) = 16. (These sequences being the trajectory of 2, 5 resp. 16 under iterations of sigma = A000203.)

Extensions

Edited by M. F. Hasler, Nov 19 2019

A257349 a(1) = 16, a(n) = sigma(a(n-1)).

Original entry on oeis.org

16, 31, 32, 63, 104, 210, 576, 1651, 1792, 4088, 8880, 28272, 79360, 196416, 633984, 1827840, 7074432, 22032000, 86640840, 364989240, 1651141800, 7540142400, 33541980160, 90193969152, 334471118520, 1415960985600, 6118878991680, 29424972595200
Offset: 1

Views

Author

N. J. A. Sloane, May 01 2015

Keywords

Crossrefs

Programs

  • Mathematica
    NestList[DivisorSigma[1,#]&,16,27] (* Ivan N. Ianakiev, May 02 2015 *)
  • PARI
    lista(nn) = {print1(v = 16, ", "); for (n=1, nn, v = sigma(v); print1(v, ", "););} \\ Michel Marcus, May 02 2015
  • Python
    from itertools import accumulate, repeat # requires Python 3.2 or higher
    from sympy import divisor_sigma
    A257349_list = list(accumulate(repeat(16,100), lambda x, _: divisor_sigma(x)))
    # Chai Wah Wu, May 02 2015
    

A257669 Number of terms in the sigma(x) -> x subtree whose root is n.

Original entry on oeis.org

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

Views

Author

Michel Marcus, May 03 2015

Keywords

Comments

For terms m of A007369, numbers m such that sigma(x) = m has no solution, as well as for m = 1, a(m) = 1.
See A257670 for more information, examples, etc. - M. F. Hasler, Nov 19 2019
Records are: a(1) = 1 = a(2), a(3) = 2, a(4) = 3, a(7) = 4, a(8) = 5, a(15) = 6, a(24) = 11, a(60) = 15, a(120) = 16, a(168) = 22 = a(336), a(360) = 26, a(480) = 39, a(1344) = 43, a(1512) = 54, a(1920) = 57, a(2016) = 65, a(2880) = 70, a(4800) = 80, a(5040) = 88, a(6552) = 93, a(8064) = 125, ... - M. F. Hasler, Nov 20 2019

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.
		

Crossrefs

Cf. A007369 (sigma(x) = n has no solution).
Cf. A216200 (number of disjoint trees), A257348 (minimal nodes of all trees).
Cf. A257670 (minimal representative of current tree).

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.
Showing 1-5 of 5 results.