a. Evaluate the integral
\int e^z/((z^2+pi)^2) where the integral is the circle of radius 4 centered at the origin.
b. Evaluate the integral
\int 1/((z^2+1)(z^2-1))
where the integral is the circle of radius 2 centered at the origin.
Use the residue theorem
$\displaystyle \oint \frac{e^z}{(z^2+\pi^2)^2}dz=\oint \frac{e^z}{(z+i\pi)^2(z-i\pi)^2}dz$
So the function has two poles of order 2.
So we need to calculate the residues at
$\displaystyle \pm i\pi$
So to calculate at
$\displaystyle i\pi$
we have
$\displaystyle \text{Res}(f,i\pi) = \lim_{z \to i\pi }\frac{d}{dz}(z-i\pi)^2\left(\frac{e^z}{(z+i\pi)^2(z-i\pi)^2} \right) $
$\displaystyle \lim_{z \to i\pi} \frac{d}{dz}\frac{e^{z}}{(z+i\pi)^2}= \lim_{z \to i\pi} \frac{e^z(z+i\pi)^2-2e^{z}(z + i \pi)}{(z+ i\pi )^4}$
$\displaystyle \frac{e^{i\pi}(2i\pi)(2i\pi-2)}{(2i\pi)^4}=\frac{-1(2 i \pi -2)}{(2i \pi)^3 }=\frac{2-2\pi i}{-8 i\pi^3}=\frac{1}{4}\left(\frac{\pi +i}{\pi^3} \right)$
Now you compute the other one and remember that the answer is
$\displaystyle 2 \pi i \sum \text{Res}(f)$
at all of the poles in the contour.