Using residue theory, show that $$\oint_C\frac{e^{z/2}}{1+e^z}dz = 2\pi$$
I've been attempted this problem using residue theory and the Cauchy integral formula that over a closed contour containing a pole (root at $\pi i$),
We should be able to confirm $2\pi$ using the equation $f(i\pi)\cdot 2\pi i$, but when I do this I am getting $-2\pi$, can anyone assist me?
Assuming that $i\pi$ is the only pole inside your contour, and that the contour is counter clockwise oriented, $$ \operatorname{Res}\limits_{z=i\pi} \frac{e^{z/2}}{1+e^z} = \left. \frac{e^{z/2}}{e^z} \right|_{z=i\pi} = \frac{e^{i\pi/2}}{e^{i\pi}} = -i, $$ so $$ \int_C \frac{e^{z/2}}{1+e^z}\,dz = 2\pi i \cdot (-i) = 2\pi. $$