OFFSET
1,2
LINKS
Alois P. Heinz, Rows n = 1..141, flattened
E. D. Bolker and A. M. Gleason, Counting permutations, J. Combin. Thy., A 29 (1980), 236-242.
EXAMPLE
Triangle begins
[1],
[2, 1],
[6, 0, 2],
[24, 9, 0, 6],
[120, 0, 0, 0, 24],
[720, 225, 160, 0, 0, 120],
[5040, 0, 0, 0, 0, 0, 720],
[40320, 11025, 0, 6300, 0, 0, 0, 5040],
[362880, 0, 62720, 0, 0, 0, 0, 0, 40320],
[3628800, 893025, 0, 0, 435456, 0, 0, 0, 0, 362880],
[39916800, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3628800],
[479001600, 108056025, 68992000, 56133000, 0, 46569600, 0, 0, 0, 0, 0, 39916800],
...
MAPLE
read transforms;
f:=(n, d)->mul(n-j+did(j, d), j=1..n); # did(d, j) = 1 iff j divides d, otherwise 0
g:=n->[seq(f(n, d), d=1..n)];
[seq(g(n), n=1..14)];
# second Maple program:
T:= proc(n, k) option remember; `if`(n=0, 1, add(
`if`(irem(j, k)=0, binomial(n-1, j-1)*(j-1)!*
T(n-j, k), 0), j=1..n))
end:
seq(seq(T(n, k), k=1..n), n=1..12); # Alois P. Heinz, May 14 2016
MATHEMATICA
T[n_, k_] := T[n, k] = If[n == 0, 1, Sum[If[Mod[j, k] == 0, Binomial[n-1, j -1] * (j-1)! * T[n-j, k], 0], {j, 1, n}]];
Table[T[n, k], {n, 1, 12}, {k, 1, n}] // Flatten (* Jean-François Alcover, May 24 2016, after Alois P. Heinz *)
CROSSREFS
KEYWORD
nonn,tabl
AUTHOR
N. J. A. Sloane, Jun 08 2012
STATUS
approved