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

A024786 Number of 2's in all partitions of n.

Original entry on oeis.org

0, 1, 1, 3, 4, 8, 11, 19, 26, 41, 56, 83, 112, 160, 213, 295, 389, 526, 686, 911, 1176, 1538, 1968, 2540, 3223, 4115, 5181, 6551, 8191, 10269, 12756, 15873, 19598, 24222, 29741, 36532, 44624, 54509, 66261, 80524, 97446, 117862, 142029, 171036, 205290, 246211
Offset: 1

Views

Author

Keywords

Comments

Also number of partitions of n-1 with a distinguished part different from all the others. [Comment corrected by Emeric Deutsch, Aug 13 2008]
In general the number of times that j appears in the partitions of n equals Sum_{kA024787, ..., A024794, for j = 2,...,10; it generalizes the formula given for A000070 for j=1. - Jose Luis Arregui (arregui(AT)posta.unizar.es), Apr 05 2002
Equals row sums of triangle A173238. - Gary W. Adamson, Feb 13 2010
The sums of two successive terms give A000070. - Omar E. Pol, Jul 12 2012
a(n) is also the difference between the sum of second largest and the sum of third largest elements in all partitions of n. More generally, the number of occurrences of k in all partitions of n equals the difference between the sum of k-th largest and the sum of (k+1)st largest elements in all partitions of n. And more generally, the sum of the number of occurrences of k, k+1, k+2..k+m in all partitions of n equals the difference between the sum of k-th largest and the sum of (k+m+1)st largest elements in all partitions of n. - Omar E. Pol, Oct 25 2012
Number of singletons in all partitions of n-1. A singleton in a partition is a part that occurs exactly once. Example: a(5) = 4 because in the partitions of 4, namely [1,1,1,1], [1,1,2'], [2,2], [1',3'], [4'] we have 4 singletons (marked by '). - Emeric Deutsch, Sep 12 2016
a(n) is also the number of non-isomorphic vertex-transitive cover graphs of lattice quotients of essential lattice congruences of the weak order on the symmetric group S_{n-1}. See Table 1 in the Hoang/Mütze reference in the Links section. - Torsten Muetze, Nov 28 2019
Assuming a partition is in weakly decreasing order, a(n) is also the number of times -1 occurs in the differences of the partitions of n+1. - George Beck, Mar 28 2023

Examples

			From _Omar E. Pol_, Oct 25 2012: (Start)
For n = 7 we have:
--------------------------------------
.                             Number
Partitions of 7               of 2's
--------------------------------------
7 .............................. 0
4 + 3 .......................... 0
5 + 2 .......................... 1
3 + 2 + 2 ...................... 2
6 + 1 .......................... 0
3 + 3 + 1 ...................... 0
4 + 2 + 1 ...................... 1
2 + 2 + 2 + 1 .................. 3
5 + 1 + 1 ...................... 0
3 + 2 + 1 + 1 .................. 1
4 + 1 + 1 + 1 .................. 0
2 + 2 + 1 + 1 + 1 .............. 2
3 + 1 + 1 + 1 + 1 .............. 0
2 + 1 + 1 + 1 + 1 + 1 .......... 1
1 + 1 + 1 + 1 + 1 + 1 + 1 ...... 0
------------------------------------
.  24 - 13 =                    11
.
The difference between the sum of the second column and the sum of the third column of the set of partitions of 7 is 24 - 13 = 11 and equals the number of 2's in all partitions of 7, so a(7) = 11.
(End)
		

References

  • J. Riordan, Combinatorial Identities, Wiley, 1968, p. 184.

Crossrefs

Column 2 of A060244.
First differences of A000097.

Programs

  • Maple
    b:= proc(n, i) option remember; local f, g;
          if n=0 or i=1 then [1, 0]
        else f:= b(n, i-1); g:= `if`(i>n, [0$2], b(n-i, i));
             [f[1]+g[1], f[2]+g[2]+`if`(i=2, g[1], 0)]
          fi
        end:
    a:= n-> b(n, n)[2]:
    seq(a(n), n=1..50);  # Alois P. Heinz, May 18 2012
  • Mathematica
    Table[ Count[ Flatten[ IntegerPartitions[n]], 2], {n, 1, 50} ]
    (* Second program: *)
    b[n_, i_] := b[n, i] = Module[{f, g}, If[n==0 || i==1, {1, 0}, f = b[n, i - 1]; g = If[i>n, {0, 0}, b[n-i, i]]; {f[[1]] + g[[1]], f[[2]] + g[[2]] + If[i == 2, g[[1]], 0]}]]; a[n_] := b[n, n][[2]]; Table[a[n], {n, 1, 50}] (* Jean-François Alcover, Sep 22 2015, after Alois P. Heinz *)
    Join[{0}, (1/((1 - x^2) QPochhammer[x]) + O[x]^50)[[3]]] (* Vladimir Reshetnikov, Nov 22 2016 *)
    Table[Sum[(1 + (-1)^k)/2 * PartitionsP[n-k], {k, 2, n}], {n, 1, 50}] (* Vaclav Kotesovec, Aug 27 2017 *)
  • Python
    from sympy import npartitions
    def A024786(n): return sum(npartitions(n-(k<<1)) for k in range(1,(n>>1)+1)) # Chai Wah Wu, Oct 25 2023

Formula

a(n) = Sum_{k=1..floor(n/2)} A000041(n-2k). - Christian G. Bower, Jun 22 2000
a(n) = Sum_{kA000041, P(0) = 1. - Jose Luis Arregui (arregui(AT)posta.unizar.es), Apr 05 2002
G.f.: (x^2/((1-x)*(1-x^2)^2))*Product_{j>=3} 1/(1-x^j) from Riordan reference second term, last eq.
a(n) = A006128(n-1) - A194452(n-1). - Omar E. Pol, Nov 20 2011
a(n) = A181187(n,2) - A181187(n,3). - Omar E. Pol, Oct 25 2012
a(n) ~ exp(Pi*sqrt(2*n/3)) / (2^(5/2) * Pi * sqrt(n)) * (1 - 25*Pi/(24*sqrt(6*n)) + (25/48 + 433*Pi^2/6912)/n). - Vaclav Kotesovec, Mar 07 2016, extended Nov 05 2016
a(n) = Sum_{k} k * A116595(n-1,k). - Emeric Deutsch, Sep 12 2016
G.f.: x^2/((1 - x)*(1 - x^2)) * Sum_{n >= 0} x^(2*n)/( Product_{k = 1..n} 1 - x^k ); that is, convolution of A004526 (partitions into 2 parts, or, modulo offset differences, partitions into parts <= 2) and A002865 (partitions into parts >= 2). - Peter Bala, Jan 17 2021

A024788 Number of 4's in all partitions of n.

Original entry on oeis.org

0, 0, 0, 1, 1, 2, 3, 6, 8, 13, 18, 28, 38, 55, 74, 105, 139, 190, 250, 336, 436, 575, 740, 963, 1228, 1577, 1995, 2538, 3186, 4013, 5005, 6256, 7751, 9617, 11847, 14605, 17894, 21927, 26730, 32582, 39531, 47942, 57915, 69920, 84114, 101116, 121176, 145095, 173248
Offset: 1

Views

Author

Keywords

Comments

The sums of four successive terms give A000070. - Omar E. Pol, Jul 12 2012
a(n) is also the difference between the sum of 4th largest and the sum of 5th largest elements in all partitions of n. - Omar E. Pol, Oct 25 2012
a(n+4) is the number of n-vertex graphs that do not contain a triangle, P_4, or K_2,3 as induced subgraph. These are the K_2,3-free bipartite cographs. Bipartite cographs are graph that are disjoint unions of complete bipartite graphs [Babel et al. Corollary 2.2], and forbidding K_2,3 leaves one possible component for each size except size 4, where there are two. Thus, this number is A000041(n) + a(n) = a(n+4). - Falk Hüffner, Jan 11 2016
a(n) (n>=3) is the number of even singletons in all partitions of n-2 (by a singleton we mean a part that occurs exactly once). Example: a(7) = 3 because in the partitions [5], [4*,1], [3,2*], [3,1,1], [2,2,1], [2*,1,1,1], [1,1,1,1,1] we have 3 even singletons (marked by *). The statement of this comment can be obtained by setting k=2 in Theorem 2 of the Andrews et al. reference. - Emeric Deutsch, Sep 13 2016

Examples

			From _Omar E. Pol_, Oct 25 2012: (Start)
For n = 7 we have:
--------------------------------------
.                             Number
Partitions of 7               of 4's
--------------------------------------
7 .............................. 0
4 + 3 .......................... 1
5 + 2 .......................... 0
3 + 2 + 2 ...................... 0
6 + 1 .......................... 0
3 + 3 + 1 ...................... 0
4 + 2 + 1 ...................... 1
2 + 2 + 2 + 1 .................. 0
5 + 1 + 1 ...................... 0
3 + 2 + 1 + 1 .................. 0
4 + 1 + 1 + 1 .................. 1
2 + 2 + 1 + 1 + 1 .............. 0
3 + 1 + 1 + 1 + 1 .............. 0
2 + 1 + 1 + 1 + 1 + 1 .......... 0
1 + 1 + 1 + 1 + 1 + 1 + 1 ...... 0
------------------------------------
.           7 - 4 =              3
The difference between the sum of the fourth column and the sum of the fifth column of the set of partitions of 7 is 7 - 4 = 3 and equals the number of 4's in all partitions of 7, so a(7) = 3.
(End)
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i) option remember; local f, g;
          if n=0 or i=1 then [1, 0]
        else f:= b(n, i-1); g:= `if`(i>n, [0$2], b(n-i, i));
             [f[1]+g[1], f[2]+g[2]+`if`(i=4, g[1], 0)]
          fi
        end:
    a:= n-> b(n, n)[2]:
    seq(a(n), n=1..100);  # Alois P. Heinz, Oct 27 2012
  • Mathematica
    Table[ Count[ Flatten[ IntegerPartitions[n]], 4], {n, 1, 50} ]
    (* second program: *)
    b[n_, i_] := b[n, i] = Module[{g}, If[n == 0 || i == 1, {1, 0}, g = If[i > n, {0, 0}, b[n - i, i]]; b[n, i - 1] + g + {0, If[i == 4, g[[1]], 0]}]]; a[n_] := b[n, n][[2]]; Table[a[n], {n, 1, 100}] (* Jean-François Alcover, Oct 09 2015, after Alois P. Heinz *)

Formula

a(n) = A181187(n,4) - A181187(n,5). - Omar E. Pol, Oct 25 2012
From Peter Bala, Dec 26 2013: (Start)
a(n+4) - a(n) = A000041(n). a(n) + a(n+2) = A024786(n).
O.g.f.: x^4/(1 - x^4) * product {k >= 1} 1/(1 - x^k) = x^4 + x^5 + 2*x^6 + 3*x^7 + ....
Asymptotic result: log(a(n)) ~ 2*sqrt(Pi^2/6)*sqrt(n) as n -> inf. (End)
a(n) ~ exp(Pi*sqrt(2*n/3)) / (8*Pi*sqrt(2*n)) * (1 - 49*Pi/(24*sqrt(6*n)) + (49/48 + 1633*Pi^2/6912)/n). - Vaclav Kotesovec, Nov 05 2016
G.f.: x^4/((1 - x)*(1 - x^2)*(1 - x^3)*(1 - x^4)) * Sum_{n >= 0} x^(4*n)/( Product_{k = 1..n} 1 - x^k ); that is, convolution of A026810 (partitions into 4 parts, or, modulo offset differences, partitions into parts <= 4) and A008484 (partitions into parts >= 4). - Peter Bala, Jan 17 2021

A024787 Number of 3's in all partitions of n.

Original entry on oeis.org

0, 0, 1, 1, 2, 4, 6, 9, 15, 21, 31, 45, 63, 87, 122, 164, 222, 298, 395, 519, 683, 885, 1146, 1475, 1887, 2401, 3050, 3845, 4837, 6060, 7563, 9402, 11664, 14405, 17751, 21807, 26715, 32634, 39784, 48352, 58649, 70969, 85690, 103232, 124143, 148951, 178407, 213277, 254509
Offset: 1

Views

Author

Keywords

Comments

Starting with the first 1 = row sums of triangle A173239. - Gary W. Adamson, Feb 13 2010
The sums of three successive terms give A000070. - Omar E. Pol, Jul 12 2012
a(n) is also the difference between the sum of 3rd largest and the sum of 4th largest elements in all partitions of n. - Omar E. Pol, Oct 25 2012

Examples

			From _Omar E. Pol_, Oct 25 2012: (Start)
For n = 7 we have:
--------------------------------------
.                             Number
Partitions of 7               of 3's
--------------------------------------
7 .............................. 0
4 + 3 .......................... 1
5 + 2 .......................... 0
3 + 2 + 2 ...................... 1
6 + 1 .......................... 0
3 + 3 + 1 ...................... 2
4 + 2 + 1 ...................... 0
2 + 2 + 2 + 1 .................. 0
5 + 1 + 1 ...................... 0
3 + 2 + 1 + 1 .................. 1
4 + 1 + 1 + 1 .................. 0
2 + 2 + 1 + 1 + 1 .............. 0
3 + 1 + 1 + 1 + 1 .............. 1
2 + 1 + 1 + 1 + 1 + 1 .......... 0
1 + 1 + 1 + 1 + 1 + 1 + 1 ...... 0
------------------------------------
.      13 - 7 =                  6
The difference between the sum of the third column and the sum of the fourth column of the set of partitions of 7 is 13 - 7 = 6 and equals the number of 3's in all partitions of 7, so a(7) = 6.
(End)
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i) option remember; local g;
          if n=0 or i=1 then [1, 0]
        else g:= `if`(i>n, [0$2], b(n-i, i));
             b(n, i-1) +g +[0, `if`(i=3, g[1], 0)]
          fi
        end:
    a:= n-> b(n, n)[2]:
    seq(a(n), n=1..100);  # Alois P. Heinz, Oct 27 2012
  • Mathematica
    Table[ Count[ Flatten[ IntegerPartitions[n]], 3], {n, 1, 50} ]
    b[n_, i_] := b[n, i] = Module[{g}, If[n==0 || i==1, {1, 0}, g = If[i>n, {0, 0}, b[n-i, i]]; b[n, i-1] + g + {0, If[i==3, g[[1]], 0]}]]; a[n_] := b[n, n][[2]]; Table[a[n], {n, 1, 100}] (* Jean-François Alcover, Oct 09 2015, after Alois P. Heinz *)
    Join[{0, 0}, (1/((1 - x^3) QPochhammer[x]) + O[x]^50)[[3]]] (* Vladimir Reshetnikov, Nov 22 2016 *)

Formula

a(n) = A181187(n,3) - A181187(n,4). - Omar E. Pol, Oct 25 2012
a(n) = Sum_{k=1..floor(n/3)} A263232(n,k). - Alois P. Heinz, Nov 01 2015
a(n) ~ exp(Pi*sqrt(2*n/3)) / (6*Pi*sqrt(2*n)) * (1 - 37*Pi/(24*sqrt(6*n)) + (37/48 + 937*Pi^2/6912)/n). - Vaclav Kotesovec, Nov 05 2016
G.f.: x^3/((1 - x)*(1 - x^2)*(1 - x^3)) * Sum_{n >= 0} x^(3*n)/( Product_{k = 1..n} 1 - x^k ); that is, convolution of A069905 (partitions into 3 parts, or, modulo offset differences, partitions into parts <= 3) and A008483 (partitions into parts >= 3). - Peter Bala, Jan 17 2021

A024789 Number of 5's in all partitions of n.

Original entry on oeis.org

0, 0, 0, 0, 1, 1, 2, 3, 5, 8, 12, 17, 25, 35, 50, 68, 94, 126, 170, 226, 299, 391, 511, 660, 853, 1091, 1393, 1766, 2235, 2811, 3527, 4403, 5484, 6800, 8415, 10369, 12752, 15627, 19110, 23298, 28346, 34389, 41642, 50295, 60636, 72929, 87563, 104903, 125470
Offset: 1

Views

Author

Keywords

Comments

The sums of five successive terms give A000070. - Omar E. Pol, Jul 12 2012
a(n) is also the difference between the sum of 5th largest and the sum of 6th largest elements in all partitions of n. - Omar E. Pol, Oct 25 2012

Examples

			From _Omar E. Pol_, Oct 25 2012: (Start)
For n = 8 we have:
--------------------------------------
.                             Number
Partitions of 8               of 5's
--------------------------------------
8 .............................. 0
4 + 4 .......................... 0
5 + 3 .......................... 1
6 + 2 .......................... 0
3 + 3 + 2 ...................... 0
4 + 2 + 2 ...................... 0
2 + 2 + 2 + 2 .................. 0
7 + 1 .......................... 0
4 + 3 + 1 ...................... 0
5 + 2 + 1 ...................... 1
3 + 2 + 2 + 1 .................. 0
6 + 1 + 1 ...................... 0
3 + 3 + 1 + 1 .................. 0
4 + 2 + 1 + 1 .................. 0
2 + 2 + 2 + 1 + 1 .............. 0
5 + 1 + 1 + 1 .................. 1
3 + 2 + 1 + 1 + 1 .............. 0
4 + 1 + 1 + 1 + 1 .............. 0
2 + 2 + 1 + 1 + 1 + 1 .......... 0
3 + 1 + 1 + 1 + 1 + 1 .......... 0
2 + 1 + 1 + 1 + 1 + 1 + 1 ...... 0
1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 .. 0
------------------------------------
.               7 - 4 =          3
The difference between the sum of the fifth column and the sum of the sixth column of the set of partitions of 8 is 7 - 4 = 3 and equals the number of 5's in all partitions of 8, so a(8) = 3.
(End)
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i) option remember; local g;
          if n=0 or i=1 then [1, 0]
        else g:= `if`(i>n, [0$2], b(n-i, i));
             b(n, i-1) +g +[0, `if`(i=5, g[1], 0)]
          fi
        end:
    a:= n-> b(n, n)[2]:
    seq(a(n), n=1..100);  # Alois P. Heinz, Oct 27 2012
  • Mathematica
    Table[ Count[ Flatten[ IntegerPartitions[n]], 5], {n, 1, 50} ]
    (* second program: *)
    b[n_, i_] := b[n, i] = Module[{g}, If[n == 0 || i == 1, {1, 0}, g = If[i > n, {0, 0}, b[n - i, i]]; b[n, i - 1] + g + {0, If[i == 5, g[[1]], 0]}]]; a[n_] := b[n, n][[2]]; Table[a[n], {n, 1, 100}] (* Jean-François Alcover, Oct 09 2015, after Alois P. Heinz *)
  • PARI
    x='x+O('x^50); concat([0, 0, 0, 0], Vec(x^5/(1 - x^5) * prod(k=1, 50, 1/(1 - x^k)))) \\ Indranil Ghosh, Apr 06 2017

