|
|
A091619
|
|
Number of compositions (ordered partitions) of n such that some part is repeated consecutively 5 times and no part is repeated consecutively more than 5 times.
|
|
2
|
|
|
1, 0, 2, 4, 9, 21, 46, 98, 213, 459, 979, 2082, 4408, 9294, 19535, 40937, 85561, 178392, 371131, 770556, 1596936, 3303986, 6825163, 14078718, 29002331, 59670920, 122627798, 251735331, 516247636, 1057687986, 2165046327, 4428017780, 9049083763, 18478717262
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
5,3
|
|
LINKS
|
|
|
MAPLE
|
b:= proc(n, l, k) option remember; `if`(n=0, 1, add(`if`(
i=l, 0, add(b(n-i*j, i, k), j=1..min(k, n/i))), i=1..n))
end:
a:= n-> b(n, 0, 5) -b(n, 0, 4):
|
|
MATHEMATICA
|
b[n_, l_, k_] := b[n, l, k] = If[n == 0, 1, Sum[If[i == l, 0, Sum[b[n - i*j, i, k], {j, 1, Min[k, n/i]}]], {i, 1, n}]];
a[n_] := b[n, 0, 5] - b[n, 0, 4];
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|