7

Does $ \displaystyle \int_{0}^{\infty} \ \frac{\sin (\tan x)}{x} dx $ converge?

$ \displaystyle \int_{0}^{\infty} \frac{\sin (\tan x)}{x} \ dx = \int_{0}^{\frac{\pi}{2}} \frac{\sin (\tan x)}{x} \ dx + \sum_{n=1}^{\infty} \int_{\pi(n-\frac{1}{2})}^{\pi(n+\frac{1}{2})} \frac{\sin (\tan x)}{x} \ dx $

The first integral converges since $\displaystyle \frac{\sin (\tan x)}{x}$ has a removable singularity at $x=0$ and is bounded near $ \displaystyle \frac{\pi}{2}$.

And $ \displaystyle \int_{\pi(n-\frac{1}{2})}^{\pi(n+\frac{1}{2})} \frac{\sin (\tan x)}{x} \ dx$ converges since $\displaystyle \frac{\sin (\tan x)}{x}$ is bounded near $\pi(n-\frac{1}{2})$ and $\pi(n+\frac{1}{2})$.

But does $ \displaystyle \sum_{n=1}^{\infty} \int_{\pi(n-\frac{1}{2})}^{\pi(n+\frac{1}{2})} \frac{\sin (\tan x)}{x} \ dx$ converge?

user26647
  • 319

3 Answers3

11

Convergence

Note that $$ \begin{align} \int_x^{\pi-x}\sin(\tan(t))\,\mathrm{d}t &=\int_x^{\pi-x}\sin(\tan(\pi-t))\,\mathrm{d}t\tag{1a}\\ &=-\int_x^{\pi-x}\sin(\tan(t))\,\mathrm{d}t\tag{1b}\\[6pt] &=0\tag{1c} \end{align} $$ $\text{(1a)}$: substitute $t\mapsto\pi-t$
$\text{(1b)}$: $\sin(\tan(\pi-t))=-\sin(\tan(t))$
$\text{(1c)}$: average the left side of $\text{(1a)}$ and $\text{(1b)}$

Define $$ I(x)=\int_0^x\sin(\tan(t))\,\mathrm{d}t\tag2 $$ Consider $$ \begin{align} \int_0^{\pi/2}\sin(\tan(t))\,\mathrm{d}t &=\int_0^\infty\sin(t)\,\frac{\mathrm{d}t}{1+t^2}\tag{3a}\\ &=\sum_{n=0}^\infty(-1)^n\int_0^\pi\sin(t)\frac{\mathrm{d}t}{1+(t+n\pi)^2}\tag{3b} \end{align} $$ $\text{(3b)}$ is an alternating sum of terms with decreasing absolute value. Since the first term is positive, all the partial sums are non-negative. The minima of $I(x)$ are the partial sums with an even number of terms. Thus, for $0\le x\le\frac\pi2$, $I(x)\ge0$.

Equation $(1)$ implies that, for all $x\in[0,\pi]$, $$ I(\pi-x)=I(x)\tag4 $$ Since $\sin(\tan(x))$ has period $\pi$ and $(1)$ says that its integral over $[0,\pi]$ is $0$, $I(x)$ also has period $\pi$. That is, $$ I(\pi+x)=I(x)\tag5 $$ Furthermore, on $\left[0,\frac\pi4\right]$, $\tan(x)$ is convex; therefore, $\tan(x)\le\frac4\pi x$. Since $\sin(x)\le\min(x,1)$, we also have that $\sin(\tan(x))\le\min\left(\frac4\pi x,1\right)$. Thus, $$ I(x)\le\frac2\pi x^2\left[0\le x\lt\tfrac\pi4\right]+\left(x-\frac\pi8\right)\left[\tfrac\pi4\le x\lt\tfrac\pi2\right]+\frac{3\pi}8\left[\tfrac\pi2\le x\right]\tag6 $$ enter image description here

Therefore, $$ \begin{align} \int_0^\infty\frac{\sin(\tan(x))}x\,\mathrm{d}x &=\int_0^\infty\frac1x\,\mathrm{d}I(x)\tag{7a}\\ &=\int_0^\infty\frac{I(x)}{x^2}\,\mathrm{d}x\tag{7b}\\ &\le\int_0^{\pi/4}\frac2\pi\,\mathrm{d}x+\int_{\pi/4}^{\pi/2}\frac{x-\frac\pi8}{x^2}\mathrm{d}x+\int_{\pi/2}^\infty\frac{3\pi}{8x^2}\,\mathrm{d}x\tag{7c}\\[6pt] &=1+\log(2)\tag{7d} \end{align} $$ Explanation:
$\text{(7a)}$: apply $(2)$
$\text{(7b)}$: integrate by parts
$\text{(7c)}$: apply $(6)$
$\text{(7d)}$: evaluate


Evaluation

After writing $(3)$, I realized that I might be able to evaluate the integral.

