login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A246071 Number of endofunctions f on [2n] satisfying f^n(i) = i for all i in [n]. 2
1, 2, 50, 1440, 215760, 11218000, 8859219696, 549669946784, 797599992178688, 195297824029876992, 225830701916170080000, 33538442785393084937728, 478648537323384927696592896, 26649057768458576467019134976, 207869233649005397144301933676544 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
LINKS
FORMULA
a(n) = A246070(2n,n).
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, n^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$2)):
seq(a(n), n=0..20);
MATHEMATICA
multinomial[n_, k_List] := n!/Times @@ (k!);
M = multinomial;
b[n_, k0_, p_] := Module[{l, g}, l = Divisors[p];
g[k_, m_, i_, t_] := g[k, m, i, t] = Module[{d, j}, d = l[[i]];
If[i == 1, If[m == 0, 1, n^m], Sum[M[k, Join[{k - (d - t)*j},
Table[d - t, {j}]]]/j!*If[j == 0, 1, (d - 1)!^j]*M[m, Join[{m - t*j},
Array[t&, j]]]*g[k - (d - t)*j, m - t*j, Sequence @@
If[d - t == 1, {i - 1, 0}, {i, t + 1}]], {j, 0, Min[k/(d - t),
If[t == 0, {}, m/t]]}]]];
g[k0, n - k0, Length[l], 0]];
a[n_] := If[n == 0, 1, b[2*n, n, n]];
Table[a[n], {n, 0, 20}] (* Jean-François Alcover, Jun 27 2022, after Alois P. Heinz *)
CROSSREFS
Cf. A246070.
Sequence in context: A083941 A080263 A221241 * A367777 A088920 A278456
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Aug 12 2014
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 8 16:29 EDT 2024. Contains 372340 sequences. (Running on oeis4.)