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.

A367969 Number of partitions of [n] whose block maxima sum to k, where k is chosen so as to maximize this number.

Original entry on oeis.org

1, 1, 1, 2, 5, 11, 37, 129, 431, 1921, 9544, 43844, 223512, 1407320, 8519457, 52422985, 373424140, 2685768084, 20354852852, 160370778238, 1318493838635, 11239312718146, 98700416575613, 916309760098349, 8735277842452542, 84921152781222758, 860903677319960583
Offset: 0

Views

Author

Alois P. Heinz, Dec 06 2023

Keywords

Examples

			a(5) = 11 = A367955(5,12) is the largest value in row 5 of A367955 and counts the partitions of [5] having block maxima sum 12: 123|4|5, 124|3|5, 125|3|4, 13|24|5, 13|25|4, 14|23|5, 15|23|4, 14|25|3, 15|24|3, 1|2|34|5, 1|2|35|4.
		

Crossrefs

Row maxima of A367955.

Programs

  • Maple
    b:= proc(n, m) option remember; `if`(n=0, 1,
          b(n-1, m)*m + expand(x^n*b(n-1, m+1)))
        end:
    a:= n-> max(coeffs(b(n, 0))):
    seq(a(n), n=0..30);
    # second Maple program:
    b:= proc(n, i, t) option remember; `if`(i*(i+1)/2 max(seq(b(k, n, 0), k=n..n*(n+1)/2)):
    seq(a(n), n=0..30);
  • Mathematica
    b[n_, m_] := b[n, m] = If[n == 0, 1, b[n-1, m]*m + Expand[x^n*b[n-1, m+1]]];
    a[n_] := Max[CoefficientList[b[n, 0], x]];
    Table[a[n], {n, 0, 30}]
    (* second program: *)
    b[n_, i_, t_] := b[n, i, t] = If[i*(i + 1)/2 < n, 0, If[n == 0, t^i, If[t == 0, 0, t*b[n, i - 1, t]] + (t + 1)^Max[0, 2*i - n - 1]*b[n - i, Min[n - i, i - 1], t + 1]]];
    a[n_] := If[n == 0, 1, Max[Table[b[k, n, 0], { k, n, n*(n + 1)/2}]]];
    Table[a[n], {n, 0, 30}] (* Jean-François Alcover, Dec 13 2023, after Alois P. Heinz *)