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-7 of 7 results.

A294617 Number of ways to choose a set partition of a strict integer partition of n.

Original entry on oeis.org

1, 1, 1, 3, 3, 5, 10, 12, 17, 24, 44, 51, 76, 98, 138, 217, 272, 366, 493, 654, 848, 1284, 1560, 2115, 2718, 3610, 4550, 6024, 8230, 10296, 13354, 17144, 21926, 27903, 35556, 44644, 59959, 73456, 94109, 117735, 150078, 185800, 235719, 290818, 365334, 467923
Offset: 0

Views

Author

Gus Wiseman, Nov 05 2017

Keywords

Comments

From Gus Wiseman, Sep 17 2024: (Start)
Also the number of strict integer compositions of n whose leaders, obtained by splitting into maximal increasing subsequences and taking the first term of each, are decreasing. For example, the strict composition (3,6,2,1,4) has maximal increasing subsequences ((3,6),(2),(1,4)), with leaders (3,2,1), so is counted under a(16). The a(0) = 1 through a(7) = 12 compositions are:
() (1) (2) (3) (4) (5) (6) (7)
(1,2) (1,3) (1,4) (1,5) (1,6)
(2,1) (3,1) (2,3) (2,4) (2,5)
(3,2) (4,2) (3,4)
(4,1) (5,1) (4,3)
(1,2,3) (5,2)
(2,1,3) (6,1)
(2,3,1) (1,2,4)
(3,1,2) (2,1,4)
(3,2,1) (2,4,1)
(4,1,2)
(4,2,1)
(End)

Examples

			The a(6) = 10 set partitions are: {{6}}, {{1},{5}}, {{5,1}}, {{2},{4}}, {{4,2}}, {{1},{2},{3}}, {{1},{3,2}}, {{2,1},{3}}, {{3,1},{2}}, {{3,2,1}}.
		

Crossrefs

Row sums of A330460 and of A330759.
This is a strict case of A374689, weak version A189076.
A011782 counts compositions, strict A032020.
A238130, A238279, A333755 count compositions by number of runs.