Formula

a(n) = A181187(n,5) - A181187(n,6). - Omar E. Pol, Oct 25 2012
a(n) ~ exp(Pi*sqrt(2*n/3)) / (10*Pi*sqrt(2*n)) * (1 - 61*Pi/(24*sqrt(6*n)) + (61/48 + 2521*Pi^2/6912)/n). - Vaclav Kotesovec, Nov 05 2016
G.f.: x^5/(1 - x^5) * Product_{k>=1} 1/(1 - x^k). - Ilya Gutkovskiy, Apr 06 2017

A024790 Number of 6's in all partitions of n.

Original entry on oeis.org

0, 0, 0, 0, 0, 1, 1, 2, 3, 5, 7, 12, 16, 24, 33, 47, 63, 89, 117, 159, 209, 278, 360, 474, 607, 786, 1001, 1280, 1615, 2049, 2565, 3222, 4011, 4998, 6180, 7653, 9407, 11571, 14154, 17308, 21063, 25630, 31044, 37586, 45339, 54646, 65646, 78804, 94305, 112761, 134473
Offset: 1

Views

Author

Keywords

Comments

The sums of six successive terms give A000070. - Omar E. Pol, Jul 12 2012
a(n) is also the difference between the sum of 6th largest and the sum of 7th largest elements in all partitions of n. - Omar E. Pol, Oct 25 2012

