Problem from the 2020 Latvian "Sophomore's Dream" competition [duplicate]

Evaluate $$\int_{-a\pi}^{a\pi} \frac{\cos^5(x)+1}{e^x+1}dx, \quad a \in \mathbb{N}$$

In the beginning, I didn't have any ideas of how to solve this. The one that later came to mind was to try using Feynman's technique, but I couldn't think of the proper function to use for the second variable.

Any ideas?


Solution 1:

Let $I$ be our integral. Substitute $t=-x \Rightarrow dt = -dx$. Then:

$$I=\int_{-a\pi}^{a\pi} \frac{\cos^5 t+1}{e^{-t}+1}\,dt=\int_{-a\pi}^{a\pi} \frac{e^t(\cos^5 t+1)}{e^{t}+1}\,dt=\int_{-a\pi}^{a\pi} \frac{e^x(\cos^5 x+1)}{e^{x}+1}\,dx$$

Therefore:

$$2I=\int_{-a\pi}^{a\pi} \frac{e^x(\cos^5 x+1)}{e^{x}+1}\,dx+\int_{-a\pi}^{a\pi} \frac{\cos^5 x+1}{e^{x}+1}\,dx=\int_{-a\pi}^{a\pi} (\cos^5 x+1)\,dx$$

$$=\bigg[x + \frac{5}{8} \sin(x) + \frac{5}{48} \sin 3 x + \frac{1}{80} \sin 5 x\bigg]_{-a\pi}^{a\pi}=2a\pi$$

Thus $I=a\pi$.