$C_c(X)$ dense in $L_1(X)$

I did the following homework, can you tell me if my answer is correct?

Prove that for any $\sigma$-compact, locally compact Hausdorff space $\Omega$ equipped with a Radon measure $\mu$ the set of continuous functions with compact support $C_c(\Omega)$ is dense in the set of Lebesgue-integrable functions $L_1(\Omega, \mu)$. Remember that any point of a locally compact space has a neighbourhood basis consisting of compact sets. A topological space is $\sigma$-compact if it allows a countable cover of compact sets.

a) We may assume that $f \in L_1(\Omega)$ is non-negative. Why? Prove that for any $\varepsilon > 0$ there exists a function $s \in L_1$ of finite support such that $\|f−s \|_1 <\varepsilon$. You may use the fact that for any measurable, non-negative function $f$ there exists a monotonely increasing sequence of simple functions $\{s_n\}$ that approximate $f$ pointwise.

Answer a.1: Because $f = f^+ - f^-$ where $f^+ , f^- \geq 0$ and so one only needs the integral on non-negative functions.

Answer a.2: To prove that one uses that for any non-negative $f$ there exists $s_n$ such that $$\forall \varepsilon > 0 \exists n_0 : n > n_0 \implies |f(x) - s_n(x) | < \frac{\varepsilon}{\mu(\Omega)} \forall x \in \Omega$$ where $s_n \leq s_{n+1}$ and $\displaystyle s_n(x) = \sum_{i=1}^N \alpha_i \chi_{Y_{i,n}}(x)$ and $Y_n := \cup Y_{i,n}$. Here I think I need to assume $\mu(\Omega) < \infty$ but maybe that follows from what is given in the question.

Then $$\| s_n(x) - f(x) \|_1 = \int_\Omega |s_n(x) - f(x)| d \mu < \varepsilon $$

Now one has a measurable function with finite (and therefore compact) support. Next one wants to make that into a continuous function.

b) Recall the Theorem of Lusin and Tietze’s Extension Theorem:

Theorem (Lusin’s Theorem). Let $\Omega$ and $\mu$ as above and $f\colon\Omega\to\mathbb R$ a $\mu$-measurable function with finite support $E$. Then for any $\delta > 0$ there exists a closed set $K\subset E$ such that $μ(E\setminus K) < \delta$ and $f$ is continuous on $K$.

Theorem (Tietze’s Extension Theorem for LCH spaces). If $\Omega$ is a locally compact Hausdorff space and $K \subset \Omega$ compact then any $f \in C(K, \mathbb R)$ can be extended to a function on $C_c(\Omega,\mathbb R)$ with supremums norm bounded by $\| f \|_\infty$.

Combine these theorems to show that $C_c(\Omega)$ is dense in $L_1$. You may need that $\mu$ is Radon.

Answer b:

From a) one has a measurable function $s_n$ with finite support $Y_n$. To make it into a continuous function one can set it to be $0$ on $Y_n \setminus K$ where $K$ is a closed set such that $μ(Y_n \setminus K) < \delta$ for some $\delta$. Let's call this modified function $\tilde{s_n}$. Then $$ \lim_{n \to \infty} \| \tilde{s_n}(x) - f(x)\|_1 = \lim_{n \to \infty} \int_{Y_n \setminus K} |s_n(x) - f(x)| d\mu = \lim_{n \to \infty} \int_{Y_n} |s_n(x) - f(x)| d\mu = 0$$

Many thanks for your help!


Answer a.1: Because $f = f^+ - f^-$ where $f^+ , f^- \geq 0$ and so one only needs the integral on non-negative functions.

Okay, but why exactly does it suffice to deal with $f^+$ and $f^-$ separately? The triangle inequality should be mentioned: for a given $\varepsilon \gt 0$ choose $s^+$ and $s^-$ such that $\|f^\pm-s^\pm\| \lt \varepsilon/2$ and then $$\|f-(s^+-s^-)\| \leq \|f^+-s^+\|+\|f^--s^-\|\lt \varepsilon$$ by the triangle inequality and the choice of $s^\pm$.

Answer a.2: To prove that one uses that for any non-negative $f$ there exists $s_n$ such that $$\forall \varepsilon > 0 \exists n_0 : n > n_0 \implies |f(x) - s_n(x) | < \frac{\varepsilon}{\mu(\Omega)} \forall x \in \Omega$$ where $s_n \leq s_{n+1}$ and $\displaystyle s_n(x) = \sum_{i=1}^N \alpha_i \chi_{Y_{i,n}}(x)$ and $Y_n := \cup Y_{i,n}$.

Here's a better and more direct way to do it (you don't say how to do it, after all!). Note that the following argument doesn't use $\sigma$-compactness of $\Omega$.

