Integration – How to Evaluate Improper Integral of arctan(x) Over Exponential Function

closed-formdefinite integralsimproper-integralsintegration

I'm trying to evaluate the improper integral,

$$I(a)=\int_{0}^{\infty}\frac{\tan^{-1}{x}}{e^{ax}-1}\mathrm{d}x,~~~\text{where }a\in\mathbb{R}^+.$$

Does this integral have a simple closed form expression? And if so, how best to obtain it?


My attempt

My first idea was to integrate by parts using $f=\tan^{-1}{x}$ and $dg=\frac{\mathrm{d}x}{e^{ax}-1}$, with the hope that the resulting integral would be amenable to solution by differentiating under the integral sign. So I found the indefinite integral,

$$\int\frac{\tan^{-1}{x}}{e^{ax}-1}\mathrm{d}x=\tan^{-1}{x}\left(\frac{1}{a}\log{(1-e^{ax})}-x\right)-\int\left(\frac{\log{(1-e^{ax})}}{a(x^2+1)}-\frac{x}{x^2+1}\right)\mathrm{d}x,$$

but then I realized that this would result in an imaginary boundary term for the corresponding definite integral over $[0,\infty)$ since,

$$\begin{cases}\lim_{x\to\infty}\tan^{-1}{x}\left(\frac{1}{a}\log{(1-e^{ax})}-x\right)=i\frac{\pi^2}{2a},\\
\lim_{x\to0}\tan^{-1}{x}\left(\frac{1}{a}\log{(1-e^{ax})}-x\right)=0.\end{cases}$$

I want to avoid complex variables if at all possible, so I don't know if I want to continue down this route.

Can anyone offer any hints or suggestions?


CORRECTION: As Vladimir pointed out, the correct anti-derivative is actually,

$$\int\frac{\tan^{-1}{x}}{e^{ax}-1}\mathrm{d}x=\tan^{-1}{x}\left(\frac{1}{a}\log{(e^{ax}-1)}-x\right)-\int\left(\frac{\log{(e^{ax}-1)}}{a(x^2+1)}-\frac{x}{x^2+1}\right)\mathrm{d}x.$$

Then, since,

$$\begin{cases}\lim_{x\to\infty}\tan^{-1}{x}\left(\frac{1}{a}\log{(e^{ax}-1)}-x\right)=\frac{\pi}{2}\cdot0=0,\\
\lim_{x\to0}\tan^{-1}{x}\left(\frac{1}{a}\log{-e^{ax}-1)}-x\right)=0,\end{cases}$$

we have,

$$I(a)=-\int_{0}^{\infty}\left(\frac{\log{(e^{ax}-1)}}{a(x^2+1)}-\frac{x}{x^2+1}\right)\mathrm{d}x.$$

Best Answer

Consider a related integral $\displaystyle\;J(a) = \int_0^\infty e^{-ax}\tan^{-1}(x) dx\;$. We can integrate it by part to get: $$J(a) = \frac{1}{a}\int_0^\infty e^{-ax}\frac{dx}{1+x^2}$$

Using this, we can rewrite our integral as $$I(a) = \int_0^\infty \left(\sum_{n=1}^\infty e^{-nax}\right)\tan^{-1}(x)dx = \sum_{n=1}^\infty J(na) = \sum_{n=1}^\infty \frac{1}{na}\int_0^\infty e^{-nax}\frac{dx}{1+x^2}$$ Replace $x$ by $x/n$ in each terms, this can be transformed as $$I(a) = \frac{1}{a}\int_0^\infty e^{-at}\left(\sum_{n=1}^\infty \frac{1}{t^2+n^2}\right) dt $$ Start with a infinite product expansion of $\displaystyle\;\frac{\sinh(\pi x)}{\pi x}\;$. By taking logarithm and differentiate, $$\frac{\sinh(\pi x)}{\pi x} = \prod_{n=1}^\infty \left(1 + \frac{x^2}{n^2}\right) \quad\implies\quad \sum_{n=1}^\infty \frac{1}{x^2 + n ^2 } = \frac{1}{2x}\left( \pi\coth(\pi x) - \frac{1}{x}\right) $$ we can rewrite the sum inside above integrand of $I(a)$ and obtain

$$I(a) = \frac{\pi}{2a}F\left(\frac{a}{\pi}\right) \quad\text{ where }\quad F(x) = \int_0^\infty e^{-xt} \left(\coth(t) - \frac{1}{t}\right) \frac{dt}{t} $$ Notice $$-\frac{dF(x)}{dx} = \int_0^\infty e^{-xt}\left(\coth(t) - \frac{1}{t}\right)dt$$ and compare this with a integral representation of digamma function $\displaystyle\;\psi(x) = \frac{d\log\Gamma(x)}{dx}\;$, $$\psi(x) = \int_0^\infty\left(\frac{e^{-t}}{t} - \frac{e^{-xt}}{1-e^{-t}}\right)dt \quad\implies\quad \psi\left(\frac{x}{2}\right) = \int_0^\infty\left(\frac{e^{-2t}}{t} - \frac{2e^{-xt}}{1-e^{-2t}}\right)dt $$ We get $$\begin{array}{rrl} &-\frac{dF(x)}{dx} &= \int_0^\infty \frac{e^{-2t} - e^{-xt}}{t}dt - \frac12 \left[\psi\left(\frac{x}{2}\right) + \psi\left(\frac{x}{2}+1\right)\right]\\ &&= \log\frac{x}{2} - \frac12\left[\psi\left(\frac{x}{2}\right) + \psi\left(\frac{x}{2}+1\right)\right]\\ \implies & F(x) &= \text{const.} + \log\Gamma\left(\frac{x}{2}\right) + \log\Gamma\left(\frac{x}{2}+1 \right) - x\log\left(\frac{x}{2e}\right) \end{array}$$ Since $\lim\limits_{x\to\infty}F(x) = 0$, we can use Stirling's approximation to fix the constant in $F(x)$ to $-\log(2\pi)$. As a result, We find

$$I(a) = \frac{\pi}{2a}\left[ 2\log\Gamma\left(\frac{a}{2\pi}+1\right) - \log(a)\right] -\frac12\log\left(\frac{a}{2\pi e}\right) $$

Related Question