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-10 of 24 results. Next

A098007 Length of aliquot sequence for n, or -1 if aliquot sequence never cycles.

Original entry on oeis.org

2, 3, 3, 4, 3, 1, 3, 4, 5, 5, 3, 8, 3, 6, 6, 7, 3, 5, 3, 8, 4, 7, 3, 6, 2, 8, 4, 1, 3, 16, 3, 4, 7, 9, 4, 5, 3, 8, 4, 5, 3, 15, 3, 6, 8, 9, 3, 7, 5, 4, 5, 10, 3, 14, 4, 6, 4, 5, 3, 12, 3, 10, 4, 5, 4, 13, 3, 6, 5, 7, 3, 10, 3, 6, 6, 6, 4, 12, 3, 8, 6, 7, 3, 7, 4, 10, 8, 8, 3, 11, 5, 7, 5, 5, 3, 10, 3, 4, 5, 6
Offset: 1

Views

Author

N. J. A. Sloane, Sep 09 2004

Keywords

Comments

The aliquot sequence for n is the trajectory of n under repeated application of the map x -> sigma(x) - x (= A001065).
The trajectory will either have a transient part followed by a cyclic part, or will have an infinite transient part and never cycle. It seems possible that this be the case for 276, i.e., a(276) = -1.
Sequence gives number of distinct terms in the trajectory = (length of transient part of trajectory) + (length of cycle (which is 1 if the trajectory reached 0)), or -1 if the sequence never cycles.
Concerning one of the previously unsolved cases, Robert G. Wilson v reports that 840 reaches 0 after 749 iterations. - Sep 10 2004
Up to 1000 there are 12 numbers whose fate is currently unknown, namely five well-known hard cases: 276, 552, 564, 660, 966 and seven others: 306, 396 and 696, all on same trajectory as 276; 780, on same trajectory as 564; 828, on same trajectory as 660; 888, on same trajectory as 552; 996, on same trajectory as 660. - T. D. Noe, Jun 06 2006
The sum-of-divisors function sigma (A000203) and thus aliquot parts A001065 are defined only on the positive integers, so the trajectory ends when 0 is reached. Some authors define A001065 to be the sum of the positive numbers less than n that divide n, in which case one would have A001065(0) = 0. - M. F. Hasler, Nov 16 2013

Examples

			Examples of trajectories:
  1, 0.
  2, 1, 0.
  3, 1, 0. (and similarly for any prime)
  4, 3, 1, 0.
  5, 1, 0.
  6, 6, 6, ... (and similarly for any perfect number)
  8, 7, 1, 0.
  9, 4, 3, 1, 0.
  12, 16, 15, 9, 4, 3, 1, 0.
  14, 10, 8, 7, 1, 0.
  25, 6, 6, 6, ...
  28, 28, 28, ... (the next perfect number)
  30, 42, 54, 66, 78, 90, 144, 259, 45, 33, 15, 9, 4, 3, 1, 0.
  42, 54, 66, 78, 90, 144, 259, 45, 33, 15, 9, 4, 3, 1, 0.
		

References

  • K. Chum, R. K. Guy, M. J. Jacobson, Jr., and A. S. Mosunov, Numerical and statistical analysis of aliquot sequences. Exper. Math. 29 (2020), no. 4, 414-425; arXiv:2110.14136, Oct. 2021 [math.NT].
  • J.-P. Delahaye, Les inattendus mathématiques, Chapter 19, "Nombres amiables et suites aliquotes", pp. 217-229, Belin-Pour la Science, Paris 2004.
  • G. Everest, A. van der Poorten, I. Shparlinski and T. Ward, Recurrence Sequences, Amer. Math. Soc., 2003; see esp. p. 255.
  • R. K. Guy, Unsolved Problems in Number Theory, B6.
  • R. K. Guy and J. L. Selfridge, Interim report on aliquot series, pp. 557-580 of Proceedings Manitoba Conference on Numerical Mathematics. University of Manitoba, Winnipeg, Oct 1971.
  • Carl Pomerance, The aliquot constant, after Bosma and Kane, Q. J. Math. 69 (2018), no. 3, 915-930.

Crossrefs

