Suppose $f$ is a measurable function and $f(x) > 0$ for all $x$. Let $g(x) = \frac{1}{f(x)}$. Prove that g is a measurable function. Suppose $f$ is a measurable function and $f(x) > 0$ for all $x$. Let $g(x) = \frac{1}{f(x)}$. Prove that g is a measurable function.
Using the definition of a measurable function I have,
$\{x : f(x) > a\} \in \mathcal{A}$ for all $a \in \mathbb{R}$. 
Can I rewrite $\{x : f(x) > a\} = \{x : \frac{1}{f(x)} < \frac{1}{a} \} = \{x : g(x) < b, \frac{1}{a} = b\}$
 A: To show that a function is measurable, it is necessary to show that the preimage of each measurable set is measurable.  To do this, it is sufficient to show that the preimage of each interval of the form $(b,\infty)$ is measurable.  So, suppose that $b \in \mathbb{R}$.
If $b \in \mathbb{R}$, then we have
\begin{align}
g^{-1}((b,\infty))
&= \left\{ x : g(x) > b\right\} \\
&= \left\{ x : \frac{1}{f(x)} > b \right\} \\
&= \left\{ x : \frac{1}{b} > f(x) \right\} \\
&= f^{-1}\left( \left(-\infty, \frac{1}{b} \right)\right). \tag{$\ast$}
\end{align}
Since $f$ is a measurable function, the preimage of every open set is measurable, which implies that the set at ($\ast$) is measurable.  But this is what we needed to show, therefore $g = \frac{1}{f}$ is measurable.
Note that if we allow the range of $g$ to include $\pm\infty$ (i.e. if we work in the extended real numbers), this proof works perfectly well (with only slight modification) when we allow $f$ to take nonpositive values.  Thus the hypothesis that $f(x) > 0$ is not strictly necessary, though we do have to enlarge the codomain to make sense of the argument.
