# Evaluate $\int_{-\infty}^\infty \frac{\sin{(x\sin{x})}}{x^2}dx$.

Evaluate $$\int_{-\infty}^\infty \frac{\sin{(x\sin{x})}}{x^2}dx.$$

Numerical investigation suggests that it equals $$\pi$$.

Let $$f(\alpha)=\frac{1}{\pi}\int_{-\alpha}^\alpha \frac{\sin{(x\sin{x})}}{x^2}dx$$.

Wolfram (free version) gives me the following results:

$$f(10)=0.992293$$
$$f(20)=0.996916$$
$$f(30)=0.998604$$
$$f(100)=0.999761$$
$$f(200)=0.999916$$
$$f(300)=0.999934$$

But with even larger values of $$\alpha$$, Wolfram behaves erratically:

$$f(1\times10^5)=2.12907$$
$$f(2\times10^5)=0.574468$$
$$f(3\times10^5)=0.351411$$

And finally, Wolfram gives:

$$f(\infty)=0.998775$$

But in the comments, @NN2 said that the paid version of Wolfram gives some detailed warnings about the accuracy of this last result.

Perhaps someone with more reliable computing power could shed some light on $$f(\infty)$$.

My attempt

I tried to use some of the techniques for proving $$\int_0^\infty {\sin{x}\over x}dx=\pi/2$$, to no avail. For example, this one sets up $$I(a)=\int_0^\infty e^{-ax}\frac{\sin x}{x}dx$$, then evaluates $$I'(a)$$ via integration by parts. If we just have $$\sin{x}$$ this is easy, but the fact that $$\int_0^\infty{\sin{(x\sin{x})}\over x^2}dx$$ involves a sine within a sine, seems to make everything difficult.

Context

I've been searching (in vain) for a definite integral with no numbers that equals $$\pi/7$$, and I stumbled upon this integral. I was surprised that it seems to admit a closed form, $$\pi$$.

• It is not $\pi$, if you set the upper limit to infinity, WA gives $3.13774$ Commented May 24, 2023 at 12:23
• If we assume that $\pi$ is indeed a correct answer, then most likely (parts of ) circles are involved (as contours) in complex analysis. So, perhaps you should try using the residue-theorem. Commented May 24, 2023 at 12:24
• @MathFail You mean $\int_{-100}^\infty \frac{\sin{(x\sin{x})}}{x^2}dx=3.13774...$ ? But we want $\int_{-\infty}^\infty \frac{\sin{(x\sin{x})}}{x^2}dx$.
– Dan
Commented May 24, 2023 at 12:27
• No, I mean the entire real axis. Commented May 24, 2023 at 12:28
• Paid version of Mathematica gives 3.13774 with 2 warnings:  - NIntegrate::slwcon: Numerical integration converging too slowly; suspect one of the following: singularity, value of the integration is 0, highly oscillatory integrand, or WorkingPrecision too small. - NIntegrate::ncvb: NIntegrate failed to converge to prescribed accuracy after 9 recursive bisections in x near {x} = {41.6667}. NIntegrate obtained 3.1377435633721444 and 0.0007050748220353499 for the integral and error estimates.
– NN2
Commented May 24, 2023 at 14:07