Cf. A001065.
There are many related sequences:
Length of transient part + length of cycle: this sequence. Other versions of the current sequence: A044050, A003023.
Length of transient part: A098008, also A007906. Records for transients: A098009, A098010.
Numbers which eventually reach 1 (or equivalently 0): A080907.
Aliquot trajectories for certain interesting starting values: A008885 (for 30), A008886 A008887 A008888 A008889 A008890 A008891 A008892 (for 276), A014360 A014361 A074907 A014362 A045477 A014363 A014364 A014365 A074906, A171103.
For n < 220, A098008 = A098007 - 1, i.e., 220 is the first sociable number. - Robert G. Wilson v, Sep 10 2004

Programs

  • Maple
    f:=proc(n) local t1, i,j,k; t1:=[n]; for i from 2 to 50 do j:= t1[i-1]; k:=sigma(j)-j; t1:=[op(t1), k]; od: t1; end; # produces trajectory for n
    # 2nd implementation:
    A098007 := proc(n)
        local trac, x;
        x := n ;
        trac := [x] ;
        while true do
            x := numtheory[sigma](x)-trac[-1] ;
            if x = 0 then
                return 1+nops(trac) ;
            elif x in trac then
                return nops(trac) ;
            end if;
            trac := [op(trac), x] ;
        end do:
    end proc:
    seq(A098007(n), n=1..100) ; # R. J. Mathar, Oct 08 2017
  • Mathematica
    g[n_] := If[n > 0, DivisorSigma[1, n] - n, 0]; f[n_] := NestWhileList[g, n, UnsameQ, All]; Table[ Length[ f[n]] - 1, {n, 100}] (* Robert G. Wilson v, Sep 10 2004 *)
  • PARI
    apply( {A098007(n, t=0)=until(bittest(t,if(n,n=sigma(n)-n)),t+=1<M. F. Hasler, Feb 24 2018, improved Aug 14 2022 thanks to a remark from Jianing Song
    
  • Python
    from sympy import divisor_sigma as sigma
    def a(n, limit=float('inf')):
        alst = []; seen = set(); i = n; c = 0
        while i and i not in seen and c < limit:
            alst.append(i); seen.add(i); i = sigma(i) - i; c += 1
        return "NA" if c == limit else len(set(alst + [i]))
    print([a(n) for n in range(1, 101)]) # Michael S. Branicky, Jul 11 2021
  • Scheme
    (define (A098007 n) (let loop ((visited (list n)) (i 1)) (let ((next (A001065 (car visited)))) (cond ((zero? next) (+ 1 i)) ((member next visited) i) (else (loop (cons next visited) (+ 1 i)))))))
    (define (A001065 n) (- (A000203 n) n)) ;; For an implementation of A000203, see under that entry.
    ;; Antti Karttunen, Nov 01 2017
    

Extensions

More terms from Robert G. Wilson v and John W. Layman, Sep 10 2004

A098008 Length of transient part of aliquot sequence for n, or -1 if transient part is infinite.

Original entry on oeis.org

1, 2, 2, 3, 2, 0, 2, 3, 4, 4, 2, 7, 2, 5, 5, 6, 2, 4, 2, 7, 3, 6, 2, 5, 1, 7, 3, 0, 2, 15, 2, 3, 6, 8, 3, 4, 2, 7, 3, 4, 2, 14, 2, 5, 7, 8, 2, 6, 4, 3, 4, 9, 2, 13, 3, 5, 3, 4, 2, 11, 2, 9, 3, 4, 3, 12, 2, 5, 4, 6, 2, 9, 2, 5, 5, 5, 3, 11, 2, 7, 5, 6, 2, 6, 3, 9, 7, 7, 2, 10, 4, 6, 4, 4, 2, 9, 2, 3, 4, 5, 2, 18
Offset: 1

Views

Author

N. J. A. Sloane, Sep 09 2004

Keywords

Comments

See A098007 for further information.
a(n) = 0 if and only if n is perfect (A000396) or part of a cycle of length greater than 1. - Comment corrected by Antti Karttunen, Nov 02 2017.
It is believed that the first time a(n) = -1 is at n = 276 (see A008892). - N. J. A. Sloane, Nov 02 2017

Examples

			From _Antti Karttunen_, Nov 02 2017: (Start)
For n = 3, a(n) = 2, because A001065(3) = 1 and A001065(1) = 0, so it took two steps to end in zero.
For n = 25, a(n) = 1, because A001065(25) = 6, and A001065(6) = 6, so it took one step to enter into a cycle.
For n = 12496, a(n) = 0, because 12496 is a member of 5-cycle of map n -> A001065(n) (see A072891).
(End)
		

References

  • R. K. Guy, Unsolved Problems in Number Theory, B6.
  • R. K. Guy and J. L. Selfridge, Interim report on aliquot series, pp. 557-580 of Proceedings Manitoba Conference on Numerical Mathematics. University of Manitoba, Winnipeg, Oct 1971.

Crossrefs

Cf. A001065, A098007, A044050, A003023, A008892. See A007906 for another version.
Cf. A206708 (gives a proper subset of zeros).

Programs

  • Mathematica
    g[n_] := If[n > 0, DivisorSigma[1, n] - n, 0]; f[n_] := NestWhileList[g, n, UnsameQ, All]; Table[ Length[ f[n]] - 2, {n, 102}] (* good only for n<220 *) (* Robert G. Wilson v, Sep 10 2004 *)
  • Scheme
    (define (A098008 n) (let loop ((visited (list n)) (i 1)) (let ((next (A001065 (car visited)))) (cond ((zero? next) i) ((member next visited) => (lambda (transientplus1) (- (length transientplus1) 1))) (else (loop (cons next visited) (+ 1 i))))))) ;; Good for at least n = 1..275.
    (define (A001065 n) (- (A000203 n) n)) ;; For an implementation of A000203, see under that entry.
    ;; Antti Karttunen, Nov 02 2017

Extensions

More terms from Robert G. Wilson v, Sep 10 2004

A008885 Aliquot sequence starting at 30.

Original entry on oeis.org

30, 42, 54, 66, 78, 90, 144, 259, 45, 33, 15, 9, 4, 3, 1, 0
Offset: 0

Views

Author

Keywords

Comments

The sum-of-divisor function A000203 and thus aliquot parts A001065 are defined only for positive integers, so the trajectory ends when 0 is reached, here at index 15. - M. F. Hasler, Feb 24 2018

Examples

			a(0) = 30.
30 has eight divisors, 1, 2, 3, 5, 6, 10, 15, 30, which add up to 72, and 72 - 30 = 42, so a(1) = 42.
		

References

  • Richard K. Guy, Unsolved Problems in Number Theory, B6.

Crossrefs

Programs

  • Maple
    f := proc(n) option remember; if n = 0 then 30; else sigma(f(n-1))-f(n-1); fi; end:
  • Mathematica
    NestList[If[# > 0, DivisorSigma[1, #] - #, 0] &, 30, 80] (* Harvey P. Dale, Jun 12 2012 *)
  • PARI
    a(n, a=30)=for(i=1, n, a=sigma(a)-a); a \\ M. F. Hasler, Feb 24 2018

Formula

a(n+1) = A001065(a(n)). - R. J. Mathar, Oct 11 2017

Extensions

Edited by M. F. Hasler, Feb 24 2018

A008888 Aliquot sequence starting at 138.

Original entry on oeis.org

138, 150, 222, 234, 312, 528, 960, 2088, 3762, 5598, 6570, 10746, 13254, 13830, 19434, 20886, 21606, 25098, 26742, 26754, 40446, 63234, 77406, 110754, 171486, 253458, 295740, 647748, 1077612, 1467588, 1956812, 2109796, 1889486, 953914, 668966, 353578, 176792
Offset: 0

Views

Author

Keywords

Comments

The sum-of-divisor function A000203 and aliquot parts A001065 are defined only for positive integers, so the trajectory ends when 0 is reached, here at index 178. - M. F. Hasler, Feb 24 2018
Merges into sequence A008889 after the first step.

References

  • R. K. Guy, Unsolved Problems in Number Theory, B6.
  • Enoch Haga, Exploring Prime Numbers on Your PC, 2nd ed., 1998, pages 83-84 and Table 8, page 46. ISBN 1-885794-16-9.

Crossrefs

Cf. A008885 (starting at 30), ..., A008892 (starting at 276), A098007 (length of aliquot sequences).

Programs

  • Maple
    f := proc(n) option remember; if n = 0 then 138; else sigma(f(n-1))-f(n-1); fi; end:
  • Mathematica
    FixedPointList[If[# > 0, DivisorSigma[1, #] - #, 0]&, 138] // Most (* Jean-François Alcover, Mar 28 2020 *)
  • PARI
    a(n,a=138)={for(i=1,n,a=sigma(a)-a);a} \\ M. F. Hasler, Feb 24 2018

Formula

a(n) = A001065(a(n-1)) for n > 0, thus a(n) = A001065^n(138) for all n < 179. - M. F. Hasler, Nov 16 2013
a(n) = A008889(n-1) for all n >= 1. - M. F. Hasler, Feb 24 2018

Extensions

Term 179 removed from b-file by Ivan Panchenko, Nov 16 2013
Edited by M. F. Hasler, Feb 24 2018

A014360 Aliquot sequence starting at 552.

Original entry on oeis.org

552, 888, 1392, 2328, 3552, 6024, 9096, 13704, 20616, 30984, 46536, 86904, 165816, 367704, 628356, 837836, 628384, 630356, 491884, 368920, 499400, 772840, 978650, 975652, 744248, 696712, 628628, 857836, 857892, 1472268
Offset: 0

Views

Author

Keywords

References

  • R. K. Guy, Unsolved Problems in Number Theory, B6.

Crossrefs

Cf. A001065, A098007 (length of aliquot sequences).
Some other examples: A008885 (starting at 30) .. A008892 (starting at 276), A014361 (starting at 564) .. A014365 (starting at 1134), see link to index for a more complete list.

Programs

  • Mathematica
    FixedPointList[If[# > 0, DivisorSigma[1, #] - #, 0]&, 552, 100] (* Jean-François Alcover, Mar 28 2020 *)
  • PARI
    a(n, a=552)={for(i=1, n, a=sigma(a)-a); a} \\ M. F. Hasler, Feb 24 2018

Formula

a(n+1) = A001065(a(n)). - R. J. Mathar, Oct 11 2017

A014365 Aliquot sequence starting at 1134.

Original entry on oeis.org

1134, 1770, 2550, 4146, 4158, 7362, 8628, 11532, 16272, 29670, 46362, 46374, 48666, 48678, 70362, 86118, 92058, 95622, 95634, 180846, 246834, 381006, 460458, 562902, 612138, 612150, 1316298, 1350582, 1509690, 3086790
Offset: 0

Views

Author

Keywords

References

  • Richard K. Guy, Unsolved Problems in Number Theory, 3rd Edition, Springer, 2004, Section B6, pp. 92-95.

Crossrefs

Cf. A098007 (length of aliquot sequences); some other examples: A008885 (starting at 30) .. A008892 (starting at 276), A014360 (starting at 552) .. A014364 (starting at 1074), see link to index for a more complete list.
Cf. A001065.

Programs

  • Mathematica
    f[n_] := DivisorSigma[1, n] - n; NestList[f, 1134, 100] (* Robert G. Wilson v, Dec 22 2012 *)
  • PARI
    a(n, a=1134)={for(i=1, n, a=sigma(a)-a); a} \\ M. F. Hasler, Feb 25 2018

Formula

a(n+1) = A001065(a(n)). - R. J. Mathar, Oct 11 2017

A121507 Conjectured list of numbers whose aliquot sequence eventually reaches a cycle of length two or more.

Original entry on oeis.org

220, 284, 562, 1064, 1184, 1188, 1210, 1308, 1336, 1380, 1420, 1490, 1604, 1690, 1692, 1772, 1816, 1898, 2008, 2122, 2152, 2172, 2362, 2542, 2620, 2630, 2652, 2676, 2678, 2856, 2924, 2930, 2950, 2974, 3124, 3162, 3202, 3278, 3286, 3332, 3350, 3360
Offset: 1

Views

Author

Joshua Zucker, Aug 04 2006

Keywords

Comments

For some numbers the outcome of the aliquot sequence is unknown. Currently, 276 is the least such.

Crossrefs

Extensions

Edited by Don Reble, Aug 15 2006

A008889 Aliquot sequence starting at 150.

Original entry on oeis.org

150, 222, 234, 312, 528, 960, 2088, 3762, 5598, 6570, 10746, 13254, 13830, 19434, 20886, 21606, 25098, 26742, 26754, 40446, 63234, 77406, 110754, 171486, 253458, 295740, 647748, 1077612, 1467588, 1956812, 2109796, 1889486, 953914, 668966, 353578, 176792
Offset: 0

Views

Author

Keywords

Comments

Start at 150, and repeatedly apply the map x -> Sum of divisors of x excluding x.
The sum-of-divisor function A000203 and aliquot parts A001065 are defined only for positive integers, so the trajectory ends when 0 is reached, here at index 14. - M. F. Hasler, Feb 24 2018

References

  • R. K. Guy, Unsolved Problems in Number Theory, B6.

Crossrefs

Cf. A008885 (starting at 30), ..., A008892 (starting at 276), A098007 (length of aliquot sequences).

Programs

  • Maple
    f := proc(n) option remember; if n = 0 then 150; else sigma(f(n-1))-f(n-1); fi; end:
  • Mathematica
    FixedPointList[If[# > 0, DivisorSigma[1, #] - #, 0]&, 150] // Most (* Jean-François Alcover, Mar 28 2020 *)
  • PARI
    a(n,a=150)={for(i=1,n,a=sigma(a)-a);a} \\ M. F. Hasler, Feb 24 2018

Formula

a(n) = A008888(n+1). - R. J. Mathar, Oct 28 2008

A131884 Numbers conjectured to have an infinite, aperiodic, aliquot sequence.

Original entry on oeis.org

276, 306, 396, 552, 564, 660, 696, 780, 828, 888, 966, 996, 1074, 1086, 1098, 1104, 1134, 1218, 1302, 1314, 1320, 1338, 1350, 1356, 1392, 1398, 1410, 1464, 1476, 1488, 1512, 1560, 1572, 1578, 1590, 1632, 1650, 1662, 1674, 1722, 1734, 1758, 1770, 1806, 1836
Offset: 1

Views

Author

J. Lowell, Oct 24 2007

Keywords

Comments

From Martin Renner, Oct 28 2011: (Start)
There are 12 numbers up to 1000 with the five yet unknown trajectories
(1) 276 ->
306 -> 396 -> 696 -> ...
(2) 552 -> 888 -> ...
(3) 564 -> 780 -> ...
(4) 660 ->
828 ->
996 -> 1356 -> ...
(5) 966 -> 1338 -> ...
The least starting numbers 276, 552, 564, 660 and 966 for the trajectories are called Lehmer five.
There are currently 81 open end trajectories up to 10000. (End)
Sequence A216072 lists only the values that are the lowest starting elements of open end aliquot sequences that are the part of different open-ending families. But this sequence lists all the starting values of an aliquot sequence that lead to open-ending. It includes all values obtained by iterating from the starting values of this sequence. - V. Raman, Dec 08 2012

Crossrefs

Programs

  • Mathematica
    (* This script is not suitable for a large number of terms *) maxAliquot = 10^50; A131884 = {}; s[1] = 1; s[n_] := DivisorSigma[1, n] - n; selQ[n_ /; n <= 5] = True; selQ[n_] := NestWhile[s, n, If[{##}[[-1]] > maxAliquot, Print[n]; AppendTo[A131884, n]; False, Length[{##}] < 4 || {##}[[-4 ;; -3]] != {##}[[-2 ;; -1]]] &, All] == 1; selQ /@ Range[1000]; A131884 (* Jean-François Alcover, Sep 10 2015 *)

Extensions

More terms and links from Martin Renner, Oct 28 2011

A171103 Aliquot sequence starting at 46758.

Original entry on oeis.org

46758, 46770, 65550, 113010, 158286, 191922, 205518, 205530, 375078, 443418, 449958, 497562, 574278, 574290, 972090, 1918278, 2574522, 3034458, 4479750, 8807706, 11409894, 13311582, 13311594, 16269846, 16509018, 16578438
Offset: 0

Views

Author

N. J. A. Sloane, Sep 25 2010, based on a posting by Hans Havermann to the Math Fun Mailing List, Sep 16, 2010

Keywords

Comments

As of today, 3488 terms of the sequence sequence are known, cf. link to the factodb web site. - M. F. Hasler, Feb 25 2018

Crossrefs

Cf. A098007 (length of aliquot sequences); some other examples: A008885 (starting at 30) .. A008892 (starting at 276), A014360 (starting at 552) .. A014365 (starting at 1134), see link to index entries for a more complete list.

Programs

  • Mathematica
    FixedPointList[If[# > 0, DivisorSigma[1, #] - #, 0]&, 46758, 100] (* Jean-François Alcover, Mar 28 2020 *)
  • PARI
    a(n,a=46758)={for(i=1,n,a=sigma(a)-a);a} \\ M. F. Hasler, Feb 24 2018

Extensions

Erroneous comment replaced by M. F. Hasler, Mar 01 2018
Showing 1-10 of 24 results. Next