I am having trouble understanding the concept of borel algebra on $\mathbb R^n$ and how it applies to measurable functions. I learned in class that the sigma algebra on $\mathbb R^n$ is generated by $O_1\times O_2\times\ldots O_n$, where each $O_i$ is a collection of open sets in $\mathbb R$. When applied to a measurable function $g:\mathbb R^n\rightarrow \mathbb R$, this amounts to saying that for any $B\in\mathcal B(\mathbb R)$, $g^{-1}(B)=C_1\times C_2\times\ldots C_n$, for some $C_1,\ldots C_n\in\mathcal B(\mathbb R)$. However, this doesn't seem to be correct to me! To me, it seems that a possible value for, say, the $n$th co-ordinate, must depend on the values of the other co-ordinates and so the set cannot be a product.
For example, consider a function $g:\mathbb R^2\rightarrow\mathbb R, \,g(x) = x_1+x_2$. We know that this is measurable. But then, how do you represent, say, $g^{-1}((0,\infty))$ as a product of anything? Clearly, $(-2,3),(3,-2)\in g^{-1}((0,\infty))$, and so if it is a product of two sets, it must contain $(-2,-2)$, which it doesn't!
I realize that I must be making some very basic conceptual error here, and I apologize for that. Can someone please help me understand this? Thanks in advance.
It does not. To say that $\mathcal{B}(\mathbb{R}^n)$ is generated by such Cartesian products says only that $\mathcal{B}(\mathbb{R}^n)$ is the smallest $\sigma$-algebra that contains all such Cartesian products. The variety of sets found in $\mathcal{B}(\mathbb{R}^n)$ is bewildering.
Chapter 5 of Lebesgue Integration on Euclidean Space, by Frank Jones, contains the folllowing advice.
For example, when proving that
if
then
the same book states the following.