# Using Cauchy Integral Formula To Solve Integrals

Would the solution to the following integral: $$\int_{|z|=1} e^{2z} \frac1z \,dz$$

be 2$$\pi$$i when using Cauchy's Integral Formula?

Also, how would I use the value from this integral to evaluate the following: $$\int_0^{2𝜋} e^{2\cosθ}\cos(2\sinθ) \,dθ$$

Yes, the solution would be $$2\pi i$$. Letting $$z=e^{i\theta}$$, we have $$\text{d}z=ie^{i\theta}\text{d}\theta$$, and your integral becomes
$$i\int_{0}^{2\pi}e^{2\cos\theta}\cos\left(2\sin\theta\right)\text{d}\theta-\int_{0}^{2\pi}e^{2\cos\theta}\sin\left(2\sin\theta\right)\text{d}\theta.$$
Notice that the right integral equals $$0$$ because it is odd with a period of $$2\pi$$. Thus,
$$\int_{\left\lvert z\right\rvert=1}\frac{e^{2z}}{z}\text{d}z=i\int_{0}^{2\pi}e^{2\cos\theta}\cos\left(2\sin\theta\right)\text{d}\theta=2\pi i,$$
giving $$\int_{0}^{2\pi}e^{2\cos\theta}\cos\left(2\sin\theta\right)\text{d}\theta=2\pi.$$