In the proof provided above, it seems very confusing to me that the sum of two simple functions $g = \sum_{i=1}^n a_i \mathbf{1}_{A_i}$
and $h=\sum_{i=1}^m b_i \mathbf{1}_{B_i}$,
where $\mathbf{1}_{S}$ is the indicator function,
is given by $f = \sum_{i=1}^n \sum_{j=1}^m (a_i+b_j) \mathbf{1}_{A_i\cap B_j}$.
For example, let $g = 3\times\mathbf{1}_{\omega\geq 0}$ and $h = 2\times\mathbf{1}_{\omega< 0}$. If $\omega = 2$, then $g(2) = 3, h(2) = 0$, while $f(2) = 0 $ since the intersection of ${\omega\geq 0}$ and ${\omega< 0}$ is empty.
Moreover, in the third equality in the proof where $\sum_{j=1}^m\mu(A_i\cap B_j)$ is said to be $ = \mu(A_i)$ by finite additivity, how do we know that the union of all intersections of $B_j$'s with $A_i$ will cover all of $A_i$ ?
Thanks in advance!