OFFSET
0,2
COMMENTS
FORMULA
T(n,k) = (1/(n+1))*binomial(n+1,k)*Sum_{j=0..n+1-k}3^(n-2k+j+2)*binomial(n+1-k,j)*binomial(j,k-1-j).
G.f. = G = G(t,z) satisfies G = (1+z(G-1+t))^3.
EXAMPLE
T(2,2)=3 because we have (Q,L,M), (Q,L,R) and (Q,M,R), where Q denotes the root and L (M,R) denotes a left (middle, right) child of Q.
Triangle starts:
1;
3;
9, 3;
27, 27, 1;
81, 162, 30;
243, 810, 360, 15;
MAPLE
T:=proc(n, k) if k<=n+1-ceil(n/3) then (1/(n+1))*binomial(n+1, k)*sum(3^(n+j-2*k+2)*binomial(n+1-k, j)*binomial(j, k-1-j), j=0..n+1-k) else 0 fi end: 1; for n from 1 to 11 do seq(T(n, k), k=1..n+1-ceil(n/3)) od; # yields sequence in triangular form
CROSSREFS
KEYWORD
nonn,tabf
AUTHOR
Emeric Deutsch, Jul 21 2006
STATUS
approved