$$\newcommand{\Res}{\operatorname*{Res}} \begin{align} \int_0^\infty\frac{\sin(\tan(x))}x\,\mathrm{d}x &=\frac12\int_{-\infty}^\infty\frac{\sin(\tan(x))}x\,\mathrm{d}x\tag{8a}\\ &=\frac12\sum_{n\in\mathbb{Z}}\int_{\left(n-\frac12\right)\pi}^{\left(n+\frac12\right)\pi}\frac{\sin(\tan(x))}x\,\mathrm{d}x\tag{8b}\\ &=\frac12\sum_{n\in\mathbb{Z}}\int_{-\pi/2}^{\pi/2}\frac{\sin(\tan(x))}{x+n\pi}\,\mathrm{d}x\tag{8c}\\ &=\frac12\int_{-\pi/2}^{\pi/2}\frac{\sin(\tan(x))}{\tan(x)}\,\mathrm{d}x\tag{8d}\\ &=\frac12\int_{-\infty}^\infty\frac{\sin(x)}{x\left(1+x^2\right)}\,\mathrm{d}x\tag{8e}\\ &=\frac14\int_{-\infty}^\infty\left(\frac2x-\frac1{x-i}-\frac1{x+i}\right)\sin(x)\,\mathrm{d}x\tag{8f}\\ &=\frac{\pi}4\left(2\Res_{z=0}\frac{e^{iz}}{z}-\Res_{z=i}\frac{e^{iz}}{z-i}-\Res_{z=-i}\frac{e^{-iz}}{z+i}\right)\tag{8g}\\[3pt] &=\frac\pi2\left(1-\frac1e\right)\tag{8h} \end{align} $$ Explanation:
$\text{(8a)}$: integrand is even, so double and halve
$\text{(8b)}$: break up the integral into tangent domains
$\text{(8c)}$: substitute $x\mapsto x+n\pi$
$\text{(8d)}$: $\sum\limits_{n\in\mathbb{Z}}\frac1{x+n\pi}=\cot(x)$ (see this answer)
$\text{(8e)}$: substitute $x\mapsto\tan^{-1}(x)$
$\text{(8f)}$: partial fractions
$\text{(8g)}$: $\sin(x)=\frac{e^{ix}-e^{-ix}}{2i}$
$\phantom{\text{(8g):}}$ $\lim\limits_{R\to\infty}\left[-R-\frac i2,R-\frac i2\right]\cup Re^{i[0,\pi]}-\frac i2$ contains $z=0$ and $z=i$
$\phantom{\text{(8g):}}$ $\lim\limits_{R\to\infty}\left[-R-\frac i2,R-\frac i2\right]\cup Re^{-i[0,\pi]}-\frac i2$ contains $z=-i$
$\text{(8h)}$: evaluate the residues


Exchanging the Sum and Integral in $\bf{(8d)}$

Here is some justification for the reversal of the order of the sum and the integral in step $\text{(8d)}$.

For any fixed $m$, we easily have $$ \sum_{|n|\le m}\int_{-\pi/2}^{\pi/2}\frac{\sin(\tan(x))}{x+n\pi}\,\mathrm{d}x=\int_{-\pi/2}^{\pi/2}\sum_{|n|\le m}\frac{\sin(\tan(x))}{x+n\pi}\,\mathrm{d}x\tag9 $$ Then, we have $$ \begin{align} \left|\int_{-\pi/2}^{\pi/2}\frac{\sin(\tan(x))}{x+n\pi}\,\mathrm{d}x\right| &=\left|\int_{-\pi/2}^{\pi/2}\left(\frac1{x+n\pi}-\frac1{n\pi}\right)\sin(\tan(x))\,\mathrm{d}x\right|\tag{10a}\\ &=\left|\int_{-\pi/2}^{\pi/2}\frac{x\sin(\tan(x))}{(x+n\pi)n\pi}\,\mathrm{d}x\right|\tag{10b}\\[3pt] &\le\frac1{2n(n-1)}\tag{10c} \end{align} $$ Thus, $$ \sum_{|n|\gt m}\left|\int_{-\pi/2}^{\pi/2}\frac{\sin(\tan(x))}{x+n\pi}\,\mathrm{d}x\right|\le\frac1m\tag{11} $$ Furthermore, for $|x|\le\frac\pi2$, $$ \begin{align} \left|\,\sum_{|n|\gt m}\frac{\sin(\tan(x))}{x+n\pi}\,\right| &=\left|\,\sum_{n=m+1}^\infty\left(\frac1{x+n\pi}+\frac1{x-n\pi}\right)\sin(\tan(x))\,\right|\tag{12a}\\ &=\left|\,\sum_{n=m+1}^\infty\frac{2x}{n^2\pi^2-x^2}\,\sin(\tan(x))\,\right|\tag{12b}\\ &\le\sum_{n=m+1}^\infty\frac{2|x|}{\pi^2n(n-1)}\tag{12c}\\[3pt] &=\frac{2|x|}{m\pi^2}\tag{12d} \end{align} $$ Thus, $$ \int_{-\pi/2}^{\pi/2}\left|\,\sum_{|n|\gt m}\frac{\sin(\tan(x))}{x+n\pi}\,\right|\mathrm{d}x\le\frac1{2m}\tag{13} $$