Using the known expansion for $$\sin(x\sin x)$$ in terms of Bessel functions, $$\int_{ - \infty }^{ + \infty } {\frac{{\sin (x\sin x)}}{{x^2 }}{\rm d}x} = 2\int_0^{ + \infty } {\frac{{\sin (x\sin x)}}{{x^2 }}{\rm d}x} \\ = 4\sum\limits_{k = 0}^\infty {( - 1)^k \int_0^{ + \infty } {\frac{{J_{2k + 1} (x)\sin ((2k + 1)x)}}{{x^2 }}{\rm d}x} } .$$ The term corresponding to $$k=0$$ is, by $$(10.16.1)$$ and $$(10.22.57)$$, $$\int_0^{ + \infty } {\frac{{J_1 (x)\sin (x)}}{{x^2 }}{\rm d}x} = \sqrt {\frac{\pi }{2}} \int_0^{ + \infty } {\frac{{J_1 (x)J_{1/2} (x)}}{{x^{3/2} }}{\rm d}x} = \sqrt {\frac{\pi }{2}} \frac{1}{{\sqrt 2 }}\frac{{\Gamma \!\left( {\frac{1}{2}} \right)\Gamma\! \left( {\frac{3}{2}} \right)}}{{2\Gamma (1)\Gamma\! \left( {\frac{3}{2}} \right)}} = \frac{\pi }{4}.$$ For $$k\ge 1$$, $$(10.22.56)$$ gives \begin{align*} & \int_0^{ + \infty } {\frac{{J_{2k + 1} (x)\sin ((2k + 1)x)}}{{x^2 }}{\rm d}x} = \sqrt {\frac{{\pi (2k + 1)}}{2}} \int_0^{ + \infty } {\frac{{J_{2k + 1} (x)J_{1/2} ((2k + 1)x)}}{{x^{3/2} }}{\rm d}x} \\ & = \frac{{\sqrt{\pi}\,\Gamma \!\left( {k + \frac{1}{2}} \right)}}{{4 (2k + 1)^{2k} \Gamma (1 - k)}}{\bf F}\!\left( {k + \frac{1}{2},k;2k + 2;\frac{1}{{(2k + 1)^2 }}} \right) = 0, \end{align*} since $$1/\Gamma(z)$$ is zero for $$z=0,-1,-2,\ldots$$. Here $$\bf{F}$$ denotes the regularised hypergeometric function. Hence the value of the original integral is indeed $$\pi$$.

• Do you think there's a nice way to see that all of those integrals vanish through some sort of orthogonality relation stemming from the differential equations that the Bessel functions satisfy? Commented May 25, 2023 at 5:08
• @user196574 Actually, as Random Variable pointed out, there's a general reason why the integrals are zero: an entire function which is asymptotically bounded above by an exponential in the upper and lower half planes will have a Fourier transform with compact support, since for Fourier frequency $|\omega|$ large enough, one can safely close the integral with a semicircular contour, and the resulting closed contour encloses no poles. This implies all sorts of neat things, like that Fourier transforms of products of Bessel functions will have compact support. Commented May 29, 2023 at 16:41
• In each case considered by Gary and Random Variable, the integral against $\sin$ was like evaluating the Fourier transform for a frequency large enough that one could safely close the contour. Only in the case of $k=0$ was the function $\frac{J_1(x)}{x^2}$ not entire, and so that was the only integral that could be non-vanishing. I'm really quite happy to see this, as I think this sort of idea can generate all sorts of fun integrals that are not obvious to do by complex analysis on inspection but only on an appropriate expansion involving entire functions. Commented May 29, 2023 at 16:47

With regard to Gary's answer, we can also use contour integration to show that $$\int_{0}^{\infty} \frac{J_{1}(x) \sin(x)}{x^{2}} \, \mathrm dx = \frac{1}{2} \int_{-\infty}^{\infty} \frac{J_{1}(x) \sin(x)}{x^{2}} \, \mathrm dx= \frac{\pi}{4}$$ and $$\int_{0}^{\infty} \frac{J_{2k+1}(x) \sin\left((2k+1)x\right)}{x^{2}} \, \mathrm dx = \frac{1}{2} \int_{-\infty}^{\infty}\frac{J_{2k+1}(x) \sin\left((2k+1)x\right)}{x^{2}} \, \mathrm dx = 0$$ for $$k \in \mathbb{Z}_{\ge 1}$$ by integrating the functions $$f(z,k) = \frac{J_{2k+1}(z) \exp(i(2k+1)z)}{z^{2}}, \, \quad k \in \mathbb{Z}_{\ge 0},$$ around a contour that consists of the real axis and the semicircle above it.

