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.

A180284 Number of arrangements of n indistinguishable balls in n boxes with the maximum number of balls in any box equal to 4.

Original entry on oeis.org

4, 20, 90, 392, 1652, 6804, 27600, 110715, 440374, 1740024, 6838832, 26762645, 104356980, 405706292, 1573256772, 6087597150, 23511579564, 90659983064, 349090305487, 1342531370565, 5157512878694, 19794331541270, 75905591609120, 290857683782250, 1113774550930080
Offset: 4

Views

Author

R. H. Hardin, Aug 24 2010

Keywords

Crossrefs

Column 4 of A180281.

Programs

  • Maple
    b:= proc(n, i, k) option remember; `if`(n=0, 1,
          `if`(i=0, 0, add(b(n-j, i-1, k), j=0..min(n, k))))
        end:
    a:= n-> (k-> b(n$2, k)-b(n$2, k-1))(4):
    seq(a(n), n=4..30);  # Alois P. Heinz, Aug 17 2018
  • Mathematica
    b[n_, i_, k_] := b[n, i, k] = If[n == 0, 1, If[i == 0, 0, Sum[b[n - j, i - 1, k], {j, 0, Min[n, k]}]]];
    a[n_] := If[n == 0, 1, b[n, n, 4] - b[n, n, 3]];
    Table[a[n], {n, 4, 30}] (* Jean-François Alcover, Aug 28 2022, after Maple program *)