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

A107742 G.f.: Product_{j>=1} Product_{i>=1} (1 + x^(i*j)).

Original entry on oeis.org

1, 1, 2, 4, 6, 10, 17, 25, 38, 59, 86, 125, 184, 260, 369, 524, 726, 1005, 1391, 1894, 2576, 3493, 4687, 6272, 8373, 11090, 14647, 19294, 25265, 32991, 42974, 55705, 72025, 92895, 119349, 152965, 195592, 249280, 316991, 402215, 508932, 642598, 809739, 1017850, 1276959, 1599015, 1997943, 2491874, 3102477, 3855165, 4782408, 5922954
Offset: 0

Views

Author

Vladeta Jovovic, Jun 11 2005

Keywords

Comments

From Gus Wiseman, Sep 13 2022: (Start)
Also the number of multiset partitions of integer partitions of n into intervals, where an interval is a set of positive integers with all differences of adjacent elements equal to 1. For example, the a(1) = 1 through a(4) = 6 multiset partitions are:
{{1}} {{2}} {{3}} {{4}}
{{1},{1}} {{1,2}} {{1},{3}}
{{1},{2}} {{2},{2}}
{{1},{1},{1}} {{1},{1,2}}
{{1},{1},{2}}
{{1},{1},{1},{1}}
Intervals are counted by A001227, ranked by A073485.
The initial version is A007294.
The strict version is A327731.
The version for gapless multisets instead of intervals is A356941.
The case of strict partitions is A356957.
Also the number of multiset partitions of integer partitions of n into distinct constant blocks. For example, the a(1) = 1 through a(4) = 6 multiset partitions are:
{{1}} {{2}} {{3}} {{4}}
{{1,1}} {{1,1,1}} {{2,2}}
{{1},{2}} {{1},{3}}
{{1},{1,1}} {{1,1,1,1}}
{{2},{1,1}}
{{1},{1,1,1}}
Constant multisets are counted by A000005, ranked by A000961.
The non-strict version is A006171.
The unlabeled version is A089259.
The non-constant block version is A261049.
The version for twice-partitions is A279786, factorizations A296131.
Also the number of multiset partitions of integer partitions of n into constant blocks of odd length. For example, a(1) = 1 through a(4) = 6 multiset partitions are:
{{1}} {{2}} {{3}} {{4}}
{{1},{1}} {{1,1,1}} {{1},{3}}
{{1},{2}} {{2},{2}}
{{1},{1},{1}} {{1},{1,1,1}}
{{1},{1},{2}}
{{1},{1},{1},{1}}
The strict version is A327731 (also).
(End)

Crossrefs

Product_{k>=1} (1 + x^k)^sigma_m(k): this sequence (m=0), A192065 (m=1), A288414 (m=2), A288415 (m=3), A301548 (m=4), A301549 (m=5), A301550 (m=6), A301551 (m=7), A301552 (m=8).
A000041 counts integer partitions, strict A000009.
A000110 counts set partitions.
A072233 counts partitions by sum and length.

