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 19 results. Next

A001065 Sum of proper divisors (or aliquot parts) of n: sum of divisors of n that are less than n.

Original entry on oeis.org

0, 1, 1, 3, 1, 6, 1, 7, 4, 8, 1, 16, 1, 10, 9, 15, 1, 21, 1, 22, 11, 14, 1, 36, 6, 16, 13, 28, 1, 42, 1, 31, 15, 20, 13, 55, 1, 22, 17, 50, 1, 54, 1, 40, 33, 26, 1, 76, 8, 43, 21, 46, 1, 66, 17, 64, 23, 32, 1, 108, 1, 34, 41, 63, 19, 78, 1, 58, 27, 74, 1, 123, 1, 40, 49, 64, 19, 90, 1, 106
Offset: 1

Views

Author

Keywords

Comments

Also total number of parts in all partitions of n into equal parts that do not contain 1 as a part. - Omar E. Pol, Jan 16 2013
Related concepts: If a(n) < n, n is said to be deficient, if a(n) > n, n is abundant, and if a(n) = n, n is perfect. If there is a cycle of length 2, so that a(n) = b and a(b) = n, b and n are said to be amicable. If there is a longer cycle, the numbers in the cycle are said to be sociable. See examples. - Juhani Heino, Jul 17 2017
Sum of the smallest parts in the partitions of n into two parts such that the smallest part divides the largest. - Wesley Ivan Hurt, Dec 22 2017
a(n) is also the total number of parts congruent to 0 mod k in the partitions of k*n into equal parts that do not contain k as a part (the comment dated Jan 16 2013 is the case for k = 1). - Omar E. Pol, Nov 23 2019
Fixed points are in A000396. - Alois P. Heinz, Mar 10 2024

Examples

			x^2 + x^3 + 3*x^4 + x^5 + 6*x^6 + x^7 + 7*x^8 + 4*x^9 + 8*x^10 + x^11 + ...
For n = 44, sum of divisors of n = sigma(n) = 84; so a(44) = 84-44 = 40.
Related concepts: (Start)
From 1 to 17, all n are deficient, except 6 and 12 seen below. See A005100.
Abundant numbers: a(12) = 16, a(18) = 21. See A005101.
Perfect numbers: a(6) = 6, a(28) = 28. See A000396.
Amicable numbers: a(220) = 284, a(284) = 220. See A259180.
Sociable numbers: 12496 -> 14288 -> 15472 -> 14536 -> 14264 -> 12496. See A122726. (End)
For n = 10 the sum of the divisors of 10 that are less than 10 is 1 + 2 + 5 = 8. On the other hand, the partitions of 10 into equal parts that do not contain 1 as a part are [10], [5,5], [2,2,2,2,2], there are 8 parts, so a(10) = 8. - _Omar E. Pol_, Nov 24 2019
		

References

  • M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964 (and various reprintings), p. 840.
  • George E. Andrews, Number Theory. New York: Dover, 1994; Pages 1, 75-92; p. 92 #15: Sigma(n) / d(n) >= n^(1/2).
  • Carl Pomerance, The first function and its iterates, pp. 125-138 in Connections in Discrete Mathematics, ed. S. Butler et al., Cambridge, 2018.
  • H. J. J. te Riele, Perfect numbers and aliquot sequences, pp. 77-94 in J. van de Lune, ed., Studieweek "Getaltheorie en Computers", published by Math. Centrum, Amsterdam, Sept. 1980.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • James J. Tattersall, Elementary Number Theory in Nine Chapters, Cambridge University Press, 1999, page 91.

Crossrefs

Least inverse: A070015, A359132.
Values taken: A078923, values not taken: A005114.
Records: A034090, A034091.
First differences: A053246, partial sums: A153485.
a(n) = n - A033879(n) = n + A033880(n). - Omar E. Pol, Dec 30 2013
Row sums of A141846 and of A176891. - Gary W. Adamson, May 02 2010
Row sums of A176079. - Mats Granvik, May 20 2012
Alternating row sums of A231347. - Omar E. Pol, Jan 02 2014
a(n) = sum (A027751(n,k): k = 1..A000005(n)-1). - Reinhard Zumkeller, Apr 05 2013
For n > 1: a(n) = A240698(n,A000005(n)-1). - Reinhard Zumkeller, Apr 10 2014
A134675(n) = A007434(n) + a(n). - Conjectured by John Mason and proved by Max Alekseyev, Jan 07 2015
Cf. A037020 (primes), A053868, A053869 (odd and even terms).
Cf. A048138 (number of occurrences), A238895, A238896 (record values thereof).
Cf. A007956 (products of proper divisors).
Cf. A005100, A005101, A000396, A259180, A122726 (related concepts).

