# Residue theorem integral

I have this integral $$\int_{ 0}^{2\pi } \frac{1}{1+\cos^2x } \,dx$$ I have two double order poles at $$z^2=-3\pm2\sqrt2$$ I'm having trouble taking the limit and finding the residue of this double order pole $$\lim_{z\to-3+2\sqrt{2}}\frac{d}{dz}[(z-(-3+2\sqrt2)^2\frac{z}{(z-(-3+2\sqrt2)(z-(-3-2\sqrt2)}]$$ any help would be greatly appreciated it

-
What function of $\,z\,$ are you taking that has those complex numbers as poles?? – DonAntonio Nov 25 '12 at 12:21
the function is z^4+6z+1 – L.oiler Nov 25 '12 at 13:56
Ok, from here we should have begun. – DonAntonio Nov 25 '12 at 15:28

You make the change of variable $z=e^{ix}$. Then $$dx=\frac{1}{i}\frac{dz}{z},$$ $$\frac{1}{1+\cos^2x}=\frac{1}{1+(z+z^{-1})^2}=\frac{4\,z^2}{z^4+6\,z^2+1},$$ and $$\int_0^{2\pi}\frac{dx}{1+\cos^2x}=\frac{1}{i}\int_{|z|=1}\frac{4\,z}{z^4+6\,z^2+1}\,dz.$$ To apply the residue theorem you need the poles inside the circle $\{|z|=1\}$, that is, the solutions of $$z^4+6\,z^2+1=0,\quad |z|<1.$$ Solving for $z^2$ gives $$z^2=-3\pm2\,\sqrt2.$$
There are no double poles. You are interested only on the poles in the unit disk. Since $$|-3-2\,\sqrt2|>1\text{ and }|-3+2\,\sqrt2|<1,$$ you have to consider only $$z^2=2\,\sqrt2-3\ .$$ This gives you two simple poles at $$z=\pm\sqrt{2\,\sqrt2-3\,}\ .$$
I'm a still a bit confused. Basically my compex function I'm integrating is $$\frac{-4iz}{z^4+6z+1}dz$$ so how do I get the residue of the function at $$z=\pm\sqrt{(2\sqrt2-3)}$$? – L.oiler Nov 25 '12 at 13:29