Sobolev space on a closed subset Hi I have a question about Sobolev spaces.
Let $U \subset \mathbb{R}^{d} $ be a bounded open subset and $dx$ be a Lebesgue measure on $U$ 
\begin{align}
W^{1,2}(U):=\left\{u \in L^{2}(U;dx): \frac{\partial u}{\partial x_{i}} \in L^{2}(U;dx), 1\leq i \leq d \right\}
\end{align}
$W^{1,2}(U)$ becomes a Hilbert space with the following inner product:
\begin{align}
(u,v)=\int uv dx+\sum_{i=1}^{d}\int \frac{\partial u}{\partial x_{i}}\frac{\partial v}{\partial x_{i}}dx
\end{align}
$\displaystyle W_{0}^{1,2}(U):=\overline{C_{0}^{\infty}(U)}^{\|\cdot\|_{W^{1,2}}} $ i.e. $W_{0}^{1,2}(U)$ is the completion of $C_{0}^{\infty}(U)$ w.r.t. $\|\cdot\|=(\cdot,\cdot)^{1/2}$
I know that in general $W^{1,2}_{0}(U)\neq W^{1,2}(U)$.
Question Let $F$ be a closure of $U$ and $\partial F$ is $C^{1}$. Then
$W^{1,2}_{0}(F)= W^{1,2}(F)$ holds? Do you know any good references that cover this?
Thank you in advance.

Since $U$ is a bounded domain, its closure $F=\bar U$ is compact.
Therefore any (smooth) function $F\to\mathbb R$ is compactly supported and so $C_0^\infty(F)=C^\infty(F)$.
Consequently $W^{1,2}_0(F)=W^{1,2}(F)$.
It is possible that someone prefers to work with a closed set instead of an open one (as in the case of manifolds with boundary) and means $W^{1,2}_0(F)=W^{1,2}_0(\operatorname{int}F)$ (and similarly for $C^\infty_0(F)$).
That is, things might depend on the source you are reading, so beware.
