Let $X$ be a random variable. If we toss a coin and get "head" $X\sim U(0,1)$ , else $X\sim U(1,2)$. Define $G_1=\sigma(\{X^{-1}(1/2)\},\{X^{-1}(3/2)\})$ and $G_2=\sigma(\{X^{-1}(A):A\subseteq [1/2,3/2],:A \text{ Borelset}\})$. Compute $\mathbb{E}(X|G_1), \mathbb{E}(X|G_2)$.
My try:
$$\mathbb{E}(\mathbb{E}(X|G_1)\mathbb{1}_{\{X^{-1}(1/2)\}}) = \mathbb{E}(X\mathbb{1}_{\{X^{-1}(1/2)\}}) = 1/2 \mathbb{P}(X=1/2) = 0$$ and it is similar for $X^{-1}(3/2)$, that's why $$\mathbb{E}(X|G_1)=0.$$
Moreover we have $$\mathbb{E}(\mathbb{E}(X|G_2)\mathbb{1}_{\{X^{-1}(A):A\subseteq [1/2,1]\}}) = \mathbb{E}(X\mathbb{1}_{\{X^{-1}(A):A\subseteq [1/2,1]\}}) = \frac{1+1/2}{2} = \frac{3}{4}$$ and $$\mathbb{E}(\mathbb{E}(X|G_2)\mathbb{1}_{\{X^{-1}(A):A\subseteq [1,3/2]\}}) = \mathbb{E}(X\mathbb{1}_{\{X^{-1}(A):A\subseteq [1,3/2]\}}) = \frac{1+3/2}{2} = \frac{5}{4},$$ so we have $$\mathbb{E}(X|G_2)=1/2 * 3/4 + 1/2 * 5/4= 1.$$
I would appreciate it if someone could tell me if it is correct or if there is an error somewhere.