2

I am trying to solve integral $\int_{-∞}^\infty \frac{cos(x)dx}{(x^2+a^2)(x^2+b^2)}$ using residue theorem. I found example of that with very similair integral, which is $\int_{0}^\infty \frac{cos(x)dx}{x^2+b^2}$. Everything would be clear, except one thing. When we substitute x $\to$ z and make our complex function, in the example cos(x) is replaced by $e^{ix}$. Why only $e^{ix}$, and not $\frac{e^{ix} + e^{-ix}}{2}$, since cos(x) = $\frac{e^{ix} + e^{-ix}}{2}$? Does this mean, that I should use this substitution on my integral, too?

  • 1
    Remember that $e^{ix}=\cos x+i\sin x$. Making that substitution (which is simpler than yours) only implies that you may take the REAL PART of the final result to gget your integral. It is a very standard argument. – Tito Eliatron Nov 09 '20 at 18:01
  • See the answer by Mark Viola, and pay attention to what would happen if you leave $\cos z$ in place. (Specifically, look at the integral along the semicircle.) – metamorphy Nov 09 '20 at 18:12

1 Answers1

4

Note that $\cos(x)=\text{Re}(e^{ix})$. Hence, we can write

$$\int_{-\infty}^\infty \frac{\cos(x)}{(x^2+a^2)(x^2+b^2)}\,dx=\operatorname{Re}\left(\int_{-\infty}^\infty \frac{e^{ix}}{(x^2+a^2)(x^2+b^2)}\,dx\right)\tag1$$

which facilitates the analysis. To see this, we evaluate the contour integral $I(a,b)$, $ab\ne0$, given by

$$I(a,b)=\oint_C \frac{e^{iz}}{(z^2+a^2)(z^2+b^2)}\,dx\tag2$$

where $C$ is the closed contour comprised of $(i)$ the real line segment from $-R$ to $R$ and $(ii)$ the semi-circular arc centered at $z=0$ with radius $R$ from $R$ to $-R$.

We evaluate $(2)$ by application of the residue theorem. Then, we let $R\to \infty$ and take the real part to find the value of $(1)$

$$\begin{align}\int_{-\infty}^\infty \frac{\cos(x)}{(x^2+a^2)(x^2+b^2)}\,dx&=\operatorname{Re}\left(2\pi i \operatorname{Res}\left(\frac{e^{iz}}{(z^2+a^2)(z^2+b^2)}, z=i|a|\right)\\+2\pi i \operatorname{Res}\left(\frac{e^{iz}}{(z^2+a^2)(z^2+b^2)}, z=i|b|\right)\right) \end{align}$$

And the rest is left to the interested reader.

Mark Viola
  • 179,405
  • If I may suggest one small change: replacing \text{foo} with \operatorname{foo} will make spacing within e.g. $2\pi i\text{Res}f(z)$ a little cleaner as $2\pi i\operatorname{Res}f(z)$ – user170231 Nov 09 '20 at 18:15
  • @user170231 Certainly. I've edited accordingly. Thank you for the tip! Much appreciated. – Mark Viola Nov 09 '20 at 18:26
  • Thank you, after some hours I managed to calculate these residues, which was first order poles. Just one more question from curiosity: would I get the same answer, if I had used that clumsy substitution cos(x) = $\frac{e^{ix} + e^{-ix}}{2}$? – Vytautas Sirautas Nov 09 '20 at 20:10
  • You're welcome. My pleasure. If you begin with Euler's identity, you'll need to solve two problems, the first by closing in the upper half plane and the second by closing in the lower half plane. – Mark Viola Nov 10 '20 at 00:01