OFFSET
0,3
COMMENTS
Row n has n-1 entries (n>=2).
Sum of entries in row n is n! (A000142(n)).
T(n,0) = A152876(n).
T(n,n-2) = A092186(n).
T(2n+1,2n-2) = A047677(n) = 2*n!*(n+1)!. - Alois P. Heinz, Nov 10 2013
LINKS
Alois P. Heinz, Rows n = 0..142, flattened
E. Munarini and N. Zagaglia Salvi, Binary strings without zigzags, Sem. Lotharingien de Combinatoire, 49, 2004, B49h.
FORMULA
It would be good to have a formula or generating function for this sequence (a formula for column 0 is given in A152876).
Sum_{k>=1} k*T(n,k) = A329550(n). - Alois P. Heinz, Nov 16 2019
EXAMPLE
T(3,1) = 2 because we have 123 and 321.
Triangle starts:
1;
1;
2;
4, 2;
16, 0, 8;
60, 24, 24, 12;
288, 144, 216, 0, 72;
1584, 1296, 1152, 576, 288, 144;
10368, 9216, 10368, 4608, 4608, 0, 1152;
...
MAPLE
b:= proc(o, u, t) option remember; `if`(u+o=0, 1, expand(
o*b(o-1, u, [2, 2, 5, 5, 2][t])*`if`(t=4, x, 1)+
u*b(o, u-1, [3, 4, 3, 3, 4][t])*`if`(t=5, x, 1)))
end:
T:= n-> (p-> seq(coeff(p, x, i), i=0..degree(p)))(
b(ceil(n/2), floor(n/2), 1)):
seq(T(n), n=0..12); # Alois P. Heinz, Nov 10 2013
MATHEMATICA
b[o_, u_, t_] := b[o, u, t] = If[u+o == 0, 1, Expand[o*b[o-1, u, {2, 2, 5, 5, 2}[[t]]]*If[t == 4, x, 1] + u*b[o, u-1, {3, 4, 3, 3, 4}[[t]]]*If[t == 5, x, 1]]]; T[n_] := Function[{p}, Table[Coefficient[p, x, i], {i, 0, Exponent[p, x]}]] [b[Ceiling[n/2], Floor[n/2], 1]]; Table[T[n], {n, 0, 12}] // Flatten (* Jean-François Alcover, May 27 2015, after Alois P. Heinz *)
CROSSREFS
KEYWORD
nonn,tabf
AUTHOR
Emeric Deutsch, Dec 17 2008
EXTENSIONS
More terms from Alois P. Heinz, Nov 10 2013
STATUS
approved