Let $$ \begin{align} I=\int_0^{2\pi}\frac{1}{4+\cos t}dt \end{align} $$
I would like to evaluate this integral using cauchhy's Integral formula, I understand that I have to convert this into a form like $\int_{\gamma}\frac{f(z)}{z-z_0}dz$ .
I tried using $\cos t=\frac{e^{it}+e^{-it}}{2}$, but I didn't get anywhere. I haven't seen an example like this.
Note that your integral can be rewritten as follows:
Define now $z \equiv e^{it}$, $\mathrm{d}z = ie^{it} \, \mathrm{d}t = i z \, \mathrm{d}t $, so:
What should then $\gamma$ be? Can you take it from here?
Cheers!
Spoiler: