A006128
Total number of parts in all partitions of n. Also, sum of largest parts of all partitions of n.
Original entry on oeis.org
0, 1, 3, 6, 12, 20, 35, 54, 86, 128, 192, 275, 399, 556, 780, 1068, 1463, 1965, 2644, 3498, 4630, 6052, 7899, 10206, 13174, 16851, 21522, 27294, 34545, 43453, 54563, 68135, 84927, 105366, 130462, 160876, 198014, 242812, 297201, 362587, 441546, 536104, 649791, 785437, 947812, 1140945, 1371173, 1644136, 1968379, 2351597, 2805218, 3339869, 3970648, 4712040, 5584141, 6606438, 7805507, 9207637
Offset: 0
For n = 4 the partitions of 4 are [4], [2, 2], [3, 1], [2, 1, 1], [1, 1, 1, 1]. The total number of parts is 12. On the other hand, the sum of the largest parts of all partitions is 4 + 2 + 3 + 2 + 1 = 12, equaling the total number of parts, so a(4) = 12. - _Omar E. Pol_, Oct 12 2018
- S. M. Luthra, On the average number of summands in partitions of n, Proc. Nat. Inst. Sci. India Part. A, 23 (1957), p. 483-498.
- N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
- T. D. Noe and Vaclav Kotesovec, Table of n, a(n) for n = 0..10000 (terms 0..1000 from T. D. Noe)
- Paul Erdős and Joseph Lehner, The distribution of the number of summands in the partitions of a positive integer, Duke Math. J. 8, (1941), 335-345.
- John A. Ewell, Additive evaluation of the divisor function, Fibonacci Quart. 45 (2007), no. 1, 22-25. See Table 1.
- Guo-Niu Han, An explicit expansion formula for the powers of the Euler Product in terms of partition hook lengths, arXiv:0804.1849 [math.CO], 2008; see p.27
- I. Kessler and M. Livingston, The expected number of parts in a partition of n, Monatsh. Math. 81 (1976), no. 3, 203-212.
- I. Kessler and M. Livingston, The expected number of parts in a partition of n, Monatsh. Math. 81 (1976), no. 3, 203-212.
- Martin Klazar, What is an answer? — remarks, results and problems on PIO formulas in combinatorial enumeration, part I, arXiv:1808.08449 [math.CO], 2018.
- Vaclav Kotesovec, Graph - The asymptotic ratio
- Arnold Knopfmacher and Neville Robbins, Identities for the total number of parts in partitions of integers, Util. Math. 67 (2005), 9-18.
- S. M. Luthra, On the average number of summands in partitions of n, Proc. Nat. Inst. Sci. India Part. A, 23 (1957), p. 483-498.
- C. L. Mallows & N. J. A. Sloane, Emails, May 1991
- C. L. Mallows & N. J. A. Sloane, Emails, Jun. 1991
- Ljuben Mutafchiev, On the Largest Part Size and Its Multiplicity of a Random Integer Partition, arXiv:1712.03233 [math.PR], 2017.
- Omar E. Pol, Illustration of initial terms
- J. Sandor, D. S. Mitrinovic, B. Crstici, Handbook of Number Theory I, Volume 1, Springer, 2005, p. 495.
- Eric Weisstein's World of Mathematics, q-Polygamma Function, q-Pochhammer Symbol.
- H. S. Wilf, A unified setting for selection algorithms (II), Annals Discrete Math., 2 (1978), 135-148.
The version for normal multisets is
A001787.
The version for factorizations is
A066637.
A000070 counts partitions with a selected part.
A336875 counts compositions with a selected part.
A339564 counts factorizations with a selected factor.
-
List([0..60],n->Length(Flat(Partitions(n)))); # Muniru A Asiru, Oct 12 2018
-
a006128 = length . concat . ps 1 where
ps _ 0 = [[]]
ps i j = [t:ts | t <- [i..j], ts <- ps t (j - t)]
-- Reinhard Zumkeller, Jul 13 2013
-
g:= add(n*x^n*mul(1/(1-x^k), k=1..n), n=1..61):
a:= n-> coeff(series(g,x,62),x,n):
seq(a(n), n=0..61);
# second Maple program:
a:= n-> add(combinat[numbpart](n-j)*numtheory[tau](j), j=1..n):
seq(a(n), n=0..61); # Alois P. Heinz, Aug 23 2019
-
a[n_] := Sum[DivisorSigma[0, m] PartitionsP[n - m], {m, 1, n}]; Table[ a[n], {n, 0, 41}]
CoefficientList[ Series[ Sum[n*x^n*Product[1/(1 - x^k), {k, n}], {n, 100}], {x, 0, 100}], x]
a[n_] := Plus @@ Max /@ IntegerPartitions@ n; Array[a, 45] (* Robert G. Wilson v, Apr 12 2011 *)
Join[{0}, ((Log[1 - x] + QPolyGamma[1, x])/(Log[x] QPochhammer[x]) + O[x]^60)[[3]]] (* Vladimir Reshetnikov, Nov 17 2016 *)
Length /@ Table[IntegerPartitions[n] // Flatten, {n, 50}] (* Shouvik Datta, Sep 12 2021 *)
-
f(n)= {local(v,i,k,s,t);v=vector(n,k,0);v[n]=2;t=0;while(v[1]1,i--;s+=i*(v[i]=(n-s)\i));t+=sum(k=1,n,v[k]));t } /* Thomas Baruchel, Nov 07 2005 */
-
a(n) = sum(m=1, n, numdiv(m)*numbpart(n-m)) \\ Michel Marcus, Jul 13 2013
-
from sympy import divisor_count, npartitions
def a(n): return sum([divisor_count(m)*npartitions(n - m) for m in range(1, n + 1)]) # Indranil Ghosh, Apr 25 2017
A066186
Sum of all parts of all partitions of n.
Original entry on oeis.org
0, 1, 4, 9, 20, 35, 66, 105, 176, 270, 420, 616, 924, 1313, 1890, 2640, 3696, 5049, 6930, 9310, 12540, 16632, 22044, 28865, 37800, 48950, 63336, 81270, 104104, 132385, 168120, 212102, 267168, 334719, 418540, 520905, 647172, 800569, 988570, 1216215, 1493520
Offset: 0
a(3)=9 because the partitions of 3 are: 3, 2+1 and 1+1+1; and (3) + (2+1) + (1+1+1) = 9.
a(4)=20 because A000041(4)=5 and 4*5=20.
- Vincenzo Librandi, Table of n, a(n) for n = 0..1000
- F. G. Garvan, Higher-order spt functions, Adv. Math. 228 (2011), no. 1, 241-265, alternate copy. - From _N. J. A. Sloane_, Jan 02 2013
- F. G. Garvan, Higher-order spt functions, arXiv:1008.1207 [math.NT], 2010.
- T. J. Osler, A. Hassen and T. R. Chandrupatia, Surprising connections between partitions and divisors, The College Mathematics Journal, Vol. 38. No. 4, Sep. 2007, 278-287 (see p. 287).
- Omar E. Pol, Illustration of a(10), prism and tower, each polycube contains 420 cubes.
- Omar E. Pol, Illustration of initial terms of A066186 and of A139582 (n>=1)
Row sums of triangles
A138785,
A181187,
A245099,
A337209,
A339106,
A340423,
A340424,
A221529,
A302246,
A338156,
A340035,
A340056,
A340057,
A346741. -
Omar E. Pol, Aug 02 2021
-
a066186 = sum . concat . ps 1 where
ps _ 0 = [[]]
ps i j = [t:ts | t <- [i..j], ts <- ps t (j - t)]
-- Reinhard Zumkeller, Jul 13 2013
-
with(combinat): a:= n-> n*numbpart(n): seq(a(n), n=0..50); # Zerinvary Lajos, Apr 25 2007
-
PartitionsP[ Range[0, 60] ] * Range[0, 60]
-
a(n)=numbpart(n)*n \\ Charles R Greathouse IV, Mar 10 2012
-
from sympy import npartitions
def A066186(n): return n*npartitions(n) # Chai Wah Wu, Oct 22 2023
-
[n*Partitions(n).cardinality() for n in range(41)] # Peter Luschny, Jul 29 2014
A207034
Sum of all parts minus the number of parts of the n-th partition in the list of colexicographically ordered partitions of j, if 1<=n<=A000041(j).
Original entry on oeis.org
0, 1, 2, 2, 3, 3, 4, 3, 4, 4, 5, 4, 5, 5, 6, 4, 5, 5, 6, 6, 6, 7, 5, 6, 6, 7, 6, 7, 7, 8, 5, 6, 6, 7, 7, 7, 8, 7, 8, 8, 8, 9, 6, 7, 7, 8, 7, 8, 8, 9, 8, 8, 9, 9, 9, 10, 6, 7, 7, 8, 8, 8, 9, 8, 9, 9, 9, 10, 8, 9, 9, 10, 9, 10, 10, 10, 11, 7, 8, 8, 9, 8, 9
Offset: 1
Illustration of initial terms, n = 1..15. Consider the last 15 rows of the tail of the last section of the set of partitions in colexicographic order of any integer >= 8. The tail contains at least A000041(8-1) = 15 parts of size 1. a(n) is also the number of dots in the n-th row of the diagram.
----------------------------------
n Tail a(n)
----------------------------------
15 1 . . . . . . 6
14 1 . . . . . 5
13 1 . . . . . 5
12 1 . . . . 4
11 1 . . . . . 5
10 1 . . . . 4
9 1 . . . . 4
8 1 . . . 3
7 1 . . . . 4
6 1 . . . 3
5 1 . . . 3
4 1 . . 2
3 1 . . 2
2 1 . 1
1 1 0
----------------------------------
Written as a triangle:
0;
1;
2;
2,3;
3,4;
3,4,4,5;
4,5,5,6;
4,5,5,6,6,6,7;
5,6,6,7,6,7,7,8;
5,6,6,7,7,7,8,7,8,8,8,9;
6,7,7,8,7,8,8,9,8,8,9,9,9,10;
6,7,7,8,8,8,9,8,9,9,9,10,8,9,9,10,9,10,10,10,11;
...
Consider a matrix [j X A000041(j)] in which the rows represent the partitions of j in colexicographic order (see A211992). Every part of every partition is located in a cell of the matrix. We can see that a(n) is the number of empty cells in row n for any integer j, if A000041(j) >= n. The number of empty cells in row n equals the sum of all parts minus the number of parts in the n-th partition of j.
Illustration of initial terms. The smallest part of every partition is located in the last column of the matrix.
---------------------------------------------------------
. j: 1 2 3 4 5 6
n a(n)
---------------------------------------------------------
1 0 | 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
2 1 | . 2 . 2 1 . 2 1 1 . 2 1 1 1 . 2 1 1 1 1
3 2 | . . 3 . . 3 1 . . 3 1 1 . . 3 1 1 1
4 2 | . . 2 2 . . 2 2 1 . . 2 2 1 1
5 3 | . . . 4 . . . 4 1 . . . 4 1 1
6 3 | . . . 3 2 . . . 3 2 1
7 4 | . . . . 5 . . . . 5 1
8 3 | . . . 2 2 2
9 4 | . . . . 4 2
10 4 | . . . . 3 3
11 5 | . . . . . 6
...
Illustration of initial terms. In this case the largest part of every partition is located in the first column of the matrix.
---------------------------------------------------------
. j: 1 2 3 4 5 6
n a(n)
---------------------------------------------------------
1 0 | 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1
2 1 | 2 . 2 1 . 2 1 1 . 2 1 1 1 . 2 1 1 1 1 .
3 2 | 3 . . 3 1 . . 3 1 1 . . 3 1 1 1 . .
4 2 | 2 2 . . 2 2 1 . . 2 2 1 1 . .
5 3 | 4 . . . 4 1 . . . 4 1 1 . . .
6 3 | 3 2 . . . 3 2 1 . . .
7 4 | 5 . . . . 5 1 . . . .
8 3 | 2 2 2 . . .
9 4 | 4 2 . . . .
10 4 | 3 3 . . . .
11 5 | 6 . . . . .
...
Cf.
A135010,
A138121,
A141285,
A182703,
A194548,
A196087,
A207031,
A207032,
A207035,
A211992,
A228716,
A230440.
A207035
Sum of all parts minus the total number of parts of the last section of the set of partitions of n.
Original entry on oeis.org
0, 1, 2, 5, 7, 16, 20, 39, 52, 86, 113, 184, 232, 353, 462, 661, 851, 1202, 1526, 2098, 2670, 3565, 4514, 5967, 7473, 9715, 12162, 15583, 19373, 24625, 30410, 38274, 47112, 58725, 71951, 89129, 108599, 133612, 162259, 198346, 239825, 291718, 351269, 425102
Offset: 1
For n = 7 the last section of the set of partitions of 7 looks like this:
.
. (. . . . . . 7)
. (. . . 4 . . 3)
. (. . . . 5 . 2)
. (. . 3 . 2 . 2)
. (1)
. (1)
. (1)
. (1)
. (1)
. (1)
. (1)
. (1)
. (1)
. (1)
. (1)
.
The sum of all parts = 7+4+3+5+2+3+2+2+1*11 = 39, on the other hand the total number of parts is 1+2+2+3+1*11 = 19, so a(7) = 39 - 19 = 20. Note that the number of dots in the picture is also equal to a(7) = 6+5+5+4 = 20.
Cf.
A006128,
A066186,
A135010,
A138121,
A138135,
A138137,
A138879,
A138880,
A187219,
A194548,
A207038.
-
b:= proc(n, i) option remember; local f, g;
if n=0 then [1, 0]
elif i<2 then [0, 0]
elif i>n then b(n, i-1)
else f:= b(n, i-1); g:= b(n-i, i);
[f[1]+g[1], f[2]+g[2] +g[1]*(i-1)]
fi
end:
a:= n-> b(n, n)[2]:
seq (a(n), n=1..50); # Alois P. Heinz, Feb 20 2012
-
b[n_, i_] := b[n, i] = Module[{f, g}, Which[n==0, {1, 0}, i<2, {0, 0}, i>n , b[n, i-1], True, f = b[n, i-1]; g = b[n-i, i]; {f[[1]] + g[[1]], f[[2]] + g[[2]] + g[[1]]*(i-1)}]]; a[n_] := b[n, n][[2]]; Table[a[n], {n, 1, 50}] (* Jean-François Alcover, Sep 13 2015, after Alois P. Heinz *)
Original entry on oeis.org
0, 1, 3, 5, 8, 11, 15, 18, 22, 26, 31, 35, 40, 45, 51, 55, 60, 65, 71, 77, 83, 90, 95, 101, 107, 114, 120, 127, 134, 142, 147, 153, 159, 166, 173, 180, 188, 195, 203, 211, 219, 228, 234, 241, 248, 256, 263, 271, 279, 288, 296, 304, 313, 322, 331, 341
Offset: 1
Written as a triangle:
0;
1;
3;
5,8;
11,15;
18,22,26,31;
35,40,45,51;
55,60,65,71,77,83,90;
95,101,107,114,120,127,134,142;
147,153,159,166,173,180,188,195,203,211,219,228;
234,241,248,256,263,271,279,288,296,304,313,322,331,341;
A161224
Triangular table a(n,m) that counts the occurrences of m in all partitions of 2n in exactly n parts.
Original entry on oeis.org
0, 0, 1, 1, 2, 1, 3, 4, 1, 1, 8, 7, 3, 1, 1, 15, 12, 4, 2, 1, 1, 31, 19, 8, 4, 2, 1, 1, 51, 30, 11, 6, 3, 2, 1, 1, 90, 45, 19, 9, 6, 3, 2, 1, 1, 142, 67, 26, 15, 8, 5, 3, 2, 1, 1, 228, 97, 41, 21, 13, 8, 5, 3, 2, 1, 1, 341, 139, 56, 31, 18, 12, 7, 5, 3, 2, 1, 1, 525, 195, 83, 45, 28, 17, 12, 7, 5, 3, 2, 1, 1
Offset: 0
Table starts:
0;
0, 1;
1, 2, 1;
3, 4, 1, 1;
8, 7, 3, 1, 1;
since the strict partitions of
(2 in 1 part) is {2} with 0 "1" and 1 "2"
(4 in 2 parts) is {2,2}, {3,1} with1 "1", 2 "2" and 1 "3"
(6 in 3 parts) is {2,2,2}, {3,2,1}, {4,1,1} with 3 "1", 4 "2", 1 "3" and 1 "4"
-
b:= proc(n, i, t) option remember; `if`(n=0, `if`(t=0, 1, 0),
`if`(i=1, `if`(t=n, 1+t*x, 0), expand(add((p->p+coeff(
p, x, 0)*j*x^i)(b(n-i*j, i-1, t-j)), j=0..min(t, n/i)))))
end:
a:= n->(p->seq(coeff(p, x, i), i=1..n+1))(b(2*n$2, n)):
seq(a(n), n=0..12); # Alois P. Heinz, Feb 11 2014
-
<Jean-François Alcover, May 24 2016, after Alois P. Heinz *)
Row 0 inserted and tabf changed to tabl by
Alois P. Heinz, Feb 11 2014
A182276
Sum of all parts minus the total number of parts of the shell model of partitions with n regions.
Original entry on oeis.org
0, 1, 3, 4, 8, 10, 15, 16, 20, 22, 31, 33, 38, 41, 51, 52, 56, 58, 67, 71, 74, 90, 92, 97, 100, 110, 112, 119, 123, 142, 143, 147, 149, 158, 162, 165, 181, 184, 192, 197, 201, 228, 230, 235, 238, 248, 250, 257, 261, 280, 284, 287, 299, 305, 310, 341
Offset: 1
Written has a triangle:
0,
1,
3,
4, 8;
10, 15;
16, 20, 22, 31;
33, 38, 41, 51;
52, 56, 58, 67, 71, 74, 90;
92, 97,100,110,112,119,123,142;
143,147,149,158,162,165,181,184,192,197,201,228;
230,235,238,248,250,257,261,280,284,287,299,305,310,341;
-
lex[n_]:=DeleteCases[Sort@PadRight[Reverse /@ IntegerPartitions@n], x_ /; x==0,2];
reg = {}; l = {};
For[j = 1, j <= 56, j++,
mx = Max@lex[j][[j]]; AppendTo[l, mx];
For[i = j, i > 0, i--, If[l[[i]] > mx, Break[]]];
t = Take[Reverse[First /@ lex[mx]], j - i];
AppendTo[reg, Total@t - Length@t]
];
Accumulate@reg (* Robert Price, Jul 25 2020 *)
Showing 1-7 of 7 results.
Comments