Help Calculating a Residue, and Evaluating a Real Integral using Complex Analysis

The integral in question is $$\int_{-\infty}^{\infty} \frac{\cos(\alpha x)}{(x^2 + b^2)^2}\,dx,$$ with $\alpha , b \geq 0$.

I was thinking of evaluating the integral around a semicircle with radius $R$ (taking $R$ to $\infty$), and a line segment on the bottom (i.e., the contour with the line segment from $-R$ to $R$, and the semicircle on top). I was going to evaluate the integral of the function $$f(z) = \frac{e^{iz \alpha} }{(z^2+b^2)^2}$$ around this contour.

However, since there is a singularity at $ib$ , a point contained within the contour, I had to use the residue theorem to calculate the integral around the entire region. I thought this would be an easy task, but it actually proved to be a hold up, as using the limit technique of evaluating poles of order 2 lead me to a limit which I could not figure out how to compute.

To summarize my intent was to take the integral of $f(z)$ around the two pieces of the contour, show that the top part goes to 0, and then note that the integral around the bottom line segment is twice as much as the desired integral, since the function of the desired integral is even. Then we have that the desired integral is one-half of the residue value. However I got stuck on calculating the residue using the limit definition, and could not find a Laurent expansion of my function.

Edit: Just to clarify, the contour I am describing can be parametrized as $$\phi_1(t) = t ,-R\leq t\leq R \text{ and }\phi_2(t) = Re^{it}, 0\leq t\leq\pi.$$

-
Relevant to you?: en.wikipedia.org/wiki/… – anon Aug 9 '11 at 5:48
Yeah I actually tried using the limit formula for higher powers that you linked, but I don't think that was the intended direction of the problem, because it was not introduced in the textbook. – I Love Cake Aug 9 '11 at 6:00

Like you said, you have a pole at $ib$. Note that $ib$ is the only pole located in the upper half plane. The other pole $-ib$ is not in the upper half plane. However $ib$ is a pole of order $2$
$$\mathrm{Res}(f,ib)=\lim_{z\to ib}\frac{d}{dz}\left[(z-ib)^2 \frac{e^{iz\alpha}}{(z^2+b^2)^2}\right]=\lim_{z\to ib} \frac{d}{dz} \frac{e^{iz\alpha}}{(z+ib)^2}= \frac{ie^{-b\alpha}(-b\alpha-1)}{4b^3}$$