# Need help with $\int_0^\infty\frac{\log(1+x)}{\left(1+x^2\right)\,\left(1+x^3\right)}dx$

I need you help with this integral: $$\int_0^\infty\frac{\log(1+x)}{\left(1+x^2\right)\,\left(1+x^3\right)}dx.$$ Mathematica says it does not converge, which is apparently false.

• Surely $$\int_0^\infty \frac{\log(1+x)}{(1+x^2)(1+x^3)} \leq \int_0^\infty \frac{x}{(1+x^2)(1+x^3)} < +\infty...$$ – gt6989b Mar 3 '14 at 20:45
• I don't see any poles and plotting the integrand would imply the integral converges; in fact it eventually decays quite rapidly. If you ask for the antiderivative you get logs and dilogs and you can plug in the limits (it will probably simplify too using dilog identities) I get 0.3075243884. – Graham Hesketh Mar 3 '14 at 20:52
• Maple finds it in a closed form. See here as an exported pdf file. – user64494 Mar 3 '14 at 21:20
• The result given by Maple can be simplified in Mathematica to $\frac{G}{2}-\frac{37\pi^2}{864}+\frac{\pi\ln2}{8}$, where $G$ is Catalan's constant. – Vladimir Reshetnikov Mar 3 '14 at 21:50
• @user64494: for the Nth time, if you don't want to play, then don't disparage the game. – Ron Gordon Mar 4 '14 at 1:07

Huge pain in the rump, but in the end, fairly straightforward. First observe that

\begin{align}\int_0^{\infty} dx \frac{\log{(1+x)}}{(1+x^2)(1+x^3)} &= \int_0^{1} dx \frac{\log{(1+x)}}{(1+x^2)(1+x^3)} + \int_1^{\infty} dx \frac{\log{(1+x)}}{(1+x^2)(1+x^3)}\\ &= \int_0^{1} dx \frac{\log{(1+x)}}{(1+x^2)(1+x^3)} + \int_0^{1} dx \, x^3 \frac{\log{(1+x)}-\log{x}}{(1+x^2)(1+x^3)}\\ &= \int_0^1 dx \frac{\log{(1+x)}}{1+x^2} - \int_0^1 dx \frac{x^3 \log{x}}{(1+x^2)(1+x^3)}\end{align}

The first integral may be evaluated by subbing $x=\tan{t}$:

\begin{align} \int_0^1 dx \frac{\log{(1+x)}}{1+x^2} &= \int_0^{\pi/4} dt \, \log{(1+\tan{t})}\\ &= \int_0^{\pi/4} dt \, \log{(\sin{t}+\cos{t})} - \int_0^{\pi/4} dt \, \log{(\cos{t})}\\ &= \int_0^{\pi/4} dt \, \log{(\sqrt{2} \cos{(t-\pi/4)})} - \int_0^{\pi/4} dt \, \log{(\cos{t})}\\ &= \frac{\pi}{8} \log{2} + \int_0^{\pi/4} dt \, \log{(\cos{(t-\pi/4)})} - \int_0^{\pi/4} dt \, \log{(\cos{t})}\\ &= \frac{\pi}{8} \log{2}\end{align}

The second integral is messy but still doable. First, we may use partial fractions. Then we will get a series of zeta-like sums. Some of them we will immediately recognize. To the rest, we may apply the residue theorem.

\begin{align}\int_0^1 dx \frac{x^3 \log{x}}{(1+x^2)(1+x^3)} &= \frac12 \int_0^1 dx \left [\frac{1-x}{1+x^2} - \frac{1-x-x^2}{1+x^3} \right ] \log{x}\\ &= \frac12 \sum_{k=0}^{\infty} (-1)^k \int_0^1 dx \left (x^{2 k}-x^{2 k+1}-x^{3 k}+x^{3 k+1}+x^{3 k+2} \right ) \log{x}\\ &= -\frac12 \sum_{k=0}^{\infty} (-1)^k \left [ \frac1{(2 k+1)^2} - \frac1{(2 k+2)^2} - \frac1{(3 k+1)^2}\\ + \frac1{(3 k+2)^2}+\frac1{(3 k+3)^2}\right ] \\ &= \frac{5}{72} \frac{\pi^2}{12} - \frac12 G + \frac12 \sum_{k=0}^{\infty} (-1)^k \left [\frac1{(3 k+1)^2} - \frac1{(3 k+2)^2}\right ] \end{align}

