Introduction
In quantum mechanics, we have some integrals like this one (spherically symmetric electron-electron electrostatic repulsion):
$$ I = \int_0^{\infty} r^2 R(r)^2 V(r) d r $$
with $R(r)$ the radial electron real wave function with normalization condition:
$$ \int_0^{\infty} r^2 R(r)^2 d r = 1 $$
The potential $V(r)$ is given by:
$$ V(r) = \frac{1}{r} \int_0^r r'^2 R(r')^2 d r' + \int_r^{\infty} r' R(r')^2 d r' $$
So the big integral $I$ is defined as:
$$ I = \int_0^{+ \infty} r^2 R(r)^2 \left( \frac{1}{r} \int_0^r r'^2 R(r')^2 d r' + \int_r^{\infty} r' R(r')^2 d r' \right) d r $$
Question
I have found that for certain functions, like $R \propto e^{ - a r}$ ($a > 0$, parameter), we have:
$$ \int_0^{\infty} r R(r)^2 d r \int_0^r r'^2 R(r')^2 d r' =^? \int_0^{\infty} r^2 R(r)^2 d r \int_r^{\infty} r' R(r')^2 d r' $$
Does this equality hold for every $R(r)$ (square integrable functions on the unit sphere) ? If yes, how to prove it ?
This is just Fubini's Theorem. Let me use variables $x,y$ for clarity. Then $$\begin{align*} \int_0^\infty x R(x)^2 dx \int_0^x y^2 R(y)^2 dy &= \int_0^\infty dx \int_0^x dy\; xy^2 R(x)^2 R(y)^2 \\ &= \int_0^\infty dy \int_y^\infty dx\; xy^2 R(x)^2 R(y)^2 \\ &= \int_0^\infty y^2 R(y)^2 dy \int_y^\infty x R(x)^2 dx, \end{align*}$$ which is exactly what you want (you can relabel $r=x, r'=y$ in the first integral, $r=y, r'=x$ in the second one). The exchange of integration is justified since $R$ is real and hence everything is positive.