Find $$\int_{-\infty}^{\infty}\frac{1}{(x^2+1)(2-2x+x^2)}dx$$
So I am going to integrate this using a semicircular contour. Is it safe to say that on the curved part, the integral vanishes? because we have two terms that are of the order $x^2$. Wouldn't this mean that the Integral that I wish to calculate is equivalent to $2\pi i\sum Res$. Now the zeros of the denominator are $\pm i$ and $1\pm i$. However, only $i$ and $1+i$ belong in the semicircle. Is this part correct so far? Also, how would I calculate the residues at those two points.
Yes, you are correct so far. To calculate the residue at $i$, multiply by $x-i$, then evaluate at $i$. So calculate $$\frac1{(x+i)(x^2-2x+2)}$$ at $x=i$, and multiply by $2\pi i$. Then do the same for $1+i$.