OFFSET
0,2
FORMULA
G.f.: A(x,y) = ( x*H(x) - y*H(x*y^3) )/( x*(1+y)^3 - y ), where H(x) satisfies: H(x) = G*H(x^4*G^3) and G(x) is g.f. of A001764: G(x) = 1 + x*G(x)^3.
EXAMPLE
Triangle begins:
1;
3, 3, 1, 3;
12, 19, 18, 15, 10, 3, 12;
55, 111, 138, 128, 96, 66, 55, 39, 12, 55;
276, 636, 930, 1005, 876, 669, 498, 360, 263, 240, 177, 55, 276;
Convolution of [1,3,3,1] with each row produces:
[1,3,3,1]*[1] = [1,3,3,1];
[1,3,3,1]*[3,3,1,3] = [3,12,19,18,15,10,3];
[1,3,3,1]*[12,19,18,15,10,3,12] = [12,55,111,138,128,96,66,55,39,12];
[1,3,3,1]*[55,111,138,128,96,66,55,39,12,55] =
[55,276,636,930,1005,876,669,498,360,263,240,177,55];
These convoluted rows, when concatenated, yield the sequence:
1,3,3,1, 3,12,19,18,15,10,3, 12,55,111,138,128,96,66,55,39,12, 55,...
which equals the concatenated rows of this original triangle:
1, 3,3,1,3, 12,19,18,15,10,3,12, 55,111,138,128,96,66,55,39,12,55, ...
MATHEMATICA
T[n_, k_] := T[n, k] = If[3*n < k || k < 0, 0, If[n == 0 && k == 0, 1, If[k == 3*n, T[n, 0], T[n - 1, k + 1] + 3*T[n - 1, k] + 3*T[n - 1, k - 1] + T[n - 1, k - 2]]]];
Table[T[n, k], {n, 0, 10}, {k, 0, 3 n}] // Flatten (* Jean-François Alcover, Jan 24 2018, translated from PARI *)
PROG
(PARI) /* Generate Triangle by the Recurrence: */
{T(n, k)=if(3*n<k || k<0, 0, if(n==0 && k==0, 1, if(k==3*n, T(n, 0), T(n-1, k+1)+3*T(n-1, k)+3*T(n-1, k-1)+T(n-1, k-2))))}
for(n=0, 10, for(k=0, 3*n, print1(T(n, k), ", ")); print(""))
(PARI) /* Generate Triangle by the G.F.: */
{T(n, k)=local(A, F=(1+x)^3, d=3, G=x, H=1+x, S=ceil(log(n+1)/log(d+1))); for(i=0, n, G=x*subst(F, x, G+x*O(x^n))); for(i=0, S, H=subst(H, x, x*G^d+x*O(x^n))*G/x); A=(x*H-y*subst(H, x, x*y^d +x*O(x^n)))/(x*subst(F, x, y)-y); polcoeff(polcoeff(A, n, x), k, y)}
for(n=0, 10, for(k=0, 3*n, print1(T(n, k), ", ")); print(""))
CROSSREFS
KEYWORD
nonn,tabl
AUTHOR
Paul D. Hanna, Jul 17 2006
STATUS
approved