Evaluate $\int_0^{\infty} \frac{ \operatorname{erf}^2(x)}{x^2}dx$, where, $\operatorname{erf}(x)=\frac{2}{\sqrt\pi}\int_0^x e^{-t^2}dt$

definite integralsimproper-integralsintegration

I'm trying to evaluate $\displaystyle \int_0^{\infty} \frac{ \operatorname{erf}^2(x)}{x^2}dx$
I suspect this integral is possible to solve by Feynman's Trick of differentiating under the integral sign. I've tried by parametrising like follows:

$$I(a)=\displaystyle \int_0^{\infty} \frac{ \operatorname{erf}^2(ax)}{x^2}dx$$
$$I'(a)=\displaystyle \int_0^{\infty} \frac{4e^{-a^2x^2} \operatorname{erf}(ax)}{\sqrt{\pi}x}dx$$

If I can somehow get rid of the factor of x in the denominator, the integral can be solved by a simple substitution. Anyone have any idea how to achieve this? Or is there another method I am missing?

Best Answer

$$I= \int_0^{\infty} \frac{ \operatorname{erf}^2(x)}{x^2}dx=\int_0^{\infty} \operatorname{erf}^2(x)d\left(\frac{-1}x\right)$$ Integration by part

$$I=-\frac{\operatorname{erf}^2(x)}x\bigg|_0^\infty+ \frac{4}{\pi}\int_0^{\infty}\frac{1}x 2\operatorname{erf}(x)\cdot e^{-x^2}dx=\frac{8}{\pi}\int_0^{\infty}\int_0^{x}\frac{1}x e^{-t^2-x^2}dtdx$$

Use polar coordinate $x=r\cos\theta, t=r\sin\theta$:

$$\begin{align}I&=\frac{8}{\pi}\int_0^{\pi/4}\int_0^{\infty}\frac{1}{r\cos\theta} e^{-r^2}r~drd\theta\\ \\ &=\frac{8}{\pi}\int_0^{\pi/4}\frac{1}{\cos\theta}d\theta\int_0^{\infty} e^{-r^2}~dr\\ \\ &=\frac{8}{\pi}\cdot\ln(1+\sqrt2)\cdot\frac{\sqrt\pi}2\\ \\ &=\frac{4}{\sqrt\pi}\ln(1+\sqrt2)\end{align}$$