2

I'm asked to show that if $X, Y$ are random variables (discrete or continuous) and $E(X|Y) = Y$, $E(Y|X) = X$, then $X = Y$ almost surely.

I'd like to argue as follows: Suppose not. Then

$$\{X\neq Y\} = \bigcup _{r\in\mathbb{Q}} \left(\{X<r\} \cap \{r<Y\}\right) \cup \bigcup _{r\in\mathbb{Q}}\left(\{X>r\} \cap \{r>Y\}\right)$$

has positive measure, and hence without loss of generality there's some $r\in \mathbb{Q}$ such that $\{X<r<Y\}$ has positive measure. Let's call this set $C$. Then we get:

$$\int_CX<\mu(C)\cdot r<\int_CY=\int_CE(Y|X)=\int_CX$$

where the second-last equality comes from the definition of conditional expectation, and the last equality comes from one of the given equations. But the above is a contradiction, so that does it.

The problem here is that I've only used one of the given assumptions, so have I implicitly used the other one somewhere? Is there some measurability-related concern I'm overlooking?

1 Answers1

2

One can use the law of total variance: $$ \operatorname{var}(X) = \mathbb{E}(\operatorname{var}(X \mid Y)) + \operatorname{var}(\mathbb{E}(X \mid Y)) = \mathbb{E}(\operatorname{var}(X \mid Y)) + \operatorname{var}(Y) $$ so $$ \operatorname{var}(X) \le \operatorname{var}(Y), $$ and by the same argument, but with $X$ and $Y$ interchanged, the reverse inequality also holds. It follows that $$ \mathbb{E}(\operatorname{var}(X \mid Y)) = 0 \text{ and }\mathbb{E}(\operatorname{var}(Y \mid X)) = 0. $$ If the conditional expected value of something is $Y$ and the conditional variance is $0$, then that "something" is "almost surely" equal to $Y$.