Crossrefs

Programs

  • Maple
    b:= proc(n, i) option remember; local g;
          if n=0 or i=1 then [1, 0]
        else g:= `if`(i>n, [0$2], b(n-i, i));
             b(n, i-1) +g +[0, `if`(i=6, g[1], 0)]
          fi
        end:
    a:= n-> b(n, n)[2]:
    seq(a(n), n=1..100);  # Alois P. Heinz, Oct 27 2012
  • Mathematica
    Table[ Count[ Flatten[ IntegerPartitions[n]], 6], {n, 1, 52} ]
    b[n_, i_] := b[n, i] = Module[{g}, If [n == 0 || i == 1, {1, 0}, g = If[i > n, {0, 0}, b[n - i, i]]; b[n, i - 1] + g + {0, If[i == 6, g[[1]], 0]}]]; a[n_] := b[n, n][[2]]; Table[a[n], {n, 1, 100}] (* Jean-François Alcover, Oct 09 2015, after Alois P. Heinz *)

Formula

a(n) = A181187(n,6) - A181187(n,7). - Omar E. Pol, Oct 25 2012
From Peter Bala, Dec 26 2013: (Start)
a(n+6) - a(n) = A000041(n). a(n) + a(n+3) = A024787(n).
a(n) + a(n+2) + a(n+4) = A024786(n).
O.g.f.: x^6/(1 - x^6) * product {k >= 1} 1/(1 - x^k) = x^6 + x^7 + 2*x^8 + 3*x^9 + ....
Asymptotic result: log(a(n)) ~ 2*sqrt(Pi^2/6)*sqrt(n) as n -> inf. (End)
a(n) ~ exp(Pi*sqrt(2*n/3)) / (12*Pi*sqrt(2*n)) * (1 - 73*Pi/(24*sqrt(6*n)) + (73/48 + 3601*Pi^2/6912)/n). - Vaclav Kotesovec, Nov 05 2016

