# Fundamental lemma of calculus of variations

In mathematics, specifically in the calculus of variations, the fundamental lemma of the calculus of variations states that if the definite integral of the product of a continuous function f(x) and h(x) is zero, for all continuous functions h(x) that vanish at the endpoints of the domain of integration and have their first two derivatives continuous, then f(x)=0. This lemma is used in deriving the Euler–Lagrange equation of the calculus of variations.[1] It is a lemma that is typically used to transform a problem from its weak formulation (variational form) into its strong formulation (differential equation).

## Statement

A function is said to be of class $C^k$ if it is k-times continuously differentiable. For example, class $C^0$ consists of continuous functions, and class $C^\infty$ consists of infinitely smooth functions.

Let f be of class $C^k$ on the interval [a,b]. Assume furthermore that

$\int_a^b f(x) \, h(x) \, dx = 0$

for every function h that is of class $C^k$ on [a,b] with h(a) = h(b) = 0. Then the fundamental lemma of the calculus of variations states that $f (x)$ is identically zero on $[a, b]$.

In other words, the test functions h ($C^k$ functions vanishing at the endpoints) separate $C^k$ functions: $C^k[a,b]$ is a Hausdorff space in the weak topology of pairing against $C^k$ functions that vanish at the endpoints.

## Proof

Let f satisfy the hypotheses. Let r be any smooth function that is 0 at a and b and positive on the open interval (a, b); for example, r = - (x - a) (x - b). Let h = r f. Then h is of class Ck on [a,b]. By the hypotheses,

$0 = \int_a^b f(x) h(x) \; dx = \int_a^b r(x) f(x)^2 \; dx.$

The integrand now must be 0 except perhaps on a subset of [a, b] of measure 0. However, by continuity if there are points where the integrand is non-zero, there is also some interval around that point where the integrand is non-zero, which has non-zero measure. Thus the integrand must be identically 0 over the entire interval. Since r is positive on (a, b), f is 0 there and hence on all of [a, b].

## The du Bois-Reymond lemma

The du Bois-Reymond lemma (named after Paul du Bois-Reymond) is a more general version of the above lemma. It defines a sufficient condition to guarantee that a function vanishes almost everywhere. Suppose that $f$ is a locally integrable function defined on an open set $\Omega \subset \mathbb{R}^n$. If

$\int_\Omega f(x) h(x) dx = 0\,$

for all $h \in C^\infty_0(\Omega),$ then f(x) = 0 for almost all x in Ω. Here, $C^\infty_0(\Omega)$ is the space of all infinitely differentiable functions defined on Ω whose support is a compact set contained in Ω.

## Applications

This lemma is used to prove that extrema of the functional

$J[y] = \int_{x_0}^{x_1} L(t,y(t),\dot y(t)) \, dt$

are weak solutions $y:[x_0,x_1]\to V$ (for an appropriate vector space $V$) of the Euler-Lagrange equation

${\partial L(t,y(t),\dot y(t)) \over \partial y} = {d \over dt} {\partial L(t,y(t),\dot y(t)) \over \partial \dot y} .$

The Euler-Lagrange equation plays a prominent role in classical mechanics and differential geometry.

## Footnotes

1. ^ Courant, R.; Hilbert, D. (1953). Methods of Mathematical Physics. Vol. 1. New York, New York: Interscience Publishers, Inc. p. 185. ISBN 978-0470179529.