Cauchy integral formula for $\int_\gamma \frac{\sin z }{z^4-16}dz$ I have working through past exam questions and I think I have the hang of the Cauchy integral formula and the extended formula... but am a little stuck with how to work these examples out... and the denominators aren't of the form $(z-z_0)^n$
Any help in how to solve these types of questions would be greatly appreciated...
$(i) \displaystyle\int_\gamma \dfrac{\sin z}{z^4-16}$ (with $\gamma$ in the unit circle in $\mathbb{C}$ traversed in the anti-clockwise direction)
$(ii)\displaystyle\int_\gamma \dfrac{\cos z}{z(z^2-8)}$ (with $\gamma$ being the circular contour given by $\gamma(t)=e^{it}$ for $1 \leq t \leq 2\pi$
 A: $(i)~z^4-16=0\iff z=\pm2,\pm2i.$ 
All of $\pm2,\pm2i$ lie outside $\gamma.$ So $\dfrac{\sin z}{z^4-16}$ is analytic everywhere on and inside $\gamma.$ 
Consequently, by Cauchy-Goursat theorem $\displaystyle\int_\gamma \dfrac{\sin z}{z^4-16}=0.$ (Similar Question)
$(ii) \dfrac{\cos z}{z(z^2-8)}$ is analytic everywhere on and inside $\gamma$ except at $0.$ Note $\dfrac{\cos z}{z(z^2-8)}$
$=-\dfrac{1}{8z}\left(1+\dfrac{z^2}{2!}+\dfrac{z^4}{4!}+...\right)\left(1-\dfrac{z^2}{8}\right)^{-1}$$=-\dfrac{1}{8z}\left(1+\dfrac{z^2}{2!}+\dfrac{z^4}{4!}+...\right)\left(1+\dfrac{z^2}{8}+...\right)$$=...$ is the Laurent series expansion of $\dfrac{\cos z}{z(z^2-8)}$ around $0.$ 
So $\text{Res}_{z=0}\dfrac{\cos z}{z(z^2-8)}=-\dfrac{1}{8}.$
Consequently, due to the Residue theorem, $\displaystyle\int_\gamma \dfrac{\cos z}{z(z^2-8)}=2\pi i\times\left(-\dfrac{1}{8}\right)=-\dfrac{\pi i}{4}.$
A: (i): what are the roots of the denominator?  Where do they lie with respect to the interior of $\gamma$?
Note that the roots of $z^4-16$ all have magnitude of $2$.
(ii): same questions.  Note however that $z=0$ is a root and therefore inside $\gamma$.  IN that case, the residue of that pole is
$$i 2 \pi \frac{1}{-8} = -i \frac{\pi}{4}$$
The other roots have magnitude $2 \sqrt{2}$; what does that mean?
