Fundamental Theorem of the Calculus of Variations. Let $u \in L^1_{\text{loc}}(a,b)$ and $$ \int_{a}^{b} u(x) \varphi(x) dx = 0 \quad \forall \varphi \in \mathcal{C}^{\infty}_{\text{c}}(a,b). $$ Then, we have $u|_{(a,b)} \equiv 0$ almost everywhere.
I am going to present the proof our professor did and the one I found in the lecture notes from the same course a few years back. I would like to know if both approaches are correct or the first is not because it ignores some details or if the second proof is just unnecessarily complicated.
Proof 1: Let $[c,d] \subset (a,b)$ a compact interval with $c < d$. We aim to show $\int_{c}^{d} | u(x) | dx = 0$, which yields the claim since $[c,d]$ was chosen arbitrarily. Define $\omega := \text{sgn}(u) \cdot \chi_{[c,d]}$. Furthermore, define $\omega_{\varepsilon} := \omega \star J_{\varepsilon}$ ($\star$ = convolution), where $$ J_{\varepsilon}(x) := \begin{cases} c_{\varepsilon}\exp\left(\frac{1}{x^2 - 1}\right), & | x | < 1, \\ 0, & \text{else.} \end{cases} $$ and $c_{\varepsilon}$ is chosen such that $\int_{\mathbb{R}} J_{\varepsilon}(x) dx = 1$.
In a previous lemma we have shown that
- for sufficiently small $\varepsilon > 0$ we have $\omega_{\varepsilon} \in \mathcal{C}^{\infty}_{\text{c}}(a,b)$ and
- $\omega_{\varepsilon} \xrightarrow{\varepsilon \searrow 0} \omega$ almost everywhere on $(a,b)$.
We now want to use Lebesgue's theorem to show \begin{equation*} \int_{a}^{b} \omega_{\varepsilon}(x) u(x) = \int_{c}^{d} | u(x) | dx = 0. \end{equation*} To find a integrable majorant for $\omega_{\varepsilon}$ we observe that \begin{equation*} | \omega_{\varepsilon}(x) | = \left| \int_{\mathbb{R}} J_{\varepsilon}(x - \xi) \omega_{\varepsilon}(\xi) d\xi \right| \le \max_{\xi \in \mathbb{R}} | \omega_{\varepsilon}(\xi) | \cdot \int_{\mathbb{R}} J_{\varepsilon}(x - \xi) d \xi = 1 \cdot 1 = 1. \end{equation*} Therefore, $| u(x) \omega_{\varepsilon}(x) | \le | u(x) |$.
Because $u \in L^1_{\text{loc}}(a,b)$ we have $u \in L^1(c,d)$ and therefore, $| u |$ is a integrable majorant for $u \omega_{\varepsilon}$. $\square$
Proof 2 Let $u \in L^1_{\text{loc}}(a,b)$ and $[c,d] \subset (a,b)$. Define $\omega = \text{sgn}(u) \chi_{[c,d]}$. Then we have $\omega \in L^1_{\text{loc}}(a,b)$ and $\text{supp}(\omega) \subset [c,d]$.
!The $\tilde{J}_{\varepsilon}$ is the $J_{\varepsilon}$ from above!
Now define $\omega_{\varepsilon} := \tilde{J}_{\varepsilon} \ast \omega$. Then, $\omega_{\varepsilon} \to \omega$ almost everywhere on $(a,b)$ and $\text{supp}(\omega_{\varepsilon}) \subset [c - \varepsilon, d + \varepsilon]$, hence $\omega_{\varepsilon} \in \mathcal{C}^{\infty}_{\text{c}}(a,b)$ if $\varepsilon$ is small enough.
We obtain \begin{align*} 0 = \int_{a}^{b} \underbrace{u(x) \omega_{\varepsilon}(x)}_{\xrightarrow{\textrm{a.e.}} u(x) \omega(x)} dx & = \int_{c - \varepsilon}^{d + \varepsilon} u(x) \omega_{\varepsilon}(x) dx \\ & = \int_{a}^{b} u(x) \chi_{[c - \varepsilon, d + \varepsilon]}(x) \omega_{\varepsilon}(x) dx. \end{align*} As \begin{equation*} | \omega_{\varepsilon}(x) | \le \int \tilde{J}_{\varepsilon}(x - y) \underbrace{| \omega(y) |}_{\le 1} dy \le 1, \end{equation*} For $\varepsilon_0 < \min(c - a, b - d)$ and all $\varepsilon < \varepsilon_0$ we get \begin{equation*} | u(x) \omega_{\varepsilon}(x) | \le | u(x) | \chi_{[c - \varepsilon_0, d + \varepsilon_0]}(x) \end{equation*} This function is integrable on $(a,b)$. Therefore, Lebesgues theorem shows \begin{equation*} 0 = \int_{a}^{b} u(x) \omega(x) dx = \int_{c}^{d} | u(x) | dx, \end{equation*} hence $u \equiv 0$ almost everywhere on $[c,d]$. As $[c,d] \subset (a,b)$ was chosen arbitrarily, this yields the claim. $\square$