This problem was asked in here. I need to ask something.
Provide details for the following alternative proof that if $u \in H^1(U)$, then $$Du = 0 \text{ a.e. } \, \text{ on the set } \{u=0\}. $$ Let $\phi$ be a smooth, bounded and nondecreasing function, such that $\phi'$ is bounded and $\phi(z)=z$ if $|z| \le 1$. Set $$u^\epsilon(x) := \epsilon \phi(u/\epsilon).$$ Show that $u^\epsilon \rightharpoonup 0$ weakly in $H^1(U)$ and therefore $$\int_U Du^\epsilon \cdot Du \, dx = \int_U \phi'(u/\epsilon) |Du|^2 \, dx \to 0.$$ Employ this observation to finish the proof.
I solved it under 2 assumptions: $U$ is bounded, and $C_c^{\infty}(U)$ is dense in $L^2(U)$. The proof is at below.
1) Is the assumtion that $U$ is bounded essential? If not, how to prove without this assumption?
2) Is it true that $C_c^{\infty}(U)$ is dense in $L^2(U)$ for any open set $U \subset \Bbb R ^n$? I guess this answer will be negative, since I found only that $C_c^{\infty}(\Bbb R ^n)$ is dense in $W^{1,p}(U)$ ($1 \le p < \infty$) if $U$ has boundary of class $C$ (Leoni, Thm10.29). But then how can I solve this problem?
My proof: To show $u^\epsilon \to 0 $ weakly in $H^1$, we need to show that $u^\epsilon, D_{x_i} u^\epsilon \to 0$ weakly in $L^2$.
For $v \in L^2$, $|| v u^\epsilon||_1 \le ||v||_2 ||u^\epsilon||_2 \le ||v||_2 \epsilon M vol(U) \to 0$ (as $\epsilon \to 0$) since $|u^\epsilon| \le \epsilon M$ for some $M>0$. So $u^\epsilon \to 0$ weakly in $L^2$.
Since $C_c^{\infty}(U)$ is dense in $L^2(U)$, $\exists v_n \to v$ in $L^2$. Then $||(v-v_n)D_{x_i} u^\epsilon||_1 \le ||v-v_n||_2 ||D_{x_i}u^\epsilon||_2 \le ||v-v_n||_2 M' || D_{x_i}u ||_2$ since $|D_{x_i}u^\epsilon| = |\phi' D_{x_i}u| \le M' |D_{x_i}u|$. Since $\int v D_{x_i} u^\epsilon = \int (v-v_n) D_{x_i} u^\epsilon + \int v_n D_{x_i} u^\epsilon$ and $\int v_n D_{x_i} u^\epsilon= - \int u^\epsilon D_{x_i} v_n $, $D_{x_i} u^\epsilon \to 0$ weakly in $L^2$.
The result follows as in here