Discover the reason why two iterated integrals with different orders are not equal

fubini-tonelli-theoremslebesgue-integralmeasure-theorysolution-verification

Consider on $[0,1]^{2}$ the function defined by $$f(x,y):=\dfrac{x^{2}-y^{2}}{(x^{2}+y^{2})^{2}}.$$

I have computed out the iterated integrals are not the same if we swap the order of the integral. That is, $$\int_{0}^{1}\Big(\int_{0}^{1}f(x,y)dx\Big)dy\neq \int_{0}^{1}\Big(\int_{0}^{1}f(x,y)dy\Big)dx.$$ Indeed, we could see that $$LHS=-\dfrac{\pi}{4}\ \text{while}\ RHS=\dfrac{\pi}{4}.$$

However, I want to figure out why they are not equal in the sense of measure theory. That is, there must be something that violates Fubini theorem.

I tried to figure it out in the following way:

Firstly we can see that $f(x,y)$ is continuous in $y$ and $x$, and thus is measurable with respect to $x-$region (if treating $y$ as a constant) and vice versa. So the only thing left is that $f(x,y)$ is not integrable with the product measure on $[0,1]\times [0,1]$.

I tried to show $$\int_{[0,1]\times [0,1]}|f(x,y)|dxdy=\infty,$$ in the following way. Firstly, we replace $x:=r\cos\theta$ and $y:=r\sin\theta$, so that
\begin{align*}
\int_{[0,1]\times [0,1]}|f(x,y)|dxdy&=\int_{0}^{2\pi}\int_{0}^{1}\dfrac{|\cos^{2}(\theta)-\sin^{2}(\theta)|}{r^{2}}rdrd\theta\\
&=\int_{0}^{2\pi}|\cos^{2}(\theta)-\sin^{2}(\theta)|d\theta\int_{0}^{1}\dfrac{1}{r}dr
\end{align*}

Now the problem comes, $\int_{0}^{1}\dfrac{1}{r}dr=\infty$, and thus the whole integral is $\infty$.

Is my proof correct? Thank you!

Best Answer

As Henry Lee suggested, my above proof is okay. But he also pointed out that $$\lim_{(x,y)\rightarrow (0,0)}f(x,y)=\infty.$$ One could see this using polar coordinate again.

Therefore, the continuity of $f(x,y)$ is problematic around $(0,0)$. Hence, $f(x,y)$ is actually not a continuous function on $x-$region or $y-$region, since for example in $x-$region when $y=0$, the thing became subtle. This problem finally causes the non-integrability of $f(x,y)$.

Related Question