# Complex contour integrals

So I'm working through some practice questions for my complex analysis unit and I've come across this integral:

$$\int_\Gamma {(3z^2-z)\over(z-1)^2(z+1)}dz$$

where $\Gamma$ is the following contour

Now I know that there are two basic approaches to this question. The first being using partial fractions, and the second using Cauchy's Integration Theorem by contracting the contour down to two circles around $-1$ and $1$.

My question is this. When $\Gamma$ get contracted down, the circle around $1$ is going clockwise while the circle around $-1$ is going anti-clockwise. How does the direction of the contour effect the integral?

• Reversing the direction changes the sign of the integral. – mrf Sep 19 '13 at 13:56
• Instead of just summing the residue, you weight the residue of a pole by the winding number of the contour with respect to that pole. (counterclockwise once = +1, clockwise once = -1). For your case, the contour integral = $2\pi i \left( -\text{Residue}(z = 1) + \text{Residue}(z = -1)\right)$. – achille hui Sep 19 '13 at 14:00

To illustrate @achille's point:

The residue about $z=1$ is, because it is a double pole:

$$\left [\frac{d}{dz} \frac{3 z^2-z}{z+1} \right]_{z=1}= \left [ \frac{6 z-1}{z+1} - \frac{3 z^2-z}{(z+1)^2}\right ]_{z=1} = 2$$

The residue about $z=-1$ is simply

$$\frac{3 (-1)^2-(-1)}{(-1-1)^2} = 1$$

We weight the residue about $z=-1$ by $-1$ because we wind clockwise. The value of the integral is thus $i 2 \pi (2-1) = i 2 \pi$.

Write $f(z) = {3z^2-z\over(z-1)^2(z+1)}$. By the Cauchy Residue Theorem, $$\int_\Gamma {f(z)}dz = 2 \pi i \left( w(\Gamma,-1) \text{Res}(\Gamma,-1) + w(\Gamma,1) \text{Res}(f,1) \right),$$ where $w(\Gamma,a)$ is the winding number of $\Gamma$ around $a$ and $\text{Res}(f,a)$ the residue of $f$ at $a$. Because $\Gamma$ loops clockwise around 1 (once), $w(\Gamma,1) = -1$ and because it loops counterclockwise around -1 (once), $w(\Gamma,-1) = 1$).