A063834
Twice partitioned numbers: the number of ways a number can be partitioned into not necessarily different parts and each part is again so partitioned.
Original entry on oeis.org
1, 1, 3, 6, 15, 28, 66, 122, 266, 503, 1027, 1913, 3874, 7099, 13799, 25501, 48508, 88295, 165942, 299649, 554545, 997281, 1817984, 3245430, 5875438, 10410768, 18635587, 32885735, 58399350, 102381103, 180634057, 314957425, 551857780, 958031826, 1667918758
Offset: 0
G.f. = 1 + x + 3*x^2 + 6*x^3 + 15*x^4 + 28*x^5 + 66*x^6 + 122*x^7 + 266*x^8 + ...
If n=6, a possible first partitioning is (3+3), resulting in the following second partitionings: ((3),(3)), ((3),(2+1)), ((3),(1+1+1)), ((2+1),(3)), ((2+1),(2+1)), ((2+1),(1+1+1)), ((1+1+1),(3)), ((1+1+1),(2+1)), ((1+1+1),(1+1+1)).
A001970 counts multiset partitions of integer partitions.
-
with(combinat):
b:= proc(n, i) option remember; `if`(n=0 or i=1, 1,
b(n, i-1)+`if`(i>n, 0, numbpart(i)*b(n-i, i)))
end:
a:= n-> b(n$2):
seq(a(n), n=0..50); # Alois P. Heinz, Nov 26 2015
-
Table[Plus @@ Apply[Times, IntegerPartitions[i] /. i_Integer :> PartitionsP[i], 2], {i, 36}]
(* second program: *)
b[n_, i_] := b[n, i] = If[n==0 || i==1, 1, b[n, i-1] + If[i > n, 0, PartitionsP[i]*b[n-i, i]]]; a[n_] := b[n, n]; Table[a[n], {n, 0, 50}] (* Jean-François Alcover, Jan 20 2016, after Alois P. Heinz *)
-
{a(n) = if( n<0, 0, polcoeff( 1 / prod(k=1, n, 1 - numbpart(k) * x^k, 1 + x * O(x^n)), n))}; /* Michael Somos, Dec 19 2016 */
A358914
Number of twice-partitions of n into distinct strict partitions.
Original entry on oeis.org
1, 1, 1, 3, 4, 7, 13, 20, 32, 51, 83, 130, 206, 320, 496, 759, 1171, 1786, 2714, 4104, 6193, 9286, 13920, 20737, 30865, 45721, 67632, 99683, 146604, 214865, 314782, 459136, 668867, 972425, 1410458, 2040894, 2950839, 4253713, 6123836, 8801349, 12627079
Offset: 0
The a(1) = 1 through a(6) = 13 twice-partitions:
((1)) ((2)) ((3)) ((4)) ((5)) ((6))
((21)) ((31)) ((32)) ((42))
((2)(1)) ((3)(1)) ((41)) ((51))
((21)(1)) ((3)(2)) ((321))
((4)(1)) ((4)(2))
((21)(2)) ((5)(1))
((31)(1)) ((21)(3))
((31)(2))
((3)(21))
((32)(1))
((41)(1))
((3)(2)(1))
((21)(2)(1))
This is the distinct case of
A270995.
The case of strictly decreasing sums is
A279785.
The case of constant sums is
A279791.
For distinct instead of weakly decreasing sums we have
A336343.
This is the twice-partition case of
A358913.
A001970 counts multiset partitions of integer partitions.
A055887 counts sequences of partitions.
A330462 counts set systems by total sum and length.
A358830 counts twice-partitions with distinct lengths.
Cf.
A000009,
A000219,
A075900,
A271619,
A296122,
A304969,
A321449,
A336342,
A358901,
A358906,
A358907.
-
twiptn[n_]:=Join@@Table[Tuples[IntegerPartitions/@ptn],{ptn,IntegerPartitions[n]}];
Table[Length[Select[twiptn[n],UnsameQ@@#&&And@@UnsameQ@@@#&]],{n,0,10}]
-
seq(n,k)={my(u=Vec(eta(x^2 + O(x*x^n))/eta(x + O(x*x^n))-1)); Vec(prod(k=1, n, my(c=u[k]); sum(j=0, min(c,n\k), x^(j*k)*c!/(c-j)!, O(x*x^n))))} \\ Andrew Howroyd, Dec 31 2022
A098407
Number of different hierarchical orderings that can be formed from n unlabeled elements with no repetition of subhierarchies.
Original entry on oeis.org
1, 1, 2, 6, 13, 33, 78, 186, 436, 1028, 2394, 5566, 12877, 29689, 68198, 156194, 356599, 811959, 1843956, 4177436, 9442166, 21295934, 47932572, 107677140, 241443980, 540441068, 1207689636, 2694452060, 6002389882, 13351958546, 29659179804, 65794744420, 145768641091
Offset: 0
Let a pair of parentheses () indicate a subhierarchy and let square brackets [] denote a set of subhierarchies, that is, a hierarchy (also called a society). Let the ranks be ordered from left to right and separated by a colon; e.g., (2:3) is a subhierarchy with three elements ("individuals") on top and two elements on the bottom rank.
Then the hierarchical ordering for n = 4 is composed of the following sets: [(1:1),(2)]; [(1),(3)]; [(1),(1:1:1)]; [(1),(2:1)]; [(1),(1:2)]; [(4)]; [(2:2)]; [(1:3)]; [(3:1)]; [(1:1:2)]; [(1:2:1)]; [(2:1:1)]; [(1:1:1:1)]; thus a(4) = 13.
For example, the following hierarchy is not allowed: [(1),(1),(1),(1)] because of the repetition of (1).
-
main := proc(n::integer) local a, ListOfPartitions, NumberOfPartitions, APartition, APart, ASet, MultipliticityOfAPart, ndxprttn, ndxprt, Term, Produkt; with(combinat): with(ListTools): a := 0; ListOfPartitions := partition(n); NumberOfPartitions := nops(ListOfPartitions); for ndxprttn from 1 to NumberOfPartitions do APartition := ListOfPartitions[ndxprttn]; ASet := convert(APartition,set); Produkt := 1; for ndxprt from 1 to nops(ASet) do APart := op(ndxprt,ASet); MultipliticityOfAPart := Occurrences(APart, APartition); Term := 2^(APart-1); Term := binomial(Term,MultipliticityOfAPart); Produkt := Produkt * Term; # End of do-loop *** ndxprt ***. end do; a := a + Produkt; # End of do-loop *** ndxprttn ***. end do; print("n, a(n):",n,a); end proc;
PartitionList := proc (n, k) # Authors: # Herbert S. Wilf and Joanna Nordlicht, # Source: # Lecture Notes "East Side West Side,..." # University of Pennsylvania, USA, 2002. # Available from http://www.cis.upenn.edu/~wilf/lecnotes.html # Berechnet die Partitionen von n mit k Summanden. local East, West; if n < 1 or k < 1 or n < k then RETURN([]) elif n = 1 then RETURN([[1]]) else if n < 2 or k < 2 or n < k then West := [] else West := map(proc (x) options operator, arrow; [op(x), 1] end proc, PartitionList(n-1, k-1)) end if; if k <= n-k then East := map(proc(y) options operator, arrow; map(proc (x) options operator, arrow; x+1 end proc, y) end proc, PartitionList(n-k, k)) else East := [] end if; RETURN([op(West), op(East)]) end if end proc;
# second Maple program:
series(exp(add((-1)^(j-1)/j*z^j/(1-2*z^j), j=1..40)), z, 40); # Cf. A102866; Vladeta Jovovic, Feb 19 2008
# alternative Maple program:
b:= proc(n, i) option remember; `if`(n=0 or i=1, `if`(n>1, 0, 1),
add(b(n-i*j, i-1)*binomial(2^(i-1), j), j=0..n/i))
end:
a:= n-> b(n$2):
seq(a(n), n=0..32); # Alois P. Heinz, May 22 2018
-
terms = 32; CoefficientList[Product[(1 + x^k)^(2^(k-1)), {k, 1, terms+1}] + O[x]^(terms+1), x] // Rest (* Jean-François Alcover, Nov 10 2017, after Vladeta Jovovic *)
nmax = 40; CoefficientList[Series[Exp[Sum[-(-1)^k*x^k/(k*(1 - 2 x^k)), {k, 1, nmax}]], {x, 0, nmax}], x] (* Vaclav Kotesovec, Jun 08 2018 *)
A358908
Number of finite sequences of distinct integer partitions with total sum n and weakly decreasing lengths.
Original entry on oeis.org
1, 1, 2, 6, 10, 23, 50, 95, 188, 378, 747, 1414, 2739, 5179, 9811, 18562, 34491, 64131, 118607, 218369, 400196, 731414, 1328069, 2406363, 4346152, 7819549, 14027500, 25090582, 44749372, 79586074, 141214698, 249882141, 441176493, 777107137, 1365801088, 2395427040, 4192702241
Offset: 0
The a(1) = 1 through a(4) = 10 sequences:
((1)) ((2)) ((3)) ((4))
((11)) ((21)) ((22))
((111)) ((31))
((1)(2)) ((211))
((2)(1)) ((1111))
((11)(1)) ((1)(3))
((3)(1))
((11)(2))
((21)(1))
((111)(1))
This is the distinct case of
A055887 with weakly decreasing lengths.
This is the distinct case is
A141199.
The case of distinct lengths also is
A358836.
This is the case of
A358906 with weakly decreasing lengths.
A001970 counts multiset partitions of integer partitions.
A358830 counts twice-partitions with distinct lengths.
A358901 counts partitions with all distinct Omegas.
A358912 counts sequences of partitions with distinct lengths.
A358914 counts twice-partitions into distinct strict partitions.
-
ptnseq[n_]:=Join@@Table[Tuples[IntegerPartitions/@comp],{comp,Join@@Permutations/@IntegerPartitions[n]}];
Table[Length[Select[ptnseq[n],UnsameQ@@#&&GreaterEqual@@Length/@#&]],{n,0,10}]
-
P(n,y) = {1/prod(k=1, n, 1 - y*x^k + O(x*x^n))}
R(n,v) = {[subst(serlaplace(p), y, 1) | p<-Vec(prod(k=1, #v, (1 + y*x^k + O(x*x^n))^v[k] ))]}
seq(n) = {my(g=P(n,y)); Vec(prod(k=1, n, Ser(R(n, Vec(polcoef(g, k, y), -n))) ))} \\ Andrew Howroyd, Dec 31 2022
A358907
Number of finite sequences of distinct integer compositions with total sum n.
Original entry on oeis.org
1, 1, 2, 8, 18, 54, 156, 412, 1168, 3200, 8848, 24192, 66632, 181912, 495536, 1354880, 3680352, 9997056, 27093216, 73376512, 198355840, 535319168, 1443042688, 3884515008, 10445579840, 28046885824, 75225974912, 201536064896, 539339293824, 1441781213952
Offset: 0
The a(1) = 1 through a(4) = 18 sequences:
((1)) ((2)) ((3)) ((4))
((11)) ((12)) ((13))
((21)) ((22))
((111)) ((31))
((1)(2)) ((112))
((2)(1)) ((121))
((1)(11)) ((211))
((11)(1)) ((1111))
((1)(3))
((3)(1))
((1)(12))
((11)(2))
((1)(21))
((12)(1))
((2)(11))
((21)(1))
((1)(111))
((111)(1))
This is the strict case of
A133494.
The version for sequences of partitions is
A358906.
A001970 counts multiset partitions of integer partitions.
A218482 counts sequences of compositions with weakly decreasing lengths.
A358830 counts twice-partitions with distinct lengths.
A358901 counts partitions with all different Omegas.
A358914 counts twice-partitions into distinct strict partitions.
Cf.
A000009,
A000041,
A000219,
A055887,
A075900,
A296122,
A304961,
A307068,
A336342,
A358836,
A358912.
-
g:= proc(n) option remember; ceil(2^(n-1)) end:
b:= proc(n, i, p) option remember; `if`(n=0, p!, `if`(i<1, 0, (t->
add(binomial(t, j)*b(n-i*j, i-1, p+j), j=0..min(t, n/i)))(g(i))))
end:
a:= n-> b(n$2, 0):
seq(a(n), n=0..32); # Alois P. Heinz, Dec 15 2022
-
comps[n_]:=Join@@Permutations/@IntegerPartitions[n];
Table[Length[Select[Join@@Table[Tuples[comps/@c],{c,comps[n]}],UnsameQ@@#&]],{n,0,10}]
A358912
Number of finite sequences of integer partitions with total sum n and all distinct lengths.
Original entry on oeis.org
1, 1, 2, 5, 11, 23, 49, 103, 214, 434, 874, 1738, 3443, 6765, 13193, 25512, 48957, 93267, 176595, 332550, 622957, 1161230, 2153710, 3974809, 7299707, 13343290, 24280924, 43999100, 79412942, 142792535, 255826836, 456735456, 812627069, 1440971069, 2546729830
Offset: 0
The a(1) = 1 through a(4) = 11 sequences:
(1) (2) (3) (4)
(11) (21) (22)
(111) (31)
(1)(11) (211)
(11)(1) (1111)
(11)(2)
(1)(21)
(2)(11)
(21)(1)
(1)(111)
(111)(1)
The case of set partitions is
A007837.
This is the case of
A055887 with all distinct lengths.
For distinct sums instead of lengths we have
A336342.
The case of twice-partitions is
A358830.
The version for constant instead of distinct lengths is
A358905.
A141199 counts sequences of partitions with weakly decreasing lengths.
Cf.
A000219,
A001970,
A038041,
A060642,
A218482,
A271619,
A319066,
A358831,
A358901,
A358906,
A358908.
-
ptnseq[n_]:=Join@@Table[Tuples[IntegerPartitions/@comp],{comp,Join@@Permutations/@IntegerPartitions[n]}];
Table[Length[Select[ptnseq[n],UnsameQ@@Length/@#&]],{n,0,10}]
-
P(n,y) = {1/prod(k=1, n, 1 - y*x^k + O(x*x^n))}
seq(n) = {my(g=P(n,y)); [subst(serlaplace(p), y, 1) | p<-Vec(prod(k=1, n, 1 + y*polcoef(g, k, y) + O(x*x^n)))]} \\ Andrew Howroyd, Dec 30 2022
A358904
Number of finite sets of compositions with all equal sums and total sum n.
Original entry on oeis.org
1, 1, 2, 4, 9, 16, 38, 64, 156, 260, 632, 1024, 2601, 4096, 10208, 16944, 40966, 65536, 168672, 262144, 656980, 1090240, 2620928, 4194304, 10862100, 16781584, 41940992, 69872384, 168403448, 268435456, 693528552, 1073741824, 2695006177, 4473400320, 10737385472
Offset: 0
The a(1) = 1 through a(4) = 9 sets:
{(1)} {(2)} {(3)} {(4)}
{(11)} {(12)} {(13)}
{(21)} {(22)}
{(111)} {(31)}
{(112)}
{(121)}
{(211)}
{(1111)}
{(2),(11)}
The case of sets of partitions is
A359041.
A001970 counts multisets of partitions.
-
Table[If[n==0,1,Sum[Binomial[2^(d-1),n/d],{d,Divisors[n]}]],{n,0,30}]
-
a(n) = if (n, sumdiv(n, d, binomial(2^(d-1), n/d)), 1); \\ Michel Marcus, Dec 14 2022
A358913
Number of finite sequences of distinct sets with total sum n.
Original entry on oeis.org
1, 1, 1, 4, 6, 11, 28, 45, 86, 172, 344, 608, 1135, 2206, 4006, 7689, 13748, 25502, 47406, 86838, 157560, 286642, 522089, 941356, 1718622, 3079218, 5525805, 9902996, 17788396, 31742616, 56694704, 100720516, 178468026, 317019140, 560079704, 991061957
Offset: 0
The a(1) = 1 through a(5) = 11 sequences of sets:
({1}) ({2}) ({3}) ({4}) ({5})
({1,2}) ({1,3}) ({1,4})
({1},{2}) ({1},{3}) ({2,3})
({2},{1}) ({3},{1}) ({1},{4})
({1},{1,2}) ({2},{3})
({1,2},{1}) ({3},{2})
({4},{1})
({1},{1,3})
({1,2},{2})
({1,3},{1})
({2},{1,2})
The case of strictly decreasing sums is
A279785.
This is the distinct case of
A304969.
This is the case of
A358906 with strict partitions.
The version for compositions instead of strict partitions is
A358907.
The case of twice-partitions is
A358914.
A001970 counts multiset partitions of integer partitions.
A055887 counts sequences of partitions.
A330462 counts set systems by total sum and length.
A358830 counts twice-partitions with distinct lengths.
-
g:= proc(n) option remember; `if`(n=0, 1, add(g(n-j)*add(
`if`(d::odd, d, 0), d=numtheory[divisors](j)), j=1..n)/n)
end:
b:= proc(n, i, p) option remember; `if`(n=0, p!, `if`(i<1, 0,
add(binomial(g(i), j)*b(n-i*j, i-1, p+j), j=0..n/i)))
end:
a:= n-> b(n$2, 0):
seq(a(n), n=0..35); # Alois P. Heinz, Feb 13 2024
-
ptnseq[n_]:=Join@@Table[Tuples[IntegerPartitions/@comp],{comp,Join@@Permutations/@IntegerPartitions[n]}];
Table[Length[Select[ptnseq[n],UnsameQ@@#&&And@@UnsameQ@@@#&]],{n,0,10}]
A359041
Number of finite sets of integer partitions with all equal sums and total sum n.
Original entry on oeis.org
1, 1, 2, 3, 6, 7, 14, 15, 32, 31, 63, 56, 142, 101, 240, 211, 467, 297, 985, 490, 1524, 1247, 2542, 1255, 6371, 1979, 7486, 7070, 14128, 4565, 32953, 6842, 42229, 37863, 56266, 17887, 192914, 21637, 145820, 197835, 371853, 44583, 772740, 63261, 943966, 1124840
Offset: 0
The a(1) = 1 through a(6) = 14 sets:
{(1)} {(2)} {(3)} {(4)} {(5)} {(6)}
{(11)} {(21)} {(22)} {(32)} {(33)}
{(111)} {(31)} {(41)} {(42)}
{(211)} {(221)} {(51)}
{(1111)} {(311)} {(222)}
{(2),(11)} {(2111)} {(321)}
{(11111)} {(411)}
{(2211)}
{(3111)}
{(21111)}
{(111111)}
{(3),(21)}
{(3),(111)}
{(21),(111)}
The version for compositions instead of partitions is
A358904.
A001970 counts multisets of partitions.
-
Table[If[n==0,1,Sum[Binomial[PartitionsP[d],n/d],{d,Divisors[n]}]],{n,0,50}]
-
a(n) = if (n, sumdiv(n, d, binomial(numbpart(d), n/d)), 1); \\ Michel Marcus, Dec 14 2022
Showing 1-9 of 9 results.
Comments