OFFSET
0,8
LINKS
Alois P. Heinz, Rows n = 0..140, flattened
FORMULA
E.g.f.: G(t,z) = exp[(1/4)(t-1)(2z - 1 + exp(2z))]/(1-z).
The 4-variate g.f. H(u,v,w,z) (exponential with respect z), where u marks number of cycles with 1 alternating run, v marks number of cycles with 2 alternating runs, w marks the number of all cycles, and z marks the size of the permutation, is given by
H(u,v,w,z) = exp[(1/4)w((v-1)(exp(2z)+2z)+4(u-v)exp(z)+1-4u+3v)]/(1-z)^w.
We have G(t,z) = H(t,t,1,z).
EXAMPLE
T(3,2)=3 because we have (1)(23), (12)(3), and (13)(2).
T(4,0)=2 because we have (1423) and (1324).
T(4,1)=4 because we have (1234), (1243), (1342), and (1432).
Triangle starts:
1;
0,1;
0,1,1;
0,2,3,1;
2,4,11,6,1;
16,18,40,35,10,1;
MAPLE
G := exp((1/4)*(t-1)*(2*z-1+exp(2*z)))/(1-z): Gser := simplify(series(G, z = 0, 15)): for n from 0 to 13 do P[n] := sort(expand(factorial(n) * coeff(Gser, z, n))) end do: for n from 0 to 10 do seq(coeff(P[n], t, k), k = 0 .. n) end do; # yields sequence in triangular form
# second Maple program:
b:= proc(n) option remember; expand(
`if`(n=0, 1, add(b(n-j)*binomial(n-1, j-1)*
`if`(j=1, x, (j-1)!+2^(j-2)*(x-1)), j=1..n)))
end:
T:= n-> (p-> seq(coeff(p, x, i), i=0..n))(b(n)):
seq(T(n), n=0..12); # Alois P. Heinz, Apr 15 2017
MATHEMATICA
b[n_] := b[n] = Expand[If[n==0, 1, Sum[b[n-j]*Binomial[n-1, j-1]*If[j==1, x, (j-1)! + 2^(j-2)*(x-1)], {j, 1, n}]]];
T[n_] := Function[p, Table[Coefficient[p, x, i], {i, 0, n}]][b[n]];
Table[T[n], {n, 0, 12}] // Flatten (* Jean-François Alcover, May 18 2017, after Alois P. Heinz *)
CROSSREFS
KEYWORD
nonn,tabl
AUTHOR
Emeric Deutsch, Mar 07 2011
STATUS
approved