I'm stuck with the following problem:
I need to calculate $\sum_{k=0}^n \binom{n}{k} ^2$ using Parseval's identity for the function $f(x) = (1+e^{i x})^n$.
Here's what I did so far:
$f(x) = (1+e^{i x})^n = \sum_{k=0}^n \binom{n}{k} e^{i k x}$, so the Fourier coefficients of $f$ are $f_k = \begin{cases} \binom{n}{k} & 0 \leq k \leq n \\ 0 & \text{otherwise}\end{cases}$. Now I would like to use Parseval, but what is tripping me up is how to get $\int_0^{2 \pi} |f(x)|^2 dx$.
Any help is appreciated.
You could perhaps use complex methods: You have $$ |f(x)|^2=(1+e^{ix})^n(1+e^{-ix})^n. $$ Let $z=e^{ix}$. Then, by the Cauchy integral formula, $$ \begin{aligned} \int_0^{2\pi}|f(x)|^2\,dx &=\int_0^{2\pi}(1+e^{ix})^n(1+e^{-ix})^n\,dx\\ &=\int_{|z|=1}(1+z)^n(1+1/z)^n\frac{1}{iz}\,dz\\ &=-i\int_{|z|=1}(1+z)^{2n}\frac{1}{z^{n+1}}\,dz\\ &=-i\cdot i2\pi\cdot\frac{1}{n!}\frac{d^n}{dz^n}(1+z)^{2n}\Bigl|_{z=0}=2\pi\binom{2n}{n}. \end{aligned} $$