where $G$ is Catalan's constant. As for the sum:

\begin{align} \frac12 \sum_{k=0}^{\infty} (-1)^k \left [\frac1{(3 k+1)^2} - \frac1{(3 k+2)^2}\right ] &= \frac14 \sum_{k=-\infty}^{\infty} (-1)^k \left [\frac1{(3 k+1)^2} - \frac1{(3 k+2)^2}\right ] \\ &= -\frac{\pi}{4} \frac1{3^2} \left [\operatorname*{Res}_{z=-1/3} \frac{\csc{\pi z}}{(z+1/3)^2} \\- \operatorname*{Res}_{z=-2/3} \frac{\csc{\pi z}}{(z+2/3)^2} \right ]\\ &= \frac{\pi^2}{36} \left [\frac{\cos{\pi/3}}{\sin^2{\pi/3}} - \frac{\cos{2 \pi/3}}{\sin^2{2 \pi/3}} \right ]\\ &= \frac{\pi^2}{27}\end{align}

Therefore

$$\int_0^1 dx \frac{x^3 \log{x}}{(1+x^2)(1+x^3)} = \frac{5 \pi^2}{864} - \frac12 G + \frac{\pi^2}{27} = \frac{37 \pi^2}{864} - \frac{G}{2}$$

and finally...

$$\int_0^{\infty} dx \frac{\log{(1+x)}}{(1+x^2)(1+x^3)} = \frac{G}{2} + \frac{\pi}{8} \log{2} - \frac{37 \pi^2}{864} \approx 0.307524\cdots$$

• I'm always very pleased to see your answers. Out of curiosity, is there a particular source of problems/techniques that you've picked up and liked, or is it a conglomeration from over the years? – davidlowryduda Mar 4 '14 at 1:28
• @mixedmath: Thank you! To answer your question...I'm not quite sure how to answer your question. I simply have a set of techniques I am very comfortable with, especially residue theory. The important thing is that the art of integration lies in finding a transformation from one form that looks unwieldy to another that fits in a particular bag of tricks. Comfort with residue theory expands that bag of tricks enormously. – Ron Gordon Mar 4 '14 at 1:36
• $\displaystyle{\int_{0}^{\pi/4}\ln\left(1 + \tan\left(t\right)\right)\,{\rm d}t ={1 \over 2}\int_{0}^{\pi/4}\ln\left(1 + \tan\left(t\right)\right)\,{\rm d}t + {1 \over 2}\int_{0}^{\pi/4}\ln\left(2 \over 1 + \tan\left(t\right)\right)\,{\rm d}t={1 \over 2}\int_{0}^{\pi/4}\ln\left(2\right)\,{\rm d}t = {\pi \over 8}\,\ln\left(2\right)}$ – Felix Marin Mar 4 '14 at 3:22
• @RonGordon $\displaystyle{\int_{0}^{a}{\rm f}\left(x\right)\,{\rm d} x ={1 \over 2}\left[\int_{0}^{a}{\rm f}\left(x\right)\,{\rm d} x + \int_{0}^{a}{\rm f}\left(a - x\right)\,{\rm d} x\right]}$ – Felix Marin Mar 4 '14 at 5:36
• @RonGordon $\displaystyle{1 + \tan\left({\pi \over 4} - \theta\right) = 1 + {1 - \tan\left(\theta\right) \over 1 + \tan\left(\theta\right)} = {2 \over 1 + \tan\left(\theta\right)}}$ – Felix Marin Mar 4 '14 at 5:37

