Associativity of the product of measurable spaces The product of two measurable spaces $(X_1,M_1)$, $(X_2,M_2)$ is defined to be $(X,M)$, with $X = X_1\times X_2$, cartesian product of $X_1$ and $X_2$ and $M = M_1 \otimes M_2$ sigma-algebra generated by the collection of rectangles $A\times B$ with $A \in M_1$ and $B \in M_2$. The definition is naturally generalized to the case of the product of $n$ spaces.
Can someone give me an hint to the proof of:

Let $(X_1,M_1)$, $(X_2,M_2)$ and $(X_3,M_3)$ be measurable spaces. Prove that $(M_1 \otimes M_2) \otimes M_3 = M_1 \otimes M_2 \otimes M_3$, if we identify $((x_1,x_2),x_3)$ with $(x_1,x_2,x_3)$.

The fact that any rectangle $A \times B \times C$ belongs to $(M_1 \otimes M_2) \otimes M_3$ is obvious, so $M_1\otimes M_2\otimes M_3 \subseteq (M_1\otimes M_2)\otimes M_3$. But I have troubles proving formally that any set of the form $D\times C$, with $D \in M_1 \otimes M_2$ and $C \in M_3$, belongs also to $M_1\otimes M_2\otimes M_3$.
 A: When thinking about these types of problems, it's often useful to think of the minimality property of the $\sigma$-algebra generated by some set as being a sort of "induction principle":

Let $A \subseteq P(X)$, and let $\phi$ be a property on subsets of $X$.  Furthermore, suppose:
  
  
*
  
*$\phi(\emptyset)$.
  
*For every $S \in A$, $\phi(S)$.
  
*For every $S \subseteq X$, if $\phi(S)$, then $\phi(X \setminus S)$.
  
*Whenever $S_1, S_2, \ldots \subseteq X$ and $\phi(S_n)$ for each $n$, then $\phi(\bigcup_{n=1}^\infty S_n)$.
  
  
  Then for every $S$ in the $\sigma$-algebra on $X$ generated by $A$, we have $\phi(S)$.

(Proof is easy: the conditions imply that for $B = \{ S \subseteq X \mid \phi(S) \}$, we have $A \subseteq B$ and $B$ is a $\sigma$-algebra.  Therefore, the $\sigma$-algebra generated by $A$ is contained in $B$.)
The way I think about this principle is: you can informally think of the $\sigma$-algebra generated by $A$ as built up "from the bottom" in steps.  First, you start off with $\emptyset$ and elements of $A$.  Then, you take complements and countable unions of what you have "so far" and add them to the set.  If you repeat this "enough times" then what you get is the generated $\sigma$-algebra.  (In fact, you can make this precise using transfinite recursion up to step $\omega_1$.)  Then, the conditions say that you start off only with sets satisfying your condition $\phi$, and at each step since you're performing operations on sets satisfying $\phi$, the results will also have to satisfy $\phi$.
Now, what we want to prove in the problem at hand is that whenever $D \in M_1 \otimes M_2$ and $C \in M_3$, then $D \times C \in M_1 \otimes M_2 \otimes M_3$.  To do this, we prove by "induction" on $D$, using the above induction principle, that this holds for every $C \in M_3$.  That is, for $D \subseteq X_1 \times X_2$, $\phi(D)$ is the property: $\forall C \in M_3, D \times C \in M_1 \otimes M_2 \otimes M_3$.  Now, once this is set up, it should be straightforward to prove the "inductive step" conditions (3) and (4), as well as the "base case" (1) and the "base case" (2) where $D = A \times B$, $A \in M_1$, $B \in M_2$.  Thus, by the induction principle, it will follow that whenever $D \in M_1 \otimes M_2$, $\phi(D)$ which was what we wanted.

(Note: if you want to replace "$\sigma$-algebra generated by $A$" with "$\sigma$-ring generated by $A$", then all you need to do in the induction principle above is to replace (3) with: For every $S_1, S_2 \subseteq X$, if $\phi(S_1)$ and $\phi(S_2)$, then $\phi(S_1 \setminus S_2)$.)
