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.

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

A045572 Numbers that are odd but not divisible by 5.

Original entry on oeis.org

1, 3, 7, 9, 11, 13, 17, 19, 21, 23, 27, 29, 31, 33, 37, 39, 41, 43, 47, 49, 51, 53, 57, 59, 61, 63, 67, 69, 71, 73, 77, 79, 81, 83, 87, 89, 91, 93, 97, 99, 101, 103, 107, 109, 111, 113, 117, 119, 121, 123, 127, 129, 131, 133, 137, 139, 141, 143, 147, 149, 151, 153
Offset: 1

Views

Author

Jeff Burch, Dec 11 1999

Keywords

Comments

Contains the repunits R_n, (A000042 or A002275): For any m in the sequence (divisible by neither 2 nor 5), Euler's theorem (i.e., m | 10^m - 1 = 9*R_n) guarantees that R_n is always some multiple of m (see A099679) and thus forms a subsequence. - Lekraj Beedassy, Oct 26 2004
Inverse formula: n = 4*floor(a(n)/10) + floor((a(n) mod 10)/3) + 1. - Carl R. White, Feb 06 2008
Numbers ending with 1, 3, 7 or 9. - Lekraj Beedassy, Apr 04 2009
Complement of A065502. - Reinhard Zumkeller, Nov 15 2009
Union of evenish and oddish numbers, cf. A045797, A045798. - Reinhard Zumkeller, Dec 10 2011
Numbers k such that k^(4*j) mod 10 = 1, for any j. - Gary Detlefs, Jan 03 2012
Numbers coprime to 10. - Charles R Greathouse IV, Sep 05 2013
This is also the sequence of numbers such that all their divisors are the sum of the proper divisors of some number (see A001065 (sum of proper divisors) and A078923 (possible values of sigma(n)-n)). This is due to the fact that in the set of untouchable numbers (A005114) there are only 2 prime numbers (2 and 5) and all other terms are even composite. - Michel Marcus, Jun 14 2014
Numbers n for which A001589(n) is divisible by 5. - Bruno Berselli, Jun 18 2014
For a(n) > 1, positive integers x such that the decimal representation of 1/x is purely periodic after the decimal point (1/x is a repeating decimal with no non-repeating portion). - Doug Bell, Aug 05 2015
The asymptotic density of this sequence is 2/5. - Amiram Eldar, Oct 18 2020

Examples

			a(18) = 10*floor(17/4) + 2*floor( (4*(17 mod 4) + 1)/3 ) + 1
      = 10*4 + 2*floor( (4*(1)+1)/3 ) + 1
      = 40 + 2*floor(5/3) + 1
      = 40 + 2*1 + 1
      = 43.
G.f. = x + 3*x^2 + 7*x^3 + 9*x^4 + 11*x^5 + 13*x^6 + 17*x^7 + 19*x^8 + ...
		

Crossrefs

Relative complement of A017329 in A005408.
Cf. A000035, A000042, A001065, A001589, A002275, A005114, A045797, A045798, A065502, A078923, A079998, A082768 (numbers that begin with 1, 3, 7 or 9), A085820, A099679.

Programs

Formula

