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 13 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

A063769 Aspiring numbers: numbers whose aliquot sequence terminates in a perfect number.

Original entry on oeis.org

25, 95, 119, 143, 417, 445, 565, 608, 650, 652, 675, 685, 783, 790, 909, 913
Offset: 1

Views

Author

Tanya Khovanova and Alexey Radul, Aug 14 2001

Keywords

Comments

There are many numbers whose aliquot sequences have not yet been completely computed, so this sequence is not fully known. In particular, 276 may, perhaps, be an element of this sequence, although this is very unlikely.
Numbers less than 1000 whose aliquot sequence is not known that could possibly be in this sequence are: 276, 306, 396, 552, 564, 660, 696, 780, 828, 888, 966, 996. - Robert Price, Jun 03 2013

Examples

			The divisors of 95 less than itself are 1, 5 and 19. They sum to 25. The divisors of 25 less than itself are 1 and 5. They sum to 6, which is perfect.
		

References

  • No number terminates at 28, the second perfect number.

Crossrefs

Programs

  • Mathematica
    perfectQ[n_] := DivisorSigma[1, n] == 2*n; maxAliquot = 10^45; A131884 = {}; s[1] = 1; s[n_] := DivisorSigma[1, n] - n; selQ[n_ /; n <= 5] = False; selQ[n_] := NestWhile[s, n, If[{##}[[-1]] > maxAliquot, Print["A131884: ", n]; AppendTo[A131884, n]; False, Length[{##}] < 4 || {##}[[-4 ;; -3]] != {##}[[-2 ;; -1]]] &, All] // perfectQ; Reap[For[k = 1, k < 1000, k++, If[! perfectQ[k] && selQ[k], Print[k]; Sow[k]]]][[2, 1]] (* Jean-François Alcover, Nov 15 2013 *)

Extensions

a(13)-a(16) from Robert Price, Jun 03 2013

A126016 Numbers whose aliquot sequence does not terminate in 1.

Original entry on oeis.org

6, 25, 28, 95, 119, 143, 220
Offset: 1

Views

Author

Keywords

Comments

Sequence continues 276?, 284, 306?, 396?, 417, 445, 496, .... Because 276, 306 and 396 are all in the same family, either all 3 are present or none are. It is not known whether any aliquot sequence grows without bound; 276 is the smallest number for which this is unknown.
Additional tentative terms: 552, 562, 564, 565, 608, 650, 652, 660, 675, 685, 696, 780, 783, 790, 828, 840, 888, 909, 913, 966, 996, 1064, 1074, 1086, 1098, ... - Jean-François Alcover, Nov 14 2013
For additional terms, if the Goldbach Conjecture is assumed, take any odd term, subtract 1, and find two distinct primes that sum to it. For some numbers there will not be any pair of distinct primes. Multiply the two primes and the product is an element of the sequence. Note that this process does not work if the term - 1 is power of a prime. - Nathaniel J. Strout, Nov 25 2018

Crossrefs

Complement of A080907. Includes A000396, A063990 and other sociable numbers, A063769, numbers whose aliquot sequence reaches a sociable number and numbers whose aliquot sequence grows without bound.

Programs

  • Mathematica
    maxAliquot = 10^45; A131884 = {}; s[1] = 1; s[n_] := DivisorSigma[1, n] - n; selQ[n_ /; n <= 5] = True; selQ[n_] := NestWhile[s, n, If[{##}[[-1]] > maxAliquot, Print["A131884: ", n]; AppendTo[A131884, n]; False, Length[{##}] < 4 || {##}[[-4 ;; -3]] != {##}[[-2 ;; -1]]] & , All] == 1; Reap[For[k = 1, k < 1100, k++, If[!selQ[k], Print[k]; Sow[k]]]][[2, 1]]

A125601 a(n) is the smallest k > 0 such that there are exactly n numbers whose sum of proper divisors is k.

Original entry on oeis.org

2, 3, 6, 21, 37, 31, 49, 79, 73, 91, 115, 127, 151, 121, 181, 169, 217, 265, 253, 271, 211, 301, 433, 379, 331, 361, 457, 391, 451, 655, 463, 541, 421, 775, 511, 769, 673, 715, 865, 691, 1015, 631, 1069, 1075, 721, 931, 781, 1123, 871, 925, 901, 1177, 991, 1297
Offset: 0

Views

Author

Klaus Brockhaus, Nov 27 2006

Keywords

Comments

Minimal values for nodes of exact degree in aliquot sequences. Find each node's degree (number of predecessors) in aliquot sequences and choose the smallest value as the sequence member. - Ophir Spector, ospectoro (AT) yahoo.com Nov 25 2007

Examples

			a(4) = 37 since there are exactly four numbers (155, 203, 299, 323) whose sum of proper divisors is 37. For k < 37 there are either fewer or more numbers (32, 125, 161, 209, 221 for k = 31) whose sum of proper divisors is k.
		

Crossrefs

Programs

  • PARI
    {m=54;z=1500;y=600000;v=vector(z);for(n=2,y,s=sigma(n)-n; if(s
    				

A127163 Integers whose aliquot sequences terminate by encountering the prime 3. Also known as the prime family 3.

Original entry on oeis.org

3, 4, 9, 12, 15, 16, 26, 30, 33, 42, 45, 46, 52, 54, 66, 72, 78, 86, 87, 90, 102, 105, 114, 121, 123, 126, 135, 144, 165, 166, 174, 186, 198, 207, 212, 243, 246, 247, 249, 258, 259, 270
Offset: 1

Views

Author

Ant King, Jan 07 2007

Keywords

Comments

This sequence is complete only as far as the last term given, for the eventual fate of the aliquot sequence generated by 276 is not (yet) known

Examples

			a(5)=15 because the fifth integer whose aliquot sequence terminates by encountering the prime 3 as a member of its trajectory is 15. The complete aliquot sequence generated by iterating the proper divisors of 15 is 15->9->4->3->1->0
		

References

  • Benito, Manuel; Creyaufmueller, Wolfgang; Varona, Juan Luis; and Zimmermann, Paul; Aliquot Sequence 3630 Ends After Reaching 100 Digits; Experimental Mathematics, Vol. 11, No. 2, Natick, MA, 2002, pp. 201-206.

Crossrefs

Programs

  • Mathematica
    s[n_] := DivisorSigma[1, n] - n; g[n_] := If[n > 0, s[n], 0]; Trajectory[n_] := Most[NestWhileList[g, n, UnsameQ, All]]; Select[Range[275], MemberQ[Trajectory[ # ], 3] &]

Formula

Define s(i)=sigma(i)-i=A000203(i)-i. Then if the aliquot sequence obtained by repeatedly applying the mapping i->s(i) terminates by encountering the prime 3 as a member of its trajectory, i is included in this sequence

A127164 Integers whose aliquot sequences terminate by encountering the prime 7. Also known as the prime family 7.

Original entry on oeis.org

7, 8, 10, 14, 20, 22, 34, 38, 49, 62, 75, 118, 148, 152, 169, 188, 213, 215
Offset: 1

Views

Author

Ant King, Jan 07 2007

Keywords

Comments

This sequence is complete only as far as the last term given, for the eventual fate of the aliquot sequence generated by 276 is not (yet) known.

Examples

			a(5)=20 because the fifth integer whose aliquot sequence terminates by encountering the prime 7 as a member of its trajectory is 20. The complete aliquot sequence generated by iterating the proper divisors of 15 is 20->22->14->10->8->7->1->0
		

References

  • Benito, Manuel; Creyaufmueller, Wolfgang; Varona, Juan Luis; and Zimmermann, Paul; Aliquot Sequence 3630 Ends After Reaching 100 Digits; Experimental Mathematics, Vol. 11, No. 2, Natick, MA, 2002, pp. 201-206.

Crossrefs

Programs

  • Mathematica
    s[n_] := DivisorSigma[1, n] - n; g[n_] := If[n > 0, s[n], 0]; Trajectory[n_] := Most[NestWhileList[g, n, UnsameQ, All]]; Select[Range[275], MemberQ[Trajectory[ # ], 7] &]

Formula

Define s(i)=sigma(i)-i=A000203(i)-i. Then if the aliquot sequence obtained by repeatedly applying the mapping i->s(i) terminates by encountering the prime 7 as a member of its trajectory, i is included in this sequence.

A127161 Integers whose aliquot sequences terminate by encountering a prime number.

Original entry on oeis.org

2, 3, 4, 5, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 26, 27, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75
Offset: 1

Views

Author

Ant King, Jan 06 2007

Keywords

Comments

This sequence is the same as A080907 from A080907's second term onwards.

Examples

			a(10)=12 because the tenth integer whose aliquot sequence terminates by encountering a prime as a member of its trajectory is 12. The complete aliquot sequence generated by iterating the proper divisors of 12 is 12->16->15->9->4->3->1->0
		

References

  • Benito, Manuel; Creyaufmueller, Wolfgang; Varona, Juan Luis; and Zimmermann, Paul; Aliquot Sequence 3630 Ends After Reaching 100 Digits; Experimental Mathematics, Vol. 11, No. 2, Natick, MA, 2002, pp. 201-206.

Crossrefs

Programs

  • Mathematica
    s[n_] := DivisorSigma[1, n] - n; g[n_] := If[n > 0, s[n], 0]; Trajectory[n_] := Most[NestWhileList[g, n, UnsameQ, All]]; Select[Range[2, 275], Last[Trajectory[ # ]] == 0 &]

Formula

Define s(i)=sigma(i)-i=A000203(i)-i. Then if the aliquot sequence obtained by repeatedly iterating s contains a prime as a member of its trajectory, i is included in this sequence

A127162 Composite numbers whose aliquot sequences terminate by encountering a prime number.

Original entry on oeis.org

4, 8, 9, 10, 12, 14, 15, 16, 18, 20, 21, 22, 24, 26, 27, 30, 32, 33, 34, 35, 36, 38, 39, 40, 42, 44, 45, 46, 48, 49, 50, 51, 52, 54, 55, 56, 57, 58, 60, 62, 63, 64, 65, 66, 68, 69, 70, 72, 74, 75, 76, 77, 78, 80, 81, 82, 84, 85, 86, 87, 88, 90, 91, 92, 93, 94, 96, 98, 99
Offset: 1

Views

Author

Ant King, Jan 06 2007

Keywords

Examples

			a(5)=12 because the fifth composite number whose aliquot sequence terminates by encountering a prime as a member of its trajectory is 12. The complete aliquot sequence generated by iterating the proper divisors of 12 is 12->16->15->9->4->3->1->0
		

References

  • Benito, Manuel; Creyaufmueller, Wolfgang; Varona, Juan Luis; and Zimmermann, Paul; Aliquot Sequence 3630 Ends After Reaching 100 Digits; Experimental Mathematics, Vol. 11, No. 2, Natick, MA, 2002, pp. 201-206.

Crossrefs

Programs

  • Mathematica
    s[n_] := DivisorSigma[1, n] - n; g[n_] := If[n > 0, s[n], 0]; Trajectory[n_] := Most[NestWhileList[g, n, UnsameQ, All]]; Select[Range[2, 275], ! PrimeQ[ # ] && Last[Trajectory[ # ]] == 0 &]

Formula

Define s(i)=sigma(i)-i=A000203(i)-i. Then if i is composite and the aliquot sequence obtained by repeatedly applying the mapping i->s(i) contains a prime as a member of its trajectory, i is included in this sequence.

A135244 Largest m such that the sum of the aliquot parts of m (A001065) equals n, or 0 if no such number exists.

Original entry on oeis.org

0, 4, 9, 0, 25, 8, 49, 15, 14, 21, 121, 35, 169, 33, 26, 55, 289, 77, 361, 91, 38, 85, 529, 143, 46, 133, 28, 187, 841, 221, 961, 247, 62, 253, 24, 323, 1369, 217, 81, 391, 1681, 437, 1849, 403, 86, 493, 2209, 551, 94, 589, 0, 667, 2809, 713, 106, 703, 68, 697, 3481
Offset: 2

Views

Author

Ophir Spector (ospectoro(AT)yahoo.com), Nov 25 2007

Keywords

Comments

Previous name: Aliquot predecessors with the largest values.
Find each node's predecessors in aliquot sequences and choose the largest predecessor.
Climb the aliquot trees on shortest paths (see A135245 = Climb the aliquot trees on thickest branches).
The sequence starts at offset 2, since all primes satisfy sigma(n)-n = 1. - Michel Marcus, Nov 11 2014

Examples

			a(25) = 143 since 25 has 3 predecessors (95,119,143), 143 being the largest.
a(5) = 0 since it has no predecessors (see Untouchables - A005114).
		

Crossrefs

Programs

  • Mathematica
    seq[max_] := Module[{s = Table[0, {n, 1, max}], i}, Do[If[(i = DivisorSigma[1, n] - n) <= max, s[[i]] = Max[s[[i]], n]], {n, 2, (max - 1)^2}]; Rest @ s]; seq[50]
  • PARI
    lista(nn) = {for (n=2, nn, k = (n-1)^2; while(k && (sigma(k)-k != n), k--); print1(k, ", "););} \\ Michel Marcus, Nov 11 2014

Extensions

a(1)=0 removed and offset set to 2 by Michel Marcus, Nov 11 2014
New name from Michel Marcus, Oct 31 2023

A371421 Numbers whose aliquot-like sequence based on the largest aliquot divisor of the sum of divisors of n (A371418) terminates in a fixed point.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 16, 17, 18, 19, 20, 21, 22, 24, 25, 26, 27, 28, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 43, 45, 46, 47, 49, 50, 51, 52, 53, 55, 57, 58, 59, 61, 63, 64, 67, 68, 71, 73, 74, 79, 80, 81, 82, 89, 93, 96, 97, 98, 100, 101
Offset: 1

Views

Author

Amiram Eldar, Mar 23 2024

Keywords

Comments

It is unknown whether 222 is a term of this sequence or not (see A371423).

Examples

			3 is a term because when we start with 3 and repeatedly apply the mapping x -> A371418(x), we get the sequence 3, 2, 1, 1, 1, ...
40 is a term because when we start with 40 and repeatedly apply the mapping x -> A371418(x), we get the sequence 40, 45, 39, 28, 28, 28, ...
		

Crossrefs

A023194 is a subsequence.

Programs

  • Mathematica
    r[n_] := n/FactorInteger[n][[1, 1]]; f[n_] := r[DivisorSigma[1, n]]; q[n_] := Module[{m = NestWhileList[f, n, UnsameQ, All][[-1]]}, f[m] == m]; Select[Range[221], q]
Showing 1-10 of 13 results. Next