We can use the parametric integral to evaluate the integral. Let $$I(\alpha)=\int_0^\infty\frac{\ln(1+\alpha x)}{(1+x^2)(1+x^3)}dx.$$ Then it is easy to see \begin{eqnarray*} I'(\alpha)&=&\int_0^\infty\frac{x}{(1+\alpha x)(1+x^2)(1+x^3)}dx\\ &=&\pi\frac{(9+8\sqrt{3})\alpha^2+(8\sqrt{3}-9)}{(\alpha^2+1)(\alpha^2+\alpha+1)}-\frac{\alpha^3\ln\alpha}{(1+\alpha^2)(1-\alpha^3)} \end{eqnarray*} and hence \begin{eqnarray*} I(1)&=&\int_0^1I'(\alpha)d\alpha\\ &=&\pi\int_0^1\frac{(9+8\sqrt{3})\alpha^2+(8\sqrt{3}-9)}{(\alpha^2+1)(\alpha^2+\alpha+1)}d\alpha+\int_0^1\frac{\alpha^3\ln\alpha}{(1+\alpha^2)(1-\alpha^3)}d\alpha\\ &=&I_1+I_2. \end{eqnarray*} It is not hard to get $$I_1=\frac{\pi(5\pi+54\ln 2)}{432}.$$ Note \begin{eqnarray*} \frac{\alpha^3}{(1+\alpha^2)(1-\alpha^3)} &=&-\frac{1}{2}\frac{1+\alpha}{1+\alpha^2}+\frac12\frac{1+\alpha-\alpha^2}{1-\alpha^3} \end{eqnarray*} and hence \begin{eqnarray*} I_2&=&\int_0^1\frac{\alpha^3\ln\alpha}{(1-\alpha)(\alpha^2+1)(\alpha^2+\alpha+1)}d\alpha\\ &=&-\frac{1}{2}\int_0^1\frac{(1+\alpha)\ln\alpha}{1+\alpha^2}d\alpha+\frac{1}{2}\int_0^1\frac{(1+\alpha-\alpha^2)\ln\alpha}{1-\alpha^3}d\alpha \end{eqnarray*} But \begin{eqnarray*} \int_0^1\frac{(1+\alpha)\ln\alpha}{1+\alpha^2}d\alpha&=&\int_0^1\frac{\ln\alpha}{1+\alpha^2}d\alpha+\int_0^1\frac{\alpha\ln\alpha}{1+\alpha^2}d\alpha\\ &=&\sum_{n=0}^\infty\int_0^1(-\alpha^2)^n\ln\alpha d\alpha+\sum_{n=0}^\infty\int_0^1\alpha(-\alpha^2)^n\ln\alpha d\alpha\\ &=&-\sum_{n=0}^\infty\frac{(-1)^n}{(2n+1)^2}-\sum_{n=0}^\infty\frac{(-1)^n}{4(n+1)^2}=-G-\frac{\pi^2}{48}\\ \int_0^1\frac{(1+\alpha-\alpha^2)\ln\alpha}{1-\alpha^3}d\alpha &=&\int_0^1\frac{\ln\alpha}{1-\alpha^3}d\alpha+\int_0^1\frac{\alpha\ln\alpha}{1-\alpha^3}d\alpha-\int_0^1\frac{\alpha^2\ln\alpha}{1-\alpha^3}d\alpha\\ &=&\sum_{n=0}^\infty\int_0^\infty\alpha^{3n}\ln\alpha d\alpha+\sum_{n=0}^\infty\int_0^\infty\alpha^{3n+1}\ln\alpha d\alpha-\sum_{n=0}^\infty\int_0^\infty\alpha^{3n+2}\ln\alpha d\alpha\\ &=&-\sum_{n=0}^\infty\frac{1}{(3n+1)^2}-\sum_{n=0}^\infty\frac{1}{(3n+2)^2}+\frac{1}{9}\sum_{n=0}^\infty\frac{1}{(n+1)^2}\\ &=&-\sum_{n=0}^\infty\frac{1}{(3n+1)^2}-\sum_{n=0}^\infty\frac{1}{(3n+2)^2}-\frac{1}{9}\sum_{n=0}^\infty\frac{1}{(n+1)^2}+\frac{2}{9}\sum_{n=0}^\infty\frac{1}{(n+1)^2}\\ &=&-\frac{7\pi^2}{54}. \end{eqnarray*} Putting everything together, we have $$I(1)=\frac{G}{2}-\frac{37\pi}{864}+\frac{1}{8}\pi\ln 2.$$

Hint

This would probably work. Let $u = \ln(1+x)$ then $du = \frac{dx}{1+x}$ and factor the bottom $1+x^3 = (1+x)(\ldots)$.

• @nayrb i did not mean by parts, straight substition yields $u du$ divided by some exponentials. – gt6989b Mar 3 '14 at 20:59