A024794 Number of 10's in all partitions of n.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 2, 3, 5, 7, 11, 15, 22, 30, 43, 57, 79, 104, 140, 183, 242, 312, 407, 520, 670, 849, 1081, 1359, 1715, 2141, 2678, 3322, 4125, 5085, 6274, 7691, 9430, 11502, 14025, 17024, 20655, 24959, 30140, 36270, 43612, 52274, 62604, 74763
Offset: 1

Views

Author

Keywords

Comments

The sums of ten successive terms give A000070. - Omar E. Pol, Jul 12 2012
a(n) is also the difference between the sum of 10th largest and the sum of 11th largest elements in all partitions of n. - Omar E. Pol, Oct 25 2012
In general, if m>0 and a(n+m)-a(n) = A000041(n), then a(n) ~ exp(sqrt(2*n/3)*Pi) / (2*Pi*m*sqrt(2*n)) * (1 - Pi*(1/24 + m/2)/sqrt(6*n) + (1/48 + Pi^2/6912 + m/4 + m*Pi^2/288 + m^2*Pi^2/72)/n). - Vaclav Kotesovec, Nov 05 2016

Crossrefs

Programs

  • Maple
    b:= proc(n, i) option remember; local g;
          if n=0 or i=1 then [1, 0]
        else g:= `if`(i>n, [0$2], b(n-i, i));
             b(n, i-1) +g +[0, `if`(i=10, g[1], 0)]
          fi
        end:
    a:= n-> b(n, n)[2]:
    seq(a(n), n=1..100);  # Alois P. Heinz, Oct 27 2012
  • Mathematica
    Table[ Count[ Flatten[ IntegerPartitions[n]], 10], {n, 1, 55} ]
    b[n_, i_] := b[n, i] = Module[{g}, If[n == 0 || i == 1, {1, 0}, g = If[i > n, {0, 0}, b[n - i, i]]; b[n, i - 1] + g + {0, If[i == 10, g[[1]], 0]}]]; a[n_] := b[n, n][[2]]; Table[a[n], {n, 1, 100}] (* Jean-François Alcover, Oct 09 2015, after Alois P. Heinz *)