Programs

  • Maple
    b:= proc(n, i, t) option remember; `if`(n>i*(i+1)/2, 0,
          `if`(n=0, combinat[bell](t), b(n, i-1, t)+
          `if`(i>n, 0, b(n-i, min(n-i, i-1), t+1))))
        end:
    a:= n-> b(n$2, 0):
    seq(a(n), n=0..50);  # Alois P. Heinz, Nov 07 2017
  • Mathematica
    Table[Total[BellB[Length[#]]&/@Select[IntegerPartitions[n],UnsameQ@@#&]],{n,25}]
    (* Second program: *)
    b[n_, i_, t_] := b[n, i, t] = If[n > i (i + 1)/2, 0, If[n == 0, BellB[t], b[n, i - 1, t] + If[i > n, 0, b[n - i, Min[n - i, i - 1], t + 1]]]];
    a[n_] := b[n, n, 0];
    a /@ Range[0, 50] (* Jean-François Alcover, May 10 2021, after Alois P. Heinz *)

Formula

A279375(n) <= a(n) <= A279790(n).
G.f.: Sum_{k>=0} Bell(k) * x^(k*(k + 1)/2) / Product_{j=1..k} (1 - x^j). - Ilya Gutkovskiy, Jan 28 2020

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

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

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

Original entry on oeis.org

1, 0, 1, 0, 2, 0, 0, 3, 2, 0, 0, 5, 4, 0, 0, 0, 7, 11, 1, 0, 0, 0, 11, 20, 6, 0, 0, 0, 0, 15, 40, 16, 0, 0, 0, 0, 0, 22, 68, 40, 3, 0, 0, 0, 0, 0, 30, 120, 91, 11, 0, 0, 0, 0, 0, 0, 42, 195, 186, 41, 0, 0, 0, 0, 0, 0, 0, 56, 320, 367, 105, 3, 0, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Gus Wiseman, Dec 19 2019

Keywords

Examples

			Triangle begins:
  1
  0  1
  0  2  0
  0  3  2  0
  0  5  4  0  0
  0  7 11  1  0  0
  0 11 20  6  0  0  0
  0 15 40 16  0  0  0  0
  0 22 68 40  3  0  0  0  0
  ...
Row n = 5 counts the following sets of multisets:
  {{5}}          {{1},{4}}        {{1},{2},{1,1}}
  {{1,4}}        {{2},{3}}
  {{2,3}}        {{1},{1,3}}
  {{1,1,3}}      {{1},{2,2}}
  {{1,2,2}}      {{2},{1,2}}
  {{1,1,1,2}}    {{3},{1,1}}
  {{1,1,1,1,1}}  {{1},{1,1,2}}
                 {{1,1},{1,2}}
                 {{2},{1,1,1}}
                 {{1},{1,1,1,1}}
                 {{1,1},{1,1,1}}
		

Crossrefs

Row sums are A261049.
Column k = 1 is A000041.
Multisets of multisets are A061260, with row sums A001970.
Sets of sets are A330462, with row sums A050342.
Multisets of sets are A285229, with row sums A089259.
Sets of disjoint sets are A330460, with row sums A294617.

Programs

  • Maple
    b:= proc(n, i) option remember; `if`(n=0, 1, `if`(i<1, 0, add(binomial(
           combinat[numbpart](i), j)*expand(b(n-i*j, i-1)*x^j), j=0..n/i)))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=0..n))(b(n$2)):
    seq(T(n), n=0..14);  # Alois P. Heinz, Dec 30 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],And[UnsameQ@@#,Length[#]==k]&]],{n,0,10},{k,0,n}]
    (* Second program: *)
    b[n_, i_] := b[n, i] = If[n == 0, 1, If[i<1, 0, Sum[Binomial[
         PartitionsP[i], j]*Expand[b[n - i*j, i - 1]*x^j], {j, 0, n/i}]]];
    T[n_] := Function[p, Table[Coefficient[p, x, i], {i, 0, n}]][b[n, n]];
    T /@ Range[0, 14] // Flatten (* Jean-François Alcover, May 18 2021, after Alois P. Heinz *)
  • PARI
    A(n)={my(v=Vec(prod(k=1, n, (1 + x^k*y + O(x*x^n))^numbpart(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)^A000041(j). - Andrew Howroyd, Dec 29 2019

A330759 Number T(n,k) of set partitions into k blocks of strict integer partitions of n; triangle T(n,k), n>=0, 0<=k<=A003056(n), read by rows.

Original entry on oeis.org

1, 0, 1, 0, 1, 0, 2, 1, 0, 2, 1, 0, 3, 2, 0, 4, 5, 1, 0, 5, 6, 1, 0, 6, 9, 2, 0, 8, 13, 3, 0, 10, 23, 10, 1, 0, 12, 27, 11, 1, 0, 15, 40, 19, 2, 0, 18, 51, 26, 3, 0, 22, 71, 40, 5, 0, 27, 100, 73, 16, 1, 0, 32, 127, 93, 19, 1, 0, 38, 163, 132, 31, 2, 0, 46, 215, 184, 45, 3
Offset: 0

Views

Author

Alois P. Heinz, Dec 29 2019

Keywords

Examples

			T(10,1) = 10: (10), 1234, 127, 136, 145, 19, 235, 28, 37, 46.
T(10,2) = 23: 123|4, 124|3, 12|34, 12|7, 134|2, 13|24, 13|6, 14|23, 14|5, 15|4, 16|3, 17|2, 1|234, 1|27, 1|36, 1|45, 1|9, 23|5, 25|3, 2|35, 2|8, 3|7, 4|6.
T(10,3) = 10: 12|3|4, 13|2|4, 14|2|3, 1|23|4, 1|24|3, 1|2|34, 1|2|7, 1|3|6, 1|4|5, 2|3|5.
T(10,4) = 1: 1|2|3|4.
Triangle T(n,k) begins:
  1;
  0,  1;
  0,  1;
  0,  2,   1;
  0,  2,   1;
  0,  3,   2;
  0,  4,   5,  1;
  0,  5,   6,  1;
  0,  6,   9,  2;
  0,  8,  13,  3;
  0, 10,  23, 10,  1;
  0, 12,  27, 11,  1;
  0, 15,  40, 19,  2;
  0, 18,  51, 26,  3;
  0, 22,  71, 40,  5;
  0, 27, 100, 73, 16, 1;
  ...
		

Crossrefs

Columns k=0-1 give: A000007, A000009 (for n>0).
Row sums give A294617.
Cf. A000041, A000096, A000217, A003056, A072706, A330460 (another version), A330765.

Programs

  • Maple
    b:= proc(n, i, k) option remember; `if`(i*(i+1)/2 b(n-i, t, k)*k
            +b(n-i, t, k+1))(min(n-i, i-1))))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=0..degree(p)))(b(n$2, 0)):
    seq(T(n), n=0..20);
  • Mathematica
    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] + With[{t = Min[n-i, i-1]},
         b[n-i, t, k]*k + b[n-i, t, k+1]]]];
    T[n_] := CoefficientList[b[n, n, 0], x];
    T /@ Range[0, 20] // Flatten (* Jean-François Alcover, Mar 12 2021, after Alois P. Heinz *)

Formula

Sum_{k=0..2} T(n,k) = A072706(n).
Sum_{k=1..A003056(n)} k * T(n,k) = A330765(n).
T(A000217(n),n) = 1.
T(A000096(n),n) = A000041(n).
T(n*(n+1)/2+j,n) = A000041(j) for 0 <= j <= n.

A330765 Total number of blocks in all set partitions of strict integer partitions of n.

Original entry on oeis.org

0, 1, 1, 4, 4, 7, 17, 20, 30, 43, 90, 103, 160, 210, 304, 515, 646, 894, 1223, 1659, 2176, 3484, 4226, 5873, 7638, 10335, 13150, 17695, 24974, 31394, 41383, 53766, 69718, 89573, 115613, 146344, 201625, 247880, 322099, 406445, 524634, 654298, 839584, 1043012
Offset: 0

Views

Author

Alois P. Heinz, Dec 29 2019

Keywords

Crossrefs

Programs

  • Maple
    b:= proc(n, i, k) option remember; `if`(i*(i+1)/2 b(n-i, t, k)*k
            +b(n-i, t, k+1))(min(n-i, i-1))))
        end:
    a:= n-> b(n$2, 0):
    seq(a(n), n=0..50);
  • Mathematica
    b[n_, i_, k_] := b[n, i, k] = If[i(i+1)/2 < n, 0, If[n==0, k, b[n, i-1, k] + b[n-i, #, k] k + b[n-i, #, k+1]&[Min[n-i, i-1]]]];
    a[n_] := b[n, n, 0];
    a /@ Range[0, 50] (* Jean-François Alcover, May 08 2020, after Maple *)

Formula

a(n) = Sum_{k=1..A003056(n)} k * A330460(n,k).
a(n) = Sum_{k=1..A003056(n)} k * A330759(n,k).
Showing 1-7 of 7 results.