The idea (the basic idea of all of Lebesgue's integration theory!) is to slice the set of values of $f$ into fine strips of height $2^{-n}$:

Assume $f \geq 0$ and put $A_{k,n} = \{x\in \Omega : 2^{-n} k \leq f(x) \lt 2^{-n}(k+1)\}$ and consider $s_n = 2^{-n} \sum\limits_{k=0}^{2^{2n}}k \cdot[A_{k,n}]$. Then $s_n$ approximates $f$ on $\{x \in \Omega\,:\,0 \leq f \lt 2^n + 2^{-n}\}$ up to a precision of $2^{-n}$ pointwise.

Thus $s_n \nearrow f$ pointwise a.e. and since $f \in L^1$ we have $s_n \in L^1$, in particular $s_n$ is supported on a set of finite measure.

By the dominated convergence theorem, then, we have $s_n \to f$ in $L^1$: note that $\|f-s_n\| = \int f-s_n$ and $0 \leq f-s_n \leq f$ while $s_n \to f$ pointwise a.e.

But, as was stated in the exercise you may assume this fact, so there would be no need to spell it out.

Here I think I need to assume $\mu(\Omega) < \infty$ but maybe that follows from what is given in the question.

The space $\mathbb{R}$ with Lebesgue measure is $\sigma$-compact (it is the union of the countably many compact intervals $[-n,n]$, for example) but it is certainly not of finite measure, so no, this does not follow from the assumptions.

Now one has a measurable function with finite (and therefore compact) support.

What? I hope this is a typo. Finite measure certainly doesn't imply compactness, not even boundedness: the set $\bigcup_{n=1}^{\infty} (n, n+2^{-n})$ has Lebesgue measure $1$ is open and unbounded, so...

Next one wants to make that into a continuous function.

b) Recall the Theorem of Lusin and Tietze’s Extension Theorem:

Theorem (Lusin’s Theorem). Let $\Omega$ and $\mu$ as above and $f\colon\Omega\to\mathbb R$ a $\mu$-measurable function with finite support $E$. Then for any $\delta > 0$ there exists a closed set $K\subset E$ such that $μ(E\setminus K) < \delta$ and $f$ is continuous on $K$.

Added: Note that "finite support" should read "support of finite measure" here.

Theorem (Tietze’s Extension Theorem for LCH spaces). If $\Omega$ is a locally compact Hausdorff space and $K \subset \Omega$ compact then any $f ∈ C(K, \mathbb R)$ can be extended to a function on $C_c(\Omega,\mathbb R)$ with supremums norm bounded by $|| f ||_\infty$.

Combine these theorems to show that $C_c(\Omega)$ is dense in $L_1$. You may need that $\mu$ is Radon.

Well, it is certainly a good idea to recall Lusin's theorem and Tietze's extension theorem from time to time, but they are actually not needed here.

We have already shown that each integrable $f \geq 0$ can be approximated in the $L^1$-norm by simple functions with finite support. It remains to show that a characteristic function can be approximated by continuous functions. I'm not spelling the reduction to that fact out, because I should leave something to you.

So let $A \subset \Omega$ be a set of finite measure. Since $\mu$ is a Radon measure on a $\sigma$-compact space (hence it is inner and outer regular on Borel sets of finite measure), we can find a compact subset $K \subset A$ and an open set $U \supset A$ such that $\mu(U \setminus K) \lt \varepsilon$. By Urysohn's lemma we can find a continuous function of compact support $g$ such that $0 \leq g \leq 1$, $g = 1$ on $K$ and $g =0$ outside $U$. This gives that $\int |[A] - g| \leq \mu(U \setminus K) \lt \varepsilon$, hence every characteristic function can be approximated arbitrarily well by continuous functions of compact support.

Answer b:

From a) one has a measurable function $s_n$ with finite support $Y_n$. To make it into a continuous function one can set it to be $0$ on $Y_n \backslash K$ where $K$ is a closed set such that $\mu(Y_n \backslash K) < \delta$ for some $\delta$. Let's call this modified function $\tilde{s_n}$. Then $$ \lim_{n \rightarrow \infty} || \tilde{s_n}(x) - f(x)||_1 = \lim_{n \rightarrow \infty} \int_{Y_n \backslash K} |s_n(x) - f(x)| d\mu = \lim_{n \rightarrow \infty} \int_{Y_n} |s_n(x) - f(x)| d\mu = 0$$

I don't understand this argument at all, I'm afraid. What exactly is $\tilde{s}_n$ and how exactly does that limiting argument work?

