On the Continuity of Sobolev Functions The statement is simple. Further discussion follows. Does there exist a proof of the following lemma which doesn't make use of the fact that Schwartz functions or test functions are dense in the Sobolev space?

Lemma: Let $d$ be a positive integer, $\Omega$ a measurable subset of $\mathbb{R}^d$, and $p \geq 1$ a real number. If $f \in W^{k,p}(\Omega)$ for every $k = 0,1,\ldots,$ then $f$ is almost everywhere equal to a continuous function on $\Omega$.

If needed, $\Omega$ can be whatever you want it to be, but I would prefer to not infringe upon $\Omega$'s free will, if possible.

Apparently, this fact is at least true for $\Omega = \mathbb{R}^d$. According to Exercise 33 in Terrence Tao's blog post (link), we can find $k$ great enough that $W^{k,p}(\mathbb{R}^d)$ embeds into $W^{1,2d}(\mathbb{R}^d)$. Then, by Hölder-Sobolev embedding, $W^{1,2d}(\mathbb{R}^d)$ embeds into $C^{0,\alpha}(\mathbb{R}^d)$ for some $\alpha$, the exact value of which is not consequential. Overall,
$
    W^{k,p}(\mathbb{R}^d)
\hookrightarrow
    W^{1,2d}(\mathbb{R}^d)
\hookrightarrow
    C^{0,\alpha}(\mathbb{R}^d)
$
for some $k$ which has to be chosen arbitrarily large given arbitrarily large $d$. In fact, if I'm not mistaken, this reasoning generalizes to show that $W^{\infty,p}(\mathbb{R}^d) \hookrightarrow C^\infty(\mathbb{R}^d)$ where $W^{\infty,p}(\Omega) := \bigcap_{k=0}^\infty W^{k,p}(\Omega).$
I admit that I, myself, still can't articulate the proof of either the Sobolev embedding theorem or the aforementioned Exercise. However, assuming I haven't misstated them, that isn't the present concern. In summary, those embedding theorems both feel like they might be overkill, don't they? Is there not a direct proof?
References are never a bad thing.
Thank you.
 A: If you're interested in avoiding density arguments as much as possible, you might be interested in the following line of reasoning. It somehow reduces the dependence on density.
$\newcommand{\R}{\mathbb{R}}$
$\newcommand{\vp}{\varphi}$

Lemma 1. If $u \in W^{1,1}((a,b))$, then $u$ has a continuous representative.

Proof. Consider the distributional derivative $u' \in L^1((a,b))$ and the auxiliary function
$$
v(x) = \int_a^x u'(t) dt.
$$
It is easily checked that $v'=u'$ in the distributional sense. Indeed, for any $\vp \in C_c^\infty((a,b))$ we have
\begin{align*}
\int_a^b \vp'(x) v(x) dx 
& = \int_a^b \int_a^x \vp'(x) u'(t) dt dx \\
& = \int_a^b \int_a^b \vp'(x) u'(t) \chi_{t<x} dt dx \\
& = \int_a^b \int_t^b \vp'(x) u'(t) dx dt \\
& = \int_a^b (\vp(b)-\vp(t)) u'(t) dt \\
& = - \int_a^b \vp(t) u'(t) dt 
\end{align*}
by an application of Fubini's theorem. Hence, the function $u-v$ has zero distributional derivative. Let us use the following lemma as a black box:

Lemma 2. If $w \in L^1((a,b))$ and $w' = 0$ in the distributional sense, then $w$ is constant a.e.

Using this, we infer that $u-v$ is constant a.e. and hence
$$
u(x) = v(x)+c \quad \text{for a.e. } x \in (a,b),
$$
where $v$ is a continuous function as an integral of $u' \in L^1$.

Remark 1. I was not able to justify Lemma 2 without some kind of density argument. For example:

*

*One can consider a sequence of mollifications $w_\varepsilon = w * \vp_\varepsilon$. The distributional derivative of $w_\varepsilon$ is $w_\varepsilon' = w' * \vp_\varepsilon = 0$, but since $w_\varepsilon$ is smooth, then also $w_\varepsilon' = 0$ in the classical sense, so $w_\varepsilon$ is constant. At the same time, $w_\varepsilon \to w$ in $L^1$, so $w$ also needs to be constant. We're not using the density of $C_c^\infty$ in $W^{1,1}$ here, but we're almost proving it.

