I am reading a solution of a complex integral using residue, in one step it syas
$$\text{Res}(\frac{e^{iz}}{\sinh(z)},0) = \frac{e^{iz}}{\cosh(z)}\bigg|_{z=0}$$
I cannot understand how to get the RHS from the formula for polynomial case.
Can anyone please let me know how to get the RHS? Thanks!
Suppose $z_0$ is a simple pole of $f(z)=\frac{P(z)}{Q(z)}$. We have
$$\text{Res}(z_0, f) = \frac{P(z)}{Q'(z)} \bigg|_{z = z_0}.$$
This is easily proven using that
$$\text{Res}(z_0, f) = \lim_{z \rightarrow z_0} (z-z_0) \frac{P(z)}{Q(z)} = \lim_{z \rightarrow z_0} \frac{P(z)}{\tfrac{Q(z)-Q(z_0)}{z-z_0}} = \frac{P(z_0)}{Q'(z_0)}.$$
Observe that this onluy works when $z_0$ is a simple pole, otherwise the expression above would also have a singularity.