Formula

a(n) = A181187(n,10) - A181187(n,11). - Omar E. Pol, Oct 25 2012
From Peter Bala, Dec 26 2013: (Start)
a(n+10) - a(n) = A000041(n). a(n) + a(n+5) = A024789(n).
a(n) + a(n+2) + a(n+4) + a(n+6) + a(n+8) = A024786(n).
O.g.f.: x^10/(1 - x^10) * product {k >= 1} 1/(1 - x^k) = x^10 + x^11 + 2*x^12 + 3*x^13 + ....
Asymptotic result: log(a(n)) ~ 2*sqrt(Pi^2/6)*sqrt(n) as n -> inf. (End)
a(n) ~ exp(Pi*sqrt(2*n/3)) / (20*Pi*sqrt(2*n)) * (1 - 121*Pi/(24*sqrt(6*n)) + (121/48 + 9841*Pi^2/6912)/n). - Vaclav Kotesovec, Nov 05 2016

A024792 Number of 8's in all partitions of n.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 1, 1, 2, 3, 5, 7, 11, 15, 23, 31, 44, 59, 82, 108, 146, 191, 254, 328, 429, 549, 709, 900, 1148, 1446, 1829, 2286, 2865, 3559, 4427, 5465, 6752, 8288, 10178, 12429, 15175, 18442, 22404, 27102, 32767, 39473, 47516, 57012, 68349, 81703, 97579, 116236
Offset: 1