*Alternatively, one could fix $x,y \in (a,b)$ and exploit the condition $\int w \vp' = 0$ for smooth functions $\vp$ for which $\vp' \approx \delta_x - \delta_y$. Applying Lebesgue's differentiation theorem, we infer that $w(x) = w(y)$ for all Lebesgue points $x,y$. But again, some density argument is hidden in the proof of Lebesgue's differentiation theorem.

Remark 2. With some care, one should be able to generalize this reasoning to $\R^n$, as in ktoi's answer.
A: As mentioned in the comments I don't think there's a way to avoid density in some form, but there is a relatively simple and self-contained way to prove this result. Broadly one proceeds as follows:

*

*Localise by multiplying by a cut-off, and show the cutoff also lies in $W^{k,1}$ for all $k \geq 0.$

*By mollifying we can assume this localised function is smooth.

*Iteratively using the fundamental theorem of calclus prove the embedding $W^{d,1} \hookrightarrow C.$

*Pass to the limit to conclude.

The idea is that continuity is a local condition, which allows us to localise. In this case the approximation argument follows by a straightforward mollification. Finally I use a relatively simple variant of the Sobolev inequality which can be proven without reference to the general inequality. I will make this construction precise below; here $Q_r(x)$ denotes the open cube in $\Bbb R^d$ centered at $x$ with side-length $2r.$
Step 1: Given any $Q_{3\rho}(x) \subset \Omega,$ choose a cutoff $\chi \in C^{\infty}_c(\Omega)$ such that $\chi \equiv 1$ on $Q_{\rho}(x)$ and vanishes outside $B_{2\rho}(x).$ Then $v = \chi u$ can be checked to lie in $W^{k,q}(\Omega)$ for all $k \geq 0$ and $1 \leq q \leq p;$ the case $q=p$ follows using the Leibniz rule and the fact that all derivatives of $\chi$ are bounded, and in general we can use Hölder's inequality since $v$ is supported in the bounded domain $B_{2\rho}(x).$ Also note $v = u$ on $Q_{\rho}(x)$ still.
Step 2: Now if $\rho_{\varepsilon}$ is a standard mollifier, we have $v_{\varepsilon} = \rho_{\varepsilon} \ast (\chi u)$ is smooth and is supported in $\Omega$ provided $\varepsilon < 1.$ By standard properties of mollifiers we know that $v_{\varepsilon} \to v$ in $W^{k,q}(\Omega)$ for all $k \geq 0$ and $1 \leq q \leq p.$ We will prove a uniform estimate for $v_{\varepsilon}$ and use this convergence to pass to the limit.
Step 3: Since each $v_{\varepsilon}$ is smooth, observe by the fundamental theorem of calculus that for any $z \in Q_{3\rho}$ we have
$$ v_{\varepsilon}(x+z) = \int_0^{z_d} \int_0^{z_{d-1}} \dots \int_0^{z_1} \partial_{x_d}\partial_{x_{d-1}} \dots \partial_{x_1}v_{\varepsilon}(x_1+t_1,\dots,x_d+t_d) \,\mathrm{d}t_1\dots \,\mathrm{d}t_{d-1}\,\mathrm{d}t_d. $$
Hence taking absolute values we get
$$ |v_{\varepsilon}(x+z)| \leq \int_{-3\rho}^{3\rho} \dots \int_{-3\rho}^{3\rho} |\nabla^du(x_1+t_1,\dots,x_d+t_d)| \,\mathrm{d}t_1\dots \,\mathrm{d}t_d = \int_{Q_{3\rho}(x)} |\nabla^du(y)| \,\mathrm{d}y.$$
This establishes the estimate
$$ \sup_{y \in Q_{3\rho}(x)} |v_{\varepsilon}(y)| \leq \lVert v_{\varepsilon} \rVert_{W^{d,1}(Q_{3\rho}(x))}. $$
Step 4: Sending $\varepsilon \to 0$ and applying the above inequality to $v_{\varepsilon} - v_{\delta}$ since the derivation is linear, we deduce that since $v_{\varepsilon}$ is Cauchy in $W^{d,1}$ it is Cauchy in the uniform norm. Hence $v_{\varepsilon} \to v_*$ uniformly on $B_{3\rho}(x),$ which gives a continuous representative of $v.$ Hence restricted to $B_{\rho}(x)$ this gives a local continuous representative of $u,$ and doing this at all points establishes the result.
