# What did I do wrong in calculating $\int_{-\infty}^{\infty}\frac{\sin{x}}{x}\mathrm{d}x$ via $\oint_{\gamma}\frac{\sin{z}}{z}\mathrm{d}z$?

I tried to calculate the $\int_{-\infty}^{\infty}\frac{\sin{x}}{x}\mathrm{d}x$ by the complex integral $\oint_{\gamma}\frac{\sin{z}}{z}\mathrm{d}z$, where $\gamma$ is the half-circle with $y > 0$.

\begin{align*} \int_{-\infty}^{\infty}\frac{\sin{x}}{x}\mathrm{d}x &= \Im\left \{\oint_{\gamma}\frac{\mathrm{e}^{iz}}{z}\mathrm{d}z \right \}=\Im\left \{ 2\pi i Res\left [ \frac{\mathrm{e}^{iz}}{z}, 0 \right ] \right \}=\Im\left \{ 2\pi i \lim_{z\to0} \left ( z \frac{\mathrm{e}^{iz}}{z} \right ) \right \} \\ &= \Im\left \{ 2\pi i \lim_{z\to0} \mathrm{e}^{iz} \right \}=\Im\left \{ 2\pi i {e}^{i0} \right \}=\Im\left \{ 2\pi i \cdot 1 \right \}=2\pi \end{align*} Now, I know the integral $\int_{-\infty}^{\infty}\frac{\sin{x}}{x}\mathrm{d}x = \pi$ by many other theorems. So, what did I do wrong?

If you know, can you please write the correct answer? Thanks!

• Drop that annoying $\;\Im\;$ , do the integral and just write down $\;\Im\;$ at the end. – DonAntonio Apr 9 '18 at 11:43
• Your question has no meaning at all if you don't specify clearly what the integration path $\;\gamma\;$ is... – DonAntonio Apr 9 '18 at 11:44
• @DonAntonio it's doesn't metter, It will still be a $2\pi$, and the $\gamma$ is a standart letter for the half circle of the xy plane where y > 0. – Ziv Sdeor Apr 9 '18 at 11:46
• No, of course not. It won't still be $\;2\pi\;$ at all. Read my answer. And again: everything depends on what path you choose! Without specifying that a complex integral has no meaning at all. – DonAntonio Apr 9 '18 at 11:55
• "the $\gamma$ is a standart letter for the half circle of the xy plane where y > 0." You may be overgeneralizing from a not-very-large set of examples. The letter $\gamma$ is widely used to name any curve in the plane. So while it's used for the half-circle you mention, it's also used for everything else. – John Hughes Apr 9 '18 at 12:17

Define for real $\;r>0\;$ :

$$\gamma_r^{\pm}:=\left\{\,z\in\Bbb C\;|\;\;|z|=r\;,\;\;\text{Im}>0\,\right\}$$

where the sign is $\;+\;$ if we take that half circle in the positive direction, and $\;-\;$ otherwise.

Now take the closed, simple path

$$\gamma:=[-R,-\epsilon]\cup\gamma_\epsilon^-\cup[\epsilon, R]\cup\gamma_R^+\;\;,\;\;\;0<R\in\Bbb R$$

Use now the corollary of this lemma to get for $\;f(z)=\cfrac{e^{iz}}z\;$ ,

$$\int_{\gamma_\epsilon^-}f(z)\,dz\xrightarrow[\epsilon\to0]{}-i\pi\cdot1=-\pi i$$

and then

$$0=\lim_{R\to\infty,\,\epsilon\to0}\int_\gamma f(z)\,dz=\int_{-\infty}^\infty f(x)\,dx-\pi i+0$$

and now just equate imaginary parts and we're done. Observe the integral over $\;\gamma_R\;$ vanishes at the limit because of Jordan's Lemma...or directly also by Cauchy's Estimate.

• Please accept my edit. You are equating $0$ and $-\pi i$ in your last equation. – Szeto Apr 9 '18 at 13:22
• @Szeto You are completely right, thanks. That equality sign was an ugly typo, yet someone else already rejected your edit. Anyway, I already edited that. Thanks again. – DonAntonio Apr 9 '18 at 13:34