Computation of an integral using residue theorem.

complex-analysisimproper-integralsintegrationresidue-calculus

Using residue theorem compute the following integral $$\int_{-\infty}^{\infty} \frac {e^{\frac {x} {2}}} {1 + e^x}\ dx.$$

I have tried to proceed by the method of substitution by taking $y = e^{\frac {x} {2}}.$ Then $dy = \frac {1} {2} e^{\frac {x} {2}}\ dx$ i.e. $e^{\frac {x} {2}}\ dx = 2\ dy.$ Then the limit of integration becomes $0$ to $\infty.$ So by this substitution the integral becomes $$2 \int_{0}^{\infty} \frac {dy} {1 + y^2} = 2 \lim\limits_{x \to \infty} \arctan x = \pi.$$

By residue theorem how to deal with the same integral? Any help in this regard would be much appreciated.

Thanks for your time.

Best Answer

Starting from your result, we have that $$2\int_{[0,\infty)}\frac{1}{1+y^2}dy=\int_{\mathbb{R}}\frac{1}{1+z^2}dz$$ Consider the half-disk of radius $R$, which we call $C_R$; by the residue theorem $$\int_{C_R}\frac{1}{1+z^2}dz=2\pi i\, \textrm{Res}\bigg(\frac{1}{1+z^2},i\bigg)$$ $$\textrm{Res}\bigg(\frac{1}{1+z^2},i\bigg)=\lim_{z \to i}(z-i)\frac{1}{(z-i)(z+i)}=-\frac{1}{2}i$$ $$\int_{C_R}\frac{1}{1+z^2}dz=\pi$$ We may want to estimate the integral on the semicircle $\Gamma_R$. $$\bigg|\int_{\Gamma_R}\frac{1}{1+z^2}dz\bigg|\leq \pi R \max_{z \in \Gamma_R}\bigg|\frac{1}{1+z^2}\bigg|$$ $$\bigg|\int_{\Gamma_R}\frac{1}{1+z^2}dz\bigg|\leq \pi R \frac{1}{R^2-1}\stackrel{R \to \infty}{\rightarrow} 0$$ Since $$\int_{[-R,R]}\frac{1}{1+y^2}dy=\int_{C_R}\frac{1}{1+z^2}dz-\int_{\Gamma_R}\frac{1}{1+z^2}dz$$ in the limit we obtain the desired result.

Related Question