# Using Cauchy's integral formula to calculate an integral

Calculate $\int_0^{2\pi} e^{\cos(x)} \cos(\sin(x)) \; dx$ using Cauchy's integral formula.

I am really confused as I cannot bring the integral of the exercise and Cauchy's integral formula together.

When considering the integral bounds ($0$ to $2\pi$), it seems to me that the integral is calculated on a circle (what Cauchy's integral formula uses, as far as I understand it).

We already introduced line integrals as $$\int_\gamma f(z) \; dz = \int_a^bf(\gamma(t)) y'(t) dt$$ (where $\gamma$ is a path in the complex plane), but the integral provided doesn't look like that one.

Can you please tell me how the integral can be calculated using Cauchy's integral formula?

## 1 Answer

Consider the function $f(z)=e^{z}$. Using Cauchy's integral formula, you have \begin{align} 1=f(0)&=\frac1{2\pi i}\int_{|z|=1} \frac{e^z}{z} \; dz = \frac1{2\pi}\int_0^{2\pi}e^{e^{ix}}dx\\ &=\frac1{2\pi}\int_0^{2\pi}e^{\cos x +i\sin x}dx=\frac1{2\pi}\int_0^{2\pi}e^{\cos x }e^{i\sin x}dx\\ &=\frac1{2\pi}\int_0^{2\pi}e^{\cos x }(\cos (\sin x)+i\sin(\sin x))dx\\ &=\frac1{2\pi}\int_0^{2\pi}e^{\cos x }\cos (\sin x)dx+\left(\frac1{2\pi}\int_0^{2\pi}e^{\cos x }\sin(\sin x)dx\right)i. \end{align}

It follows that $$\int_0^{2\pi}e^{\cos x }\cos (\sin x)dx=2\pi.$$

• thank you for your answer! Could you please explain your first three steps? (1) Why do you get $z$ as denominator for your first integral (f(0) = $\int\cdots$)? (2) how do you get to $e^{e^{ix}}$ (3) how do you get from $e^{e^{ix}}$ to $e^{cos(x)} e^{i sin(x)}$? – muffel May 9 '14 at 19:42
• Well. (1). It is Cauchy Integral Formula for $z_0=0$. (2). Since $|z|=1$ then $z=e^{ix}$. (3). $e^{e^{ix}}=e^{\cos x +i\sin x}$ – Jlamprong May 9 '14 at 19:49