[go: up one dir, main page]

login
A318113
Number of compositions of n into exactly n nonnegative parts <= five.
2
1, 1, 3, 10, 35, 126, 456, 1667, 6147, 22825, 85228, 319683, 1203632, 4546270, 17218995, 65372310, 248705155, 947926359, 3618884895, 13836004764, 52968655260, 203022926480, 779008308235, 2992051471500, 11502445734096, 44256184906376, 170408995261326
OFFSET
0,3
LINKS
FORMULA
a(n) = [x^n] ((x^6-1)/(x-1))^n.
a(n) <= A088218(n) with equality only for n < 6.
a(n) = Sum_{k=0..floor(n/6)} (-1)^k * binomial(n,k) * binomial(2*n-6*k-1,n-6*k). - Ilya Gutkovskiy, Nov 03 2021
MAPLE
b:= proc(n, i) option remember; `if`(n=0, 1,
`if`(i=0, 0, add(b(n-j, i-1), j=0..min(n, 5))))
end:
a:= n-> b(n$2):
seq(a(n), n=0..30);
CROSSREFS
Column k=5 of A305161.
Cf. A088218.
Sequence in context: A047037 A339040 A201058 * A216710 A087946 A318114
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Aug 17 2018
STATUS
approved