Calculus of variations
High school
Calculus of variations is the study of finding the best curve or function among all possible curves or functions, where “best” is measured by a number computed from the whole curve, like the length of the curve or the time it takes to slide down the curve.
Undergraduate (analysis)
Calculus of variations is the study of problems of finding a function $y : [a, b] \to \reals^n$, with fixed end values $y(a) = y_a$ and $y(b) = y_b$, that minimizes (or maximizes) a functional of the form
\[J[y] = \int_a^b L\bigl(t, y(t), y^{\prime}(t)\bigr) \, \mathrm{d}t.\]Examples
Examples
-
Finding the shortest curve $y(x)$ in the plane from $(0, 0)$ to $(1, 1)$
Undergraduate
Finding the shortest curve from $(0, 0)$ to $(1, 1)$ is a problem in the calculus of variations, because the unknown is a function $y$ with fixed end values, and the length is the integral of $L(y^{\prime}) = \sqrt{1 + (y^{\prime})^2}$. The Euler–Lagrange equation gives $y^{\prime\prime} = 0$, so the shortest curve is the straight line $y = x$.
-
Minimizing $\int_0^\infty \bigl(x(t)^2 + u(t)^2\bigr) \, \mathrm{d}t$ for the system $\dot{x} = x + u$, with $x(0) = 1$
Graduate
Minimizing $\int_0^\infty (x^2 + u^2) \, \mathrm{d}t$ for $\dot{x} = x + u$ is also a problem in the calculus of variations, because the input is unconstrained, so substituting $u = \dot{x} - x$ gives the functional $\int_0^\infty \bigl(x^2 + (\dot{x} - x)^2\bigr) \, \mathrm{d}t$ of $x$ alone.
Non-examples
Things that may be mistaken for examples.
-
Moving a cart from rest at position $0$ to rest at position $1$ in the shortest time, with an acceleration $u(t)$ between $-1$ and $1$
Undergraduate
Moving a cart in minimum time with acceleration between $-1$ and $1$ is not a calculus of variations problem, because the bound $\abs{\ddot{x}} \leq 1$ constrains the derivatives of the unknown function, and the optimal acceleration jumps from $1$ to $-1$, so the optimal position is not a smooth solution of an Euler–Lagrange equation.
Properties
- If a continuously differentiable function $y$ minimizes $J$, then $y$ satisfies the Euler–Lagrange equation $\frac{\mathrm{d}}{\mathrm{d}t} \frac{\partial L}{\partial y^{\prime}} = \frac{\partial L}{\partial y}$.
- A problem in the calculus of variations is the optimal control problem with the dynamics $\dot{x} = u$ and no constraints on the input $u$, where the state $x$ plays the role of $y$.
Notes
The name comes from the variation $\delta y$: a small change to the function $y$, which changes $J$ by approximately $\delta J$, much as a small change in $x$ changes $f(x)$ by approximately $f^{\prime}(x) \, \delta x$.
Distinctions involving this term
- Calculus of variations vs. optimal control: The calculus of variations and optimal control seek a function of time that minimizes a cost given by an integral. In the calculus of variations, the unknown is a curve $y(t)$, and the cost depends on $y$ and its derivative $y^{\prime}$, which can be chosen freely. In optimal control, the unknown is an input $u(t)$, which may be constrained to a set $U$, and the state $x(t)$ is determined by the input through the dynamics $\dot{x} = f(x, u)$.