If $E[X|Y]=Y$ almost surely and $E[Y|X]=X$ almost surely then $X=Y$ almost surely

11.8k Views Asked by At

Assume that $X$ and $Y$ are two random variables such that $Y=E[X|Y]$ almost surely and $X= E[Y|X]$ almost surely. Prove that $X=Y$ almost surely.

The hint I was given is to evaluate: $$E[X-Y;X>a,Y\leq a] + E[X-Y;X\leq a,Y\leq a]$$

which I can write as: $$\int_A(X-Y)dP +\int_B(X-Y)dP$$ where $A=\{X>a, Y\leq a\}$ and $B=\{X\leq a,Y\leq a\}$.

But I need some more hints.