A closed-contour integral of a function with finitely many isolated singularities reduces to a finite sum of residues. That’s the whole content of the residue theorem, and it’s the main computational tool in complex analysis.

Statement

Let be analytic on a simply connected domain except at finitely many isolated singularities . Let be a positively oriented simple closed contour in that passes through none of the singularities. Let be the singularities lying inside . Then

Singularities outside contribute nothing.

Sketch of proof

Connect to small circles around each interior singularity via thin “keyhole” corridors traversed in both directions. The composite contour ( counterclockwise, each clockwise, plus the keyhole bridges) bounds a region on which is analytic, so its integral is zero by Cauchy’s theorem. The keyhole bridges cancel in pairs.

What remains: with each now counterclockwise around .

On each , expand in its Laurent series around and integrate term by term. By the fundamental integral if and otherwise, only the term contributes. Sum gives . ∎

What the theorem unifies

Every earlier closed-contour result is a special case:

  • Cauchy’s theorem: no singularities inside sum is empty integral .
  • Cauchy integral formula: with analytic, inside . Simple pole, . Integral .
  • Generalized CIF: . Pole of order , residue computed via the formula gives . Integral .

All of them collapse to “compute residues, sum, multiply by .”

The closed-contour decision tree

For with positively oriented:

  1. Find all singularities of inside . If none, integral is .
  2. Classify each one: removable, pole of order , or essential.
  3. Compute residues by the matching formula:
    • Removable: .
    • Simple pole (): , or if applicable.
    • Pole of order : .
    • Essential: read from Laurent expansion.
  4. Sum residues and multiply by .

Every closed-contour integral collapses to this procedure.

Worked example 1

.

Singularities: , both inside .

Residue at (simple pole, ): , , . .

Residue at : .

Sum: . Result: .

Worked example 2

.

Both singularities inside.

Residue at (pole of order 2): .

Residue at (simple pole): .

Sum: . Result: .

Real trig integrals via the unit circle

For with rational in , substitute :

As runs to , traverses counterclockwise, so the real integral becomes a closed contour integral on .

Example: .

Substitute: . .

Denominator: .

Integral becomes .

Roots of : . Only lies inside (the other is ).

Residue at (simple pole, ): .

Multiply: . Result: .

Real improper integrals: rational functions

For with rational, , no real poles:

  • Close the contour with a large upper semicircle of radius .
  • As , the semicircle contribution vanishes by ML estimate (since decays as or faster on ).
  • The real-axis integral plus the semicircle integral equals (upper half-plane).

Example: .

Poles at . Upper half-plane: . Residue ( with ): .

Real integral . ✓ (Direct check: .)

Real improper integrals with cos x or sin x

For with rational and decaying: replace with (take real part at end), close contour in the upper half-plane (so decays for ). The semicircle contribution vanishes by Jordan’s lemma.

Example: .

Consider . Pole in UHP: . Residue: .

Contour integral: .

Real part: . So . (Imaginary part vanishes by parity: is odd.)

Where it applies

  • Closed-contour integrals of meromorphic functions.
  • Real trig integrals via unit-circle contour.
  • Real improper integrals via large semicircle.
  • Real improper integrals with or multipliers via Jordan’s lemma.

Computing the residues is mechanical. The hard part is choosing the right contour and verifying the negligibility of any auxiliary pieces (semicircles, indentations).