TITLE: Nonlinear Fubini-Tonelli?
QUESTION [11 upvotes]: A student raised the question today: can one interchange the integrals in
$$
\int_0^1 \left(\int_0^x f(y) \, dy \right)^2 \, dx
$$
for sufficiently nice functions $f$.  I answered no, with the reasoning that integrals are fundamentally linear operations.
However now that I think about it, it is certainly possible that some kind of non-linear analogy to Fubini-Tonelli exists and I'm simply not aware of it.  Indeed, it seems quite plausible that some interchanged expression involving square roots is equal to the expression above, and perhaps in general something involving the inverse of the non-linear function of the inner integral.
Is anyone aware of a non-linear Fubini-Tonelli theorem?

REPLY [5 votes]: Following up on Willie Wong's comment:
$$
\begin{align}
& \phantom{= {}} \int_0^1 \left( \int_0^x f(y)\,dy \right)^2\,dx = \int_0^1 \int_0^x \int_0^x f(y)f(z)\,dy\,dz \, dx = \int_0^1\int_0^1 \int_{\max\{y,z\}}^1 f(y)f(z)\, dx \, dy\, dz \\
& = \int_0^1\int_0^1 \left( f(y)f(z) \int_{\max\{y,z\}}^1  1\, dx \right) dy \, dz = \int_0^1\int_0^1 f(y)f(z) \left(1-{\max\{\,y,z\,\}}\right) \, dy  \, dz.
\end{align}
$$
The integration with respect to $x$ now appears as $1-\max\{\,y,z\,\}$ on the inside; the square of the integral with respect to $y$ now appears as $\int_0^1\int_0^1 \cdots\,dy\,dz$ on the outside.
As for "dimensional" correctness, $dy$ and $dz$ are both in the same units as $dy$ in the original integral; $f(y)$ and $f(z)$ are both in the same units as $f(y)$ in the original integral; and $x$ has to be in the same units as $y$ in the original integral; so $x$ is in the same units as $1-\max\{\,y,z\,\}$.  So the units are of the form $a^2 b^3$ on both sides of the "$=$".