I am trying to derive the density of Hooke's atom.
I know this is a physics model, but I think my problem is more in the realm of mathematics than physics. Let me give a quick description of the model and problem.
For this model the wave function is given as:
$$ \Psi\left(\mathbf{r}_{1},\mathbf{r}_{2}\right)=A\left(1+\frac{1}{2}\left|\mathbf{r}_{1}-\mathbf{r}_{2}\right|\right)\exp\left(-\frac{1}{4}\left(r_{1}^{2}+r_{2}^{2}\right)\right) $$
Or, expanded out:
$$ \Psi\left(\mathbf{r}_{1},\mathbf{r}_{2}\right) = A\exp\left(-\frac{1}{4}\left(r_{1}^{2}+r_{2}^{2}\right)\right)+\frac{A}{2}\left|\mathbf{r}_{1}-\mathbf{r}_{2}\right|\exp\left(-\frac{1}{4}\left(r_{1}^{2}+r_{2}^{2}\right)\right) $$
With $\mathbf{r}=\left<x,y,z\right>$, and $A$ being a constant that normalizes the wave function. Also note that everything is real, i.e. no imaginary part of either the constant or the coordinates.
The density is now defined as:
$$ \rho\left(\mathbf{r}_{1}\right) = \int_\Omega \Psi\left(\mathbf{r}_{1},\mathbf{r}_{2}\right)\Psi\left(\mathbf{r}_{1},\mathbf{r}_{2}\right) \mathrm{d}\mathbf{r}_{2} $$
Here $\Omega$ is over all space.
Inserting the wave function in the above it is easily found that:
$$ \rho\left(\mathbf{r}_{1}\right) =A^{2}\exp\left(-\frac{1}{2}r_{1}^{2}\right)\underset{I_{1}}{\underbrace{\int_{\Omega}\exp\left(-\frac{1}{2}r_{2}^{2}\right)\mathrm{d}\mathbf{r}_{2}}} \\ +\frac{A^{2}}{4}\exp\left(-\frac{1}{2}r_{1}^{2}\right)\underset{I_{2}}{\underbrace{\int_{\Omega}\left|\mathbf{r}_{1}-\mathbf{r}_{2}\right|^{2}\exp\left(-\frac{1}{2}r_{2}^{2}\right)\mathrm{d}\mathbf{r}_{2}}} \\ +A^{2}\exp\left(-\frac{1}{2}r_{1}^{2}\right)\underset{I_{3}}{\underbrace{\int_{\Omega}\left|\mathbf{r}_{1}-\mathbf{r}_{2}\right|\exp\left(-\frac{1}{2}r_{2}^{2}\right)\mathrm{d}\mathbf{r}_{2}}} $$
Given that:
$$ \int_{\Omega}f\left(\mathbf{r}\right)\mathrm{d}\mathbf{r}=\int_{-\infty}^{\infty}\int_{-\infty}^{\infty}\int_{-\infty}^{\infty}f\left(x,y,z\right)\mathrm{d}x\mathrm{d}y\mathrm{d}z $$
and,
$$ r=\sqrt{x^{2}+y^{2}+z^{2}} $$
The two first integrals $I_1$ and $I_2$ can easily be evaluated by separation of the cartesian coordinates to give:
$$ I_1 = \int_{\Omega}\exp\left(-\frac{1}{2}r_{2}^{2}\right)\mathrm{d}\mathbf{r}_{2} = \sqrt{2\pi}^{3} $$
and,
$$ I_2 =\int_{\Omega}\left|\mathbf{r}_{1}-\mathbf{r}_{2}\right|^{2}\exp\left(-\frac{1}{2}r_{2}^{2}\right)\mathrm{d}\mathbf{r}_{2}= r_{1}^{2}\sqrt{2\pi}^{3}+3\sqrt{2\pi}^{3} $$
Now my problem arises when trying to evaluate the third integral:
$$ I_3 = \int_{\Omega}\left|\mathbf{r}_{1}-\mathbf{r}_{2}\right|\exp\left(-\frac{1}{2}r_{2}^{2}\right)\mathrm{d}\mathbf{r}_{2} $$
Writing it out in cartesian coordinates I get:
$$ I_3 = \int_{-\infty}^{\infty}\int_{-\infty}^{\infty}\int_{-\infty}^{\infty}\sqrt{\left(x_{1}-x_{2}\right)^{2}+\left(y_{1}-y_{2}\right)^{2}+\left(z_{1}-z_{2}\right)^{2}} \\ \exp\left(-\frac{1}{2}x_{2}^{2}\right)\exp\left(-\frac{1}{2}y_{2}^{2}\right)\exp\left(-\frac{1}{2}z_{2}^{2}\right)\mathrm{d}x_{2}\mathrm{d}y_{2}\mathrm{d}z_{2} $$
But from here on I am stuck. I cannot see any way to separate the variable in $\sqrt{\left(x_{1}-x_{2}\right)^{2}+\left(y_{1}-y_{2}\right)^{2}+\left(z_{1}-z_{2}\right)^{2}}$.
From the solution on Wikipedia https://en.wikipedia.org/wiki/Hooke%27s_atom, the solution is going to be proportional to:
$$ I_3 \propto \left(r + \frac{1}{r}\right)\mathrm{erf}(r) $$
But I have been unable to find any relations with the error-function that could point me towards the solution.
What would be my next step to figure out how to solve $I_3$?
Not a full solution, but too long for a comment. $$I_3 = \int_{\Omega}\left|\mathbf{r}_{1}-\mathbf{r}_{2}\right|\exp\left(-\frac{1}{2}r_{2}^{2}\right)\mathrm{d}\mathbf{r}_{2}$$ Choose a spherical system of coordinates with $Z$ axis directed along $\vec r_1$ (this is your right to identify the coordinate system; the result does not depend on your choice).
In this system the integral $$I_3=\int_0^{2\pi}\int_0^\infty\int_0^\pi\exp\left(-\frac{1}{2}r_{2}^{2}\right)\sqrt{r^2_1+r_2^2-2r_1r_2\cos\theta}\,\,\sin\theta \,d\theta\,r_2^2\,dr_2\, d\phi$$ You can integrate first over $\phi$ and $\theta$: $$I_3=2\pi\int_0^\infty\int_{-1}^1\exp\left(-\frac{1}{2}r_{2}^{2}\right)\sqrt{r^2_1+r_2^2-2r_1r_2x}\,\,dx\,r_2^2\,dr_2$$ $$=\frac{2\pi}{3\,r_1}\int_0^\infty\exp\left(-\frac{1}{2}r_{2}^{2}\right)\biggl(\bigl((r_1+r_2)^2\bigr)^{\frac{3}{3}}-\bigl((r_1-r_2)^2\bigr)^{\frac{3}{3}}\biggr)r_2 dr_2$$ When integrating $\bigl((r_1-r_2)^2\bigr)^{\frac{3}{3}}$ you should be careful with the sign and limits: the expression is positive at any $r_2$. You should split the integration: from $0$ to $r_1$ and from $r_1$ to $\infty$ (and here the function $\mathrm{erf}(r)$ appears).