Here's a suggestion: use Lusin's theorem to find a closed set of finite measure $K$ such that $\mu(E\setminus K) \lt \delta$ on which $s_n$ is continuous. Use inner regularity of $\mu$ to find a compact set $C \subset K$ with $\mu(C \subset K) \lt \delta$. Apply Tietze's extension theorem to extend the restriction $s_n|_{C}$ to a continuous function of compact support $\tilde{s}_{n}$,close to $s_n$ in the $L^1$-norm.


I fancied typing up the answer myself. As I'll leave commenter's answer accepted I don't think anyone should be bothered by this.

a) For $\varepsilon > 0$ and $f \in L^1$ we want to find an $s$ such that $\| s - f \|_{L^1} < \varepsilon$ where $\mu (\operatorname{supp}{s}) < \infty $.

We may assume that $f \geq 0$ because if we can approximate non-negative functions then we can approximate all functions in $L^1$. To see this let $f \in L^1$. Then $f = f^+ - f^-$ and we can find $s^+$ and $s^-$ such that $\| f^+ - s^+\| < \frac{\varepsilon}{2}$ and $\| f^- - s^- \| < \frac{\varepsilon}{2}$ and hence $\| f - (s^+ - s^-) \| \leq \|f^+ - s^+\| + \| f^- - s^- \| < \varepsilon$.

If $f$ is non-negative we know that there is a sequence of step functions $s_n$ such that $s_n \to f$ pointwise and $0 \leq s_n \leq s_{n+1}$. We need to show that $s_n$ also converges to $f$ in norm, i.e. $\| f - s_n \|_{L^1} \to 0$. For this we observe that $|f(x) - s_n(x)| \leq |f(x)|$ and $f$ is integrable hence we can apply the Lebesgue dominated convergence theorem: $$ \lim_{n \to \infty} \| f - s_n \|_{L^1} = \lim_{n \to \infty} \int_\Omega |f(x) - s_n(x)| d\mu = \int_\Omega \lim_{n \to \infty} |f(x) - s_n(x)| d\mu = 0$$

To finish part a) we need to argue that $s_n$ have finite support. But this is clear: $\int_\Omega s_n d \mu = \sum_{i=1}^N \alpha_i \mu(Y_i) < \infty$ implies that $\mu(Y_i) < \infty$ because $s_n \in L^1$ and $s_n \geq 0$ hence $\mu (Y_i) < \infty$ for all $i$ and therefore $\mu(\operatorname{supp}{s_n}) = \mu (\bigcup Y_i) \leq \sum_{i=1}^N \mu(Y_i) < \infty$.


b) Now for $\varepsilon > 0$ we want to use $s \in L^1$ with finite support and $\| s - f\|_{L^1} < \frac{\varepsilon}{2}$ to construct an $\tilde{s}$ with compact support and $\| \tilde{s} - f\|_{L^1} < \varepsilon$.

First we use that $\mu$ is Radon (and therefore inner regular) to get a compact set $K_\delta \subseteq \operatorname{supp}{s}$ with $\mu(\operatorname{supp}{s} \setminus K_\delta) < \delta$ for all $\delta > 0$. Then because $\mu(K_\delta) < \infty$ we can apply Lusin's theorem to get a closed set $C_{\delta^\prime}$ with $f$ continuous on $C_{\delta^\prime}$ and $\mu(K_\delta \setminus C_\delta^\prime) < \delta^\prime$ for all $\delta^\prime > 0$. A closed subset of a compact set is compact and so $C_{\delta^\prime}$ is compact.

Now we use outer regularity of $\mu$ to get an open set $O_\tau$ such that $\mu(O_\tau \setminus \operatorname{supp}{s}) < \tau$ for all $\tau > 0$.

And we'll use the following version of Tietze's extension theorem:

Theorem (Tietze’s Extension Theorem for LCH spaces). Let $\Omega$ be locally compact, let $K \subset \Omega$ be compact and let $f: K \to \mathbb{R}$ be continuous. For every open set $U \supset K$ there exists a continuous function $g:\Omega \to \mathbb{R}$ with $\operatorname{supp}{g} \subset U$ and $\operatorname{supp}{g}$ compact such that $g|_K=f$.

Then we can apply this version of Tietze's theorem to extend $s|_{C_{\delta^\prime}}$ to a continuous and bounded function $\tilde{s} : \Omega \to \mathbb{R}$ which is $0$ outside $O_\tau$. Then $$ \| \tilde{s} - f \|_{L^1} \leq \int_\Omega |\tilde{s} - s| d \mu + \int_\Omega | f - s| d \mu < \| s \|_\infty 2 (\delta + \delta^\prime + \tau) + \frac{\varepsilon}{2}$$

Where the second last term is doubled because an error might occur on each side of the support.