a(n) = 10*floor((n-1)/4) + 2*floor( (4*((n-1) mod 4) + 1)/3 ) + 1; a(n) = a(n-1) + 2 + 2*floor(((x+6) mod 10)/9). - Carl R. White, Feb 06 2008
a(n) = 2*n + 2*floor((n-3)/4) + 1. - Kenneth Hammond (weregoose(AT)gmail.com), Mar 07 2008
a(n) = -1 + 2*n + 2*floor((n+1)/4). - Kenneth Hammond (weregoose(AT)gmail.com), Mar 25 2008
From R. J. Mathar, Sep 22 2009: (Start)
a(n) = a(n-1) + a(n-4) - a(n-5).
G.f.: x*(1 + 2*x + 4*x^2 + 2*x^3 + x^4)/((1+x) * (x^2+1) * (x-1)^2). (End)
A000035(a(n))*(1 - A079998(a(n))) = 1. - Reinhard Zumkeller, Nov 15 2009
a(n) = (10*n + 2*(-1)^(n*(n+1)/2) - (-1)^n - 5)/4. - Bruno Berselli, Nov 06 2011
G.f.: x * (1 + 2*x + 4*x^2 + 2*x^3 + x^4) / ((1 - x) * (1 - x^4)). - Michael Somos, Jun 15 2014
a(1 - n) = -a(n) for all n in Z. - Michael Somos, Jun 15 2014
0 = (a(n) - 2*a(n+1) + a(n+2)) * (a(n) - 4*a(n+2) + 3*a(n+3)) for all n in Z. - Michael Somos, Jun 15 2014
From Mikk Heidemaa, Nov 22 2017: (Start)
a(n) = (1/2)*(5*n + ((3*n + 2) mod 4) - 4);
a(n) = (1/4)*((-1)^(n + 1) + 10*n + 2*cos((n*Pi)/2) - 2*sin((n*Pi)/2) - 5);
a(n) = (1/4)*((-1)^(1 + n) + (1 - i)*exp(-(1/2)*i*n*Pi) + (1 + i)*exp(i*n*Pi/2) + 10*n - 5) (for n > 0), where i is the imaginary unit. (End)
Sum_{n>=1} (-1)^(n+1)/a(n) = sqrt(10-2*sqrt(5))*Pi/10. - Amiram Eldar, Dec 12 2021
E.g.f.: (2 + cos(x) + (5*x - 3)*cosh(x) - sin(x) + (5*x - 2)*sinh(x))/2. - Stefano Spezia, Dec 07 2022

A005114 Untouchable numbers, also called nonaliquot numbers: impossible values for the sum of aliquot parts function (A001065).

Original entry on oeis.org

2, 5, 52, 88, 96, 120, 124, 146, 162, 188, 206, 210, 216, 238, 246, 248, 262, 268, 276, 288, 290, 292, 304, 306, 322, 324, 326, 336, 342, 372, 406, 408, 426, 430, 448, 472, 474, 498, 516, 518, 520, 530, 540, 552, 556, 562, 576, 584, 612, 624, 626, 628, 658
Offset: 1

Views

Author

Keywords

Comments

Complement of A078923. - Lekraj Beedassy, Jul 19 2005
Chen & Zhao show that the lower density of this sequence is at least 0.06, improving on te Riele. - Charles R Greathouse IV, Dec 28 2013
Numbers k such that A048138(k) = 0. A048138(k) measures how "touchable" k is. - Jeppe Stig Nielsen, Jan 12 2020
From Amiram Eldar, Feb 13 2021: (Start)
The term "untouchable number" was coined by Alanen (1972). He found the 570 terms below 5000.
Erdős (1973) proved that the lower asymptotic density of untouchable numbers is positive, te Riele (1976) proved that it is > 0.0324, and Banks and Luca (2004, 2005) proved that it is > 1/48.
Pollack and Pomerance (2016) conjectured that the asymptotic density is ~ 0.17. (End)
The upper asymptotic density is less than 1/2 by the 'almost all' binary Goldbach conjecture, independently proved by Nikolai Chudakov, Johannes van der Corput, and Theodor Estermann. (In this context, this shows that the density of the odd numbers of this form is 0 (consider A001065(p*q) for prime p, q); full Goldbach would prove that 5 is the only odd number in this sequence.) - Charles R Greathouse IV, Dec 05 2022

References

  • Richard K. Guy, Unsolved Problems in Number Theory, 3rd ed., Springer, 2004, section B10, pp. 100-101.
  • Clifford A. Pickover, A Passion for Mathematics, Wiley, 2005; see p. 65.
  • József Sándor, Dragoslav S. Mitrinovic, Borislav Crstici, Handbook of Number Theory I, Springer Science & Business Media, 2005, page 93.
  • 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 147.
  • David Wells, The Penguin Dictionary of Curious and Interesting Numbers. Penguin Books, NY, 1986, Revised edition 1987. See p. 125.

Crossrefs

