Integral $\int_0^\infty \log^2 x\frac{1+x^2}{1+x^4}dx=\frac{3 \pi^3}{16\sqrt 2}$

This integral below
$$
I:=\int_0^\infty \log^2 x\frac{1+x^2}{1+x^4}dx=\frac{3 \pi^3}{16 \sqrt 2}
$$
is what I am trying to prove. Thanks.

We can not expand the denominator as a series since the domain of integration is for $x\in [0,\infty)$. Next I wrote
$$
I=\int_0^\infty \log^2 x \frac{1+x^4-x^4+x^2}{1+x^4}dx=\int_0^\infty \log^2x \left(\frac{1+x^4}{1+x^4}+\frac{x^2-x^4}{1+x^4}\right)dx=\\
\int_0^\infty \log^2 x \, dx+\int_0^\infty \log^2 x \frac{x^2}{1+x^4}dx-\int_0^\infty \log^2 x \frac{x^4}{1+x^4}dx,
$$
however only the middle integral is convergent. I am not sure how to go about solving this problem. Thank you

Solutions Collecting From Web of "Integral $\int_0^\infty \log^2 x\frac{1+x^2}{1+x^4}dx=\frac{3 \pi^3}{16\sqrt 2}$"

Following Mhenni’s suggestion, I will calculate $$I(\mu) = \int_0^{\infty} x^{\mu}\frac{1+x^2}{1+x^4} \,dx $$ and then take $I”(0)$.
By the ubiquitous formula $$\int_0^{\infty}\frac{x^a}{1+x^b} \,dx =\frac{\pi}{b \sin(\pi(a+1)/b)}$$
we obtain $$I(\mu)=\frac{\pi}{4} \left[ \frac{1}{\sin(\pi(\mu+1)/4)} + \frac{1}{\sin(\pi(\mu+3)/4)} \right]$$
This gives (after some simple algebra)

$$I”(0) = \int_0^{\infty} \frac{1+x^2}{1+x^4} \log^2 x \,dx = \frac{\pi}{4}\left[\frac{3 \pi ^2}{8 \sqrt{2}}+\frac{3 \pi ^2}{8 \sqrt{2}} \right] = \frac{3 \pi ^3}{16 \sqrt{2}}$$
as was to be shown.

A related problem. Recalling the Mellin transform of a function $f$

$$ F(s)=\int_{0}^{\infty} x^{s-1}f(x)dx \implies F”(s)=\int_{0}^{\infty} \ln(x)^2x^{s-1}f(x)dx .$$

Now the whole problem boils down to finding the Mellin transform of $\frac{1+x^2}{1+x^4}$, differentiating twice, and then taking the limit as $s \to 1$.

Can you finish it?

Here is another way to calculate. It is much simpler. Clearly
\begin{eqnarray*}
I&=&2\int_0^1 \log^2 x\frac{1+x^2}{1+x^4}dx\\
&=&2\int_0^1\sum_{n=0}^\infty(1+x^2)(-1)^nx^{4n}\log^2xdx\\
&=&2\int_0^1\sum_{n=0}^\infty(-1)^n(x^{4n}+x^{4n+2})\log^2xdx\\
&=&2\sum_{n=0}^\infty\int_0^1(-1)^n(x^{4n}+x^{4n+2})\log^2xdx\\
&=&4\sum_{n=0}^\infty(-1)^n(\frac{1}{(4n+1)^3}+\frac{1}{(4n+3)^3})\\
&=&4\sum_{n=-\infty}^\infty(-1)^n\frac{1}{(4n+1)^3}\\
&=&\frac{3\pi^3}{16\sqrt2}
\end{eqnarray*}
Here we use the following theorem
$$ \sum_{n=-\infty}^\infty (-1)^nf(n)=-\pi \sum_{k=1}^m\text{Re}(\frac{f(z)}{\sin\pi z},a_k) $$
where $a_1,a_2,\cdots,a_m$ are poles of $f(z)$. For $f(z)=\frac{1}{(4z+1)^3}$, $z=-\frac{1}{4}$ is the only pole and
$$ \text{Re}(\frac{f(z)}{\sin\pi z},-\frac{1}{4})=-\frac{3\pi^2}{64\sqrt2}. $$
Thus we have the result.

