Why Measure Smoothness With Derivatives?
In nonparametric regression, smoothness classes describe which regression functions are under consideration. A derivative-based class can express a useful idea: a function is smoother when its derivatives, up to a specified order, remain controlled. But a function that is smooth except at a corner may still be statistically and analytically well behaved. Requiring classical derivatives at every point would exclude such functions unnecessarily.
Sobolev spaces address this by defining derivatives through integration against smooth test functions. These weak derivatives agree with ordinary derivatives when the latter exist and satisfy suitable integrability conditions, but they can also exist when the function has a kink. An L2 Sobolev ball then bounds the squared integrals of the function and its weak derivatives.
Weak Derivatives
Let \(\Omega\) be an open subset of \(\mathbb R^d\). A test function is an infinitely differentiable function \(\varphi\) whose support is a compact subset of \(\Omega\); the collection of these functions is denoted \(C_c^\infty(\Omega)\). Write \(L^2(\Omega)\) for the functions whose squared absolute values have finite integral, identifying functions that agree almost everywhere.
A multi-index is a vector \(\alpha=(\alpha_1,\ldots,\alpha_d)\) of nonnegative integers. Its order is \(|\alpha|=\sum_{j=1}^d\alpha_j\), and \(D^\alpha\) denotes differentiation \(\alpha_j\) times in coordinate \(j\) when the classical derivatives exist.
The definition moves derivatives from \(u\) onto the test function, with a sign change for each differentiation. Test functions vanish near the boundary, so this definition imposes no boundary values on \(u\). If \(u\) has classical derivatives through order \(|\alpha|\), integration by parts shows that those derivatives are weak derivatives whenever the identity is valid and they belong to \(L^2(\Omega)\).
Weak derivatives are unique up to equality almost everywhere. Indeed, if \(g_1\) and \(g_2\) both satisfy the definition, their difference \(h=g_1-g_2\) has \(\int_\Omega h\varphi=0\) for every test function. The fundamental lemma for test functions then gives \(h=0\) almost everywhere. Thus it makes sense to refer to the weak derivative as an L2 function, even though its values on a set of measure zero do not matter.
Sobolev Spaces and Balls
For an integer \(m\geq 0\), the Sobolev space \(W^{m,2}(\Omega)\) consists of the L2 functions whose weak derivatives of every order at most \(m\) also belong to L2. The order-zero derivative is the function itself. The convention below counts each multi-index once, including mixed partial derivatives such as \(D^{(1,1)}u\).
The norm includes both the function and all weak derivatives up to order \(m\). The corresponding order-\(m\) seminorm includes only the derivatives with \(|\alpha|=m\); it does not, by itself, control the L2 size of the function or its lower-order derivatives. Different conventions sometimes use equivalent norms, but a numerical ball radius depends on the convention. The sum above fixes that choice here.
Worked Example: A Kink With a Square-Integrable Weak Derivative
On \(\Omega=(-1,1)\), let \(u(x)=x_+=\max(x,0)\). The function is continuous but has no classical derivative at \(x=0\). We verify that its weak first derivative is \(g(x)=\mathbf 1_{(0,1)}(x)\).
For any \(\varphi\in C_c^\infty((-1,1))\), the definition requires \[ \int_{-1}^1 x_+\varphi'(x)\,dx=-\int_{-1}^1 g(x)\varphi(x)\,dx. \] The left side is \(\int_0^1 x\varphi'(x)\,dx\). Integration by parts gives \[ \int_0^1 x\varphi'(x)\,dx = [x\varphi(x)]_0^1-\int_0^1\varphi(x)\,dx = -\int_0^1\varphi(x)\,dx, \] because \(\varphi\) vanishes near \(1\), and the factor \(x\) vanishes at \(0\). This is the required identity, so \(D u=g\) weakly.
The squared L2 norm of \(u\) is \(\int_0^1x^2\,dx=1/3\), and that of \(g\) is \(\int_0^1 1\,dx=1\). Therefore \[ \|u\|_{W^{1,2}((-1,1))}^2=\frac13+1=\frac43. \] Thus \(u\) belongs to the first-order ball of radius \(R\) exactly when \(R\geq 2/\sqrt{3}\).
Worked Example: A Polynomial in a Second-Order Ball
Take \(\Omega=(0,1)\), \(u(x)=x^2\), and \(m=2\). Its ordinary derivatives are \(u'(x)=2x\) and \(u''(x)=2\); since they are square-integrable, integration by parts against compactly supported test functions identifies them as the weak derivatives.
The squared norm is the sum of the three squared L2 norms: \[ \|u\|_{W^{2,2}((0,1))}^2 = \int_0^1 x^4\,dx+\int_0^1(2x)^2\,dx+\int_0^1 2^2\,dx = \frac15+\frac43+4 = \frac{83}{15}. \] Consequently \(u\) belongs to \(\mathcal W^{2,2}((0,1),R)\) if and only if \(R\geq\sqrt{83/15}\). The second derivative contributes \(4\) to the squared norm; it is not the whole norm.
Worked Example: Counting Mixed Derivatives in Two Dimensions
On the square \(\Omega=(0,1)^2\), consider \(u(x,y)=xy\) and \(m=2\). The multi-indices of order at most two give the function \(xy\), first derivatives \(D^{(1,0)}u=y\) and \(D^{(0,1)}u=x\), and second derivatives \(D^{(2,0)}u=0\), \(D^{(1,1)}u=1\), and \(D^{(0,2)}u=0\).
Their squared L2 norms are respectively \(1/9, 1/3, 1/3, 0, 1,\) and \(0\), since the square has area one and, for example, \(\int_0^1\int_0^1 x^2\,dx\,dy=1/3\). Hence \[ \|u\|_{W^{2,2}((0,1)^2)}^2=\frac19+\frac13+\frac13+1=\frac{16}{9}, \qquad \|u\|_{W^{2,2}((0,1)^2)}=\frac43. \] The mixed derivative is counted once under the stated multi-index convention.
What First-Order Sobolev Smoothness Means in One Dimension
On an interval, weak differentiability has a useful concrete interpretation. An absolutely continuous function can be recovered from its derivative by integration. The following characterization explains why the kink in the first example is admissible: absolute continuity allows a derivative to fail at isolated points, while requiring that the derivative be square-integrable.
Proof. First suppose \(u\in W^{1,2}(I)\), with weak derivative \(g\in L^2(I)\). Since \(I\) has finite length, \(g\in L^1(I)\) by the Cauchy–Schwarz inequality. Define \(G(x)=\int_a^x g(t)\,dt\). Then \(G\) is absolutely continuous and \(G'=g\) almost everywhere. Integration by parts for absolutely continuous functions shows that \(G\) has weak derivative \(g\).
It follows that \(h=u-G\) has weak derivative zero: \(\int_I h\varphi'=0\) for every \(\varphi\in C_c^\infty(I)\). To see that \(h\) is constant almost everywhere, take any test function \(\psi\) with \(\int_I\psi=0\), and set \(\varphi(x)=\int_a^x\psi(t)\,dt\). This \(\varphi\) is a test function: it vanishes near \(a\), and the zero integral makes it vanish near \(b\). Therefore \(\int_I h\psi=\int_I h\varphi'=0\). Fix a test function \(\eta\) with \(\int_I\eta=1\), and set \(c=\int_I h\eta\). For any test function \(\psi\), the function \(\psi-(\int_I\psi)\eta\) has integral zero, so \(\int_I h\psi=c\int_I\psi\). The fundamental lemma for test functions implies \(h=c\) almost everywhere. Thus \(u\) agrees almost everywhere with \(c+G\), an absolutely continuous function whose derivative \(g\) is in L2.
Conversely, suppose \(u\) has an absolutely continuous representative with derivative \(g\in L^2(I)\). The representative is bounded on the compact interval, hence belongs to L2. For every compactly supported smooth \(\varphi\), integration by parts gives \(\int_I u\varphi'=-\int_I g\varphi\); the boundary term is zero because \(\varphi\) vanishes near the endpoints. Thus \(g\) is the weak derivative and \(u\in W^{1,2}(I)\). \(\square\)
Where Classical Differentiability Still Matters
Weak derivatives do not mean that every irregularity is permitted at every order. The same kink \(u(x)=x_+\) has no second weak derivative in L2. Its first weak derivative is the indicator \(g=\mathbf 1_{(0,1)}\), whose jump at zero produces a point mass when differentiated. The following argument shows why that point mass cannot be represented by an L2 function.
If an L2 weak second derivative \(q\) existed, then the weak derivative identity for \(g\) would require \(\int_{-1}^1 g(x)\varphi'(x)\,dx=-\int_{-1}^1q(x)\varphi(x)\,dx\). The left side equals \(\int_0^1\varphi'(x)\,dx=-\varphi(0)\). Choose a smooth function \(\rho\) supported in \((-1,1)\) with \(\rho(0)=1\), and use \(\varphi_\epsilon(x)=\rho(x/\epsilon)\) for sufficiently small \(\epsilon>0\). The required identity would imply \[ 1=\left|\int_{-1}^1q(x)\varphi_\epsilon(x)\,dx\right| \leq \|q\|_{L^2((-1,1))}\|\varphi_\epsilon\|_{L^2((-1,1))} = \|q\|_{L^2((-1,1))}\sqrt{\epsilon}\,\|\rho\|_{L^2((-1,1))}. \] The right side tends to zero as \(\epsilon\) tends to zero, a contradiction. So \(x_+\in W^{1,2}((-1,1))\) but \(x_+\notin W^{2,2}((-1,1))\).
A Sobolev norm measures integrated derivative size, not pointwise bounds on every derivative. It also does not encode boundary conditions: test functions are supported inside the domain, and the defining identities do not prescribe values at its edge. In applications, the domain, the derivative order, and the radius are all part of the smoothness assumption.
Common Mistake
- Wrong reasoning: “The function \(x_+\) is not classically differentiable at zero, so it cannot belong to a first-order derivative class.”
- Correction: A single point of classical nondifferentiability does not prevent a weak derivative from existing. Check the test-function identity: \(x_+\) has weak derivative \(\mathbf 1_{(0,1)}\), which is in L2. For second-order membership, however, the jump in that first derivative prevents an L2 weak second derivative.
- Another frequent error: reporting only the highest-order derivative norm as the full Sobolev norm. Under the convention here, \(W^{m,2}\) includes every derivative of order at most \(m\), including the function itself.
Check Your Understanding
Use the definitions and calculations above to answer these questions.
- State the test-function identity defining a weak first derivative in one dimension.
- For \(u(x)=x_+\) on \((-1,1)\), what is its weak first derivative, and what is its squared \(W^{1,2}\) norm?
- Why does the \(W^{2,2}\) norm include lower-order derivatives as well as the second derivative?
- For \(u(x,y)=xy\) on \((0,1)^2\), which mixed derivative is included in the stated order-two norm?
- What does the one-dimensional characterization say about absolutely continuous representatives of \(W^{1,2}\) functions?