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

A152454 Irregular triangle in which row n lists the numbers whose proper divisors sum to n.

Original entry on oeis.org

4, 9, 6, 25, 8, 10, 49, 15, 14, 21, 121, 27, 35, 22, 169, 16, 33, 12, 26, 39, 55, 289, 65, 77, 34, 361, 18, 51, 91, 20, 38, 57, 85, 529, 95, 119, 143, 46, 69, 133, 28, 115, 187, 841, 32, 125, 161, 209, 221, 58, 961, 45, 87, 247, 62, 93, 145, 253, 24, 155, 203, 299, 323, 1369
Offset: 2

Views

Author

T. D. Noe, Dec 05 2008

Keywords

Comments

In an aliquot sequence, all numbers in row n can be predecessors of n. This sequence is a permutation of the composite numbers; number k appears in row A001065(k). We start with n=2 because every prime would be in row 1. Note that row 2 is empty -- as are all the rows listed in A005114. Row n contains A048138(n) numbers. When n is prime, the largest number in row n+1 is n^2. When n>7 is odd, the largest number in row n is less than ((n-1)/2)^2 and (if a strong form of the Goldbach conjecture is true) has the form pq, with primes p
In row n, the first term is A070015(n), and the last term is A135244(n). - Michel Marcus, Nov 11 2014
The first row with several terms is row(6), where the difference between extreme terms is 25-6=19. The next row with a smaller difference is row(13) with a difference 35-27=8. And the next one is row(454) with a difference 602-596=6. Is there a next row with a smaller difference? - Michel Marcus, Nov 11 2014

Examples

			Irregular triangle starts:
  ; (empty row at n=2)
  4;
  9;
  ; (empty row at n=5)
  6, 25;
  8;
  10, 49;
  15;
  14;
  21;
  121;
  27, 35;
  22, 169;
  16, 33;
  12, 26;
  39, 55;
  289;
  ...
		

Crossrefs

