I was wondering what happens when evaluating an improper integral involving a trigonometric function where the denominator is a rational function with a zero at $x=0$.

The example I have in mind is $$\int_{-\infty}^{\infty}\frac{sin(ax)}{x(x-i)(x+i)} dx$$

If I rewrite the sine in terms of the exponential and then evaluate two integrals, one for the upper half-plane and one for the lower I have a problem because of the singularity at $z=0$ which seems to be in both halves of the plane. Do I treat it in both integrals then? Any suggestions/comments are welcome.


One way of avoiding to deal with the (redundant) singularity after spliting the integrals is to first differentiate w.r.t. $a$ and use Eulers identity

$$ I'(a)=\Re \int_{\mathbb{R}} \frac{e^{i a x}}{(x-i)(x+i)} $$

Assuming that $a>0$ we have to close our contour of integration, which is a big semicircle , in the upper halfplane(for $a<0$ it is the other way round)

We get

$$ I'(a)=\Re(2\pi i \text{Res}(x=i))=\pi e^{-a} $$

integrating back w.r.t. $a$ yields $$ I(a)=-\pi e^{-a}+C $$

and the constant of integration is fixed by the requirement that $I(0)=0$

which brings us to our final result

$$ I(a)=\pi(1-e^{-a}) $$

I leave the case $a<0$ to you

  • $\begingroup$ So for $a<0, I(a)= \pi (e^{-a} - 1)$ ? Also is there a factor $ \frac{1}{2} $ missing for your expression of $I'(a)$ ? Anyway, thanks a ton! $\endgroup$ – fizicar Jan 13 '16 at 1:13
  • $\begingroup$ it is $(e^a-1)\pi$ for $a<0$. why should be there a foctor of $1/2$? $\endgroup$ – tired Jan 13 '16 at 1:16
  • $\begingroup$ The residue at $x=i$ is $\frac{e^{-a}}{2i}$ and theres a factor $\frac{1}{2i}$ from Eulers identity for the sine and one of these $\frac{1}{2i}$ cancels with the factor $2\pi i$ in the expression for $I'(a)$, right? So $I'(a)=2\pi i^2 \frac{1}{2i} \frac{e^{-a}}{2i} =\pi \frac{e^{-a}}{2} $. $\endgroup$ – fizicar Jan 13 '16 at 1:24
  • $\begingroup$ eulers identiy yields a 1/2 because of the cosine so u a nearly right ;) i should go to bed... $\endgroup$ – tired Jan 13 '16 at 1:27
  • $\begingroup$ Thanks a lot. Understandably, you are tired. $\endgroup$ – fizicar Jan 13 '16 at 1:29

Another approach is to use partial fraction expansion to write

$$\int_{-\infty}^\infty\frac{\sin(ax)}{x(x^2+1)}\,dx=\int_{-\infty}^\infty\frac{\sin(ax)}{x}\,dx-\int_{-\infty}^\infty\frac{x\sin(ax)}{x^2+1}\,dx \tag 1$$

Now, the first integral on the right-hand side of $(1)$ can be evaluated by using Cauchy's Integral Theorem and writing

$$\begin{align} \int_{-\infty}^\infty\frac{\sin(ax)}{x}\,dx&=\lim_{\epsilon \to 0^+}\left(\text{Im}\left(\int_{-\infty}^{-\epsilon}\frac{e^{iax}}{x}\,dx+\int_\epsilon^\infty \frac{e^{iax}}{x}\,dx\right)\right)\\\\ &=\lim_{\epsilon \to 0^+}\left(-\text{sgn}(a)\text{Im}\left(\int_\pi^0 \frac{e^{ia\epsilon e^{i\theta}}}{\epsilon e^{^{i\theta}}}\,i\epsilon e^{i\theta}\,d\theta\right)\right)\\\\ &=\pi\, \text{sgn}(a) \end{align}$$

where we have tacitly used Jordan's Lemma to find that the contribution from integration over the infinite semi-circular contour integral that encloses the contour in a half plane is zero.

More simply, using the Residue Theorem, the second integral on the right-hand side of $(1)$ becomes

$$\int_{-\infty}^\infty \frac{x\sin(ax)}{x^2+1}\,dx=2\pi i \,\text{sgn}(a)\,\text{Im}\left(\text{Res}\left(\frac{ze^{iaz}}{z^2+1},z= i \text{sgn}(a)\right)\right)=\text{sgn}(a)\pi e^{-|a|}$$

where again, one can use Jordan's Lemma to show that the contribution from integration over the infinite semi-circle is zero.

Putting everything together yields

$$\bbox[5px,border:2px solid #C0A000]{\int_{-\infty}^\infty\frac{\sin(ax)}{x(x^2+1)}\,dx=\pi\, \text{sgn}(a)\left(1-e^{-|a|}\right)}$$


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.