Views

Author

Keywords

Comments

The sums of eight successive terms give A000070. - Omar E. Pol, Jul 12 2012
a(n) is also the difference between the sum of 8th largest and the sum of 9th largest elements in all partitions of n. - Omar E. Pol, Oct 25 2012

Crossrefs

Programs

  • Maple
    b:= proc(n, i) option remember; local g;
          if n=0 or i=1 then [1, 0]
        else g:= `if`(i>n, [0$2], b(n-i, i));
             b(n, i-1) +g +[0, `if`(i=8, g[1], 0)]
          fi
        end:
    a:= n-> b(n, n)[2]:
    seq(a(n), n=1..100);  # Alois P. Heinz, Oct 27 2012
  • Mathematica
    Table[ Count[ Flatten[ IntegerPartitions[n]], 8], {n, 1, 53} ]
    (* second program: *)
    b[n_, i_] := b[n, i] = Module[{g}, If[n == 0 || i == 1, {1, 0}, g = If[i > n, {0, 0}, b[n - i, i]]; b[n, i - 1] + g + {0, If[i == 8, g[[1]], 0]}]]; a[n_] := b[n, n][[2]]; Table[a[n], {n, 1, 100}] (* Jean-François Alcover, Oct 09 2015, after Alois P. Heinz *)

