14

Show that $$\int_\mathbb R \frac{dx}{(e^x-x+1)^2+\pi^2}=\frac12$$ I encountered this integral in Victor H. Moll's note "Seized Opportunities". He mentions it can be solved using "elementary methods". I did a few substitutions that didn't work, and after that I tried this:

Consider the Laplace transform $$\mathcal L\{e^{-at}\sin(bt)\}=\frac{b}{(s+a)^2+b^2}$$ Setting $s=e^x+1$, $a=-x$, $b=\pi$, we have $$\int_\mathbb R \frac{dx}{(e^x-x+1)^2+\pi^2}=\frac1\pi\int_\mathbb R \int_{\mathbb R_{\ge 0}} e^{-te^x-t+xt}\sin(\pi t)dtdx=\frac1{\pi} \int_{\mathbb R_{\ge0}}e^{-t}\sin(\pi t)\int_{\mathbb R}e^{tx}e^{-te^x}dxdt$$ After $u=e^x$ we have $$\frac{1}{\pi} \int_{\mathbb R}e^{-t}\sin(\pi t)\int_{\mathbb R_{\ge 0}}u^{t-1}e^{-tu}dudt=\frac{1}{\pi} \int_{\mathbb R}e^{-t}\sin(\pi t)\int_{\mathbb R_{\ge 0}}u^{t-1}e^{-tu}dudt=\frac{1}{\pi} \int_{\mathbb R}e^{-t}\sin(\pi t)\frac{\Gamma(t)}{t^t}dt$$ Note that this is due to the formula $$\mathcal{L}\{u^t\}(s)=\frac{n!}{s^{n+1}}$$ Here I used Euler's reflection formula $$\Gamma(z)\Gamma(1-z)=\frac{\pi}{\sin(\pi z)}$$ to get the form $$\int_{0}^{\infty}\frac{dt}{(et)^t\Gamma(1-t)}$$

This looks really complicated, though, and I don't think it helps.

aaron
  • 514
  • 1
    Do you take contour integration as an answer to this question? – Thinh Dinh Apr 06 '25 at 05:30
  • 1
    Similar but not duplicate, and obviously non-elementary result: Here. I'm doubt that this would be help... – Myungheon Lee Apr 06 '25 at 05:31
  • 1
    @ThinhDinh Sure, but I would also appreciate any "elementary" methods if there exist any. – aaron Apr 06 '25 at 05:34
  • @aaron I think he's lying on saying that this integral could be evaluated using "elementary methods", unless he takes contour integration's idea to make it elementary methods in disguise. – Thinh Dinh Apr 06 '25 at 05:52
  • 5
    Amazingly, this integral is equivalent to $$\int_{\Bbb{R}}\frac{e^xdx}{(e^x-x+1)^2+\pi^2}$$ because the difference between the two integrals has an elementary antiderivative and gives $0$ over the whole real line. – Ninad Munshi Apr 06 '25 at 07:18

1 Answers1

10

If the complex integration approach is acceptable, we can do the following. $$I=\int_{-\infty}^\infty\;\frac{dx}{\pi^2+( 1-x+e^x)^2}=\frac1{2\pi i}\int_{-\infty}^\infty\left(\frac1{1-x+e^x-\pi i}-\frac1{1-x+e^x+\pi i}\right)dx$$ Now, let's consider the integral in the complex plane along the rectangular contour $C_R:\,\, -R\to R\to R-2\pi i\to-R-2\pi i\to -R$ (clockwise). Using the fact that $e^{z+2\pi i}=e^z$ $$\lim_{R\to\infty}\frac1{2\pi i}\oint_{C_R}\frac{dz}{1-z+e^z-\pi i}$$ $$=I+\lim_{R\to\infty}\left(\int_R^{R-2\pi i}\frac{dz}{1-z+e^z-\pi i}+\int_{-R-2\pi i}^{-R}\frac{dz}{1-z+e^z-\pi i}\right)=I$$ We have a single simple pole (at $z=-\pi i$), and we go around this pole in the negative direction.

Therefore, $$ I=-2\pi i\,\frac1{2\pi i}\,\underset{z=-\pi i}{\operatorname{Res}}\frac1{1-z+e^z-\pi i}=\frac12$$


To make sure that we have only one pole inside the contour, let's take $z=x+iy-\pi i;\,\, x\in(-\infty;\infty); \,\, y\in[-\pi;\pi]$

For the zeros of the denominator, taking the real and imaginary parts, we get a couple of equations: $$1-x=e^x\cos y;\quad-y=\sin y\, e^x$$ From the second equation it follows $\,y=0$, and after that from the first one $\,\,\Rightarrow \,x=0$

Svyatoslav
  • 20,502