This is the first entry in a series on the Euler-Lagrange Equations and the Calculus of Variations. The first main result I prove is the Fundamental Lemma of the Calculus of Variations. It’s a small but important result, used not only in CoV but also in the modern theory of Partial Differential Equations, where it underpins the definition of distributional derivatives. For that reason, I want to discuss it first.

Then I will use it to prove the Euler-Lagrange Equations in a bit more general setting than what you might find in standard textbooks.

I write this out of personal interest, for readers with some mathematical background.

Notation

Some typical notation I will use in my blogs:

What is the Calculus of Variations

The theory of Calculus of Variations (CoV) is about optimizing a functional, a function that takes in another function and spits out a number. Similar to how you might want to find the point $x$ where some function $f$ has an extremum, that is, is minimized or maximized (for instance, $f(x) = {(x-1)^2}$ has minimum at $x=1$), in the CoV you want to find the input function so that the functional is minimized or maximized.

The typical functional for a problem in the CoV is of the form

\[ I(u) = \int_\Omega f(x, u(x), Du(x)) \mathrm{d}x. \]

Here,

  • $I$ is the functional whose extremum we seek; we look for a function $u$ at which functional $I(u)$ is minimal or maximal,
  • $\Omega \subset \mathbb{R}^m$ is a bounded open domain,
  • $u: \Omega \to \mathbb{R}^n$ is the input function,
  • $Du: \Omega \to \mathbb{R}^{n \times m}$ is the Jacobian matrix of $u$, that is, \[ Du = \begin{pmatrix} \frac{\partial u_1}{\partial x_1} & \ldots & \frac{\partial u_1}{\partial x_m} \\ \vdots & & \vdots \\ \frac{\partial u_n}{\partial x_1} & \ldots & \frac{\partial u_n}{\partial x_m} \end{pmatrix}, \]
  • $f: \Omega \times \mathbb{R}^n \times \mathbb{R}^{n \times m} \to \mathbb{R}$ is a given function used to define the functional $I$.

This is a very general problem, because a function $u$ can describe many things, such as shapes, states, or processes, and a functional $I$ can represent a surface area, the action, energy, cost, to name a few. As such, this type of problem shows up everywhere, making CoV a classical and fundamental branch of mathematics.

What to expect from a minimizer

Remember from high school mathematics how you can try to find the minimum or maximum of a smooth function $f$ by setting its derivative to zero, i.e., $f'(x) = 0$ and solving for $x$.

fxf'(x)=0

In other words, if $x$ is a point where $f$ has an extremum, then $f'(x) = 0$.

The same idea holds for multivariable functions, where it is simplest expressed using the directional derivative. The directional derivative of $f: \mathbb R^n \to \mathbb R$ in the direction $v \in \mathbb R^n$ is given by

\[ \nabla_v f (x) := \frac{\mathrm{d}}{\mathrm d s}f(x + s \cdot v)_{|s=0}, \quad x \in \mathbb R^n. \]
vxff(x + s * v)

Then the statement becomes: if $f: \mathbb{R}^n \to \mathbb{R}$ is a smooth function with an extremum at the point $x \in \mathbb{R}^n$, then $\nabla_v f(x) = 0$ for all $v \in \mathbb R^n$. In other words,

\[ \frac{\mathrm{d}}{\mathrm d s}f(x + s \cdot v)_{|s=0} = 0 \]

for any $v \in \mathbb{R}^n$.

This exact idea carries over to CoV, where we express it using the first variation of a functional. The first variation of a functional $I$ at $u$ in the direction $\eta$ is given by

\[ \delta I(u,\eta) := \frac{\mathrm{d}}{\mathrm d s}I(u + s \cdot \eta)_{|s=0}. \]

The statement for functionals then becomes: if functional $I$ attains an extremum for the function $u$, then \[ \delta I(u,\eta) = \frac{\mathrm{d}}{\mathrm d s}I(u + s \cdot \eta)_{|s=0} = 0 \] for any smooth function $\eta: \Omega \to \mathbb R^n$ with compact support. Comparing to the multivariable case, $\eta$ plays the role of the direction $v$.

