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.

A332721 Number of compositions of n^2 with parts <= n, such that each element of [n] is used at least once.

Original entry on oeis.org

1, 1, 3, 72, 5752, 1501620, 1171326960, 2571831080160, 15245263511750160, 236246829658682027760, 9325247205993698149853760, 917699267902161951609308035200, 221117091698491444413008381486903040, 128433050637127079872089064922773889126400
Offset: 0

Views

Author

Alois P. Heinz, Feb 21 2020

Keywords

Examples

			a(2) = 3: 112, 121, 211.
a(3) = 72: 111123, 111132, 111213, 111231, 111312, 111321, 112113, 112131, 112311, 113112, 113121, 113211, 121113, 121131, 121311, 123111, 131112, 131121, 131211, 132111, 211113, 211131, 211311, 213111, 231111, 311112, 311121, 311211, 312111, 321111, 11223, 11232, 11322, 12123, 12132, 12213, 12231, 12312, 12321, 13122, 13212, 13221, 21123, 21132, 21213, 21231, 21312, 21321, 22113, 22131, 22311, 23112, 23121, 23211, 31122, 31212, 31221, 32112, 32121, 32211, 1233, 1323, 1332, 2133, 2313, 2331, 3123, 3132, 3213, 3231, 3312, 3321.
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, p) option remember; `if`(n=0 or i=1, (p+n)!
           /(n+1)!, add(b(n-i*j, i-1, p+j)/(j+1)!, j=0..n/i))
        end:
    a:= n-> b(n*(n-1)/2, n$2):
    seq(a(n), n=0..15);
  • Mathematica
    b[n_, i_, p_] := b[n, i, p] = If[n == 0 || i == 1, (p + n)!/(n + 1)!, Sum[b[n - i*j, i - 1, p + j]/(j + 1)!, {j, 0, n/i}]];
    a[n_] := b[n(n - 1)/2, n, n];
    Table[a[n], {n, 0, 15}] (* Jean-François Alcover, Mar 04 2022, after Alois P. Heinz *)

Formula

a(n) = A373118(n^2,n). - Alois P. Heinz, May 26 2024

A332796 Number of compositions of n^2 into parts >= n.

Original entry on oeis.org

1, 1, 2, 6, 26, 140, 882, 6349, 51284, 457704, 4459940, 47019819, 532485538, 6438774524, 82710138994, 1123798871990, 16090426592488, 241979954659728, 3811335657375786, 62712512310820402, 1075527196672980525, 19186234784992217621, 355349469934379290700
Offset: 0

Views

Author

Alois P. Heinz, Feb 24 2020

Keywords

Examples

			a(0) = 1: (), the empty composition.
a(1) = 1: 1.
a(2) = 2: 22, 4.
a(3) = 6: 333, 36, 63, 45, 54, 9.
a(4) = 26: 4444, 556, 565, 655, 466, 646, 664, 457, 475, 547, 574, 745, 754, 448, 484, 844, 88, 79, 97, 6(10), (10)6, 5(11), (11)5, 4(12), (12)4, (16).
		

Crossrefs

Programs

  • Maple
    b:= proc(n, k) option remember; `if`(n=0, 1,
          add(b(n-j, k), j=k..n))
        end:
    a:= n-> b(n^2, n):
    seq(a(n), n=0..23);
  • Mathematica
    b[n_, k_] := b[n, k] = If[n == 0, 1, Sum[b[n - j, k], {j, k, n}]];
    a[n_] := b[n^2, n];
    Table[a[n], {n, 0, 23}] (* Jean-François Alcover, Mar 04 2022, after Alois P. Heinz *)

A333048 Number of compositions of n^2 into powers of n.

Original entry on oeis.org

1, 1, 6, 20, 96, 572, 3971, 31201, 272334, 2605268, 27042522, 302171806, 3611295430, 45911641817, 618074912240, 8776287336812, 130994094465946, 2049114914257540, 33504826964461451, 571285301051283841, 10136481840545237652, 186803012671904648805
Offset: 0

Views

Author

Alois P. Heinz, Mar 06 2020

Keywords

Examples

			a(0) = 1: the empty composition.
a(1) = 1: 1.
a(2) = 6: 1111, 112, 121, 211, 22, 4.
a(3) = 20: 111111111, 1111113, 1111131, 1111311, 1113111, 1131111, 1311111, 3111111, 11133, 11313, 11331, 13113, 13131, 13311, 31113, 31131, 31311, 33111, 333, 9.
		

Crossrefs

Programs

  • Maple
    a:= n-> `if`(n<2, 1, 1+add(binomial(n*(n-j)+j, j), j=0..n)):
    seq(a(n), n=0..21);

Formula

a(n) = 1 + Sum_{j=0..n} binomial(n*(n-j)+j,j) if n>1, a(0) = a(1) = 1.
Showing 1-3 of 3 results.