The functions are analytic in the upper half-plane.

But the contour needs to be indented at the origin for the function $$f(z, 0)$$ because there is a simple pole there.

Also, the integrals vanish along the semicircle as its radius goes to infinity because the growth in the magnitude of $$J_{2k+1}(z)$$ as $$\Im(z) \to +\infty$$ is neutralized by the decay in the magnitude of $$\exp(i(2k+1)z)$$ as $$\Im(z) \to +\infty$$. (See here.)

Integrating the function $$f(z,0)$$ around the contour, we get $$\operatorname{PV} \int_{-\infty}^{\infty} \frac{J_{1}(x) \exp\left(ix\right)}{x^{2}} \, \mathrm dx - i \pi \operatorname{Res}[f(z,0),0] =0.$$

Therefore, \begin{align} \operatorname{PV} \int_{-\infty}^{\infty} \frac{J_{1}(x) \exp\left(ix\right)}{x^{2}} \, \mathrm dx &= i \pi \operatorname{Res}[f(z,0),0] \\ &= i \pi \lim_{z \to 0} \frac{J_{1}(z)}{z} \, \exp\left(iz\right) \\ &= i \pi \left(\frac{1}{2} \right)(1) \\& = \frac{i \pi}{2}. \end{align}

Equating the imaginary parts on both sides of the equation, we get $$\int_{-\infty}^{\infty} \frac{J_{1}(x) \sin(x)}{x^{2}} \, \mathrm dx = \frac{\pi}{2}.$$

And integrating the functions $$f(z,k)$$, $$k \in \mathbb{Z}_{\ge 1}$$, around the contour, we have simply $$\int_{-\infty}^{\infty} \frac{J_{2k+1}(x) \exp\left(i(2k+1)x\right)}{x^{2}} \, \mathrm dx =0.$$

Equating the imaginary parts on both sides of the equation, we get $$\int_{-\infty}^{\infty}\frac{J_{2k+1}(x) \sin\left((2k+1)x\right)}{x^{2}} \, \mathrm dx =0 \, , \quad k \in \mathbb{Z}_{\ge 1}.$$

• Talking about typos, there are still two in the part starting with "Therefore,...". A missing $i$ at the end and an $x$ instead of $z$ in the exponential. Commented May 25, 2023 at 9:11
• @Diger Fixed. Thanks. Commented May 25, 2023 at 9:23

Let $$S_n=2\int_{n \pi}^{(n+1)\pi} \frac{\sin (x \sin (x))}{x^2}\,dx \qquad \text{and} \qquad T_p=\sum_{n=0}^p S_n$$ and compute for an high accuracy (the numbers below are truncated)

$$\left( \begin{array}{cc} p & T_p \\ 0 & 3.08335068793 \\ 1 & 3.08795887316 \\ 2 & 3.11823682853 \\ 3 & 3.12373609535 \\ 4 & 3.13000260857 \\ 5 & 3.13207351895 \\ 6 & 3.13445795667 \\ 7 & 3.13547222096 \\ 8 & 3.13665697958 \\ 9 & 3.13723885677 \\ 10 & 3.13792351502 \\ 20 & 3.14019199333 \\ 30 & 3.14081055776 \\ 40 & 3.14107819187 \\ 50 & 3.14122173949 \\ 60 & 3.14130906854 \\ 70 & 3.14136680535 \\ 80 & 3.14140730433 \\ 90 & 3.14143699830 \\ 100 & 3.14145953226 \\ 200 & 3.14154523773 \\ 300 & 3.14156678031 \\ 400 & 3.14157582788 \\ 500 & 3.14158060530 \\ 600 & 3.14158348369 \\ 700 & 3.14158537420 \\ \end{array} \right)$$

I did not see a single error or warning message from Mathematica

I stop at this point this @Gary provided the proof.