--- > [!theorem] Theorem. ([[Lp density of test functions]] on $\mathbb{R}^{n}$) > >1. For every $1 \leq p < \infty$, [[bump function|the set]] $C_{c}^{\infty}(\mathbb{R}^{n})$ is [[dense]] [[Lp-norm|in]] $L^{p}(\mathbb{R}^{n})$. >2. $C_{c}^{\infty}(\mathbb{R}^{n})$ is *not* [[dense]] in $L^{\infty}(\mathbb{R}^{n})$. ^theorem > [!proof] > Well don't actually have to invoke simple functions at all (nor limits all the way). Just say: given $\eta>0$, want to find some $f_{c} \in C_{c}^{\infty}(\mathbb{R}^{n})$ satisfying $\|f-f_{c}\|_{L^{p}(\mathbb{R}^{n})}<\eta$. Then proceed separately with the 'compact support' and 'smooth' parts. First truncate $f$ to have compact support up to small error, $f=f_{c}+\text{err}$ for $f_{c}$ having compact support and $\|\text{err}\|_{L^{p}(\mathbb{R}^{n})}<\eta/2$. Then regularize $f_{c}$ with a family of [[approximation of identity|mollifiers]] $\{ \varrho_{\varepsilon} \}_{\varepsilon>0} \subset C_{c}^{\infty}(\mathbb{R}^{n})$ to obtain a [[sequence]] $(\varphi_{\varepsilon} ) \to f_{c}$ in $L^{p}$ (using [[approximation in Lp of identity]]) as $\varepsilon \to 0$. For $\varepsilon$ small enough, $\|\varphi_{\varepsilon}-f_{c}\|< \eta / 2$. Now with $f_{\eta}:=\varphi_{\varepsilon}$, $\|f - f_{\eta}\|_{L^{p}(\mathbb{R}^{n})} \leq \|f-f_{c}\|_{L^{p}}+\|f_{c}- \varphi_{\varepsilon}\| < \eta / 2+ \eta / 2= \eta$ > as desired. Let $\Omega$ be a [[bounded set|bounded]] open set in $\mathbb{R}^{n}$ with [[Lipschitz boundary]]. We obtain the following corollary: (Sheet 1, Q5) > [!theorem] Theorem. ([[Lp density of test functions]] on $\Omega$) > >1. For every $1 \leq p < \infty$, [[bump function|the set]] $C_{c}^{\infty}(\Omega)$ is [[dense]] [[Lp-norm|in]] $L^{p}(\Omega)$. >2. $C_{c}^{\infty}(\Omega)$ is *not* [[dense]] in $L^{\infty}(\Omega)$. ^theorem **Proof of corollary.** #### (i) We will show that for all $f \in L^{p}(\Omega)$ there exists a sequence of smooth functions $\Omega \to \mathbb{R}$ [[converge|converging]] to $f$, and that in fact these functions can be taken to have [[compact]] [[support]]. Shave off the [[boundary]] of $\Omega$ by [[distance from point to set|defining]] $\Omega_{k}:= \left\{ x \in \Omega: \text{dist}(x, \text{Bd }\Omega) > \frac{1}{k} \right\}, \ \ f_{k}:=f \chi_{\Omega_{k}}.$ Note that $\text{supp }f_{k}=\overline{\{ x \in X: f_{k}(x) \neq 0 \}}$ is [[closed set|closed]] by construction, and is [[bounded set|bounded]],[^1] hence is [[compact]] by [[Heine-Borel theorem|Heine-Borel]]. ![[Pasted image 20251025123411.png|300]] The strategy is to: 1. Show that each $f_{k}$ can be approximated by elements of $C^{\infty}_{c}(\Omega)$; 2. Show $(f_{k})\to f$. The result then follows from [[norm|the two-epsilon trick for normed spaces]]. **1.** Let $\varrho_{\varepsilon} \in C^{\infty}_{c}(\mathbb{R}^{n})$ be a [[bump function]] supported on $B_{\varepsilon}(0)$ and satisfying $\int _{\mathbb{R}^{n}} \varrho=1$. Extending each $f_{k}$ by zero to a function $\hat{f}_{k}:\mathbb{R}^{n} \to \mathbb{R}$. Then $h_{\varepsilon, k}=\varrho_{\varepsilon} * \hat{f}_{k}:\mathbb{R}^{n} \to \mathbb{R}$ is [[continuously differentiable|smooth]] because $\varrho$ is smooth (cf. Lemma 1.5.5.). Moreover, $\text{supp } \varrho_{\varepsilon} * \hat{f}_{k} \subset \underbrace{ \text{supp }\varrho_{\varepsilon} }_{ B_{\varepsilon}(0) } + \text{supp }\hat{f}_{k} \subset \left\{ x: \text{dist}(x, \text{Bd }\Omega) \geq \frac{1}{k}-\varepsilon \right\}.$ For $0<\varepsilon <1/k$, this set lives in $\Omega$. $\Omega$ is bounded, hence so is $\text{supp }h_{\varepsilon, k}$; [[Heine-Borel theorem|Heine-Borel]] then lets us restrict to $h_{\varepsilon, k} \in C^{\infty}_{c}(\Omega)$. Now Theorem 1.5.7 applies to yield, for each $k$, a [[sequence]] $(h_{m}) \to f_{k}$ of elements in $C_{c}^{\infty}(\Omega)$. **2.** We have $\|f-f_{k}\|_{p}= \int _{\Omega} |f - f \chi_{\Omega_{k}}|^{p}=\int _{\Omega} |f|^{p} \chi_{\Omega_{k}^{c}} .$ Since $\Omega_{k} \uparrow \Omega$, $1_{\Omega_{k}^{c}} \downarrow 0$ [[pointwise converge|pointwise]]. Now the [[Dominated Convergence Theorem]] with majorant $|f|^{p}<inf$ gives $\lim_{k \to \infty} \|f-f_{k}\|_{p}=0$, as required. The result now follows from the lemma below: ![[CleanShot 2025-10-25 at [email protected]]] #### (ii) Since $\|f_{n}-f\|_{\infty} \to 0$, there exists a [[measure zero]] set $N$ such that $f_{n} \to f$ in [[uniform metric|sup norm]] on $\Omega- N$, i.e. $f_{n}\to f$ [[uniform convergence|uniformly]] on $\Omega-N$. Applying the [[uniform limit theorem]] on $\Omega - N$, there exists [[continuous]] $g$ equal to $f$ [[almost-everywhere]] on $\Omega$. Thus the limit of any sequence in $C_{c}^{\infty}(\Omega)$ wrt the $L^{\infty}$-form has a [[continuous]] representative. But not every element of $L^{\infty}(\Omega)$ has a [[continuous]] (e.g. $\chi_{B}$ for $B \subset \Omega$ an open ball does not). Thus there is a proper containment $\overline{C_{c}^{\infty}(\Omega)} \subsetneq L^{\infty}(\Omega)$. > [!proof]- Proof. ([[Lp density of test functions]]) > ~ ---- #### ----- #### References > [!backlink] > ```dataview > TABLE rows.file.link as "Further Reading" > FROM [[]] > FLATTEN file.tags as Tag > WHERE Tag = "#definition" OR Tag = "#theorem" OR Tag = "#MOC" OR Tag = "#proposition" OR Tag = "#axiom" > GROUP BY Tag > ``` > [!frontlink] > ```dataview > TABLE rows.file.link as "Further Reading" > FROM outgoing([[]]) > FLATTEN file.tags as Tag > WHERE Tag = "#definition" OR Tag = "#theorem" OR Tag = "#MOC" OR Tag = "#proposition" OR Tag = "#axiom" > GROUP BY Tag > ```