12

Is the subset consisting of all integrable (or square integrable) smooth functions of the set of all integrable (or square integrable) functions, dense under the usual Euclidean or integral of absolute difference metric?

By smooth I mean derivatives of all orders exist.

Karthik C
  • 2,627
Rajesh D
  • 4,347

2 Answers2

26

Yes. In fact, by the Stone-Weierstrass theorem and the existence of smooth bump functions, smooth functions with compact support are uniformly dense in the space of continuous functions with compact support. Uniform density implies $L^2$ and $L^1$ density for functions with compact (and therefore finite measure) support, and since continuous functions with compact support are dense in $L^2$ and $L^1$, the result follows.

If you wanted to see this more directly, you can go through the iterations of approximating an arbitrary ($L^1$ or $L^2$) function with a bounded function with bounded support, then with a simple function, then with a step function, and finally approximate the step function with a smooth function using bump functions.

Jonas Meyer
  • 55,715
  • What about noncompact smooth functions ?...compactness is not imposed – Rajesh D Nov 01 '10 at 07:11
  • 2
    @Rajesh D: There are of course smooth functions without compact support in $L^1$ and $L^2$, but what I am saying is that if you consider the subset of smooth functions with compact support, that is already dense. A set containing a dense subset is dense. – Jonas Meyer Nov 01 '10 at 07:15
  • @Jonas Meyer: how could you approximate a noncompact function in $L^2$ with a smooth compact function ? Please explain. Your answer seems to me that it is applicable to space of compact functions and i am not able to uderstand how it is applicable to noncompact functions. – Rajesh D Dec 07 '10 at 03:15
  • @Rajesh: Let $f$ be an arbitrary function in $L^2$, with compact support or not. Consider the sequence $(f_n)$ defined by $f_n=f$ on $B(0,n)$ (the ball of radius $n$ centered at the origin) and $f_n=0$ elsewhere. Show that $f_n\to f$ in $L^2$. Each $f_n$ has compact support, so if you are satisfied with approximating functions with compact support with smooth functions, then you are done. – Jonas Meyer Dec 07 '10 at 03:45
  • @Rajesh: Note, however, that the 2 proof sketches I gave have nothing to do with assuming that the functions being approximated have compact support. It just simplifies the arguments to show that the approximation of arbitrary functions in $L^2$ can be done with smooth functions with compact support, which are only a subset of the smooth functions with arbitrary support. I advise you to work out the details of my second paragraph to better understand what is going on. The first step, for instance, is to reduce the problem to approximating bounded functions with bounded support. – Jonas Meyer Dec 07 '10 at 03:48
  • @JonasMeyer: I think there might be a subtlety your argument does not fully address, as follows: Let $f \in C_c(\mathbb{R}^n)$, and denote $k=m(\operatorname{supp}f) < \infty$. Now let $\epsilon >0$. The way I see of using the Stone-Weierstrass theorem is something like this:

    $\exists g \in C^{\infty}c(\mathbb{R}^n)$ such that $|g-f |{\sup} < \epsilon'=\frac{\epsilon}{k^{\frac{1}{p}}}$, hence $|g-f|p=\big( \int{\mathbb{R}^n}|g-f|^p \big)^{\frac{1}{p}} \stackrel{*}= \big(\int_{\operatorname{supp}f}|g-f|^p \big)^{\frac{1}{p}}<\epsilon' k^{\frac{1}{p}}=\epsilon$...

    – Asaf Shachar Feb 11 '16 at 20:12
  • @JonasMeyer: The problem is that equality $*$ is only valid if I can find such an approximating $g$ which vanishes outside $\operatorname{supp}f$ or control the rest of its $p$-norm somehow. I am not sure you get this automatically by the S-W theorem. If you can enlighten me about this point, I would be very grateful. – Asaf Shachar Feb 11 '16 at 20:13
  • @AsafShachar: Given such $f$, you could take $R>0$ such that $\operatorname{supp}f$ is contained the ball $B_R(0)$ and work in $C_0(B_R(0))$. There exists $g$ smooth with support contained in $B_R(0)$ such that $|g-f|_{\sup}<\varepsilon'=\frac{\varepsilon}{(c_n R^n)^{1/p}}$ where $c_n$ depends only on $n$ (or $c_n=6$ works for all $n$ I think). – Jonas Meyer Jun 07 '16 at 18:23
19

Jonas's argument is good. Another proof is: given $f \in L^p$ (here $p=1,2$), take the convolution of $f$ with a sequence of mollifiers $\eta_\epsilon$. Using properties of convolutions, it's easy to check that $f * \eta_\epsilon$ is a smooth function, and that $f * \eta_\epsilon \to f$ in $L^p$ as $\epsilon \to 0$. This has the advantage of being a little more direct.

Edit: For a reference, see Folland's Real Analysis, section 8.2.

The smoothness of $f * \eta_\epsilon$ is Proposition 8.10 and comes from differentiating under the integral sign in the convolution (with justification!), and choosing to put the derivative on $\eta_\epsilon$. Intuitively, it comes from the idea that convolution is an "averaging" operation and tends to smooth, smear, or blur rough areas of $f$ together, and so should be a smoothing operation. (The wikipedia article has a nice animation illustrating this.)