$\newcommand{\+}{^{\dagger}}
\newcommand{\angles}[1]{\left\langle\, #1 \,\right\rangle}
\newcommand{\braces}[1]{\left\lbrace\, #1 \,\right\rbrace}
\newcommand{\bracks}[1]{\left\lbrack\, #1 \,\right\rbrack}
\newcommand{\ceil}[1]{\,\left\lceil\, #1 \,\right\rceil\,}
\newcommand{\dd}{{\rm d}}
\newcommand{\down}{\downarrow}
\newcommand{\ds}[1]{\displaystyle{#1}}
\newcommand{\expo}[1]{\,{\rm e}^{#1}\,}
\newcommand{\fermi}{\,{\rm f}}
\newcommand{\floor}[1]{\,\left\lfloor #1 \right\rfloor\,}
\newcommand{\half}{{1 \over 2}}
\newcommand{\ic}{{\rm i}}
\newcommand{\iff}{\Longleftrightarrow}
\newcommand{\imp}{\Longrightarrow}
\newcommand{\isdiv}{\,\left.\right\vert\,}
\newcommand{\ket}[1]{\left\vert #1\right\rangle}
\newcommand{\ol}[1]{\overline{#1}}
\newcommand{\pars}[1]{\left(\, #1 \,\right)}
\newcommand{\partiald}[3][]{\frac{\partial^{#1} #2}{\partial #3^{#1}}}
\newcommand{\pp}{{\cal P}}
\newcommand{\root}[2][]{\,\sqrt[#1]{\vphantom{\large A}\,#2\,}\,}
\newcommand{\sech}{\,{\rm sech}}
\newcommand{\sgn}{\,{\rm sgn}}
\newcommand{\totald}[3][]{\frac{{\rm d}^{#1} #2}{{\rm d} #3^{#1}}}
\newcommand{\ul}[1]{\underline{#1}}
\newcommand{\verts}[1]{\left\vert\, #1 \,\right\vert}
\newcommand{\wt}[1]{\widetilde{#1}}$
$\ds{I\equiv\int_{0}^{\infty}\ln^{2}\pars{x}\,{1 + x^{2} \over 1 + x^{4}}\,\dd x
={3 \pi^{3} \over 16 \root{2}}}$

\begin{align}
I&=-\Im\bracks{\pars{1 – \ic}
\int_{0}^{\infty}{\ln^{2}\pars{x} \over x^{2} + \ic}\,\dd x}
\\[3mm]&=-\,\Im\bracks{\pars{1 – \ic}
\lim_{\mu \to 0}\partiald[2]{}{\mu}\int_{0}^{\infty}
x^{\mu}\int_{0}^{\infty}\expo{-\pars{x^{2} + \ic}\xi}\,\dd\xi\,\dd x}
\\[3mm]&=-\,\Im\bracks{\pars{1 – \ic}
\lim_{\mu \to 0}\partiald[2]{}{\mu}\int_{0}^{\infty}\expo{-\ic\xi}\
\overbrace{\int_{0}^{\infty}x^{\mu}\expo{-\xi x^{2}}\,\dd x}^{\ds{t \equiv \xi x^{2}\ \imp\ x = \xi^{-1/2}t^{1/2}}}\ \dd\xi}
\\[3mm]&=-\,\Im\bracks{\pars{1 – \ic}
\lim_{\mu \to 0}\partiald[2]{}{\mu}\int_{0}^{\infty}\expo{-\ic\xi}\
\int_{0}^{\infty}\xi^{-\mu/2}\ t^{\mu/2}\expo{-t}\xi^{-1/2}\,\half\,t^{-1/2}\,\dd t\,
\dd\xi}
\\[3mm]&=-\,\half\,\Im\bracks{\pars{1 – \ic}
\lim_{\mu \to 0}\partiald[2]{}{\mu}\int_{0}^{\infty}
\xi^{-\pars{\mu + 1}/2}\expo{-\ic\xi}
\int_{0}^{\infty}t^{\pars{\mu – 1}/2}\expo{-t}\,\dd t\,\dd\xi}
\\[3mm]&=-\,\half\,\Im\bracks{\pars{1 – \ic}
\lim_{\mu \to 0}\partiald[2]{}{\mu}\Gamma\pars{{\mu \over 2} + \half}
\color{#c00000}{\int_{0}^{\infty}\xi^{-\pars{\mu + 1}/2}\expo{-\ic\xi}\,\dd\xi}}
\tag{1}
\end{align}
where $\ds{\Gamma\pars{z}}$ is the
Gamma Function.

Also,
\begin{align}
&\overbrace{%
\color{#c00000}{\int_{0}^{\infty}\xi^{-\pars{\mu + 1}/2}\expo{-\ic\xi}\,\dd\xi}}
^{\ds{t \equiv \ic\xi\quad\imp\quad\xi = -\ic t = \expo{-\ic\pi/2}t}}
=\int_{0}^{\infty\ic}\pars{\expo{-\ic\pi/2}t}^{-\pars{\mu + 1}/2}
\expo{-t}\,\pars{-\ic\,\dd t}
\\[3mm]&=-\ic\expo{\ic\pi\pars{\mu + 1}/4}\int_{0}^{\infty}t^{-\pars{\mu + 1}/2}
\expo{-t}\,\dd t=-\ic\expo{\ic\pi\pars{\mu + 1}/4}\Gamma\pars{\half – {\mu \over 2}}
\end{align}

Expression $\pars{1}$ is reduce to:
\begin{align}
I&=-\,\half\,\Im\braces{\pars{1 – \ic}
\lim_{\mu \to 0}\partiald[2]{}{\mu}\Gamma\pars{{\mu \over 2} + \half}
\bracks{-\ic\expo{\ic\pi\pars{\mu + 1}/4}\Gamma\pars{\half – {\mu \over 2}}}}
\\[3mm]&=\half\,\Im\bracks{\pars{1 + \ic}
\lim_{\mu \to 0}\partiald[2]{}{\mu}\expo{\ic\pi\pars{\mu + 1}/4}\,
{\pi \over \sin\pars{\pi\bracks{\mu/2 + 1/2}}}}
\end{align}
where we used Euler Reflection Formula ${\bf\mbox{6.1.17}}$.

\begin{align}
I&={\root{2} \over 2}\,\pi\,
\lim_{\mu \to 0}\partiald[2]{}{\mu}\bracks{\cos\pars{\pi\mu \over 4}
\sec\pars{\pi\mu \over 2}}
={\pi \over \root{2}}\pars{-\,{\pi^{2} \over 16} + {\pi^{2} \over 4}}
\end{align}

$$\color{#00f}{\large%
I\equiv\int_{0}^{\infty}\ln^{2}\pars{x}\,{1 + x^{2} \over 1 + x^{4}}\,\dd x
={3 \pi^{3} \over 16 \root{2}}}
$$

The integrand is invariant under inversion:

$$\log^2(1/x){1+(1/x)^2\over1+(1/x)^4}d(1/x)=-\log^2x{1+x^2\over1+x^4}dx$$

Thus

$$\begin{align}
\int_0^\infty \log^2x{1+x^2\over1+x^4}dx&=\int_0^1 \log^2x{1+x^2\over1+x^4}dx+\int_1^\infty \log^2x{1+x^2\over1+x^4}dx\\
&=\int_0^1 \log^2x{1+x^2\over1+x^4}dx-\int_1^0 \log^2x{1+x^2\over1+x^4}dx\\
&=2\int_0^1 \log^2x{1+x^2\over1+x^4}dx
\end{align}$$

Maye now you can expand things as a power series.

A little long answer, but let us consider the triple integral:

$$I=\int_{0}^{\infty}\int_{0}^{\infty}\int_{0}^{\infty} \frac{xy}{(1+x^2)(1+y^2)(1+x^2y^2z^4)} \ dz \ dy \ dx.$$

Integrating in this order, we use a u substitution $z=\frac{u}{\sqrt{xy}}$ and $\ dz =\frac{du}{\sqrt{xy}},$ and this transforms the integral into

$$I=\int_{0}^{\infty}\int_{0}^{\infty}\int_{0}^{\infty} \frac{\sqrt{xy}\left(1+\frac{u^2}{xy} \right)}{(1+x^2)(1+y^2)(1+u^4)} \ du \ dy \ dx.$$ We can apply the well-known integral formula $$\int_{0}^{\infty} \frac{v^m}{1+v^n} \ dv =\frac{\pi}{n} \csc \left(\frac{\pi(m+1)}{n} \right)$$ to get that $$I=\frac{\pi^3}{2\sqrt{2}}.$$ Now let us reverse the order of integration as such.

$$I=\int_{0}^{\infty}\int_{0}^{\infty}\int_{0}^{\infty} \frac{xy}{(1+x^2)(1+y^2)(1+x^2y^2z^4)} \ dy \ dz \ dx.$$ Using partial fractions or Mathematica, we can get that

$$I= \int_{0}^{\infty}\int_{0}^{\infty} \frac{x(1+z^2)\ln(x)}{(1+x^2)(x^2z^4-1)} \ dz \ dx+\int_{0}^{\infty}\int_{0}^{\infty} \frac{2x(1+z^2)\ln(z)}{(1+x^2)(x^2z^4-1)} \ dz \ dx = J_1 + J_2.$$ Reverse the order of integration in $J_2$ and use partial fractions to see

$$J_2=4\int_{0}^{\infty} \frac{(z^2+1)(\ln(z))^2}{z^4+1} \ dz.$$ Let’s focus on $J_1.$

Integrating with respect to $z$ first with partial fractions gives

$$J_1= \int_{0}^{\infty} \frac{\pi}{4\sqrt{x}} \frac{(1-x)\ln(x)}{1+x^2} \ dx,$$ and we expand
$$J_1=-\int_{0}^{\infty}\int_{0}^{\infty} \frac{\pi(1-x)}{4\sqrt{x}} \frac{t}{(1+t^2)(1-t^2x^2)} \ dt \ dx,$$ which can be proven by partial fractions.

Reverse the order of integration and use partial fractions again to get that

$$J_1= -\frac{\pi^2}{8} \int_{0}^{\infty} \frac{t+1}{\sqrt{t}(t^2+1)} \ dt,$$ which by the well-known formula I mentioned, can be shown that $$J_1=\frac{-\pi^3}{4\sqrt{2}}.$$

Putting everything together now, we have that

$$\frac{\pi^3}{2\sqrt{2}}=\frac{-\pi^3}{4\sqrt{2}}+4\int_{0}^{\infty} \frac{(z^2+1)(\ln(z))^2}{z^4+1} \ dz,$$ which by some algebraic manipulation, gives us

$$\int_{0}^{\infty} \frac{(z^2+1)(\ln(z))^2}{z^4+1} \ dz= \frac{3 \pi^3}{16\sqrt{2}}.$$