Programs

  • Haskell
    a001065 n = a000203 n - n  -- Reinhard Zumkeller, Sep 15 2011
    
  • Magma
    [SumOfDivisors(n)-n: n in [1..100]]; // Vincenzo Librandi, May 06 2015
    
  • Maple
    A001065 := proc(n)
        numtheory[sigma](n)-n ;
    end proc:
    seq( A001065(n),n=1..100) ;
  • Mathematica
    Table[ Plus @@ Select[ Divisors[ n ], #Zak Seidov, Sep 10 2009 *)
    Table[DivisorSigma[1, n] - n, {n, 1, 80}] (* Jean-François Alcover, Apr 25 2013 *)
    Array[Plus @@ Most@ Divisors@# &, 80] (* Robert G. Wilson v, Dec 24 2017 *)
  • MuPAD
    numlib::sigma(n)-n$ n=1..81 // Zerinvary Lajos, May 13 2008
    
  • PARI
    {a(n) = if( n==0, 0, sigma(n) - n)} /* Michael Somos, Sep 20 2011 */
    
  • Python
    from sympy import divisor_sigma
    def A001065(n): return divisor_sigma(n)-n # Chai Wah Wu, Nov 04 2022
    
  • Sage
    [sigma(n, 1)-n for n in range(1, 81)] # Stefano Spezia, Jul 14 2025

Formula

G.f.: Sum_{k>0} k * x^(2*k)/(1 - x^k). - Michael Somos, Jul 05 2006
a(n) = sigma(n) - n = A000203(n) - n. - Lekraj Beedassy, Jun 02 2005
a(n) = A155085(-n). - Michael Somos, Sep 20 2011
Equals inverse Mobius transform of A051953 = A051731 * A051953. Example: a(6) = 6 = (1, 1, 1, 0, 0, 1) dot (0, 1, 1, 2, 1, 4) = (0 + 1 + 1 + 0 + 0 + 4), where A051953 = (0, 1, 1, 2, 1, 4, 1, 4, 3, 6, 1, 8, ...) and (1, 1, 1, 0, 0, 1) = row 6 of A051731 where the 1's positions indicate the factors of 6. - Gary W. Adamson, Jul 11 2008
a(n) = A006128(n) - A220477(n) - n. - Omar E. Pol Jan 17 2013
a(n) = Sum_{i=1..floor(n/2)} i*(1-ceiling(frac(n/i))). - Wesley Ivan Hurt, Oct 25 2013
Dirichlet g.f.: zeta(s-1)*(zeta(s) - 1). - Ilya Gutkovskiy, Aug 07 2016
a(n) = 1 + A048050(n), n > 1. - R. J. Mathar, Mar 13 2018
Erdős (Elem. Math. 28 (1973), 83-86) shows that the density of even integers in the range of a(n) is strictly less than 1/2. The argument of Coppersmith (1987) shows that the range of a(n) has density at most 47/48 < 1. - N. J. A. Sloane, Dec 21 2019
G.f.: Sum_{k >= 2} x^k/(1 - x^k)^2. Cf. A296955. (This follows from the fact that if g(z) = Sum_{n >= 1} a(n)*z^n and f(z) = Sum_{n >= 1} a(n)*z^(N*n)/(1 - z^n) then f(z) = Sum_{k >= N} g(z^k), taking a(n) = n and N = 2.) - Peter Bala, Jan 13 2021
Faster converging g.f.: Sum_{n >= 1} q^(n*(n+1))*(n*q^(3*n+2) - (n + 1)*q^(2*n+1) - (n - 1)*q^(n+1) + n)/((1 - q^n)*(1 - q^(n+1))^2). (In equation 1 in Arndt, after combining the two n = 0 summands to get -t/(1 - t), apply the operator t*d/dt to the resulting equation and then set t = q and x = 1.) - Peter Bala, Jan 22 2021
a(n) = Sum_{d|n} d * (1 - [n = d]), where [ ] is the Iverson bracket. - Wesley Ivan Hurt, Jan 28 2021
a(n) = Sum_{i=1..n} ((n-1) mod i) - (n mod i). [See also A176079.] - José de Jesús Camacho Medina, Feb 23 2021

A115350 Termination of the aliquot sequence starting at n.

Original entry on oeis.org

1, 2, 3, 3, 5, 6, 7, 7, 3, 7, 11, 3, 13, 7, 3, 3, 17, 11, 19, 7, 11, 7, 23, 17, 6, 3, 13, 28, 29, 3, 31, 31, 3, 7, 13, 17, 37, 7, 17, 43, 41, 3, 43, 43, 3, 3, 47, 41, 7, 43, 11, 3, 53, 3, 17, 41, 23, 31, 59, 43, 61, 7, 41, 41, 19, 3, 67, 31, 13, 43, 71, 3, 73, 43, 7, 41, 19, 3, 79, 41, 43, 43
Offset: 1

Views

Author

Sergio Pimentel, Mar 07 2006

Keywords

Comments

Catalan's conjecture [not yet established and probably false] is that every aliquot sequence terminates in a prime number followed by 1, a perfect number, a friendly pair or an aliquot cycle.
a(n) = the prime number if the sequence terminates in a prime followed by 1, a(n) = a perfect number if the sequence terminates in a perfect number, a(n) = the smallest number of the cycle if the sequence terminates in an aliquot cycle, a(n) = 0 if the sequence is open ended. So far 276 is the smallest number for which the termination of the aliquot sequence is not known.

Examples

			a(12)=3 since the aliquot sequence starting at 12 is: 12 - 16 - 15 - 9 - 4 - 3.
a(95)=6 since the aliquot sequence starting at 95 is: 95 - 25 - 6 - 6 ...
		

Crossrefs

Programs

  • Mathematica
    a[n_] := If[n == 1, 1, FixedPointList[If[# > 0, DivisorSigma[1, #] - #, 0]&, n] /. {k__, 1, 0, 0} :> {k} // Last];
    Array[a, 100] (* Jean-François Alcover, Mar 28 2020 *)

Extensions

Edited by N. J. A. Sloane, Aug 14 2006
a(61)-a(80) from R. J. Mathar's list by Robert Price, Mar 16 2019

A115060 Maximum peak of aliquot sequence starting at n.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 16, 13, 14, 15, 16, 17, 21, 19, 22, 21, 22, 23, 55, 25, 26, 27, 28, 29, 259, 31, 32, 33, 34, 35, 55, 37, 38, 39, 50, 41, 259, 43, 50, 45, 46, 47, 76, 49, 50, 51, 52, 53, 259, 55, 64, 57, 58, 59, 172, 61, 62, 63, 64, 65, 259
Offset: 1

Views

Author

Sergio Pimentel, Mar 06 2006

Keywords

Comments

According to Catalan's conjecture all aliquot sequences end in a prime followed by 1, a perfect number, a friendly pair or an aliquot cycle. Some sequences seem to be open ended and keep growing forever i.e. 276. Most sequences only go down (i.e. 10 - 8 - 7 - 1), so for most cases in this sequence, a(n) = n. The first number to achieve a significantly high peak is 138

Examples

			a(24)=55 because the aliquot sequence starting at 24 is: 24 - 36 - 55 - 17 - 1 so the maximum peak of this sequence is 55.
		

Crossrefs

Programs

  • Python
    from sympy import divisor_sigma as sigma
    def aliquot(n):
        alst = []; seen = set(); i = n
        while i and i not in seen: alst.append(i); seen.add(i); i = sigma(i) - i
        return alst
    def aupton(terms): return [max(aliquot(n)) for n in range(1, terms+1)]
    print(aupton(66)) # Michael S. Branicky, Jul 11 2021

Extensions

More terms from Jinyuan Wang, Jul 11 2021

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
    				

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

A085842 Numbers k whose divisors (apart from 1 and k) sum to a prime.

Original entry on oeis.org

4, 6, 9, 10, 22, 25, 30, 34, 42, 49, 58, 60, 70, 78, 82, 84, 102, 118, 120, 121, 138, 142, 168, 169, 186, 198, 202, 214, 216, 220, 222, 228, 234, 238, 240, 246, 258, 270, 274, 280, 282, 289, 294, 298, 348, 358, 360, 361, 364, 370, 372, 382, 390, 394, 406, 414, 438, 442, 444
Offset: 1

Views

Author

Chuck Seggelin, Jul 05 2003

Keywords

Examples

			102 is a member since the divisors of 102 are {1, 2, 3, 6, 17, 34, 51, 102} and 2 + 3 + ... + 51 = 113, a prime.
		

Crossrefs

Programs

  • Maple
    with(numtheory); b := []; for n from 3 to 2000 do t1 := divisors(n); t2 := convert(t1,list); t3 := add(t2[i],i=1..nops(t2)); if isprime(t3-1-n) then b := [op(b),n]; fi; od: b;
  • Mathematica
    f[n_]:=Plus@@Divisors[n]-n-1; lst={};Do[a=f[n];If[PrimeQ[a],AppendTo[lst,n]],{n,7!}];lst (* Vladimir Joseph Stephan Orlovsky, Sep 21 2009 *)
    Select[Range[500], PrimeQ[DivisorSigma[1, #] - # - 1] &] (* Amiram Eldar, Dec 04 2020 *)
  • PARI
    isok(k) = isprime(sigma(k)-1-k); \\ Michel Marcus, Dec 04 2020

A135245 Aliquot predecessors with the largest degrees.

Original entry on oeis.org

0, 0, 4, 9, 0, 25, 8, 49, 15, 14, 21, 121, 35, 169, 33, 12, 55, 289, 65, 361, 91, 20, 85, 529, 143, 46, 133, 28, 187, 841, 161, 961, 247, 62, 253, 24, 323, 1369, 217, 81, 391, 1681, 341, 1849, 403, 86, 493, 2209, 551, 40, 481, 0, 667, 2809, 533, 106, 703, 68, 697, 3481
Offset: 1

Views

Author

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

Keywords

Comments

Find each node's predecessors in aliquot sequences and choose the node with largest number of predecessors.
Climb the aliquot trees on thickest branches (see A135244 = Climb the aliquot trees on shortest paths).

Examples

			a(25) = 143 since 25 has 3 predecessors (95,119,143) with degrees (4,5,7), 143 having the largest degree. a(5) = 0 since it has no predecessors (see Untouchables - A005114).
		

Crossrefs

A177900 Smallest positive integer k such that the sum of the proper divisors of k gives the n-th prime, or 0 if prime(n) belongs to A005114.

Original entry on oeis.org

0, 4, 0, 8, 21, 27, 39, 65, 57, 115, 32, 155, 63, 50, 129, 235, 265, 371, 305, 201, 98, 365, 237, 171, 245, 291, 485, 309, 325, 327, 128, 189, 279, 917, 1507, 1529, 242, 785, 489, 835, 865, 1211, 385, 605, 579, 965, 338, 2321, 669, 1115, 687, 1165, 399, 2629, 549, 1285, 595, 1841, 1025, 603, 1385, 715, 3809, 921, 1175, 939, 4121, 1655, 805, 1325
Offset: 1

Views

Author

John W. Layman, Dec 15 2010

Keywords

Comments

Suggested by the following comment of T. D. Noe (see A037020): "Assuming the Goldbach conjecture, it is easy to show that all primes, except 2 and 5, are the sum of the proper divisors of some number."

Examples

			27 and 35 have the proper divisors {1,3,9} and {1,5,7}, respectively, both of which sum to prime(6)=13, and no positive integer smaller than 27 has this property.  Thus a(6)=27.
		

Crossrefs

Programs

  • Maple
    N:= 1000: # to get the first N terms
    A:= 'A': A[1]:= 0: A[3]:= 0:
    Primes:= [seq(ithprime(i),i=1..N)]:
    count:= 0:
    for k from 1  while count < N-2 do
      m:= numtheory:-sigma(k)-k;
      if member(m,Primes,'n') and not assigned(A[n]) then
         count:= count+1;
         A[n]:= k;
      fi
    od:
    seq(A[i],i=1..N); # Robert Israel, Jul 09 2014
  • Mathematica
    f[n_] := DivisorSigma[1, n] - n; k = 1; t = Table[0, {1000}]; While[ k < 24001, a = f@ k; If[a < 1001 && t[[a]] == 0, t[[a]] = k]; k++]; tt = Table[t[[n]], {n, Prime@ Range@ 168}] (* Robert G. Wilson v, Jul 09 2014 *)
  • PARI
    a(n) = {p = prime(n); if ((p != 2) && (p != 5), k = 2; while ((sigma(k) - k) != p, k++); k;);} \\ Michel Marcus, Jul 09 2014

Formula

a(n) = A070015(p_n) where p runs through the primes. - Robert G. Wilson v, Jul 09 2014

Extensions

Offset corrected to 1 by Michel Marcus, Jul 09 2014

A286842 Least k such that the sum of proper divisors of k*n is a prime number, or -1 if no such k exists.

Original entry on oeis.org

4, 2, 7, 1, 7, 54, 3, 1, 3, 5, 5, 27, 3, 7, 35, 2, 5, 18, 3, 40, 1, 11, 5, 96, 2, 13, 1, 14, 7, 120, 5, 1, 99, 68, 1, 9, 3, 19, 1, 20, 5, 5145000, 3, 88, 80, 23, 5, 48, 2, 1, 323, 52, 5, 6, 1, 7, 1, 116, 7, 60, 5, 124, 1, 2, 1, 1650, 3, 34, 299, 35, 7, 32, 5, 37, 7, 19, 1, 26693550
Offset: 1

Views

Author

Altug Alkan, Aug 01 2017

Keywords

Comments

Motivated by the fate of sequence A072326.
a(546) > 5*10^9. - Michel Marcus, Aug 06 2017
a(546) = 7975795464. When n is even the search can be sped up by observing that the exponents of the odd prime factors of n*a(n) must be even, otherwise the sum of the proper divisors n*a(n) is even and cannot be prime. So, if n is even, a(n) is equal to c*2^s*m^2, where c is the squarefree part of the odd part of n, s is 0 or 1, and m is a suitable integer. - Giovanni Resta, Aug 06 2017

Crossrefs

Cf. A001065, A037020, A072326 (dead).

Programs

  • Mathematica
    Table[SelectFirst[Range[10^7], PrimeQ[DivisorSigma[1, #] - #] &[# n] &] /. k_ /; MissingQ@ k -> -1, {n, 77}] (* Michael De Vlieger, Aug 01 2017 *)
  • PARI
    a(n) = {my(k=1); while (!isprime(sigma(k*n)-k*n), k++); k;}

Formula

a(A037020(n)) = 1.

A308150 Numbers k such that sigma(k) mod k is prime, where sigma = A000203.

Original entry on oeis.org

4, 8, 18, 20, 21, 27, 32, 35, 36, 39, 50, 55, 57, 63, 65, 77, 85, 98, 100, 104, 111, 115, 125, 128, 129, 155, 161, 171, 175, 185, 187, 189, 196, 201, 203, 205, 209, 221, 235, 237, 242, 245, 265, 275, 279, 291, 299, 305, 309, 319, 323, 324, 325, 327, 335, 338, 341, 365, 371, 377, 381, 385, 391
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, May 14 2019

Keywords

Comments

Includes 1+A000668.

Examples

			a(3) = 18 is in the sequence because sigma(18) = 39, 39 == 3 (mod 18), and 3 is prime.
		

Crossrefs

Includes A037020 and A075081.

Programs

  • Maple
    select(n -> isprime(numtheory:-sigma(n) mod n), [$2..1000]);
  • PARI
    isok(n) = isprime(sigma(n) % n); \\ Michel Marcus, May 15 2019
Showing 1-10 of 19 results. Next