I'm working through a Complex Analysis text and am working through the Residue chapter. I am not sure if I am approaching this question correctly.
$$ \int_\gamma \frac{1}{(z-1)^2(z^2+1)}$$
Such that $\gamma$ is a circle of radius of 2 centered at 0. Traversed counter clockwise.
My approach was as follows:
I know that there are poles at $z=1,i,-i$ where $1$ is of order $2$.
First I found the residues at the poles as follows:
$$\operatorname{Res} _{z=1} :\lim_{z\rightarrow 1} \frac{d}{dz} \frac{(z-1)^2}{(z-1)^2(z^2+1)}$$ $$\lim_{z\rightarrow 1} \frac{d}{dz} \frac{1}{(z^2+1)}$$ $$\lim_{z\rightarrow 1} -\frac{2z}{(z^2+1)^2}$$ $$ = -1/2$$
$$\operatorname{Res} _{z=i} :\lim_{z\rightarrow i} \frac{1}{(z-1)^2}$$ $$ = \frac{1}{(i-1)^2}$$
$$\operatorname{Res} _{z=-i} :\lim_{z\rightarrow -i} \frac{1}{(z-1)^2}$$ $$ = \frac{1}{(-i-1)^2}$$
Therefore the integral is $2\pi i$*sum of the Residues.
$$= 2\pi i(\frac{1}{(i-1)^2} - \frac{1}{2} + \frac{1}{(-i-1)^2})$$
Thank you for any guidance. The repeated root is really where I'm wondering if it makes a difference.