<s>[INST] Find Cauchy principal values of $\int_{-\infty}^{\infty}\frac{x}{(x^2+4)(x^2-2x+5)}\,dx$ I have been asked to find the Cauchy principal vlaues of the following problem using residues:
$\int_{-\infty}^{\infty}\frac{x}{(x^2+4)(x^2-2x+5)}\,dx$
So far I have taken $\oint_C\frac{z}{(z^2+4)(z^2-2z+5)}\,dz$
which gives me:
$2\pi i\sum \operatorname{Res}\biggl[\frac{z}{(z^2+4)(z^2-2z+5)}\biggl]$
Where do I go from here?
 [/INST] factor the denominator.
$\frac {z}{(z+2i)(z-2i)(z-1+2i)(z-1-2i)}$
We only care about the poles in the upper half-plane.
You have poles at $z = 2i, z = 1+2i$
at $z=2i$
$Res f(z) = \lim_\limits{z\to 2i} (z-2i)f(z) =  \frac {2i}{(4i)(-1+4i)(-1)} = \frac {1+4i}{2(17)} = \frac {1}{34} + \frac {2i}{17} $
and at  $z = 1+2i$
$Res f(z) = \frac {1+2i}{(1+4i)(1)(4i)} = \frac {(1+2i)(1-4i)}{(17)(4i)} = \frac {9 - 2i}{(17)(4i)} = -\frac{9i}{68} - \frac {1}{34}$
add them together
$2\pi i \left(\frac {-i}{68}\right) = \frac {\pi}{34}$
</s>