OFFSET
0,3
COMMENTS
Conjecture: Lim inf n->infinity a(n) / (((n-1)!)^2 * 4^(n-1) / sqrt(n)) = 1.128... . - Vaclav Kotesovec, Aug 14 2014
LINKS
Alois P. Heinz and Vaclav Kotesovec, Table of n, a(n) for n = 0..233 (first 100 terms from Alois P. Heinz)
Vaclav Kotesovec, Graph - asymptotic
FORMULA
a(n) = A246072(2n,n).
EXAMPLE
a(2) = 10: (1,2,3,4), (1,2,4,3), (1,3,2,4), (1,4,3,2), (2,1,3,4), (2,1,4,3), (3,2,1,4), (3,4,1,2), (4,2,3,1), (4,3,2,1).
a(3) = 108: (1,2,3,4,5,6), (1,2,3,4,6,5), (1,2,3,5,4,6), ... (6,4,2,3,1,5), (6,5,1,2,4,3), (6,5,2,1,3,4).
MAPLE
with(numtheory): with(combinat): M:=multinomial:
b:= proc(n, k, p) local l, g; l, g:= sort([divisors(p)[]]),
proc(k, m, i, t) option remember; local d, j; d:= l[i];
`if`(i=1, m!, add(M(k, k-(d-t)*j, (d-t)$j)/j!*
(d-1)!^j *M(m, m-t*j, t$j) *g(k-(d-t)*j, m-t*j,
`if`(d-t=1, [i-1, 0], [i, t+1])[]), j=0..min(k/(d-t),
`if`(t=0, [][], m/t))))
end; g(k, n-k, nops(l), 0)
end:
a:= n-> `if`(n=0, 1, b(2*n, n, n)):
seq(a(n), n=0..20);
MATHEMATICA
multinomial[n_, k_List] := n!/Times @@ (k!); M = multinomial;
b[n_, k_, p_] := b[n, k, p] = Module[{l, g}, l = Sort[Divisors[p]]; g[k0_, m_, i_, t_] := g[k0, m, i, t] = Module[{d}, d = l[[i]]; If[i == 1, m!, Sum[M[k0, Join[{k0 - (d - t) j}, Table[d - t, {j}]]]/j! (d - 1)!^j M[m, Join[{m - t j}, Table[t, {j}]]] If[d - t == 1, g[k0 - (d - t) j, m - t j, i - 1, 0], g[k0 - (d - t) j, m - t j, i, t + 1]], {j, 0, Min[k0/(d - t), If[t == 0, Infinity, m/t]]}]]]; g[k, n - k, Length[l], 0]];
a[n_] := If[n == 0, 1, b[2n, n, n]];
a /@ Range[0, 20] (* Jean-François Alcover, Nov 13 2020, after Alois P. Heinz *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Aug 12 2014
STATUS
approved