# $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.

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$$

• Thanks! Where do you get the increasing sequence from? $\sigma$-finite doesn't give you that: en.wikipedia.org/wiki/%CE%A3-finite_measure Commented Sep 24, 2011 at 6:49
• Did you use the Tietze theorem anywhere? Commented Sep 24, 2011 at 6:54

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.

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.

• @Matt: Sounds good, yes $L^1$ is the crucial point: this yields that $Y_n$ in your notation has finite measure. Do something like this: choose $n$ so large that $\|f-s_n\| \lt \varepsilon / 3$, choose $\delta = \varepsilon/2\|s_n\|_\infty$, choose an open set $U \supset C$ such that $\mu(U\smallsetminus C) \lt \delta$. Choose a Tietze extension $\bar{s}_n$ of $s_n$ and multiply it by a continuous function $0 \leq h \leq 1$ with compact support contained in $U$ and $h|_C = 1$. Put $\tilde{s_n} = h \bar{s}_n$. Commented Sep 25, 2011 at 15:08
• Then $$\|f-\tilde{s}_n\|_1 \leq \|f-s_n\|_1 + \|s_n-\tilde{s}_n\| \leq \varepsilon/3 + \int_{Y_n\setminus C} \|s_n\|_\infty + \int_{U\setminus C} \|s_{n}\|_{\infty} = \varepsilon.$$ Commented Sep 25, 2011 at 15:10
• @Matt: I chose $h$ to have compact support, hence so has $h\bar{s}_n$. Sorry, I should have written $\delta = \varepsilon/3\|s_n\|$ above. Note that the the whole argument yields a sharpening of Lusin's theorem by proving that we can find a continuous function coinciding with $f$ on a "large set" (in terms of measure) and arbitrarily close in the $L^1$-norm (that's of course the point of the exercise :). Commented Sep 25, 2011 at 17:02
• Note that this is also useful for your other exercise on density of smooth functions in $L^1(\mathbb{R}^n)$. Just convolve $\tilde{s}_n$ with a mollifier with $\varepsilon$ small to get a smooth function $g = \varphi_{\varepsilon} \ast \tilde{s}_n$ of compact support close to $f$ in the $L^1$-norm. Commented Sep 25, 2011 at 17:08
• @Matt: Reading your last comment again, I should probably insist on the following point: a continuous function $h: \Omega \to \mathbb{R}^n$ is continuous on all of $\Omega$. Closed support $S$ and $h|_S$ continuous is not sufficient for $h$ itself to be continuous on $\Omega$. Why should $h$ approach zero towards a boundary point of $S$? (were $h$ continuous this would have to happen by definition of support). Think of a characteristic function of a closed set, for example. That's why you need something like Tietze to extend your function to a continuous function on all of $\Omega$. Commented Sep 26, 2011 at 12:29

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.

• Dear Matt, I don't understand why $\bar{s}$ is continuous. You have a continuous and bounded function on the open set $O_{\tau}$, and you have simply extended it by zero. This typically doesn't result in a continuous function. (Think about the constant function $1$ on the open interval $(0,1)$, extended by zero to the entire real line.) Regards, Commented Jan 3, 2012 at 19:57
• Dear @MattE, thanks for pointing this out. I think it's fixed now. Commented Jan 3, 2012 at 22:42