A uniform limit of Sobolev functions is Sobolev? Let $\Omega \subseteq \mathbb{R}^n$ be an open set, and suppuse $f_n \in W^{1,p}(\Omega) \cap C(\Omega)$ uniformly converge to some $f$. Is it true that $f \in W^{1,p}(\Omega)$?
I guess not, but I don't have a counter example.
 A: For a counterexample, let $n=1$, $\Omega=(0, 1)$, and let $f$ be any continuous function on $[0, 1]$ that is not in $W^{1,p}(\Omega)$ (e.g., $f(x) = x\sin(1/x)$, or take the Weierstrass function for extra emphasis.) Recall that any continuous function on $[0, 1]$ is a uniform limit of polynomials.
However, the answer is yes if $1<p<\infty$ and the $W^{1,p}$ norms of $f_n$ are bounded by some constant independent of $n$. Indeed, 


*

*Since $W^{1,p}(\Omega)$ is reflexive, closed balls are weakly compact; hence, there is a weakly convergent subsequence $f_{n_k}\to g$, where $g\in W^{1,p}(\Omega)$. 

*We have $f_{n_k}\to f$ uniformly, hence $f_{n_k}\to f$ in the sense of distributions. We also have $f_{n_k}\to g$ weakly, hence $f_{n_k}\to g$ in the sense of distributions. And since a distributional limit is unique, $f=g$. 

*Conclusion: $f\in W^{1,p}(\Omega)$.


The above argument still works for $p=\infty$, using weak* topology. It fails for $p=1$, and so does the result: a bounded sequence in $W^{1,1}$ may converge uniformly to a function that is not in $W^{1,1}$. 
