[Math] Number of permutations with all cycles of even length

algebraic-combinatoricscombinatorics

For even $n$ (only!), let $e_n$ stand for the number of permutations with all cycle of even length. Let $E(x)$ be the exponential generating functions. Prove that $E(x) = (1 – x^2)^{-\frac12}.$

I tried to find the generating function as a formal sum, but it didn't work out.

Best Answer

We attempt to find a recurrence relation for the $e_n$, and convert that to information about the exponential generating function $E(x)=\sum_n e_n\frac{x^n}{n!}$.

Sort the permutations of $n$ with all cycles of even length by the length of the cycle that includes $1$. If this cycle has length $2k$, then there are $\binom{n-1}{2k-1}$ ways to choose the other $2k-1$ elements in the cycle, $(2k-1)!$ different cycles on those $2k$ elements, and $e_{n-2k}$ permutations of the $n-2k$ elements outside that cycle with all cycles of even length. Therefore, $$e_n = \sum_{k=1}^{\lfloor n/2\rfloor}\binom{n-1}{2k-1}\cdot (2k-1)!\cdot e_{n-2k} = \sum_{k=1}^{\lfloor n/2\rfloor}\frac{(n-1)!}{(n-2k)!}\cdot e_{n-2k}$$ $$n\frac{e_n}{n!} =\sum_{k=1}^{\lfloor n/2\rfloor}\frac{e_{n-2k}}{(n-2k)!}$$ Now, multiply by powers of $x$ to convert that to a generating function. We have that $xE'(x)=\sum_n ne_n\frac{x^n\cdot x}{n!}$, so \begin{align*}n\frac{e_n}{n!}x^n &= \sum_{k=1}^{\lfloor n/2\rfloor}\frac{e_{n-2k}x^{n-2k}}{(n-2k)!}\cdot x^{2k}\\ xE'(x) &= E(x)\cdot (x^2+x^4+\cdots) = \frac{x^2}{1-x^2}E(x)\\ \frac{E'(x)}{E(x)} &= \frac{x}{1-x^2}\\ \ln(E(x)) &= \int \frac{x}{1-x^2}\,dx = C-\frac12\ln(1-x^2)\\ E(x) &= A(1-x^2)^{-\frac12}\end{align*} We can lock down the constant of integration by evaluating at $x=0$; $e_0=1$, so $E(0)=1$ and $A=1$. There it is.