On the Gaussian Poincare inequality Let $X$ be a standard normal random variable. Then, for any differentiable $f:\mathbb{R}\to\mathbb{R}$ such that $\mathbb{E}f(X)^2<\infty,$ the Gaussian Poincare inequality states that
$$\mathrm{Var}(f(X))\leq \mathbb{E}[f^\prime(X)^2].$$
Suppose this inequality is proved for all functions that are twice continuously differentiable with compact support. Can you please tell me the precise argument that allows one to extend this to all differentiable functions $f$ with $\mathbb{E}f(X)^2<\infty$?
 A: Let $f$ be absolutely continuous with $E[f'(X)^2] < +\infty$.
Assume that $f_n$ is a sequence of functions, infinitely differentiable with compact support, such that
$$E[(f_n(X) - f(x))^2] + E[(f'(X) - f_n(X))^2] \to 0.$$
Then by the triangle inequality for $E[(\cdot)^2]^{1/2}$, we have $E[f_n^2(x)]\to E[f^2(X)]$ and $E[f_n'(X)^2]\to E[f'(X)^2]$, as well as $E[f_n(X)]\to E[f(X)]$ by Jensen's inequality by a similar argument. This implies $Var[f_n(X)]\to Var[f(X)]$, so all we have to do is find a sequence $f_n$ such that the above display holds.
The Sobolev space $W^{1,2}(\gamma_p)$ of weakly differentiable functions $f$ with $E[f(g)^2 + \|\nabla f(g)\|^2]<+\infty$ for $g\sim N(0,I_p)$ is actually well studied, see for instance section 1.5 in the book Gaussian Measures by Bogachev.
In particular this space is equal to the completion of the set of infinitely differentiable functions with compact support with respect to the norm
$\|f\|_{2,1} = E[f(g)^2]^{1/2} + E[\|\nabla f(g)\|^2]^{1/2}$. With this definition, set of infinitely differentiable with compact support is dense and for any $f\in W^{1,2}(\gamma_p)$ there exists a sequence of infinitely differentiable with compact support $f_n$ such that $\|f_n - f\|_{2,1} \to 0$. The case $p=1$ is of interest for the question, but the same strategy would work verbatim for $p>1$ and the Gaussian Poincare inequality $Var[f(g)] \le E[ \|\nabla f(g)\|^2]$.