Formula

a(n) = A181187(n,8) - A181187(n,9). - Omar E. Pol, Oct 25 2012
From Peter Bala, Dec 26 2013: (Start)
a(n+8) - a(n) = A000041(n). a(n) + a(n+4) = A024788(n).
a(n) + a(n+2) + a(n+4) + a(n+6) = A024786(n).
O.g.f.: x^8/(1 - x^8) * product {k >= 1} 1/(1 - x^k) = x^8 + x^9 + 2*x^10 + 3*x^11 + ....
Asymptotic result: log(a(n)) ~ 2*sqrt(Pi^2/6)*sqrt(n) as n -> inf. (End)
a(n) ~ exp(Pi*sqrt(2*n/3)) / (16*Pi*sqrt(2*n)) * (1 - 97*Pi/(24*sqrt(6*n)) + (97/48 + 6337*Pi^2/6912)/n). - Vaclav Kotesovec, Nov 05 2016

A024793 Number of 9's in all partitions of n.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 2, 3, 5, 7, 11, 15, 22, 31, 43, 58, 80, 106, 142, 187, 246, 319, 416, 533, 685, 872, 1108, 1397, 1762, 2204, 2755, 3426, 4251, 5250, 6476, 7950, 9746, 11905, 14514, 17638, 21403, 25888, 31265, 37661, 45288, 54329, 65079, 77775
Offset: 1

Views

Author

Keywords

Comments

The sums of nine successive terms give A000070. - Omar E. Pol, Jul 12 2012
a(n) is also the difference between the sum of 9th largest and the sum of 10th largest elements in all partitions of n. - Omar E. Pol, Oct 25 2012

Crossrefs

Programs

  • Maple
    b:= proc(n, i) option remember; local g;
          if n=0 or i=1 then [1, 0]
        else g:= `if`(i>n, [0$2], b(n-i, i));
             b(n, i-1) +g +[0, `if`(i=9, g[1], 0)]
          fi
        end:
    a:= n-> b(n, n)[2]:
    seq(a(n), n=1..100);  # Alois P. Heinz, Oct 27 2012
  • Mathematica
    Table[ Count[ Flatten[ IntegerPartitions[n]], 9], {n, 1, 55} ]
    (* second program: *)
    b[n_, i_] := b[n, i] = Module[{g}, If[n == 0 || i == 1, {1, 0}, g = If[i > n, {0, 0}, b[n - i, i]]; b[n, i - 1] + g + {0, If[i == 9, g[[1]], 0]}]]; a[n_] := b[n, n][[2]]; Table[a[n], {n, 1, 100}] (* Jean-François Alcover, Oct 09 2015, after Alois P. Heinz *)

Formula

a(n) = A181187(n,9) - A181187(n,10). - Omar E. Pol, Oct 25 2012
From Peter Bala, Dec 26 2013: (Start)
a(n+9) - a(n) = A000041(n).
a(n) + a(n+3) + a(n+6) = A024787(n).
O.g.f.: x^9/(1 - x^9) * product {k >= 1} 1/(1 - x^k) = x^9 + x^10 + 2*x^11 + 3*x^12 + ....
Asymptotic result: log(a(n)) ~ 2*sqrt(Pi^2/6)*sqrt(n) as n -> inf. (End)
a(n) ~ exp(Pi*sqrt(2*n/3)) / (18*Pi*sqrt(2*n)) * (1 - 109*Pi/(24*sqrt(6*n)) + (109/48 + 7993*Pi^2/6912)/n). - Vaclav Kotesovec, Nov 05 2016

