Prove $\frac{1}{2 \pi i}\int_{\gamma} \frac{gf'}{f} = \sum_{m=1}^{j} g(z_m) - \sum_{n=1}^{k} g(p_n)$. A First Course in Complex Analysis by Matthias Beck, Gerald Marchesi, Dennis Pixton, and Lucas Sabalka



Pf:
By Thm 8.14 and Cor 9.6, $\exists$ holomorphic $h: G \to \mathbb C$ s.t. $h(z) \ne 0$ for $z=p_1,...,p_k,z_1,...,z_k$ and $$f = \frac{h \prod_{m=1}^{j} (z-z_m)^{\text{order}(z_m)}}{\prod_{n=1}^{k} (z-p_n)^{\text{mult}(p_n)}}$$
$$\implies f'/f = \frac{h'}{h} + \sum_{m=1}^{j} \frac{\text{order}(z_m)}{z-z_m} - \sum_{n=1}^{k} \frac{\text{mult}(p_n)}{z-p_n}$$
$$\implies gf'/f = g[\frac{h'}{h} + \sum_{m=1}^{j} \frac{\text{order}(z_m)}{z-z_m} - \sum_{n=1}^{k} \frac{\text{mult}(p_n)}{z-p_n}]$$
$$\implies \int_{\gamma} gf'/f dz = \int_{\gamma} g[\frac{h'}{h} + \sum_{m=1}^{j} \frac{\text{order}(z_m)}{z-z_m} - \sum_{n=1}^{k} \frac{\text{mult}(p_n)}{z-p_n}] dz$$
$$ = \int_{\gamma} g[\frac{h'}{h}] dz + \int_{\gamma} g\sum_{m=1}^{j} \frac{\text{order}(z_m)}{z-z_m} dz - \int_{\gamma} g\sum_{n=1}^{k} \frac{\text{mult}(p_n)}{z-p_n} dz$$
$$ = \int_{\gamma} g[\frac{h'}{h}] dz + \int_{\gamma} \sum_{m=1}^{j} \frac{g \ \text{order}(z_m)}{z-z_m} dz - \int_{\gamma} \sum_{n=1}^{k} \frac{g \ \text{mult}(p_n)}{z-p_n} dz$$
$$ = \int_{\gamma} g[\frac{h'}{h}] dz + \sum_{m=1}^{j} \int_{\gamma} \frac{g \ \text{order}(z_m)}{z-z_m} dz - \sum_{n=1}^{k} \int_{\gamma} \frac{g \ \text{mult}(p_n)}{z-p_n} dz$$
$$ = \int_{\gamma} g[\frac{h'}{h}] dz + \sum_{m=1}^{j} \text{order}(z_m) \int_{\gamma} \frac{g}{z-z_m} dz - \sum_{n=1}^{k} \text{mult}(p_n) \int_{\gamma} \frac{g}{z-p_n} dz$$
Now, $g[\frac{h'}{h}]$ is holomorphic in G because it is the product of functions holomorphic in $G$: $g$ and $\frac{h'}{h}$, the former by assumption and the latter for the same reason the '$\frac{g'}{g}$' in Argument Principle 9.17 is holomorphic. Thus,
$$ = 0 + \sum_{m=1}^{j} \text{order}(z_m) \int_{\gamma} \frac{g}{z-z_m} dz - \sum_{n=1}^{k} \text{mult}(p_n) \int_{\gamma} \frac{g}{z-p_n} dz$$
Now we apply Residue Thm 9.10, Prop 9.11 or Cauchy's Integral Formula 4.27 to get
$$ = 0 + \sum_{m=1}^{j} \text{order}(z_m) [2 \pi i g(z_m)] - \sum_{n=1}^{k} \text{mult}(p_n) [2 \pi i g(p_n)]$$
QED


*

*If all the zeroes and multiplicities are somehow 1, then why are they 1 here, and why were they not 1 in Argument Principle 9.17? Also, where have I gone wrong?

*Otherwise, why is it that $$\frac{1}{2 \pi i}\int_{\gamma} \frac{gf'}{f} = \sum_{m=1}^{j} g(z_m) - \sum_{n=1}^{k} g(p_n)$$ instead of 
$$\frac{1}{2 \pi i}\int_{\gamma} \frac{gf'}{f} = \sum_{m=1}^{j} \text{order}(z_m) g(z_m) - \sum_{n=1}^{k} \text{mult}(p_n) g(p_n)$$
?
 A: The "counted according to multiplicity" in the statement means that a zero of higher order appears several times among the $z_i$, as many times as the order says.
If $\zeta_1,\dotsc, \zeta_r$ are the distinct zeros of $f$ inside $\gamma$, and $\nu_{\rho}$ is the order of the zero $\zeta_{\rho}$, then $\zeta_{\rho}$ occurs $\nu_{\rho}$ times among the $z_i$. If ordered appropriately, we would have
\begin{align}
z_1 = z_2 = \dotsc = z_{\nu_1} &= \zeta_1\,, \\
z_{\nu_1 + 1} = \dotsc = z_{\nu_1 + \nu_2} &= \zeta_2\,, \\
\hfill \vdots \hspace{3em} &\quad\vdots \\
z_{\nu_1 + \dotsc + \nu_{\rho-1} + 1} = \dotsc = z_j &=\zeta_{\rho}\,,
\end{align}
and similarly for the poles. So in the sums, we have
$$g(z_1) + \dotsc + g(z_{\nu_1}) = \nu_1\cdot g(\zeta_1) = \operatorname{order}(\zeta_1)g(\zeta_1)$$
and so on.
The order/multiplicity appears as an explicit factor if one lists the distinct zeros and poles, it appears implicitly by repeating a summand the appropriate number of times when one lists the zeros and poles according to multiplicity.