Programs

  • Maple
    N:= 100: # for rows 2 to N, flattened
    for s from 2 to N do B[s]:= NULL od:
    for k from 1 to N^2 do
      if not isprime(k) then
        s:= numtheory:-sigma(k)-k;
        if s <= N then
           B[s]:= B[s],k;
        fi
      fi
    od:
    seq(B[s],s=2..N); # Robert Israel, Nov 11 2014
  • Mathematica
    nn=100; s=Table[{},{nn}]; Do[k=DivisorSigma[1,n]-n; If[1
    				
  • PARI
    row(n) = select(x->(sigma(x)-x)==n, [1..n^2]); \\ Michel Marcus, Feb 25 2025

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

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.
		

Programs

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

A359132 Least m such that the sum of the aliquot parts of m (A001065) equals n, or -1 if no such number exists.

Original entry on oeis.org

1, 2, -1, 4, 9, -1, 6, 8, 10, 15, 14, 21, 121, 27, 22, 16, 12, 39, 289, 65, 34, 18, 20, 57, 529, 95, 46, 69, 28, 115, 841, 32, 58, 45, 62, 93, 24, 155, 1369, 217, 44, 63, 30, 50, 82, 123, 52, 129, 2209, 75, 40, 141, -1, 235, 42, 36, 106, 99, 68, 265, 3481, 371, 118, 64, 56, 117, 54
Offset: 0

Author

N. J. A. Sloane, Jan 10 2023

Keywords

Comments

"Least inverse" to A001065.
A070015 is essentially the same, except it has a different offset and a different "escape clause" value.

Crossrefs

A231965 Smallest integer starting a group of exactly n consecutive untouchable numbers (A005114) with term differences of 2.

Original entry on oeis.org

246, 288, 892, 9020, 11456, 23480, 52274, 33686, 190070, 1741856, 1668564, 7806762
Offset: 2

Author

Michel Marcus, Nov 16 2013

Keywords

Comments

Such n-tuplets from A005114 correspond to n+1 positive numbers interspersed with n zeros in A070015, and starting at a(n) - 1. For instance, a(4) = 892 is related to A070015(891) and consecutive values: 2661, 0, 4147, 0, 2945, 0, 1287, 0, 9757.

Examples

			a(5) = 9020, because 9020, 9022, 9024, 9026, 9028 are untouchable, while 9018 and 9030 are not so (A001065). For examples with smaller n, see A231964 comments.
		

Crossrefs

Cf. A110875 (analog for sigma(n)).

Programs

  • PARI
    oksucc(v, vi, n) = {for (i = 1, n-1, if (! vecsearch(v, vi+2*i, ) , return (0));); return(! vecsearch(v, vi-2) && !vecsearch(v, vi+2*n));}
    a(n) = {v = readvec("untouchable.log"); for (i=1, #v, vi = v[i]; if (oksucc(v, vi, n), return(vi)););} \\ readvec reads the file obtained by keeping the second column of b005114.txt seen as a csv file.

Extensions

a(10)-a(13) from Donovan Johnson, Nov 16 2013
Definition, data, and Pari script corrected by Michel Marcus with Donovan Johnson, Nov 18 2013

A070016 Least m such that Chowla's function value of m [A048050(m)] equals n or 0 if no such number exists.

Original entry on oeis.org

0, 4, 9, 0, 6, 8, 10, 15, 14, 21, 121, 27, 22, 16, 12, 39, 289, 65, 34, 18, 20, 57, 529, 95, 46, 69, 28, 115, 841, 32, 58, 45, 62, 93, 24, 155, 1369, 217, 44, 63, 30, 50, 82, 123, 52, 129, 2209, 75, 40, 141, 0, 235, 42, 36, 106, 99, 68, 265, 3481, 371, 118, 64, 56, 117
Offset: 1

Author

Labos Elemer, Apr 12 2002

Keywords

Comments

Remark that A070016(n)=A070015(n+1) in accordance with A048995(k)+1=A005114(k).

Examples

			n=127: a(n)=16129, divisors={1,127,16129}, 127=sigma[n]-n-1=127 and 16129 is the smallest.
		

Programs

  • Mathematica
    f1[x_] := DivisorSigma[1, x]-x-1; t=Table[0, {128}]; Do[b=f1[n]; If[b<129&&t[[b]]==0, t[[b]]=n], {n, 1, 1000000}]; t

Formula

a(n)=Min{x; A048050(x)=n} or a(n)=0 if n is from A048995.

A123930 a(n) = smallest k > 1 that is the sum of the proper divisors (cf. A001065) of at least n different numbers.

Original entry on oeis.org

2, 3, 6, 21, 31, 31, 49, 73, 73, 91, 115, 121, 121, 121, 169, 169, 211, 211, 211, 211, 211, 301, 331, 331, 331, 361, 391, 391, 421, 421, 421, 421, 421, 511, 511, 631, 631, 631, 631, 631, 631, 631, 721, 721, 721, 781, 781, 841, 841, 841, 841, 841, 841, 841, 841
Offset: 0

Author

Sergio Pimentel, Nov 22 2006

Keywords

Examples

			a(0)=2 because 2 is the smallest number that is not the sum of proper divisors of any number (untouchable). a(6)=49 since 49 is the smallest number that is the sum of proper divisors of 6 different numbers (75, 215, 287, 407, 527, 551).
		

Crossrefs

Programs

  • PARI
    {z=850;m=200000;v=vector(z);for(n=2,m,s=sigma(n)-n;if(sKlaus Brockhaus, Nov 27 2006

Extensions

Edited and extended by Klaus Brockhaus, Nov 27 2006

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

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

A261023 Least number k such that prime(n) = sigma(k) - k - 1.

Original entry on oeis.org

4, 9, 6, 10, 121, 22, 289, 34, 529, 841, 58, 1369, 30, 82, 2209, 42, 3481, 118, 4489, 5041, 70, 6241, 6889, 78, 9409, 10201, 202, 60, 214, 102, 16129, 17161, 18769, 84, 138, 298, 24649, 26569, 27889, 29929, 32041, 358, 36481, 238, 186, 394, 44521, 49729, 51529
Offset: 1

Author

Paolo P. Lava, Aug 07 2015

Keywords

Comments

For any prime k <= p^2. In fact if k = p^2 we have that sigma(p) = sigma(p^2) - p^2, that is 1 + p = 1 + p + p^2 - p^2.

Examples

			sigma(2) = 3 and 4 is the least number such that sigma(4) - 4 = 7 - 4 = 3.
sigma(13) = 14 and 22 is the least number such that sigma(22) - 22 = 36 - 22 = 14.
		

Crossrefs

Programs

  • Maple
    with(numtheory): P:=proc(q) local a,k,n; for n from 1 to q do
    if isprime(n) then for k from 1 to q do
    if sigma(n)=sigma(k)-k then print(k); break; fi; od;
    fi; od; end: P(10^9);
  • Mathematica
    Table[k = 1; While[DivisorSigma[1, Prime@ p] != DivisorSigma[1, k] - k, k++]; k, {p, 60}] (* Michael De Vlieger, Aug 07 2015 *)
  • PARI
    a(n) = my(k = 1, p = prime(n)); while(sigma(k)-k-1 != p, k++); k; \\ Michel Marcus, Aug 12 2015
    
  • PARI
    first(m)=my(v=vector(m),k);for(i=1,m,k=1;while(!(prime(i)==sigma(k)-k-1),k++);v[i]=k;);v; \\ Anders Hellström, Aug 14 2015

Formula

a(n) = A070015(A008864(n)). - Robert Israel, Aug 14 2015

A366110 a(n) is the difference between the maximum and minimum number whose proper divisors sum to n, or 0 if there is no such number.

Original entry on oeis.org

0, 0, 0, 0, 19, 0, 39, 0, 0, 0, 0, 8, 147, 17, 14, 16, 0, 12, 327, 73, 18, 28, 0, 48, 0, 64, 0, 72, 0, 189, 903, 202, 0, 160, 0, 168, 0, 0, 37, 328, 1651, 387, 1767, 280, 34, 364, 0, 476, 54, 448, 0, 432, 2767, 677, 0, 604, 0, 432, 0, 528, 3603, 753, 66, 826, 0, 768, 0, 720, 0
Offset: 2

Author

Michel Marcus, Oct 28 2023

Keywords

Comments

A152454 is the irregular triangle in which row n lists the numbers whose proper divisors sum to n.

Examples

			A152454 begins as []; [4]; [9]; []; [6, 25]; [8]; [10, 49]...
so sequence begins 0, 0, 0, 0, 19, 0, 39, ...
		

Crossrefs

Programs

  • PARI
    lista(nn) = my(v = vector(nn, k, [])); forcomposite (i=1, nn^2, my(x=sigma(i)-i); if (x <=  nn, v[x] = concat(v[x], i));); vector(nn-1, k, k++; if (#v[k], vecmax(v[k]) - vecmin(v[k])));

Formula

a(n) = A135244(n) - A070015(n).
a(A005114(n)) = a(A057709(n)) = 0.
Showing 1-10 of 12 results. Next