$$\int \frac{5 \cos(\pi z)}{(z+3i)(z-7i)}dz$$
i) where γ is the circle centre 0 and radius 4;
ii)γ is the circle centre 0 and radius 10
For part i) I have calculated using CIF that because z=-3i is only valid in γ that f(z)=(5cos(πz))/(z-7i) and so
$$\int \frac{5 \cos(\pi z)}{(z+3i)}dz =-\pi \cos(-3\pi i)$$
However for part ii) because both $z=-3i$ and $ z=7i$ are valid in γ I do not know what to set as my f(z).
You can either split your contour in 2, or use partial fractions.
If $\gamma_1$ is the right half side of the contour, $\gamma_2$ is the left half side, and $\gamma_3$ is vertically bisecting the contour, we see $$\oint _{\gamma} \frac{5cos(\pi z)}{(z+3i)(z-7i)} = \oint_{\gamma_1+\gamma_3}\frac{\frac{5cos(\pi z)}{z+3i}}{z-7i}+ \oint_{\gamma_2-\gamma_3} \frac{\frac{5cos(\pi z)}{z-7i}}{z+3i} $$ Evaluating both component integrals thru Cauchy Integral Formula gives $$2\pi i (\frac{5cos(\pi 7i)}{7i+3i})+ 2\pi i(\frac{5cos(-\pi 3i)}{-3i-7i})= \pi cos (\pi 7i) - \pi cos (-\pi 3i)$$ and simplify. This is essentially the residue theorem using CIF.
You could also just decompose into partial fractions and solve using the same contour, but that’s more complicated.