Evaluating $\int_0^\infty \frac {\cos {\pi x}} {e^{2\pi \sqrt x} - 1} \mathrm d x$
I am trying to show that$$\displaystyle \int_0^\infty \frac {\cos {\pi x}} {e^{2\pi \sqrt x} - 1} \mathrm d x = \dfrac {2 - \sqrt 2} {8}$$
I have verified this numerically on Mathematica.
I have tried substituting $u=2\pi\sqrt x$ then using the cosine Maclaurin series and then the $\zeta \left({s}\right) \Gamma \left({s}\right)$ integral formula but this doesn't work because interchanging the sum and the integral isn't valid, and results in a divergent series.
I am guessing it is easy with complex analysis, but I am looking for an elementary way if possible.
Solution 1:
This integral is one of Ramanujan's in his Collected Papers where he also shows the connection with the sin case.
Define $$\int_{0}^{\infty}\frac{\cos(\frac{a\pi x}{b})}{e^{2\pi \sqrt{x}}-1}dx$$
If a and b are both odd. In this case, they are both a=b=1.
Then, $$\displaystyle \frac{1}{4}\sum_{k=1}^{b}(b-2k)\cos\left(\frac{k^{2}\pi a}{b}\right)-\frac{b}{4a}\sqrt{b/a}\sum_{k=1}^{a}(a-2k)\sin\left(\frac{\pi}{4}+\frac{k^{2}\pi b}{a}\right)$$
letting a=b=1 results in your posted solution.