Choose the contour for real integrals of the form $\int_{-\infty}^{\infty} f(x) dx$

complex integrationcomplex-analysiscontour-integrationintegration

I am currently reading chapter 19 of Advanced Engineering Mathematics 6th ed by Dennis G. Zill. This chapter is on complex analysis and deals with evaluating real integrals by using contour integration. For the integral mentioned in the question, the text says I should replace $x$ with the comlex variable $z$, determine the poles of $f(z)$ and their locations on the complex plane, and let the contour, oriented counterclockwise, be the interval $[-R,R]$ on the real axis and a semicircle of radius $R$ in the upper half plane. Of course, $R$ should be large enough so that the contour encompasses all of the poles in the upper half plane.

Why can't the semicircular part of the contour be in the lower half plane? What is so special about the upper half plane?

enter image description here

Best Answer

One reason that people might think of working in the upper half-plane as a default is that usually we apply the Residue Theorem to simple, anticlockwise closed contours, so that the index of the contour about each enclosed singularity is $+1$: If part of a contour in the upper half-plane lies on or near the real axis---as is often the case when evaluating some integral of a real function---then that contour travels in the positive direction. If you integrate in the lower half-plane (and use an anticlockwise contour), you must introduce a $-$ sign to account for the fact that the contour travels in the negative direction.

Mathematically the upper half-plane is no better or worse than the lower half-plane. Sometimes both choices work, sometimes only one does; in general the choice of contour is governed by (1) any symmetries of the integrand, and (2) the behavior (more to the point, decay) of the function near infinity.

Example To evaluate the improper integral $$\int_{-\infty}^\infty \frac{\cos (a x) \,dx}{1 + x^2},$$ we can realize it as the real part of $$\int_{-\infty}^\infty \frac{e^{i a x} \,dx}{1 + x^2} .$$ If we write $z = x + i y$, then $|e^{i a z}| = e^{-ay}$. At any point $$\left\vert\frac{e^{i a x}}{1 + x^2}\right\vert ,$$ is bounded above by $\frac{e^{-a y}}{R^2 - 1}.$ In particular, if the exponent $-ay$ is negative, then the integrand is bounded in modulus by, say, $\frac{2}{R^2}$ for sufficiently large $R$. So, if $a > 0$, we can integrate along the boundary $\Gamma_R$ of the half-disk of radius $R$ centered at the origin in the upper half-plane: The integral along the semicircle is thus bounded by $\frac{2}{R^2} \cdot \pi R = \frac{2 \pi}{R}$, which tends to zero as $R \to \infty$, so $$\int_{-\infty}^\infty \frac{e^{i a x} \,dx}{1 + x^2} = \lim_{R \to \infty} \int_{\Gamma_R} \frac{e^{i a z} \,dz}{1 + z^2},$$ and we can apply the Residue Theorem to the contour integral on the right. On the other hand, if $a < 0$, then $e^{-ay} \to +\infty$ as $y \to \infty$, so we cannot proceed as before, but we can integrate along a contour in the lower half-plane, where $e^{-ay}$ is bounded.

Not all applications of the Residue Theorem use semicircles. For various integrals it's easier to use sectors (e.g., $\int_{-\infty}^\infty \frac{dz}{1+z^n}$), annular sectors (e.g., $\int_0^\infty \frac{\log p x \,dx}{q^2 + x^2}$), rectangles (e.g., showing that the Gaussian p.d.f. is its own Fourier transform), "Pac-man--shaped contours", "dogbones", parallelograms, or more complicated contours.