# Definite integral using complex analysis

jncarter

## Homework Statement

Considering the appropriate complex integral along a semi-circular contour on the upper half plan of z, show that
$\int^{\infty}_{\infty} \frac{cos(ax)}{x^2 + b^2} dx = \frac{\pi}{b}e^{-ab} (a>0, b>0)$​

## Homework Equations

$\int_{C} = 0$ For C is a semi-circle of infinite radius in the upper half of the complex plane.
$\oint f(z)dz = 0$ for analytic functions
$\oint f(z)dz = 2\pi i \sum Res[f(z_{0})]$ Where z0 is a singularity and you sum over all the residues within the contour.
$z^2 + b^2 = (z+ib)(z-ib)$

## The Attempt at a Solution

I've been trying to solve this by using $\int \frac{e^{iaz}}{z^2 + b^2}dz$. Which must be solved using Cauchy's Formula (the residue thing above), since f(z) is not analytic over all space. There is a singularity of order one at $\pm ib$.
Is there a better contour integral I could use? Right now the algebra is getting messy.

I tried using the contour integral $\int^{\infty}_{\infty} \frac{e^{-iaz}}{z^2+b^2}dz$ and found that it was equal to $\frac{\pi}{b}e^{-ab}$. Now I think I have to consider that a sum of different integrals. We have the top hemisphere, the x-axis and the circular contour about z0 and the lines leading to +ib. I'm finding that must of those are zero and I think I can pull out the cosine function from the integral along the x-axis...