A353851
Number of integer compositions of n with all equal run-sums.
Original entry on oeis.org
1, 1, 2, 2, 5, 2, 8, 2, 12, 5, 8, 2, 34, 2, 8, 8, 43, 2, 52, 2, 70, 8, 8, 2, 282, 5, 8, 18, 214, 2, 386, 2, 520, 8, 8, 8, 1957, 2, 8, 8, 2010, 2, 2978, 2, 3094, 94, 8, 2, 16764, 5, 340, 8, 12310, 2, 26514, 8, 27642, 8, 8, 2, 132938, 2, 8, 238, 107411, 8, 236258
Offset: 0
The a(0) = 1 through a(8) = 12 compositions:
() (1) (2) (3) (4) (5) (6) (7) (8)
(11) (111) (22) (11111) (33) (1111111) (44)
(112) (222) (224)
(211) (1113) (422)
(1111) (2112) (2222)
(3111) (11114)
(11211) (41111)
(111111) (111122)
(112112)
(211211)
(221111)
(11111111)
For example:
(1,1,2,1,1) has run-sums (2,2,2) so is counted under a(6).
(4,1,1,1,1,2,2) has run-sums (4,4,4) so is counted under a(12).
(3,3,2,2,2) has run-sums (6,6) so is counted under a(12).
The version for parts or runs instead of run-sums is
A000005.
The version for multiplicities instead of run-sums is
A098504.
All parts are divisors of n, see
A100346.
The version for run-lengths instead of run-sums is
A329738, ptns
A047966.
These compositions are ranked by
A353848.
The distinct instead of equal version is
A353850.
A005811 counts runs in binary expansion.
A353847 represents the composition run-sum transformation.
Cf.
A000005,
A006881,
A238279,
A275870,
A333755,
A351014,
A351016,
A351017,
A353832,
A353834,
A353849,
A353853-
A353859 (run-sum trajectory),
A353860,
A353863,
A353864,
A353932.
-
Table[Length[Select[Join@@Permutations/@ IntegerPartitions[n],SameQ@@Total/@Split[#]&]],{n,0,15}]
-
a(n) = {if(n <=1, return(1)); my(d = divisors(n), res = 0); for(i = 1, #d, nd = numdiv(d[i]); res+=(nd*(nd-1)^(n/d[i]-1)) ); res } \\ David A. Corneth, Jun 02 2022
A098504
Number of compositions of n such that every part occurs with the same multiplicity.
Original entry on oeis.org
1, 1, 2, 4, 5, 6, 20, 14, 28, 49, 72, 66, 298, 134, 304, 646, 707, 618, 3794, 1178, 4856, 7926, 6300, 4758, 64004, 9267, 19624, 69346, 76148, 30462, 1491780, 55742, 294642, 1181578, 386820, 932804, 21400221, 315974, 1045372, 12081290, 66532116, 958266
Offset: 0
a(6) = 20 because we have 6, 15, 51, 24, 42, 33, 123, 132, 213, 231, 312, 321, 222, 1122, 1212, 1221, 2112, 2121, 2211 and 111111.
-
G:= sum(sum((l*k)!/l!^k*x^(l*k*(k+1)/2)/product(1-x^(l*j),j=1..k), k=1..40),l=1..55):Gser:=series(G,x=0,55):seq(coeff(Gser,x^n), n=1..46); # Emeric Deutsch, Mar 28 2005
# second Maple program:
b:= proc(n, i) option remember; `if`(n>i*(i+1)/2, 0, `if`(n=0, 1,
expand(b(n, i-1)+`if`(i>n, 0, b(n-i, i-1)*x))))
end:
a:= n-> `if`(n=0, 1, add((p-> add(coeff(p, x, i)*(i*m)!/(m!)^i,
i=0..degree(p)))(b(n/m$2)), m=numtheory[divisors](n))):
seq(a(n), n=0..70); # Alois P. Heinz, May 24 2014
-
b[n_, i_] := b[n, i] = If[n>i*(i+1)/2, 0, If[n == 0, 1, Expand[b[n, i-1] + If[i>n, 0, b[n-i, i-1]*x]]]]; a[n_] := If[n == 0, 1, Sum[Function[p, Sum[Coefficient[p, x, i]*(i*m)!/m!^i, {i, 0, Exponent[p, x]}]][b[n/m, n/m]], {m, Divisors[n]}]]; Table[a[n], {n, 0, 70}] (* Jean-François Alcover, Dec 21 2016, after Alois P. Heinz *)
A317081
Number of integer partitions of n whose multiplicities cover an initial interval of positive integers.
Original entry on oeis.org
1, 1, 1, 2, 3, 5, 5, 9, 11, 16, 20, 30, 34, 50, 58, 79, 96, 129, 152, 203, 243, 307, 375, 474, 563, 707, 850, 1042, 1246, 1532, 1815, 2215, 2632, 3173, 3765, 4525, 5323, 6375, 7519, 8916, 10478, 12414, 14523, 17133, 20034, 23488, 27422, 32090, 37285, 43511, 50559
Offset: 0
The a(1) = 1 through a(9) = 16 partitions:
(1) (2) (3) (4) (5) (6) (7) (8) (9)
(21) (31) (32) (42) (43) (53) (54)
(211) (41) (51) (52) (62) (63)
(221) (321) (61) (71) (72)
(311) (411) (322) (332) (81)
(331) (422) (432)
(421) (431) (441)
(511) (521) (522)
(3211) (611) (531)
(3221) (621)
(4211) (711)
(3321)
(4221)
(4311)
(5211)
(32211)
The case with parts also covering an initial interval is
A317088.
These partitions are ranked by
A317090.
A047966 counts partitions with constant section-sums.
A048767 interchanges prime indices and prime multiplicities (Look-and-Say), see
A048768.
A055932 lists numbers whose prime indices cover an initial interval.
A116540 counts normal set multipartitions.
A381436 lists the section-sum partition of prime indices.
A381440 lists the Look-and-Say partition of prime indices.
-
normalQ[m_]:=Union[m]==Range[Max[m]];
Table[Length[Select[IntegerPartitions[n],normalQ[Length/@Split[#]]&]],{n,30}]
-
from sympy.utilities.iterables import partitions
def A317081(n):
if n == 0:
return 1
c = 0
for d in partitions(n):
s = set(d.values())
if len(s) == max(s):
c += 1
return c # Chai Wah Wu, Jun 22 2020
A353846
Triangle read by rows where T(n,k) is the number of integer partitions of n with partition run-sum trajectory of length k.
Original entry on oeis.org
1, 0, 1, 0, 1, 1, 0, 2, 1, 0, 0, 2, 2, 1, 0, 0, 3, 4, 0, 0, 0, 0, 4, 6, 1, 0, 0, 0, 0, 5, 9, 1, 0, 0, 0, 0, 0, 6, 11, 4, 1, 0, 0, 0, 0, 0, 8, 20, 2, 0, 0, 0, 0, 0, 0, 0, 10, 25, 7, 0, 0, 0, 0, 0, 0, 0, 0, 12, 37, 6, 1, 0, 0, 0, 0, 0, 0, 0
Offset: 0
Triangle begins:
1
0 1
0 1 1
0 2 1 0
0 2 2 1 0
0 3 4 0 0 0
0 4 6 1 0 0 0
0 5 9 1 0 0 0 0
0 6 11 4 1 0 0 0 0
0 8 20 2 0 0 0 0 0 0
0 10 25 7 0 0 0 0 0 0 0
0 12 37 6 1 0 0 0 0 0 0 0
0 15 47 13 2 0 0 0 0 0 0 0 0
0 18 67 15 1 0 0 0 0 0 0 0 0 0
0 22 85 25 3 0 0 0 0 0 0 0 0 0 0
0 27 122 26 1 0 0 0 0 0 0 0 0 0 0 0
For example, row n = 8 counts the following partitions (empty columns indicated by dots):
. (8) (44) (422) (4211) . . . .
(53) (332) (32111)
(62) (611) (41111)
(71) (2222) (221111)
(431) (3221)
(521) (3311)
(5111)
(22211)
(311111)
(2111111)
(11111111)
The version for run-lengths instead of run-sums is
A225485 or
A325280.
A005811 counts runs in binary expansion.
A353832 represents the operation of taking run-sums of a partition
A353836 counts partitions by number of distinct run-sums.
A353838 ranks partitions with all distinct run-sums, counted by
A353837.
A353845 counts partitions whose run-sum trajectory ends in a singleton.
-
rsn[y_]:=If[y=={},{},NestWhileList[Reverse[Sort[Total/@ Split[Sort[#]]]]&,y,!UnsameQ@@#&]];
Table[Length[Select[IntegerPartitions[n],Length[rsn[#]]==k&]],{n,0,15},{k,0,n}]
A175804
Square array A(n,k), n>=0, k>=0, read by antidiagonals: A(n,k) is the n-th term of the k-th differences of partition numbers A000041.
Original entry on oeis.org
1, 0, 1, 1, 1, 2, -1, 0, 1, 3, 2, 1, 1, 2, 5, -4, -2, -1, 0, 2, 7, 9, 5, 3, 2, 2, 4, 11, -21, -12, -7, -4, -2, 0, 4, 15, 49, 28, 16, 9, 5, 3, 3, 7, 22, -112, -63, -35, -19, -10, -5, -2, 1, 8, 30, 249, 137, 74, 39, 20, 10, 5, 3, 4, 12, 42, -539, -290, -153, -79, -40, -20, -10, -5, -2, 2, 14, 56
Offset: 0
Square array A(n,k) begins:
1, 0, 1, -1, 2, -4, 9, ...
1, 1, 0, 1, -2, 5, -12, ...
2, 1, 1, -1, 3, -7, 16, ...
3, 2, 0, 2, -4, 9, -19, ...
5, 2, 2, -2, 5, -10, 20, ...
7, 4, 0, 3, -5, 10, -20, ...
11, 4, 3, -2, 5, -10, 22, ...
- Alois P. Heinz, Antidiagonals n = 0..140, flattened
- Gert Almkvist, On the differences of the partition function, Acta Arith., 61.2 (1992), 173-181.
- Charles Knessl, Asymptotic Behavior of High-Order Differences of the Partition Function, Communications on Pure and Applied Mathematics, 44 (1991), 1033-1045.
- A. M. Odlyzko, Differences of the partition function, Acta Arith., 49 (1988), 237-254.
Row n = 1 is
A320590 except first term.
For squarefree numbers we have
A377038.
For nonsquarefree numbers we have
A377046.
-
A41:= combinat[numbpart]:
DD:= proc(p) proc(n) option remember; p(n+1) -p(n) end end:
A:= (n,k)-> (DD@@k)(A41)(n):
seq(seq(A(n, d-n), n=0..d), d=0..11);
-
max = 11; a41 = Array[PartitionsP, max+1, 0]; a[n_, k_] := Differences[a41, k][[n+1]]; Table[a[n, k-n], {k, 0, max}, {n, 0, k}] // Flatten (* Jean-François Alcover, Aug 29 2014 *)
nn=5;Table[Table[Sum[(-1)^(k-i)*Binomial[k,i]*PartitionsP[n+i],{i,0,k}],{k,0,nn}],{n,0,nn}] (* Gus Wiseman, Dec 15 2024 *)
A382525
Number of times n appears in A048767 (rank of Look-and-Say partition of prime indices). Number of ordered set partitions whose block-sums are the prime signature of n.
Original entry on oeis.org
1, 1, 1, 1, 1, 0, 1, 2, 1, 0, 1, 1, 1, 0, 0, 2, 1, 1, 1, 1, 0, 0, 1, 1, 1, 0, 2, 1, 1, 0, 1, 3, 0, 0, 0, 0, 1, 0, 0, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0, 1, 0, 1, 0, 1, 4, 0, 0, 1, 1, 0, 0, 1, 1, 1, 0, 1, 1, 0, 0, 1, 1, 2, 0, 1, 0, 0, 0, 0
Offset: 1
The a(27) = 2 partitions with Look-and-Say partition (2,2,2) are: (3,3), (2,2,1,1).
The prime indices of 3456 are {1,1,1,1,1,1,1,2,2,2}, and the partitions with Look-and-Say partition (2,2,2,1,1,1,1,1,1,1) are:
(7,3,3)
(7,2,2,1,1)
(6,3,3,1)
(5,3,3,2)
(4,3,3,2,1)
(4,3,2,2,1,1)
so a(3456) = 6.
Positions of first appearances are
A382775.
A000670 counts ordered set partitions.
A003963 gives product of prime indices.
A122111 represents conjugation in terms of Heinz numbers.
A381436 lists the section-sum partition of prime indices, ranks
A381431.
A381440 lists the Look-and-Say partition of prime indices, ranks
A048767.
Cf.
A003557,
A047966,
A048768,
A050361,
A051903,
A051904,
A066328,
A071178,
A116861,
A130091,
A217605,
A239964.
-
stp[y_]:=Select[Tuples[Select[IntegerPartitions[#],UnsameQ@@#&]&/@y],UnsameQ@@Join@@#&];
Table[Length[stp[Last/@FactorInteger[n]]],{n,100}]
A382857
Number of ways to permute the prime indices of n so that the run-lengths are all equal.
Original entry on oeis.org
1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 2, 1, 1, 1, 1, 1, 2, 2, 1, 0, 1, 2, 1, 1, 1, 6, 1, 1, 2, 2, 2, 4, 1, 2, 2, 0, 1, 6, 1, 1, 1, 2, 1, 0, 1, 1, 2, 1, 1, 0, 2, 0, 2, 2, 1, 6, 1, 2, 1, 1, 2, 6, 1, 1, 2, 6, 1, 1, 1, 2, 1, 1, 2, 6, 1, 0, 1, 2, 1, 6, 2, 2
Offset: 0
The prime indices of 216 are {1,1,1,2,2,2} and we have permutations:
(1,1,1,2,2,2)
(1,2,1,2,1,2)
(2,1,2,1,2,1)
(2,2,2,1,1,1)
so a(216) = 4.
The prime indices of 25920 are {1,1,1,1,1,1,2,2,2,2,3} and we have permutations:
(1,2,1,2,1,2,1,2,1,3,1)
(1,2,1,2,1,2,1,3,1,2,1)
(1,2,1,2,1,3,1,2,1,2,1)
(1,2,1,3,1,2,1,2,1,2,1)
(1,3,1,2,1,2,1,2,1,2,1)
so a(25920) = 5.
For distinct instead of equal run-lengths we have
A382771.
For run-sums instead of run-lengths we have
A382877, distinct
A382876.
Positions of first appearances are
A382878.
Positions of terms > 1 are
A383089.
A003963 gives product of prime indices.
A005811 counts runs in binary expansion.
A044813 lists numbers whose binary expansion has distinct run-lengths.
A164707 lists numbers whose binary expansion has all equal run-lengths, distinct
A328592.
A353744 ranks compositions with equal run-lengths, counted by
A329738.
Cf.
A000720,
A000961,
A001221,
A001222,
A003242,
A008480,
A047966,
A238130,
A238279,
A351201,
A351293,
A351295.
-
Table[Length[Select[Permutations[Join@@ConstantArray@@@FactorInteger[n]], SameQ@@Length/@Split[#]&]],{n,0,100}]
A116674
Triangle read by rows: T(n,k) is the number of partitions of n into odd parts and having exactly k distinct parts (n>=1, k>=1).
Original entry on oeis.org
1, 1, 2, 1, 1, 2, 1, 2, 2, 2, 3, 1, 5, 3, 4, 1, 2, 7, 1, 2, 8, 2, 2, 10, 3, 2, 11, 5, 2, 13, 7, 4, 12, 11, 1, 19, 11, 1, 2, 18, 17, 1, 3, 20, 21, 2, 2, 22, 27, 3, 2, 25, 32, 5, 4, 24, 41, 7, 2, 30, 46, 11, 2, 31, 56, 15, 2, 36, 62, 22, 3, 33, 80, 25, 1, 2, 39, 87, 36, 1, 4, 38, 103, 45, 2, 2, 45
Offset: 1
From _Gus Wiseman_, Jun 24 2025: (Start)
Triangle begins:
1: 1
2: 1
3: 2
4: 1 1
5: 2 1
6: 2 2
7: 2 3
8: 1 5
9: 3 4 1
10: 2 7 1
11: 2 8 2
12: 2 10 3
13: 2 11 5
14: 2 13 7
15: 4 12 11
16: 1 19 11 1
17: 2 18 17 1
18: 3 20 21 2
19: 2 22 27 3
20: 2 25 32 5
Row n = 9 counts the following partitions into odd parts by number of distinct parts:
(9) (7,1,1) (5,3,1)
(3,3,3) (3,3,1,1,1)
(1,1,1,1,1,1,1,1,1) (5,1,1,1,1)
(3,1,1,1,1,1,1)
Row n = 9 counts the following strict partitions by number of maximal runs:
(9) (6,3) (5,3,1)
(5,4) (7,2)
(4,3,2) (8,1)
(6,2,1)
(End)
A047993 counts partitions with max part = length.
A152140 counts partitions into odd parts by length.
A268193 counts partitions by number of maximal anti-runs, strict
A384905.
A384881 counts partitions by number of maximal runs.
-
g:=product(1+t*x^(2*j-1)/(1-x^(2*j-1)),j=1..35): gser:=simplify(series(g,x=0,34)): for n from 1 to 29 do P[n]:=coeff(gser,x^n) od: for n from 1 to 29 do seq(coeff(P[n],t,j),j=1..floor(sqrt(n))) od; # yields sequence in triangular form
# second Maple program:
with(numtheory):
b:= proc(n, i) option remember; expand(`if`(n=0, 1,
`if`(i<1, 0, add(b(n-i*j, i-2)*`if`(j=0, 1, x), j=0..n/i))))
end:
T:= n-> (p-> seq(coeff(p, x, i), i=1..degree(p)))(
b(n, iquo(n+1, 2)*2-1)):
seq(T(n), n=1..30); # Alois P. Heinz, Mar 08 2015
-
b[n_, i_] := b[n, i] = Expand[If[n == 0, 1, If[i<1, 0, Sum[b[n-i*j, i-2]*If[j == 0, 1, x], {j, 0, n/i}]]]]; T[n_] := Function[{p}, Table[Coefficient[p, x, i], {i, 1, Exponent[p, x]}]][b[n, Quotient[n+1, 2]*2-1]]; Table[T[n], {n, 1, 30}] // Flatten (* Jean-François Alcover, May 22 2015, after Alois P. Heinz *)
Table[Length[Select[IntegerPartitions[n],OddQ[Times@@#]&&Length[Union[#]]==k&]],{n,1,12},{k,1,Floor[Sqrt[n]]}] (* Gus Wiseman, Jun 24 2025 *)
A383708
Number of integer partitions of n such that it is possible to choose a family of pairwise disjoint strict integer partitions, one of each part.
Original entry on oeis.org
1, 1, 2, 2, 3, 5, 5, 7, 8, 13, 14, 18, 22, 27, 36, 41, 50, 61, 73, 86
Offset: 0
For y = (3,3) we can choose disjoint strict partitions ((2,1),(3)), so (3,3) is counted under a(6).
The a(1) = 1 through a(9) = 8 partitions:
(1) (2) (3) (4) (5) (6) (7) (8) (9)
(2,1) (3,1) (3,2) (3,3) (4,3) (4,4) (5,4)
(4,1) (4,2) (5,2) (5,3) (6,3)
(5,1) (6,1) (6,2) (7,2)
(3,2,1) (4,2,1) (7,1) (8,1)
(4,3,1) (4,3,2)
(5,2,1) (5,3,1)
(6,2,1)
These partitions have Heinz numbers
A382913.
The number of such families for each Heinz number is
A383706.
A098859 counts partitions with distinct multiplicities, compositions
A242882.
Cf.
A044813,
A047966,
A089259,
A116540,
A091602,
A130091,
A317141,
A351013,
A381441,
A382771,
A383013.
-
pof[y_]:=Select[Join@@@Tuples[IntegerPartitions/@y], UnsameQ@@#&];
Table[Length[Select[IntegerPartitions[n], pof[#]!={}&]],{n,15}]
A383710
Number of integer partitions of n such that it is not possible to choose a family of pairwise disjoint strict integer partitions, one of each part.
Original entry on oeis.org
0, 0, 1, 1, 3, 4, 6, 10, 15, 22, 29, 42, 59, 79, 108, 140, 190, 247, 324, 417, 541
Offset: 0
For y = (3,3) we can choose disjoint strict partitions ((2,1),(3)), so (3,3) is not counted under a(6).
The a(2) = 1 through a(8) = 15 partitions:
(11) (111) (22) (221) (222) (322) (332)
(211) (311) (411) (331) (422)
(1111) (2111) (2211) (511) (611)
(11111) (3111) (2221) (2222)
(21111) (3211) (3221)
(111111) (4111) (3311)
(22111) (4211)
(31111) (5111)
(211111) (22211)
(1111111) (32111)
(41111)
(221111)
(311111)
(2111111)
(11111111)
These partitions have Heinz numbers
A382912.
The number of such families for each Heinz number is
A383706.
A098859 counts partitions with distinct multiplicities, compositions
A242882.
-
pof[y_]:=Select[Join@@@Tuples[IntegerPartitions/@y], UnsameQ@@#&];
Table[Length[Select[IntegerPartitions[n], pof[#]=={}&]], {n,0,15}]
Comments