The Euler-Lagrange Equation

The next step is to plug in the definition of $I$. For simplicity, let’s agree on some things:

  • Assume $n = 1$ so that

    • $u: \Omega \to \mathbb R$
    • its derivative can be written as $\nabla u = {(u_{x_1}, \ldots, u_{x_m})}$.

    The general case $n > 1$ uses the exact same arguments applied to each component $k = 1, \ldots, n$, which I will show later.

  • Assume $f$ is smooth and $u$ is smooth.

  • Write $f(x,y,z)$, $x \in \Omega$, $y \in \mathbb R$, $z \in \mathbb R^{m}$ so that $f$’s partial derivatives can be written as $f_x$, $f_y$ and $\nabla_zf = (f_{z_1}, \ldots, f_{z_m})$.

  • $C^\infty_c(\Omega)$ is the set of smooth functions on $\Omega$ that have compact support in $\Omega$ (and therefore are $0$ on the boundary $\partial \Omega$ of $\Omega$).

So we get

\[ \begin{aligned} 0 &= \frac{\mathrm{d}}{\mathrm d s}I(u + s \cdot \eta)_{|s=0} \\ &= \int_\Omega \frac{\mathrm{d}}{\mathrm d s}f(x, u(x) + s \cdot \eta(x), \nabla u(x) + s \cdot \nabla \eta(x))_{|s=0}\mathrm d x \\ & \qquad \qquad \text{(switched derivative and integral)} \\ &= \int_\Omega f_y(x, u(x), \nabla u(x)) \eta (x) + \nabla_z f(x, u(x), \nabla u (x)) \cdot \nabla \eta(x) \mathrm d x \\ & \qquad \qquad \text{(applied chain rule and set $s=0$)} \\ &= \int_\Omega f_y(x, u(x), \nabla u(x)) \eta (x) \mathrm d x - \int_\Omega \mathrm{div}\left( \nabla_z f(x, u(x), \nabla u (x)) \right) \eta(x) \mathrm d x \\ & \qquad \qquad \text{(applied integration by parts)} \\ &= \int_\Omega \left( f_y(x, u(x), \nabla u(x)) - \mathrm{div}\left( \nabla_z f(x, u(x), \nabla u (x)) \right) \right) \eta(x) \mathrm d x \\ & \qquad \qquad \text{(collected terms)} \\ \end{aligned} \]

for any $\eta \in C^\infty_c(\Omega)$.

This can “clearly” only hold for every $\eta$ if

\[ f_y(x, u(x), \nabla u(x)) - \mathrm{div}\left( \nabla_z f(x, u(x), \nabla u (x)) \right) = 0 \]

for all $x \in \Omega$. This equation is called the Euler-Lagrange Equation (ELE).

I put the term clearly in quotes, since I made a bunch of strong assumptions on $f$ and $u$. To weaken the assumptions and make the theory of CoV richer, I will have to use a result called the Fundamental Lemma of the Calculus of Variations.

The Fundamental Lemma

The lemma states that if a locally integrable function $f$ yields zero when tested against any test function, then $f$ must be “effectively” zero. Let me explain what I mean:

  • locally integrable means that \[ \int_{C} |f(x)| \mathrm d x < \infty \] for any compact $C \subset \Omega$. The space of such functions is called $L^1_{\mathrm{loc}}(\Omega)$.
  • with $f$ tested against a test function $\varphi \in C^\infty_c(\Omega)$, I mean the integral $\int_\Omega f(x) \varphi(x) \mathrm d x $.
  • with “effectively” zero I mean that $f$ is zero up to a set of measure zero. In other words, the set \[ \{x\in\Omega\ |\ f(x) \neq 0\} \] might not be empty, but it does have measure zero. In practice, this means that $f$ is zero as far as integration is concerned: $\int_\Omega f(x) g(x) \mathrm d x = 0$ for any standard function $g: \Omega \to \mathbb R$ (including $g = \mathrm{sign}(f)$ so that $\int_\Omega |f(x)| \mathrm d x = 0$). In measure theory, this property is called ${ f \equiv 0 } $ almost everywhere.