A206557 Number of 7's in the last section of the set of partitions of n.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 1, 0, 1, 1, 2, 2, 4, 5, 7, 9, 13, 16, 23, 28, 39, 48, 64, 79, 104, 128, 165, 204, 258, 317, 399, 487, 606, 739, 912, 1105, 1356, 1637, 1994, 2400, 2906, 3485, 4199, 5016, 6015, 7164, 8553, 10151, 12076, 14286, 16930, 19974, 23588, 27749
Offset: 1

Views

Author

Omar E. Pol, Feb 09 2012

Keywords

Comments

Zero together with the first differences of A024791. Also number of occurrences of 7 in all partitions of n that do not contain 1 as a part. For the definition of "last section of n" see A135010. It appears that the sums of seven successive terms give the partition numbers A000041.

Crossrefs

Programs

  • Sage
    A206557 = lambda n: sum(list(p).count(7) for p in Partitions(n) if 1 not in p)

Formula

It appears that A000041(n) = Sum_{j=1..7} a(n+j), n >= 0.

A179385 The n-th term is the sum of all the 1's generated from all the combinations of prime numbers and ones possible, that add to n, when each prime is only allowed once and any number of ones are allowed.

Original entry on oeis.org

1, 2, 4, 7, 10, 15, 20, 27, 35, 44, 55, 67, 81, 97, 115, 135, 158, 183, 212, 244, 280, 320, 364, 413, 467, 526, 591, 661, 737, 820, 909, 1007, 1112, 1226, 1349, 1481, 1624, 1778, 1943, 2121, 2311, 2515, 2734, 2968, 3219, 3486, 3771, 4075, 4399, 4744, 5112, 5502
Offset: 1

Views

Author

Joseph Foley, Jul 12 2010

Keywords

Examples

			n=7 gives 11111 11, 2111 11, 311 11, 5 11, 5 2, 32 11. (Grouped in 5's) no. of 1's: 7, 5, 4, 2, 0, 2. Sum is 20, therefore a(7) = 20.
n=12 gives 11111 11111 11, 11111 11111 2, 11111 311 11, 11111 32 11, 11111 5 11, 5 2111 11, 5 311 11, 5 32 11, 7111 11, 721 11, 73 11, 73 2, 75, eleven 1, no. of 1's: 12, 10, 9, 7, 7, 5, 4, 2, 5, 3, 2, 0, 0, 1. Sum is 67, therefore a(12) = 67.
1: 1 => 1 2: 11, 2 => 2 3: 111, 21 => 4 4: 1111, 211, 22, 31 => 7 5: 11111, 2111, 311, 23 => 10 6: 11111 1, 2111 1, 311 1, 23 1, 5 1 => 15 and so on.
		

Crossrefs

Programs

  • Maple
    b:= proc(n,i) option remember; if n<=0 then 0 elif i=0 then n else b(n, i-1) +b(n-ithprime(i), i-1) fi end: # R. J. Mathar, Jul 14 2010
    a:= n-> b(n, numtheory[pi](n)): seq(a(n), n=1..80); # Alois P. Heinz
  • Mathematica
    fQ[lst_List] := Sort@ Flatten@ Most@ Split@ lst == Rest@ Union@ lst; f[n_] := Sum[ Count[ Select[ IntegerPartitions[n, {k}, Join[{1}, Prime@ Range@ PrimePi@n]], fQ@# &], 1, 2], {k, n}]; Array[f, 50] (* improved by Robert G. Wilson v, Jul 20 2010 *)
    (* second program: *)
    b[n_, i_] := b[n, i] = If[n == 0, 1, If[i < 1, 0, b[n, i - 1] + If[Prime[i] > n, 0, b[n - Prime[i], i - 1]]]];
    a[n_] := Sum[k*b[n - k, PrimePi[n - k]], {k, 1, n}];
    Table[a[n], {n, 1, 80}] (* Jean-François Alcover, Aug 29 2016, after Alois P. Heinz *)
  • PARI
    a(n) = my(r); r = x/(1-x)^2 + O(x^(n+1)); forprime(p=2,n,r*=1+x^p); polcoeff(r,n) \\ Max Alekseyev, Jul 14 2010

Formula

a(n) = Sum_{k=1..n} k * A000586(n-k). - Max Alekseyev, Jul 14 2010

Extensions

Corrected and extended by R. J. Mathar, Jul 14 2010
Showing 1-10 of 11 results. Next