In Folland's Real Analysis, he says that
$$ g_1^{-1}((a,\infty]) = \bigcup_{j = 1}^{\infty}f_j^{-1}((a,\infty]) $$
where $g_1(x) = \sup_j f_j(x)$, but he doesn't explain why. Why is this true?
It's by the definition of supremum, preimage, and union. Note that \begin{align*} x\in g_1^{-1}((a,\infty]) &\iff g_1(x) > a \\ &\iff f_j(x) > a\ \text{for some $j$} \\ &\iff x\in f_j^{-1}((a,\infty])\ \text{for some $j$}\\ &\iff x\in \bigcup_{j=1}^\infty f_j^{-1}((a,\infty]). \end{align*}
We first prove that $g_1^{-1}((a,\infty])\subseteq \bigcup_{j=1}^{\infty} f_j^{-1}((a,\infty])$. Fix arbitrary $x\in g_1^{-1}((a,\infty])$. By definition, $g_1(x)=\sup_j f_j(x)>a$ and hence there exists $j^*\in\mathbb N$ such that $f_{j^*}(x)>a$. Thus, $x\in f_{j^*}^{-1}((a,\infty]) \subseteq \bigcup_{j=1}^{\infty}f_j^{-1}((a,\infty])$.
We next prove that $\bigcup_{j=1}^{\infty}f_j^{-1}((a,\infty])\subseteq g_1^{-1}((a,\infty])$. Fix arbitrary $x\in \bigcup_{j=1}^{\infty}f_j^{-1}((a,\infty])$. By definition, there exists $j^*\in\mathbb N$ such that $x\in f_{j^*}^{-1}((a,\infty])$, meaning that $f_{j^*}(x)>a$. Therefore, $g_1(x) = \sup_j f_j(x) \geq f_{j^*}(x) > a $ and hence $x\in g_1^{-1}((a,\infty])$.