Evaluate the given integral by using Cauchy's residue theorem Evaluate the given  integral by using Cauchy residue theorem
$$\int_{|z|=1} \frac{(1-\cos z)}{(e^z-1)\sin z}$$
My attempts  : I take $f(z) = \frac{(1-\cos z)}{\sin z}$ as  Residue $z=0$ now 
 I got $f(0)=0$
$$\int_{|z|=1} \frac{(1-\cos z)}{(e^z-1)\sin z}= 2\pi if(z) _{\operatorname{res}z=0}=0$$
is its true  ?
any hints/solution
 A: No, that is not correct. The answer is indeed $0$, but in order to prove that the best way is to see that$$\frac{1-\cos(z)}{(e^z-1)\sin(z)}=\frac{\frac{z^2}{2}-\frac{z^4}{24}+\cdots}{z^2+\frac{z^3}{2}-\frac{z^5}{24}+\cdots}=\frac{\frac12-\frac{z^2}{24}+\cdots}{1+\frac z2-\frac{z^3}{24}+\cdots}$$and that therefore $0$ is a removable singularity.
A: The integrand $\frac{1-\cos(z)}{(e^z-1)\sin(z)}=\frac{\tan(z/2)}{e^z-1}$
has a removable discontinuity at $z=0$.  Hence, there is no singularity in or on $|z|\le 1$.
Cauchy's Integral Theorem guarantees that 
$$\oint_{|z|=1}\frac{1-\cos(z)}{(e^z-1)\sin(z)}\,dz=0$$
A: Note that the singularity at $z= 0$ is removable, since


*

*$\lim_{z\to 0}\frac{1-\cos z}{z^2} = \frac{1}{2}$ and

*$\lim_{z\to 0}\frac{e^z-1}{z} = 1$ and

*$\lim_{z\to 0}\frac{\sin z}{z} = 1$
Now write
$$\frac{1-\cos z}{(e^z-1)\sin z}=\frac{1-\cos z}{z^2}\frac{z^2}{(e^z-1)\sin z} $$
So, the residue is equal to $0$ as the only singularity within the region bounded by $|z|=1$ is removable.
