I got a clock as a gift recently. It has a very novel face in that the hour positions are given by a complex formula. For the most part, I have been able to verify the calculations presented as accurate, but the two o'clock identity has me stumped.
$$ \frac{\gamma}{\displaystyle{\int_0^\infty\frac{e^{-x^2}-e^{-x}}{x}\,dx}} $$
I know that $\gamma$ is the Euler-Mascheroni constant. And WolframAlpha tells me that $\int_0^\infty\frac{e^{-x^2}-e^{-x}}{x}\,dx=\frac{\gamma}{2}$ which makes sense because
$$ \frac{\gamma}{\displaystyle{\int_0^\infty\frac{e^{-x^2}-e^{-x}}{x}\,dx}}=\frac{\gamma}{\displaystyle{\frac{\gamma}{2}}}=2 $$
It is not clear how I would show $\int_0^\infty\frac{e^{-x^2}-e^{-x}}{x}\,dx=\frac{\gamma}{2}$. Could anyone shed some light on this or point me to a source (book, article, etc...) where I can read up on this. The usual internet (listed above) resources have not been helpful to me.
$$\frac{e^{-x^2}-e^{-x}}{x} = \int_x^1 dt \, e^{-x t} = \int_{x^2}^x dy \, e^{-y}$$
Therefore, let's integrate and reverse the order of integration as follows.
$$\begin{align} \int_0^{\infty} dx\, \frac{e^{-x^2}-e^{-x}}{x} &= \int_0^{\infty} \frac{dx}{x} \, \int_{x^2}^x dy \, e^{-y} \\ &= \int_0^{\infty} dy \, e^{-y} \int_y^{\sqrt{y}} \frac{dx}{x} \\ &= \int_0^{\infty} dy \, e^{-y} \left [\log{\sqrt{y}}-\log{y} \right ] \\ &=-\frac12 \int_0^{\infty} dy \, e^{-y} \, \log{y} \\ &= \frac{\gamma}{2} \end{align}$$