TITLE: Lusin's theorem from Rudin RCA
QUESTION [5 upvotes]: Hi! Let me ask questions on Lusin's theorem from Rudin's RCA.
$1)$ As we know $s_n=\varphi_n \circ f$ (from Theorem 1.17) then $$2^nt_n(x)=2^n(s_n(x)-s_{n-1}(x))=2^n(\varphi_n \circ f(x)-\varphi_{n-1} \circ f(x))=\dots$$ As $0\leq f<1$ then $$\dots=2^n\left(\dfrac{[2^nf(x)]}{2^n}-\dfrac{[2^{n-1}f(x)]}{2^{n-1}}\right)=[2^nf(x)]-2[2^{n-1}f(x)]$$ where $[\cdot]$ - integer part. Also the last equality above can be equal $0$ or $1$ since $[2\theta]-2[\theta]\in \{0,1\}$. An it's equal to $1$ if $\theta\in \bigcup \limits_{k\in \mathbb{Z}}[k+\frac{1}{2},k+1)$. So $2^nt_n(x)=1$ if $2^{n-1}f(x) \in \bigcup \limits_{k\in \mathbb{Z}}[k+\frac{1}{2},k+1)$ $\Rightarrow$ $x  \in \bigcup \limits_{k\in \mathbb{Z}}f^{-1}([2^{-(n-1)}(k+\frac{1}{2}),2^{-(n-1)}(k+1)))$. So $T_n$ is the last set and it's measurable, i.e. $T_n \in \mathfrak{M}$. Am I right? 
$2)$ When he write that "$(1)$ holds if $A$ is compact and $f$ is a bounded measurable function" what does he mean about $f$? Non-negative function or not? Is non-negative then we must replace $f$ by $\alpha^{-1}f$ where $\alpha=\sup f+1$.
$3)$ Let's Go further. Let's take a look at penultimate paragraph which I marked by red line. I understood that if $A$ is any set with finite measure then by inner regularity we can find compact set $K\subset A$ such that $m(A-K)$ as small as needed. Note that $f$ outside $K$ possibly is not zero! And we can't apply above proof because there we use that $f=0$ on $A^c$.
$4)$ Also why considers sets $B_n$? Also it's not obvious to me how he got the general case.
Would be very grateful if somebody explain what he does in this paragraph. I spent about one day but no results :( In my opinion this paragraph is very brief and horrible.

REPLY [2 votes]: Let me write you a more detailed version of the second last paragraph. Suppose $f:X\to [0,+\infty)$ is a measurable function, $\mu(A) < +\infty$, and $f = 0$ outside $A$. Note that the general complex case can be decomposed to this case by considering the positive and negative parts of real and imaginary parts. What you know is that you can approximate such an $f$ on a compact set where it's bounded. Your goal is to find some compact set $K\subset A$, such that $f$ is bounded on $K$, and $\mu(A-K)$ is small.
Fix $\epsilon > 0$. Put $B_n = \{x:f(x) \geq n\}$. Then $B_{n+1}\subset B_n$ and $\bigcap B_n = \varnothing$, because $f(x)$ is finite for each $x$. You also know that $B_1 \subset A$, so $\mu(B_1)$ is finite. That means $\mu(B_n) \to 0$ as $n\to \infty$. Let $n$ be such that $\mu(B_n) <\epsilon$. Since $\mu(A-B_n)$ has finite measure, by inner regularity you can find a compact set $K\subset A-B_n$ such that $\mu(K) > \mu(A-B_n) - \epsilon$. Now you have $f$ bounded on a compact set $K$, and $\mu(A-K) < 2\epsilon$.