robjohn
  • 345,667
  • 2
    Care to comment on the quick downvote? – robjohn Jan 27 '22 at 19:07
  • Wolfram Alpha says integral_0^∞ sin(tan(x))/x dx - 1/2 π (1 - 1/e) = -0.00444972. – marty cohen Jan 28 '22 at 04:44
  • 1
    @martycohen: I tried Mathematica, and got $-0.0039606977$. However, it also said that NIntegrate failed to converge to prescribed accuracy after $9$ recursive bisections in $x$ and that NIntegrate obtained $0.7939912876$ for the error estimate. – robjohn Jan 28 '22 at 07:24
  • 1
    Mathematica: Sum[1/(x+n Pi)+1/(x-(n+1)Pi),{n,0,Infinity}] gives Cot[x]. Then Integrate[1/2Sin[Tan[x]]Cot[x],{x,-Pi/2,Pi/2}] gives ((-1+E)Pi)/(2E) – robjohn Jan 28 '22 at 16:18
  • Then Wolfy's numerical evaluation is wrong. Don't know what method was used or how far they integrated to. Might have used a transformation from $[0, \infty]$ to a finite range and the extreme parts got lost. – marty cohen Jan 28 '22 at 19:43
  • I haven't used W/A. I assume they do a computation similar to Mma. No idea if they mention error estimates. This integral is not very well behaved for computation, with all the oscillations going on. If I up the number of recursive subdivisions to 10000, I can get an error of about 0.001, but not much better. – robjohn Jan 28 '22 at 20:08
1

Yes.

Note that $$\begin{align} I_n:=\int_{\pi(n-\frac12)}^{\pi(n+\frac12)}\frac{\sin(\tan(x))}{x}\,\mathrm dx&=\int_0^{\frac\pi2}\left(\frac1{n\pi+x}-\frac1{n\pi-x}\right)\sin(\tan(x))\,\mathrm dx\\&=\int_0^{\frac\pi2}\frac{-2x}{n^2\pi^2-x^2}\sin(\tan(x))\,\mathrm dx\\ \end{align}$$ With $A:=\int_0^{\frac\pi2}\max\{-2x\sin(\tan (x)),0\}\,\mathrm dx$, $B:=\int_0^{\frac\pi2}\min\{-2x\sin(\tan (x)),0\}\,\mathrm dx$ (which both converge), we can thus estimate $$ \frac{1}{n^2\pi^2-\pi^2/4}B+\frac{1}{n^2\pi^2-0}A\le I_n\le \frac{1}{n^2\pi^2-\pi^2/4}A+\frac{1}{n^2\pi^2-0}B,$$ The difference between these bounds and $\frac1{n^2\pi^2}(A+B)$ is governed by $$\frac{1}{n^2\pi^2-\frac{\pi^2}{4}}-\frac1{n^2\pi^2}=\frac1{4\pi^2 n^4-\pi^2 n^2},$$ hence $$ I_n=\frac1{n^2\pi^2}(A+B)+O(n^{-4}).$$ We conclude that $\sum I_n$ converges at least as good as $\sum\frac1{n^2}$.

1

We proof directly without a summation step that

$$ K=\int_{-\infty}^{\infty}\frac{e^{i \tan(x)}}{x}dx=\int_{-\infty}^{\infty} f(x)=i\pi (1-e^{-1}) $$

OPs integral is then $\tfrac{\text{Im}K}2$ by symmetry

We need the following short idenity $$\lim_{R\rightarrow\infty}\tan(R e^{i\phi})= i, \phi \in (0,\pi) \quad ({\star})$$ proof: $\tan(R e^{i\phi})= -i\tfrac{e^{Re^{i\phi}}-e^{-Re^{i\phi}}}{e^{Re^{i\phi}}+e^{-Re^{i\phi}}}=-i \tfrac{e^{R\sin(\phi)+iR\cos(\phi)}+O(e^{-R\sin(\phi)})}{-e^{R\sin(\phi)+iR\cos(\phi)}+O(e^{-R\sin(\phi)})}=i(1+O(e^{-R\sin(\phi)}))$

Now let us write (by Cauchy, note that we count the pole only half sine we enlose him half in the upper half plane)

$$ \oint f(z)dz=\int_{A(R)}f(z)dz+\int_{-R}^Rf(x)dx=-i \pi\text{res}(f(z),z=0) $$

here $A(R)$ is a halfcircle of radius $R$ in the upper half plane of $\mathbb C $ $$ \int_{-R}^Rf(x)=-\int_{A(R)}f(z)dz-i \pi \text{res}(f(z),z=0) \quad (\star\star) $$

Now by $({\star})$, if $R$ is big enough, $\int_{A(R)}f(z)dz= \int_0^{\pi} d\phi\frac{i R e ^{i\phi}e^{i*i} }{R e^{ i \phi}}=i\pi e^{-1}$.

Therefore the rhs of $(\star \star)$ exists and $\lim_{R\rightarrow \infty}\int_{-R}^Rf(x)$ is finite and equals to $K$.

No our final result is just one simple residue calculation away

$$ K=i\pi (1-e^{-1}) $$