Is $C_c^\infty$ dense in $W^{1,p}\cap C_0$? Let $\Omega\subset\mathbb{R}^N$ be a bounded open set. I was wondering if $C_c^\infty(\Omega)$ is dense in $W^{1,p}(\Omega)\cap C_0(\Omega)$ with $1\leq p<\infty$.
Here $C_0(\Omega)$ is the space of functions of $C(\overline{\Omega})$ which are zero on $\partial\Omega$, and the space $W^{1,p}(\Omega)\cap C_0(\Omega)$ is endowed with the norm $\|\cdot\|_{W^{1,p}}+\|\cdot\|_{L^\infty}$.
Thanks in advance.
 A: Take a function $f$ and convolve with a Mollifier $\phi_{\epsilon}$ and convert it into compactly supported smooth function $(1_{B_r(0)} \times f) * \phi_{\epsilon}$ where $1_{B_r(0)}$ is an indicator function of compact set $Closure(B_r(0))$. It is known that $$ \lim_{\epsilon \rightarrow 0} \lim_{r \rightarrow \infty} (1_{B_r(0)} \times f)  * \phi_{\epsilon} \rightarrow f.$$
Since $\Omega$ is a bounded set, we dont have to worry about compactness since $f|_{\partial \Omega} = 0$.
We now prove that closure of $C^{\infty}(\Omega + B_{\epsilon}(0))$ (when functions are restricted to $\Omega$) contains $W^{1,p}(\Omega) \cap C_0(\Omega)$.
Hence enough to prove: $$f  * \phi_{\epsilon} \rightarrow f$$
Let $f \in C_0(\Omega)$,
$$f_{\epsilon}(x)-f(x) = \int (f(x-y)-f(x)) \phi_{\epsilon}(y) dy $$
$$|f_{\epsilon}(x)-f(x)| \leq \int |f(x-y)-f(x)| \phi_{\epsilon}(y) dy $$
Since $f$ is uniformly continuous as $\Omega$ is a bounded set and $f|_{\partial \Omega} = 0$ and since $\phi_{\epsilon}$ is supported in the set $B_{\epsilon}(0)$, we have by choosing $\epsilon$ sufficiently small:
$$|f_{\epsilon}(x)-f(x)| \leq \epsilon_f \int  \phi_{\epsilon}(y) dy $$
$$|f_{\epsilon}(x)-f(x)| \leq \epsilon_f$$
Hence $f_{\epsilon} \rightarrow f$ uniformly.
By uniform convergence, we also have that,
$$\int |f_{\epsilon}(x)-f(x)|^p dx \leq \epsilon_f^p \times \mu(\Omega)$$
Hence $f_{\epsilon} \rightarrow f$ in $L_p$.
Now observe that:
$$f'_{\epsilon}(x) = \int f'(x-y) \phi_{\epsilon}(y) dy $$ and we repeat the same proof as above to conclude that $f_{\epsilon} \rightarrow f$ in $||.||_{W^{1,p}} + ||.||_{L_{\infty}}$. To repeat the proof, we might need the condition $f'$ is continuous and $f'|_{\partial \Omega} = 0$ OR $f'$ is uniformly continuous. Try this out and let me know.
Hence any $f_{\epsilon} \rightarrow f$ for any $f \in W^{1,p}(\Omega) \cap C_0(\Omega)$
You can also find some materials in:
http://wwwarchive.math.psu.edu/anovikov/acm105/mollifiers.pdf
EDIT:
The idea is to work with $\Omega'$ where $\Omega'$ is slightly larger than $\Omega$ such that $Closure(\Omega) \subset M \subset \Omega'$ where $M$ is a compact set. Extend the $L_p$ function $f'$ to $\Omega'$. we need to set $f'(x) = 0$, $\forall x \in \Omega' \setminus \Omega$.
Using density of $C(\Omega')$ in $L^p(\Omega')$, one can approximate $f'$ by a continuous function $g$ on $\Omega'$ and approximate the continuous function $g$ by smooth function $g_{\epsilon}$ on $Closure(\Omega)$ by using uniform continuity of $g$ on $M$ and use the inequality $|f'_{\epsilon}-g_{\epsilon}|_{L_p(\Omega)} \leq |f'-g|_{L_p(M)}$ and show that $f'_{\epsilon} \rightarrow f'$ on $\Omega$ by triangle inequality.
Thus completing the proof by observing $|f'-g|_{L_p(\Omega)} \leq |f'-g|_{L_p(M)} \leq |f'-g|_{L_p(\Omega')}$. 
The following link has some of the above details. See Theorem 1.28,Page 18,19, in https://www.math.ucdavis.edu/~hunter/m218a_09/Lp_and_Sobolev_notes.pdf
EDIT: In the above we have proved that closure of $C^{\infty}( \Omega + B_{\epsilon}(0))$ (when functions are restricted to $\Omega$) contains $W^{1,p} \cap C_0(\Omega)$. Please see below for the argument that $C_{c}^{\infty}(\Omega)$ (smooth function on compact set) is dense.
Its enough to prove $(f 1_K) * \phi_{\epsilon} \rightarrow f * \phi_{\epsilon}$ i.e., $(f 1_{\Omega \setminus K}) * \phi_{\epsilon} \rightarrow 0$. Now $$|(f 1_{\Omega \setminus K}) * \phi_{\epsilon}| = |\int (f 1_{\Omega \setminus K})(x-y) * \phi_{\epsilon}(y) dy|  \leq \int |(f 1_{\Omega \setminus K})(x-y)| * \phi_{\epsilon}(y) dy.$$
Since $f|_{\partial \Omega} = 0$ and $\Omega$ is a bounded set, by uniform continuity of $f$, there exists $K = K_{\gamma, \epsilon} \subset \Omega$, $K_{\gamma, \epsilon}$ compact such that $|f(x)| \leq \gamma \epsilon^{n+1}$, $\forall x \in \Omega \setminus K_{\gamma, \epsilon}$. Note that $|\phi_{\epsilon}(y)| \leq 1/\epsilon^n$ (see pdf in the link above). Using this, we get:
$$|(f 1_{\Omega \setminus K}) * \phi_{\epsilon} (x)|\leq \int |(f 1_{\Omega \setminus K})(x-y)| * \phi_{\epsilon}(y) dy \leq \gamma \epsilon \mu(\Omega).$$ To prove derivative, converges use exactly same argument with $\phi'_{\epsilon}$ in place of $\phi_{\epsilon}$ and use $|\phi'_{\epsilon}(y)| \leq 1/\epsilon^{n+1}$.
EDIT:
As @rubik pointed out in the comments the proof is correct/complete when we have $$\mu(\Omega \setminus K_{\frac{3}{2} \times d_{\gamma}})^{1/p} \leq constant \times d_{\gamma}.$$
as $d_{\gamma} \rightarrow 0$, where we can define: $K_{d} = \{x: x \in \Omega, dist(x,\partial \Omega) \geq d\}$ and set $K_{\gamma,\epsilon} = K_{d_{\gamma}}$ for $d_{\gamma}$ which depends on continuity of $f$ at the boundary. This is true atleast for open balls/rectangles of any radius $r$  in any $N$ dimensional space when $p=1$.