Programs

  • Mathematica
    nmax = 50; CoefficientList[Series[Product[(1+x^(i*j)), {i, 1, nmax}, {j, 1, nmax/i}], {x, 0, nmax}], x] (* Vaclav Kotesovec, Jan 04 2017 *)
    nmax = 50; CoefficientList[Series[Product[(1+x^k)^DivisorSigma[0, k], {k, 1, nmax}], {x, 0, nmax}], x] (* Vaclav Kotesovec, Mar 23 2018 *)
    nmax = 50; s = 1 + x; Do[s *= Sum[Binomial[DivisorSigma[0, k], j]*x^(j*k), {j, 0, nmax/k}]; s = Expand[s]; s = Take[s, Min[nmax + 1, Exponent[s, x] + 1, Length[s]]];, {k, 2, nmax}]; Take[CoefficientList[s, x], nmax + 1] (* Vaclav Kotesovec, Aug 28 2018 *)
    sps[{}]:={{}};sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
    mps[set_]:=Union[Sort[Sort/@(#/.x_Integer:>set[[x]])]&/@sps[Range[Length[set]]]];
    chQ[y_]:=Length[y]<=1||Union[Differences[y]]=={1};
    Table[Length[Select[Join@@mps/@IntegerPartitions[n],And@@chQ/@#&]],{n,0,5}] (* Gus Wiseman, Sep 13 2022 *)
  • PARI
    a(n)=polcoeff(prod(k=1,n,prod(j=1,n\k,1+x^(j*k)+x*O(x^n))),n) /* Paul D. Hanna */
    
  • PARI
    N=66;  x='x+O('x^N); gf=1/prod(j=0,N, eta(x^(2*j+1))); gf=prod(j=1,N,(1+x^j)^numdiv(j)); Vec(gf) /* Joerg Arndt, May 03 2008 */
    
  • PARI
    {a(n)=if(n==0,1,polcoeff(exp(sum(m=1,n,sigma(m)*x^m/(1-x^(2*m)+x*O(x^n))/m)),n))} /* Paul D. Hanna, Mar 28 2009 */

Formula

Euler transform of A001227.
Weigh transform of A000005.
G.f. satisfies: log(A(x)) = Sum_{n>=1} A109386(n)/n*x^n, where A109386(n) = Sum_{d|n} d*Sum_{m|d} (m mod 2). - Paul D. Hanna, Jun 26 2005
G.f.: A(x) = exp( Sum_{n>=1} sigma(n)*x^n/(1-x^(2n)) /n ). - Paul D. Hanna, Mar 28 2009
G.f.: Product_{n>=1} Q(x^n) where Q(x) is the g.f. of A000009. - Joerg Arndt, Feb 27 2014
a(0) = 1, a(n) = (1/n)*Sum_{k=1..n} A109386(k)*a(n-k) for n > 0. - Seiichi Manyama, Jun 04 2017
Conjecture: log(a(n)) ~ Pi*sqrt(n*log(n)/6). - Vaclav Kotesovec, Aug 29 2018

Extensions

More terms from Paul D. Hanna, Jun 26 2005

A072706 Number of unimodal partitions/compositions of n into distinct terms.

Original entry on oeis.org

1, 1, 1, 3, 3, 5, 9, 11, 15, 21, 33, 39, 55, 69, 93, 127, 159, 201, 261, 327, 411, 537, 653, 819, 1011, 1257, 1529, 1899, 2331, 2829, 3441, 4179, 5031, 6093, 7305, 8767, 10575, 12573, 14997, 17847, 21223, 25089, 29757, 35055, 41379, 48801, 57285, 67131
Offset: 0

Views

Author

Henry Bottomley, Jul 04 2002

Keywords

Comments

Also the number of ways to partition a strict integer partition of n into two unordered blocks. - Gus Wiseman, Dec 31 2019

Examples

			a(6)=9 since 6 can be written as 1+2+3, 1+3+2, 1+5, 2+3+1, 2+4, 3+2+1, 4+2, 5+1, or 6, but not for example 1+4+1 (which does not have distinct terms) nor 2+1+3 (which is not unimodal).
From _Joerg Arndt_, Mar 25 2014: (Start)
The a(10) = 33 such compositions of 10 are:
01:  [ 1 2 3 4 ]
02:  [ 1 2 4 3 ]
03:  [ 1 2 7 ]
04:  [ 1 3 4 2 ]
05:  [ 1 3 6 ]
06:  [ 1 4 3 2 ]
07:  [ 1 4 5 ]
08:  [ 1 5 4 ]
09:  [ 1 6 3 ]
10:  [ 1 7 2 ]
11:  [ 1 9 ]
12:  [ 2 3 4 1 ]
13:  [ 2 3 5 ]
14:  [ 2 4 3 1 ]
15:  [ 2 5 3 ]
16:  [ 2 7 1 ]
17:  [ 2 8 ]
18:  [ 3 4 2 1 ]
19:  [ 3 5 2 ]
20:  [ 3 6 1 ]
21:  [ 3 7 ]
22:  [ 4 3 2 1 ]
23:  [ 4 5 1 ]
24:  [ 4 6 ]
25:  [ 5 3 2 ]
26:  [ 5 4 1 ]
27:  [ 6 3 1 ]
28:  [ 6 4 ]
29:  [ 7 2 1 ]
30:  [ 7 3 ]
31:  [ 8 2 ]
32:  [ 9 1 ]
33:  [ 10 ]
(End)
		

Crossrefs

The non-strict version is A001523.

Programs

  • Maple
    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, x*b(n-i, i-1)))))
        end:
    a:= n->(p->add(coeff(p, x, i)*ceil(2^(i-1)), i=0..degree(p)))(b(n$2)):
    seq(a(n), n=0..100);  # Alois P. Heinz, Mar 25 2014
  • Mathematica
    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, x*b[n - i, i - 1]]]]]; a[n_] := Function[{p}, Sum[Coefficient[p, x, i]*Ceiling[2^(i - 1)], {i, 0, Exponent[p, x]}]][b[n, n]]; Table[a[n], {n, 0, 100}] (* Jean-François Alcover, Jan 16 2015, after Alois P. Heinz *)
    Table[If[n==0,1,Sum[2^(Length[ptn]-1),{ptn,Select[IntegerPartitions[n],UnsameQ@@#&]}]],{n,0,15}] (* Gus Wiseman, Dec 31 2019 *)
  • PARI
    N=66; q='q+O('q^N); Vec( 1 + sum(n=1, N, 2^(n-1)*q^(n*(n+1)/2) / prod(k=1, n, 1-q^k ) ) ) \\ Joerg Arndt, Mar 25 2014

Formula

a(n) = sum_k A072705(n, k) = A032020(n)-A072707(k) = A032302(n)/2 (n>0).
G.f.: 1/2*(1+Product_{k>0} (1+2*x^k)). - Vladeta Jovovic, Jun 24 2003
G.f.: 1 + sum(n>=1, 2^(n-1)*q^(n*(n+1)/2) / prod(k=1..n, 1-q^k ) ). [Joerg Arndt, Jan 20 2014]
a(n) ~ c^(1/4) * exp(2*sqrt(c*n)) / (4*sqrt(3*Pi)*n^(3/4)), where c = -polylog(2, -2) = A266576 = 1.436746366883680946362902023893583354... - Vaclav Kotesovec, Sep 22 2019

A317142 Number of refinement-ordered pairs of strict integer partitions of n.

Original entry on oeis.org

1, 1, 1, 3, 3, 5, 9, 12, 16, 24, 37, 47, 68, 90, 123, 180, 228, 307, 408, 540, 694, 970, 1207, 1598, 2048, 2669, 3357, 4382, 5599, 7109, 8990, 11428, 14330, 18144, 22652, 28343, 35746, 44269, 55094, 68384, 84780, 104477, 129360, 158682, 195323, 240177, 293704
Offset: 0

Views

Author

Gus Wiseman, Jul 22 2018

Keywords

Comments

If x and y are strict partitions of the same integer and it is possible to produce x by further partitioning the parts of y, flattening, and sorting, then x <= y.
This sequence is dominated by A294617 (set partitions of strict partitions).

Examples

			The a(9) = 24 refinement-ordered pairs:
    (9)<=(9)
  (5,4)<=(9)   (5,4)<=(5,4)
  (6,3)<=(9)   (6,3)<=(6,3)
  (7,2)<=(9)   (7,2)<=(7,2)
  (8,1)<=(9)   (8,1)<=(8,1)
(4,3,2)<=(9) (4,3,2)<=(5,4) (4,3,2)<=(6,3) (4,3,2)<=(7,2) (4,3,2)<=(4,3,2)
(5,3,1)<=(9) (5,3,1)<=(5,4) (5,3,1)<=(6,3) (5,3,1)<=(8,1) (5,3,1)<=(5,3,1)
(6,2,1)<=(9) (6,2,1)<=(6,3) (6,2,1)<=(7,2) (6,2,1)<=(8,1) (6,2,1)<=(6,2,1)
		

Crossrefs

Programs

  • Mathematica
    sps[{}]:={{}};sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
    mps[set_]:=Union[Sort[Sort/@(#/.x_Integer:>set[[x]])]&/@sps[Range[Length[set]]]];
    Table[Sum[Length[Union[Select[Sort/@Map[Total,mps[ptn],{2}],UnsameQ@@#&]]],{ptn,Select[IntegerPartitions[n],UnsameQ@@#&]}],{n,30}]

A300301 Number of ways to choose a partition, with odd parts, of each part of a partition of n into odd parts.

Original entry on oeis.org

1, 1, 1, 3, 3, 6, 10, 15, 21, 37, 56, 80, 127, 183, 280, 428, 616, 893, 1367, 1944, 2846, 4223, 6049, 8691, 12670, 18128, 25921, 37529, 53338, 75738, 108561, 153460, 216762, 308829, 433893, 612006, 864990, 1211097, 1697020, 2386016, 3331037, 4648229, 6503314
Offset: 0

Views

Author

Gus Wiseman, Mar 02 2018

Keywords

Examples

			The a(6) = 10 twice-partitions using odd partitions: (5)(1), (3)(3), (113)(1), (3)(111), (111)(3), (3)(1)(1)(1), (11111)(1), (111)(111), (111)(1)(1)(1), (1)(1)(1)(1)(1)(1).
		

Crossrefs

Programs

  • Maple
    with(numtheory):
    b:= proc(n) option remember; `if`(n=0, 1, add(add(
         `if`(d::odd, d, 0), d=divisors(j))*b(n-j), j=1..n)/n)
        end:
    g:= proc(n, i) option remember; `if`(n=0 or i=1, 1,
          g(n, i-2)+`if`(i>n, 0, b(i)*g(n-i, i)))
        end:
    a:= n-> g(n, n-1+irem(n,2)):
    seq(a(n), n=0..50);  # Alois P. Heinz, Mar 05 2018
  • Mathematica
    nn=50;
    ser=Product[1/(1-PartitionsQ[n]x^n),{n,1,nn,2}];
    Table[SeriesCoefficient[ser,{x,0,n}],{n,0,nn}]

Formula

O.g.f.: Product_{n odd} 1/(1 - A000009(n)x^n).

A300300 Number of ways to choose a multiset of strict partitions, or odd partitions, of odd numbers, whose weights sum to n.

Original entry on oeis.org

1, 1, 1, 3, 3, 6, 9, 14, 20, 32, 48, 69, 105, 150, 225, 322, 472, 669, 977, 1379, 1980, 2802, 3977, 5602, 7892, 11083, 15494, 21688, 30147, 42007, 58143, 80665, 111199, 153640, 211080, 290408, 397817, 545171, 744645, 1016826, 1385124, 1885022, 2561111, 3474730
Offset: 0

Views

Author

Gus Wiseman, Mar 02 2018

Keywords

Examples

			The a(6) = 9 multiset partitions using odd-weight strict partitions: (5)(1), (14)(1), (3)(3), (32)(1), (3)(21), (3)(1)(1)(1), (21)(21), (21)(1)(1)(1), (1)(1)(1)(1)(1)(1).
The a(6) = 9 multiset partitions using odd partitions: (5)(1), (3)(3), (311)(1), (3)(111), (3)(1)(1)(1), (11111)(1), (111)(111), (111)(1)(1)(1), (1)(1)(1)(1)(1)(1).
		

Crossrefs

Programs

  • Maple
    with(numtheory):
    b:= proc(n) option remember; `if`(n=0, 1, add(b(n-j)*add(
          `if`(d::odd, d, 0), d=divisors(j)), j=1..n)/n)
        end:
    a:= proc(n) option remember; `if`(n=0, 1, add(a(n-j)*add(
          `if`(d::odd, b(d)*d, 0), d=divisors(j)), j=1..n)/n)
        end:
    seq(a(n), n=0..45);  # Alois P. Heinz, Mar 02 2018
  • Mathematica
    nn=50;
    ser=Product[1/(1-x^n)^PartitionsQ[n],{n,1,nn,2}];
    Table[SeriesCoefficient[ser,{x,0,n}],{n,0,nn}]

Formula

Euler transform of {Q(1), 0, Q(3), 0, Q(5), 0, ...} where Q = A000009.

A330459 Number of set partitions of set-systems with total sum n.

Original entry on oeis.org

1, 1, 1, 4, 6, 11, 26, 42, 78, 148, 280, 481, 867, 1569, 2742, 4933, 8493, 14857, 25925, 44877, 77022, 132511, 226449, 385396, 657314, 1111115, 1875708, 3157379, 5309439, 8885889, 14861478, 24760339, 41162971, 68328959, 113099231, 186926116, 308230044
Offset: 0

Views

Author

Gus Wiseman, Dec 17 2019

Keywords

Comments

Number of sets of disjoint nonempty sets of nonempty sets of positive integers with total sum n.

Examples

			The a(6) = 26 partitions:
  ((6))  ((15))      ((123))          ((1)(2)(12))
         ((24))      ((1)(14))        ((1))((2)(12))
         ((1)(5))    ((1)(23))        ((12))((1)(2))
         ((2)(4))    ((2)(13))        ((2))((1)(12))
         ((1))((5))  ((3)(12))        ((1))((2))((12))
         ((2))((4))  ((1))((14))
                     ((1))((23))
                     ((1)(2)(3))
                     ((2))((13))
                     ((3))((12))
                     ((1))((2)(3))
                     ((2))((1)(3))
                     ((3))((1)(2))
                     ((1))((2))((3))
		

Crossrefs

Programs

  • Mathematica
    ppl[n_,k_]:=Switch[k,0,{n},1,IntegerPartitions[n],_,Join@@Table[Union[Sort/@Tuples[ppl[#,k-1]&/@ptn]],{ptn,IntegerPartitions[n]}]];
    Table[Length[Select[ppl[n,3],And[UnsameQ@@Join@@#,And@@UnsameQ@@@Join@@#]&]],{n,0,10}]
  • PARI
    \\ here L is A000009 and BellP is A000110 as series.
    L(n)={eta(x^2 + O(x*x^n))/eta(x + O(x*x^n))}
    BellP(n)={serlaplace(exp( exp(x + O(x*x^n)) - 1))}
    seq(n)={my(c=L(n), b=BellP(n), v=Vec(prod(k=1, n, (1 + x^k*y + O(x*x^n))^polcoef(c, k)))); vector(#v, n, my(r=v[n]); sum(k=0, n-1, polcoeff(b,k)*polcoef(r,k)))} \\ Andrew Howroyd, Dec 29 2019

Formula

a(n) = Sum_k A330462(n,k) * A000110(k).

Extensions

Terms a(18) and beyond from Andrew Howroyd, Dec 29 2019

A323301 Number of ways to fill a matrix with the parts of a strict integer partition of n.

Original entry on oeis.org

1, 1, 1, 5, 5, 9, 21, 25, 37, 53, 137, 153, 249, 337, 505, 845, 1085, 1497, 2061, 2785, 3661, 7589, 8849, 13329, 18033, 26017, 34225, 48773, 70805, 91977, 123765, 164761, 216373, 283205, 367913, 470889, 758793, 913825, 1264105, 1651613, 2251709, 2894793, 3927837
Offset: 0

Views

Author

Gus Wiseman, Jan 12 2019

Keywords

Examples

			The a(6) = 21 matrices:
  [6] [1 5] [5 1] [2 4] [4 2] [1 2 3] [1 3 2] [2 1 3] [2 3 1] [3 1 2] [3 2 1]
.
  [1] [5] [2] [4]
  [5] [1] [4] [2]
.
  [1] [1] [2] [2] [3] [3]
  [2] [3] [1] [3] [1] [2]
  [3] [2] [3] [1] [2] [1]
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, t) option remember;
          `if`(n>i*(i+1)/2, 0, `if`(n=0, t!*numtheory[tau](t),
           b(n, i-1, t)+b(n-i, min(n-i, i-1), t+1)))
        end:
    a:= n-> `if`(n=0, 1, b(n$2, 0)):
    seq(a(n), n=0..50);  # Alois P. Heinz, Jan 15 2019
  • Mathematica
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]];
    ptnmats[n_]:=Union@@Permutations/@Select[Union@@(Tuples[Permutations/@#]&/@Map[primeMS,facs[n],{2}]),SameQ@@Length/@#&];
    Table[Sum[Length[ptnmats[k]],{k,Select[Times@@Prime/@#&/@IntegerPartitions[n],SquareFreeQ]}],{n,20}]
    (* Second program: *)
    b[n_, i_, t_] := b[n, i, t] = If[n > i(i+1)/2, 0,
         If[n == 0, t!*DivisorSigma[0, t], b[n, i - 1, t] +
         b[n - i, Min[n - i, i - 1], t + 1]]];
    a[n_] := If[n == 0, 1, b[n, n, 0]];
    a /@ Range[0, 50] (* Jean-François Alcover, May 13 2021, after Alois P. Heinz *)

Formula

a(n) = Sum_{y1 + ... + yk = n, y1 > ... > yk} k! * A000005(k) for n > 0, a(0) = 1.

Extensions

a(0)=1 prepended by Alois P. Heinz, Jan 15 2019

A330462 Triangle read by rows where T(n,k) is the number of k-element sets of nonempty sets of positive integers with total sum n.

Original entry on oeis.org

1, 0, 1, 0, 1, 0, 0, 2, 1, 0, 0, 2, 2, 0, 0, 0, 3, 4, 0, 0, 0, 0, 4, 6, 2, 0, 0, 0, 0, 5, 11, 3, 0, 0, 0, 0, 0, 6, 16, 8, 0, 0, 0, 0, 0, 0, 8, 25, 15, 1, 0, 0, 0, 0, 0, 0, 10, 35, 28, 4, 0, 0, 0, 0, 0, 0, 0, 12, 52, 46, 9, 0, 0, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Gus Wiseman, Dec 18 2019

Keywords

Examples

			Triangle begins:
  1
  0  1
  0  1  0
  0  2  1  0
  0  2  2  0  0
  0  3  4  0  0  0
  0  4  6  2  0  0  0
  0  5 11  3  0  0  0  0
  0  6 16  8  0  0  0  0  0
  0  8 25 15  1  0  0  0  0  0
  0 10 35 28  4  0  0  0  0  0  0
  ...
Row n = 7 counts the following set-systems:
  {{7}}      {{1},{6}}      {{1},{2},{4}}
  {{1,6}}    {{2},{5}}      {{1},{2},{1,3}}
  {{2,5}}    {{3},{4}}      {{1},{3},{1,2}}
  {{3,4}}    {{1},{1,5}}
  {{1,2,4}}  {{1},{2,4}}
             {{2},{1,4}}
             {{2},{2,3}}
             {{3},{1,3}}
             {{4},{1,2}}
             {{1},{1,2,3}}
             {{1,2},{1,3}}
		

Crossrefs

Programs

  • Mathematica
    ppl[n_,k_]:=Switch[k,0,{n},1,IntegerPartitions[n],_,Join@@Table[Union[Sort/@Tuples[ppl[#,k-1]&/@ptn]],{ptn,IntegerPartitions[n]}]];
    Table[Length[Select[ppl[n,2],And[UnsameQ@@#,And@@UnsameQ@@@#,Length[#]==k]&]],{n,0,10},{k,0,n}]
  • PARI
    L(n)={eta(x^2 + O(x*x^n))/eta(x + O(x*x^n))}
    A(n)={my(c=L(n), v=Vec(prod(k=1, n, (1 + x^k*y + O(x*x^n))^polcoef(c,k)))); vector(#v, n, Vecrev(v[n],n))}
    {my(T=A(12)); for(n=1, #T, print(T[n]))} \\ Andrew Howroyd, Dec 29 2019

Formula

G.f.: Product_{j>=1} (1 + y*x^j)^A000009(j). - Andrew Howroyd, Dec 29 2019

A330452 Number of set partitions of strict multiset partitions of integer partitions of n.

Original entry on oeis.org

1, 1, 2, 7, 13, 34, 81, 175, 403, 890, 1977, 4262, 9356, 19963, 42573, 90865, 191206, 401803, 837898, 1744231, 3607504, 7436628, 15254309, 31185686, 63552725, 128963236, 260933000, 526140540, 1057927323, 2120500885, 4239012067, 8449746787, 16799938614
Offset: 0

Views

Author

Gus Wiseman, Dec 16 2019

Keywords

Comments

Number of sets of disjoint nonempty sets of nonempty multisets of positive integers with total sum n.

Examples

			The a(4) = 13 partitions:
  ((4))  ((22))  ((31))      ((211))      ((1111))
                 ((1)(3))    ((1)(21))    ((1)(111))
                 ((1))((3))  ((2)(11))    ((1))((111))
                             ((1))((21))
                             ((2))((11))
		

Crossrefs

Programs

  • Mathematica
    ppl[n_,k_]:=Switch[k,0,{n},1,IntegerPartitions[n],_,Join@@Table[Union[Sort/@Tuples[ppl[#,k-1]&/@ptn]],{ptn,IntegerPartitions[n]}]];
    Table[Length[Select[ppl[n,3],UnsameQ@@Join@@#&]],{n,0,10}]
  • PARI
    \\ here BellP is A000110 as series.
    BellP(n)={serlaplace(exp( exp(x + O(x*x^n)) - 1))}
    seq(n)={my(b=BellP(n), v=Vec(prod(k=1, n, (1 + x^k*y + O(x*x^n))^numbpart(k)))); vector(#v, n, my(r=v[n]); sum(k=0, n-1, polcoeff(b,k)*polcoef(r,k)))} \\ Andrew Howroyd, Dec 29 2019

Formula

a(n) = Sum_{0 <= k <= n} A330463(n,k) * A000110(k).

Extensions

Terms a(18) and beyond from Andrew Howroyd, Dec 29 2019

A330460 Triangle read by rows where T(n,k) is the number of set partitions with k blocks and total sum n.

Original entry on oeis.org

1, 0, 1, 0, 1, 0, 0, 2, 1, 0, 0, 2, 1, 0, 0, 0, 3, 2, 0, 0, 0, 0, 4, 5, 1, 0, 0, 0, 0, 5, 6, 1, 0, 0, 0, 0, 0, 6, 9, 2, 0, 0, 0, 0, 0, 0, 8, 13, 3, 0, 0, 0, 0, 0, 0, 0, 10, 23, 10, 1, 0, 0, 0, 0, 0, 0, 0, 12, 27, 11, 1, 0, 0, 0, 0, 0, 0, 0, 0, 15, 40, 19, 2, 0, 0, 0, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Gus Wiseman, Dec 18 2019

Keywords

Examples

			Triangle begins:
  1
  0  1
  0  1  0
  0  2  1  0
  0  2  1  0  0
  0  3  2  0  0  0
  0  4  5  1  0  0  0
  0  5  6  1  0  0  0  0
  0  6  9  2  0  0  0  0  0
  0  8 13  3  0  0  0  0  0  0
  0 10 23 10  1  0  0  0  0  0  0
  0 12 27 11  1  0  0  0  0  0  0  0
  0 15 40 19  2  0  0  0  0  0  0  0  0
Row n = 8 counts the following set partitions:
  {{8}}      {{1},{7}}    {{1},{2},{5}}
  {{3,5}}    {{2},{6}}    {{1},{3},{4}}
  {{2,6}}    {{3},{5}}
  {{1,7}}    {{1},{3,4}}
  {{1,3,4}}  {{1},{2,5}}
  {{1,2,5}}  {{2},{1,5}}
             {{3},{1,4}}
             {{4},{1,3}}
             {{5},{1,2}}
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, k) option remember; `if`(i*(i+1)/2 k*
             b(n-i, t, k)+b(n-i, t, k+1))(min(n-i, i-1))))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=0..n))(b(n$2, 0)):
    seq(T(n), n=0..15);  # Alois P. Heinz, Dec 29 2019
  • Mathematica
    ppl[n_,k_]:=Switch[k,0,{n},1,IntegerPartitions[n],_,Join@@Table[Union[Sort/@Tuples[ppl[#,k-1]&/@ptn]],{ptn,IntegerPartitions[n]}]];
    Table[Length[Select[ppl[n,2],Length[#]==k&&And[UnsameQ@@#,UnsameQ@@Join@@#]&]],{n,0,10},{k,0,n}]
    (* Second program: *)
    b[n_, i_, k_] := b[n, i, k] = If[i(i+1)/2 < n, 0, If[n == 0, x^k, b[n, i-1, k] + Function[t, k*b[n-i, t, k] + b[n-i, t, k + 1]][Min[n-i, i-1]]]];
    T[n_] := PadRight[CoefficientList[b[n, n, 0], x], n + 1];
    T /@ Range[0, 15] // Flatten (* Jean-François Alcover, May 16 2021, after Alois P. Heinz *)
  • PARI
    A(n)={my(v=Vec(prod(k=1, n, 1 + x^k*y + O(x*x^n)))); vector(#v, n, my(p=v[n]); vector(n, k, sum(i=k, n, polcoef(p,i-1)*stirling(i-1, k-1, 2))))}
    {my(T=A(12)); for(n=1, #T, print(T[n]))} \\ Andrew Howroyd, Dec 29 2019

Formula

T(n,k) = Sum_{k <= i <= n} A060016(n,i) * A008277(i,k).
For n > 0, T(n,2) = Sum_{k = 1..n} (2^(k - 1) -1) * A060016(n,k).
Showing 1-10 of 20 results. Next