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

A350647 Number T(n,k) of partitions of [n] having k blocks containing their own index when blocks are ordered with decreasing largest elements; triangle T(n,k), n>=0, 0<=k<=ceiling(n/2), read by rows.

Original entry on oeis.org

1, 0, 1, 1, 1, 1, 3, 1, 6, 7, 2, 16, 25, 10, 1, 73, 91, 35, 4, 298, 390, 163, 25, 1, 1453, 1797, 755, 128, 7, 7366, 9069, 3919, 737, 55, 1, 40689, 49106, 21485, 4304, 380, 11, 238258, 284537, 126273, 26695, 2696, 110, 1, 1483306, 1751554, 785435, 173038, 19272, 976, 16
Offset: 0

Views

Author

Alois P. Heinz, Jan 09 2022

Keywords

Examples

			T(4,0) = 6: 432|1, 42|31, 42|3|1, 4|31|2, 4|3|21, 4|3|2|1.
T(4,1) = 7: 4321, 43|21, 43|2|1, 421|3, 4|321, 4|32|1, 41|3|2.
T(4,2) = 2: 431|2, 41|32.
T(5,2) = 10: 5431|2, 541|32, 531|42, 51|432, 521|4|3, 5|421|3, 5|42|31, 5|42|3|1, 51|4|32, 51|4|3|2.
T(5,3) = 1: 51|42|3.
Triangle T(n,k) begins:
       1;
       0,      1;
       1,      1;
       1,      3,      1;
       6,      7,      2;
      16,     25,     10,     1;
      73,     91,     35,     4;
     298,    390,    163,    25,    1;
    1453,   1797,    755,   128,    7;
    7366,   9069,   3919,   737,   55,   1;
   40689,  49106,  21485,  4304,  380,  11;
  238258, 284537, 126273, 26695, 2696, 110, 1;
  ...
		

Crossrefs

Columns k=0-1 give: A350649, A350650.
Row sums give A000110.
T(2n,n) gives A000124(n-1) for n>=1.
T(2n+1,n+1) gives A000012.

Programs

  • Maple
    b:= proc(n, m) option remember; expand(`if`(n=0, 1, add(
          `if`(j=n, x, 1)*b(n-1, max(m, j)), j=1..m+1)))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=0..ceil(n/2)))(b(n, 0)):
    seq(T(n), n=0..14);
  • Mathematica
    b[n_, m_] := b[n, m] = Expand[If[n == 0, 1, Sum[
         If[j == n, x, 1]*b[n-1, Max[m, j]], {j, 1, m+1}]]];
    T[n_] := With[{p = b[n, 0]},
    Table[Coefficient[p, x, i], {i, 0, Ceiling[n/2]}]];
    Table[T[n], {n, 0, 14}] // Flatten (* Jean-François Alcover, Jan 11 2022, after Alois P. Heinz *)

Formula

Sum_{k=1..ceiling(n/2)} k * T(n,k) = A350648(n).

A350589 Sum over all partitions of [n] of the number of blocks containing their own index.

Original entry on oeis.org

0, 1, 3, 9, 30, 112, 464, 2109, 10411, 55351, 314772, 1903878, 12189432, 82274309, 583389847, 4332513061, 33607736990, 271657081128, 2283282938288, 19916981288017, 179994994948647, 1682624910161483, 16247280435775188, 161833756265886822, 1660836884761337248
Offset: 0

Views

Author

Alois P. Heinz, Jan 07 2022

Keywords

Comments

Also the number of partitions of [n] where the first k elements are marked (1 <= k <= n) and at least k blocks contain their own index: a(3) = 9 = 5 + 3 + 1: 1'23, 1'2|3, 1'3|2, 1'|23, 1'|2|3, 1'3|2', 1'|2'3, 1'|2'|3, 1'|2'|3'.

Examples

			a(3) = 9 = 1 + 1 + 2 + 2 + 3: 123, 12|3, 13|2, 1|23, 1|2|3.
		

Crossrefs

Programs

  • Maple
    b:= proc(n, m) option remember;
         `if`(n=0, 1, b(n-1, m+1)+m*b(n-1, m))
        end:
    a:= n-> add(b(n-i, i), i=1..n):
    seq(a(n), n=0..25);
  • Mathematica
    b[n_, m_] := b[n, m] = If[n == 0, 1, b[n - 1, m + 1] + m*b[n - 1, m]];
    a[n_] := Sum[b[n - i, i], {i, 1, n}];
    Table[a[n], {n, 0, 25}] (* Jean-François Alcover, Jan 11 2022, after Alois P. Heinz *)

Formula

a(n) = Sum_{k=1..n} A108087(n-k,k).
a(n) = Sum_{k=1..n} k * A259691(n-1,k).
a(n) = Sum_{k=1..n} A259691(n,k)/k.
a(n) = A347420(n) - A000110(n).
a(n) = 1 + A005490(n) - A000110(n).
a(n) mod 2 = A088911(n+5).

A350683 Total sum over all partitions of [n] of elements i contained in block i when blocks are ordered with decreasing largest elements.

Original entry on oeis.org

0, 1, 1, 8, 17, 98, 362, 1916, 9512, 53858, 315872, 1984979, 13105685, 91128546, 663815424, 5055622309, 40148341135, 331753228115, 2846786927873, 25323311882074, 233137061978065, 2218141402504254, 21780561656373552, 220451321425101091, 2297330116404668422
Offset: 0

Views

Author

Alois P. Heinz, Jan 11 2022

Keywords

Examples

			a(4) = 17 = 3*1 + 4*2 + 2*3: 432(1), 42(1)|3, 4(1)|3|2, 43|(2)1, 43|(2)|1, 4|3(2)1, 4|3(2)|1, 43(1)|(2), 4(1)|3(2).
		

Crossrefs

Programs

  • Maple
    b:= proc(n, m) option remember; `if`(n=0, [1, 0], add((p-> [0,
         `if`(n=j, p[1]*j, 0)]+p)(b(n-1, max(m, j))), j=1..m+1))
        end:
    a:= n-> b(n, 0)[2]:
    seq(a(n), n=0..25);
  • Mathematica
    b[n_, m_] := b[n, m] = If[n == 0, {1, 0}, Sum[With[{p = b[n-1, Max[m, j]]},
         {0, If[n == j, p[[1]]*j, 0]} + p], {j, 1, m+1}]];
    a[n_] := b[n, 0][[2]];
    Table[a[n], {n, 0, 25}]; (* Jean-François Alcover, May 08 2022, after Alois P. Heinz *)

Formula

a(n) = Sum_{k=1..max(0,A008805(n-1))} k * A350684(n,k).
Showing 1-3 of 3 results.