The fact that $f * \eta_\epsilon \to f$ in $L^p$ is Folland's Theorem 8.14 (a), and it's pretty elementary. He also has Proposition 8.17 which proves that $C^\infty_c$ is dense in $L^p$, but it sort of inexplicably starts by using the fact that $C_c$ is dense in $L^p$. I suppose this is used to get a compactly supported function, so that you can approximate $f \in L^p$ by functions which are not only smooth (which $f * \eta_\epsilon$ is) but also compactly supported (which $f * \eta_\epsilon$ need not be, although $\eta_\epsilon$ is). But an easier argument would be to first approximate $f$ in $L^p$ norm by a function $g$ which is compactly supported but not necessarily continuous; for example, $g = f 1_{[-N,N]}$ for large $N$ (this works by dominated convergence), and then apply mollifiers to $g$. Unless, of course, there is some subtlety that I've missed.

Edit 2: Indeed there is. Folland's 8.14 (a) relies upon the fact that translation is strongly continuous in $L^p$, which uses the density of $C_c$. So apparently it is not so easy to bypass this step, and that destroys a lot of the "directness" of my argument.

Nate Eldredge
  • 101,664
  • Let 'f' be a continous but nowhere differentiable function. Is f convolved with mollifier, a smooth function ? – Rajesh D Nov 02 '10 at 03:48
  • 2
    @Rajesh D: Yes. Indeed, $f$ can be much worse: if $f$ is any distribution and $\phi$ is a smooth function with compact support, then $f * \phi$ is a smooth function. – Nate Eldredge Nov 02 '10 at 05:52
  • could you please suggest a reference for the proof. – Rajesh D Nov 02 '10 at 07:31
  • the direct method of starting with convolution integral and differentiating doesnt work in this special case. – Rajesh D Nov 02 '10 at 07:31
  • @Rajesh, @Nate: For the proof of $f * \eta_\epsilon \to f$ in $L^p$ I need that the continuous functions with compact support are dense in $L^p$. Then it's not so direct any more. Can you do it without this denseness property? – Hendrik Vogt Nov 02 '10 at 15:54
  • I forget the details but I seem to recall that one should need very little for this proof. I'll look it up later on. – Nate Eldredge Nov 02 '10 at 16:00
  • @Hendrik: I don't see any need for such a condition on eta_epsilon, it follows directly from the definition of a dense subset of a metric space. – Rajesh D Nov 02 '10 at 17:57
  • @Nate: What baffles me is the smoothing property of the mollifier.I havent got to see any proof of that in any standard texts. If its true in any sense (apparently seem to be, from standard websites like Wikipedia), It looks like an axiom to me. – Rajesh D Nov 02 '10 at 18:03
  • @Rajesh D: I added some details. The smoothing property is nothing fancy. I don't know what you mean by "axiom". – Nate Eldredge Nov 02 '10 at 20:12
  • @Nate: 'and choosing to put the derivative on ηϵ<\sub>',here is the problem, if convolution is commutative then either of integrals should yield the same function which has only a single function as its first derivative. due to 'choosing', the result (smoothing property) is not obtained directly from the definition of convolution.The definition of convolution is being tampered. – Rajesh D Nov 03 '10 at 01:08
  • axiom : statement obtained by choice rather than by logical deductions. – Rajesh D Nov 03 '10 at 01:27
  • also see : http://math.stackexchange.com/questions/8711/derivative-commuting-over-integral – Rajesh D Nov 03 '10 at 03:17
  • 1
    @Rajesh, @Nate: In the proof of Theorem 8.14, Folland uses Proposition 8.5. In the proof of 8.5 he has to start from continuous functions with compact support, and then he uses the denseness of those functions. This is exactly what I meant in my above comment. – Hendrik Vogt Nov 03 '10 at 16:01
  • @Hendrik Vogt: Right, and in my amended answer above I point out why this is not needed. – Nate Eldredge Nov 03 '10 at 17:21
  • @Nate: I just don't see how you prove the convergence $f * \eta_\epsilon \to f$ if $f$ is not continuous. Can you explain this, please? – Hendrik Vogt Nov 03 '10 at 17:29
  • @Hendrik: I apologize. I did not read your comment carefully. You are right: the assumption of $C_c$ being dense is still implicit in the argument, via Folland's 8.5. So perhaps it is not as simple as I thought. – Nate Eldredge Nov 03 '10 at 19:50
  • @Nate: I've always been quite sure that you need the denseness argument in the proof. When I read your post I thought you had some magic trick to avoid this. OK, now I'm back to "rather sure it can't be avoided". Thanks for your answer. – Hendrik Vogt Nov 04 '10 at 10:46
  • @Nate: Convolution need'nt always be looked at as a sort of averaging or smoothing.It depends on the function used for the convolution.(on a statement from your answer.),(it may not matter in the current context, or may be, if its possible to construct a reverse argument(Cant we ever destroy a mollifier by convolution?)). What i need is an argument from the basic principles of calculus. – Rajesh D Nov 04 '10 at 12:03