With this colloquial phrasing, followed by some rigorous explanation, out of the way (as one does …), let me state the result.

The proof requires some knowledge on mollifiers, which is outside the scope of this blog post. For details on mollifiers, see Wikipedia and Partial Differential Equations by L.C. Evans, the section in Appendix C on mollifiers.

In short, mollifiers are used to provide smooth approximations to any ${f \in L^1_{\mathrm{loc}}}$. This is needed as $f$ could be anything, such as a step function

\[ f(x) = \left\{ \begin{aligned} 0 & & \text{if}\ x < 0,\\ 1 & & \text{if}\ x \geq 0, \end{aligned} \right. \]

which is not a nice smooth function.

For now, assume that a standard mollifier $\varphi_\varepsilon$ exists, that is, a family of smooth compactly supported functions with the properties:

  • $\varphi_\varepsilon$ is supported in $B_\varepsilon(0) := \{x \in \mathbb R^n\ |\ |x|<\varepsilon \}$
  • $f_\varepsilon(x) := \int_\Omega f(y) \varphi_\varepsilon(x-y) \mathrm d y$ is well-defined and approximates $f$ as follows: $f_\varepsilon(x) \to f(x)$ as $\varepsilon \to 0$ for almost every $x \in \Omega$ (the set where the limit does not hold has measure zero).

The Classical Theorem

Let me very precisely formulate the conditions, so that I can state the classical theorem involving the Euler-Lagrange Equations in the generality stated at the start of this post. In particular, we do not assume $n = 1$, that is, we look for a function ${u: \mathbb R^m \supset \Omega \to \mathbb R^n}$.

Assume that:

  • $\Omega\subset \mathbb R^m$ is open and bounded with a $C^1$-boundary $\partial \Omega$.
  • $f: \overline{\Omega} \times \mathbb R^n \times \mathbb R^{n \times m} \to \mathbb R, (x,y,z) \mapsto f(x,y,z)$ is twice continuously differentiable.
  • $g: \partial \Omega \to \mathbb R^n$ is a given $C^1$-function.

The goal is to find a minimizer or maximizer $u$ in the class of functions

\[ \Phi := \left\{ u \in C^1(\overline{\Omega}; \mathbb R^n)\ |\ u = g\ \text{on}\ \partial \Omega \right\}. \]

From this it is clear that $g$ represents the boundary condition we impose on the solution $u$.

I need to introduce some bookkeeping for the derivatives of $f$, to keep the formulas simple:

  • The derivative of $f$ with respect to $y \in \mathbb R^n$ is given by

    \[ \nabla_y f = \left(f_{y_1}, \ldots, f_{y_n}\right). \]
  • The derivative of $f$ with respect to $z \in \mathbb R^{n \times m}$ is given by

    \[ D_z f: \overline{\Omega} \times \mathbb R^n \times \mathbb R^{n \times m} \to \mathbb{R}^{n \times m} \]

    with entries

    \[ (D_z f)_{ij}(x,y,z) := f_{z_{ij}}(x,y,z). \]
  • I will abuse notation a bit by taking the $\mathrm{div}$ of a matrix field as follows:

    \[ \begin{aligned} &\mathrm{div}(D_z f(x, u(x), Du(x))) := \nabla_x \cdot D_z f \\ &\quad = \left(\sum_{i=1}^m (f_{z_{1i}}(x, u(x), Du(x)))_{x_i}, \ldots, \sum_{i=1}^m (f_{z_{ni}}(x, u(x), Du(x)))_{x_i} \right) \end{aligned} \]

Finally, after all that talk and agreeing on things, we are in a position to formulate the main statement of this blog post.

Sources: