TITLE: Integral of $(1+\cos(t))^n$ from $-\pi$ to $\pi$
QUESTION [5 upvotes]: Using an integration solver (Mathematica), I've gotten the following result
$$\int_{-\pi }^{\pi } (1+\cos (t))^n \, {\rm d}t = 2^{1-n} \pi \binom{2 n}{n}$$
Any suggestion on how to prove this would be appreciated. I'm not sure how the binomial coefficient gets introduced, my best guess is to use some properties of the gamma function although in not sure which. I'm also familiar with the basics of contour integration but not sure if that can be applied here. Also, if anyone knows a source for this integral that would be appreciated.

REPLY [6 votes]: Let $u=t/2$ so $1+\cos t=2\cos^2u$. Since the integrand is even, the integral is$$a_n:=2^{n+2}\int_0^{\pi/2}\cos^{2n}udu=2^{n+1}\operatorname{B}(n+\tfrac12,\,\tfrac12)=\frac{2^{n+1}\sqrt{\pi}}{n!}\Gamma(n+\tfrac12).$$Since $a_0=2\pi,\,\frac{a_{n+1}}{a_n}=\frac{2n+1}{n+1}$, you can prove your conjecture by induction.

REPLY [2 votes]: This is not a complete answer yet, but i got this far, maybe this helps you to get to a correct solution. As mentioned in the comments, something is wrong with yours.:
According to Wikipedia it holds for even $n$:
$$ \int_{-\pi}^\pi \cos(t)^n dt = \frac{2\pi}{2^n}\binom{n}{\frac n 2}.$$
This is rather a standard integral and probably could be proven with the recursion formula for cosine integrals. For odd $n$ the above integral is obviously equal to zero. We thus get by the binomial theorem:
\begin{align}
 \int_{-\pi}^\pi (1 + \cos(t))^n dt &= \sum_{i = 0}^n \binom{n}{i}\int_{-\pi}^\pi \cos(t)^n dt \\
&=\sum_{i = 0}^{\left\lfloor \frac n 2 \right\rfloor} \binom{n}{2i}\frac{2\pi}{2^{2i}} \binom{2i}{i} \\
&= 2\pi \sum_{i = 0}^{\left\lfloor \frac n 2 \right\rfloor}\frac{1}{4^i}\binom{n}{2i}\binom{2i}{i}.
\end{align}
Maybe the sum could be simplified further.