Programs

  • Mathematica
    untouchableQ[n_] := Catch[ Do[ If[n == DivisorSigma[1, k]-k, Throw[True]], {k, 0, (n-1)^2}]] === Null; Reap[ Table[ If[ untouchableQ[n], Print[n]; Sow[n]], {n, 2, 700}]][[2, 1]] (* Jean-François Alcover, Jun 29 2012, after Benoit Cloitre *)
  • PARI
    isA078923(n)=if(n==0 || n==1, return(1)); for(m=1,(n-1)^2, if( sigma(m)-m == n, return(1))); 0
    isA005114(n)=!isA078923(n)
    for(n=1,700, if (isA005114(n), print(n))) \\ R. J. Mathar, Aug 10 2006
    
  • PARI
    is(n)=if(n%2 && n<4e18, return(n==5)); forfactored(m=1,(n-1)^2, if(sigma(m)-m[1]==n, return(0))); 1 \\ Charles R Greathouse IV, Dec 05 2022
    
  • Python
    from sympy import divisor_sigma as sigma
    from functools import cache
    @cache
    def f(m): return sigma(m)-m
    def okA005114(n):
        if n < 2: return 0
        return not any(f(m) == n for m in range(1, (n-1)**2+1))
    print([k for k in range(289) if okA005114(k)]) # Michael S. Branicky, Nov 16 2024
    
  • Python
    # faster for intial segment of sequence
    from itertools import count, islice
    from sympy import divisor_sigma as sigma
    def agen(): # generator of terms
        n, touchable, t = 2, {0, 1}, 1
        for m in count(2):
            touchable.add(sigma(m)-m)
            while m > t:
                if n not in touchable:
                    yield n
                else:
                    touchable.discard(n)
                n += 1
                t = (n-1)**2
    print(list(islice(agen(), 20))) # Michael S. Branicky, Nov 16 2024

Extensions

More terms from David W. Wilson

A362401 Numbers in the range of A162296, where A162296(n) is the sum of divisors of n that have a square factor larger than 1.

Original entry on oeis.org

0, 4, 9, 12, 16, 24, 25, 27, 28, 32, 36, 48, 49, 54, 56, 60, 72, 75, 79, 80, 96, 100, 108, 112, 117, 120, 121, 124, 126, 128, 144, 147, 150, 152, 162, 168, 169, 176, 180, 183, 192, 196, 199, 200, 216, 224, 240, 248, 252, 268, 270, 272, 288, 289, 294, 296, 300
Offset: 1

Views

Author

Amiram Eldar, Apr 18 2023

Keywords

Comments

Possible values of A162296 in increasing order.

Examples

			0 is a term since A162296(k) = 0 if k is squarefree (A005117).
		

Crossrefs

Similar sequences: A078923, A002191, A002202, A002174, A274790.

Programs

  • Mathematica
    s[n_] := Module[{f = FactorInteger[n], p, e}, p = f[[;; , 1]]; e = f[[;; , 2]]; Times @@ ((p^(e + 1) - 1)/(p - 1)) - Times @@ (p + 1)]; s[1] = 0; m = 300; Select[Union[Array[s, m]], # <= m &]
  • PARI
    s(n) = {my(f = factor(n), p, e); prod(i = 1, #f~, p = f[i, 1]; e = f[i, 2]; ((p^(e + 1) - 1)/(p - 1))) -  prod(i = 1, #f~, f[i, 1] + 1);}
    lista(kmax) = select(x -> (x < kmax), Set(vector(kmax, k, s(k))))

A192277 Impossible values for both sum of proper divisors of k and sum of anti-divisors of k.

Original entry on oeis.org

120, 146, 206, 246, 268, 288, 290, 326, 342, 430, 448, 472, 530, 626, 658, 718, 726, 766, 804, 818, 836, 926, 982, 996, 1002, 1028, 1200, 1212, 1246, 1256, 1312, 1332, 1360, 1438, 1506, 1508, 1538, 1542, 1692, 1718, 1728, 1746, 1806, 1840, 2078, 2148, 2388
Offset: 1

Views

Author

Paolo P. Lava, Jul 06 2011

Keywords

Crossrefs

Intersection of A005114 and A074898.
Showing 1-5 of 5 results.