|
|
A232396
|
|
Triangular array read by rows: T(n,k) is the number of compositions of n with no two consecutive identical parts that have exactly k parts = 1, n>=0, 0<=k<=ceiling(n/3).
|
|
2
|
|
|
1, 0, 1, 1, 0, 1, 2, 1, 2, 1, 3, 3, 1, 3, 8, 3, 6, 9, 7, 1, 7, 20, 10, 2, 14, 27, 25, 5, 18, 52, 39, 14, 1, 30, 77, 78, 26, 3, 45, 132, 133, 60, 8, 66, 213, 240, 117, 24, 1, 107, 334, 421, 232, 54, 4, 157, 562, 716, 450, 127, 12, 245, 872, 1265, 842, 279, 38, 1
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,7
|
|
LINKS
|
|
|
FORMULA
|
G.f.: 1/( 1 - y*x/(1 + y*x) - Sum_{j>=2} x^j/(1 + x^j) ).
|
|
EXAMPLE
|
1;
0, 1;
1, 0;
1, 2;
1, 2, 1;
3, 3, 1;
3, 8, 3;
6, 9, 7, 1;
7, 20, 10, 2;
14, 27, 25, 5;
18, 52, 39, 14, 1;
T(7,2) = 7 because we have: 1+2+1+3, 1+2+3+1, 1+3+1+2, 1+3+2+1, 1+5+1, 2+1+3+1, 3+1+2+1.
|
|
MAPLE
|
b:= proc(n, t) option remember; `if`(n=0, 1, expand(
add(`if`(j=t, 0, b(n-j, j)*`if`(j=1, x, 1)), j=1..n)))
end:
T:= n-> seq(coeff(b(n, 0), x, i), i=0..ceil(n/3)):
|
|
MATHEMATICA
|
nn=10; CoefficientList[Series[1/(1- u z/(1+ u z) - Sum[z^j/(1+z^j), {j, 2, nn}]), {z, 0, nn}], {z, u}]//Grid
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,tabf
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|