Understanding inverse of a function I was trying to understand the proof for the following proposition.
Proposition: If $\{f_n\}$ is a sequence of $\bar{\mathbb{R}}$ valued measurable functions on $(X,\mathcal{M})$, then the functions
$$g_1(x) = \sup_j f_j(x)$$
$$g_2(x) = \inf_j f_j(x)$$
$$g_3(x) = \lim_{j\rightarrow \infty} \sup f_j(x)$$
$$g_4(x) = \lim_{j\rightarrow \infty} \inf f_j(x)$$
are all measurable.
In the proof, it is given that $g_1^{-1}((a,\infty]) = \bigcup_1^{\infty}f_j^{-1}((a,\infty])$ and $g_2^{-1}([\infty,a)) = \bigcup_1^{\infty}f_j^{-1}([\infty,a)))$.
I am unable to understand these inverses of $g$. Can you please explain this?
 A: Recall that $g_1^{-1}((a,\infty])$ means the set $\{x\in X:g_1(x)\in (a,\infty]\}$ (called the preimage of the set $(a,\infty]$ under $g_1$).  
We are told that $g_1(x)=\sup\{f_j(x)\}$.  This tells us two things:


*

*for all $x\in X$, and for all $j$, $f_j(x)\le g_1(x)$.

*if $y$ is such that for all $x\in X$ and all $j$, $f_j(x)\le y$, then $g_1(x)\le y$


(This is just the definition of a least upper bound.)
Now in order to show that 
$$
g_1^{-1}((a,\infty])=\bigcup f_j^{-1}((a,\infty])
$$
we need to show that:


*

*$\bigcup f_j^{-1}((a,\infty]) \subset g_1^{-1}((a,\infty])$ - equivalently, for each $j$, $f_j^{-1}((a,\infty])\subset g_1^{-1}((a,\infty])$.  

*$g_1^{-1}((a,\infty]) \subset \bigcup f_j^{-1}((a,\infty])$ - equivalently, for each $x$ such that $g_1(x)\in (a,\infty]$, there exists some $j$ such that $f_j(x)\in (a,\infty]$.  


I think you can prove both those things yourself.  Then try and use the same argument for $g_2^{-1}([-\infty,a))$.  
A: To say that
$$
g_1^{-1}((a,\infty]) = \bigcup_1^\infty f_j^{-1}((a,\infty])
$$
is to say that for every $x$ in the domain,
$$
g_1(x)>a\text{ if and only if there is at least one $j$ for which }f_j(x)>a.
$$
i.e.
$$
\sup_j f_j(x)>a\text{ if and only if there is at least one $j$ for which }f_j(x)>a.
$$
i.e. the smallest upper bound of a set is $>a$ if and only if at least one member of the set is $>a$.  Consider both "if" and "only if" in the light of the definition of smallest upper bound.
