Sigma algebra generated by $X+Y$ Let $X,Y$ be two random variables with values in $\{0,1\}$.
I want to show that $XY$ is measurable regarding $\sigma(X+Y)$ but I am not sure how $\sigma(X+Y)$ looks like.
I tried $\sigma(X+Y)=\sigma(\emptyset,0,1,2,\Omega)$.  
Now, to show $XY$ is measurable I need to check if $(XY)^{-1}(\mathcal{P}(\{0,1\}))  \in \sigma(X+Y):$ $\Rightarrow$ $(XY)^{-1}(1)=2 \quad \in \sigma(X+Y) \quad$ (since $2=\{X=1\}+\{Y=1\} \Rightarrow \{X=1\}\cdot\{Y=1\} =1) $ $(XY)^{-1}(0)= 0 \cup 1 \quad \in \sigma(X+Y)$.
I am honestly not quite sure, if my idea is right; may someone comment on this?
 A: Your idea is in principle correct, you are just being a bit sloppy in notation.
When you write "$(XY)^{-1}(1) = 2 \in \sigma(X+Y)$", what you actually mean is the set $\{X+Y=2\}$ (or more verbosely $\{\omega\in\Omega\mid (X+Y)(\omega) = 2\}$) and that lies indeed in $\sigma(X+Y)$.
So formally you can write
$$(XY)^{-1}(\{1\}) = \{XY=1\} = \{X=1,Y=1\}=\{X+Y=2\}=(X+Y)^{-1}(\{2\})\in\sigma(X+Y)$$
and similar for $(XY)^{-1}(\{0\})$.

Here is another way to phrase it:
We have
$$XY=\begin{cases}1, & X+Y=2 \\
0, & X+Y = 0 \text{ or } X+Y=1
\end{cases}$$
Hence for the function $f\colon\mathbb{R}\to\mathbb{R}$ given by
$$f(x)=\begin{cases}1, & x=2 \\
0, & \text{otherwise}
\end{cases}$$
we can write $XY=f(X+Y)$.
Generally speaking, for any real-valued random variables $S$, $T$ the following statements are equivalent:

*

*$S=f\circ T$ for some measurable function $f\colon \mathbb{R}\to\mathbb{R}$

*$S$ is $\sigma(T)$-measurable (i.e. $\sigma(S)\subseteq\sigma(T)$)

It is not hard to see that (1) implies (2) which is what we use here, but in fact the reverse implication also holds. This equivalence is sometimes known as Doob-Dynkin lemma.
