I am trying to show that
$\int_{\gamma} \frac{z^{p-1}}{z^2+1} d{z} = 2\pi i\cos\left(\frac{\pi p}{2}\right)e^{i\pi(p-1)}\,\,,\,\gamma:=\{z\;\;;\;\;|z|=R\}$
for $0 < p < 2$. This integral computes the path of the contour excluding the branch line along the positive real axis. So I'm really computing $\int_{\gamma}$ part in:
$\int_{\gamma} = \int_{C_1} + \int_{C_2} + \int_{C_3} + \int_{C_4}$
where $C_1, C_2, C_3$ and $C_4$ are all pieces of the contour.
I've computed the residues at $z=i$ and $z=-i$ but for some reason my calculations don't check out. I got $\displaystyle\frac{e^{i\frac{\pi}{2}(p-1)}}{2i} - \frac{e^{-i\frac{\pi}{2}(p-1)}}{2i}.$