# What's wrong with my proof of: Every measurable function is the limit a.e. of a sequence of continuous functions.

Observe that if $f_n$ converges to $f$ almost everywhere then $$f(x)=\limsup_{n\to \infty} f_n(x)$$ almost everywhere. We know that $\limsup_{n\to \infty} f_n(x)$ is measurable since $\{f_n\}_{n\in \mathbb{N}}$ is a sequence of measurable functions.

Claim: Let $f:E\to \mathbb{R}$ and let $g:E\to\mathbb{R}$. If $f$ is measurable, and $f=g$ a.e., on $E$ then $g$ is measurable.

Proof of Claim: For $a\in \mathbb{R}$, let $A=\{x\in E: f(x)>a\}$ and $B=\{x\in E: g(x)>a\}$. Then $A$ is measurable and $A\setminus B\, , B\setminus A\subseteq \{x\in E: f(x)\neq g(x)\}$ and they have zero measures. Now observe that $$B=(B\setminus A)\bigcup (B\bigcap A)=(B\setminus A)\bigcup (A\setminus (A\setminus B))$$ is measurable. Hence, $g$ is measurable.

Therefore, every measurable function is the limit a.e. of a sequence of continuous functions.

The grader took off half the points and it is too late to ask my professor(exam tomorrow!). I would appreciate it anyone helps me understand this and maybe fix my proof. Also note that various sources helped me with this proof. Thanks.

-
I don't see any mention of continuous functions, except for the last sentence. So you must have forgotten something. – azarel Mar 27 '12 at 23:19
@Sri Pot : yes, I agree with azarel's comment ; I understand that if $f=g$ a.e. then $g$ is measurable, and there is an easier way to do this : $f=g$ almost everywhere means $f-g = 0$ almost everywhere, but then the pre-image of a measurable set is always of the form $(f-g)^{-1}(\{0\}) \cup N$, where $N \subseteq (f-g)^{-1}(\mathbb R \backslash \{0\})$, which is of zero measure by assumption. Therefore $f-g$ is measurable, hence $f - (f-g) = g$ also is. – Patrick Da Silva Mar 27 '12 at 23:31
But either way, you have not said anywhere WHY measurable functions are limits of continuous functions. – Patrick Da Silva Mar 27 '12 at 23:31
You prove the converse of what was asked - that is $f$ is an a.e. limit of continuous functions, then it is measurable. – D. Thomine Mar 27 '12 at 23:36