Variational Calculus

Variational calculus deals with optimizing functionals—finding functions that minimize or maximize integrals. It is the foundation of action principles in physics, from classical mechanics to General Relativity and quantum field theory.

1. Functionals and the Calculus of Variations

A functional is a map from a space of functions to the real numbers. We seek to find functions y(x) that extremize (minimize or maximize) such functionals.

Definition of a Functional

A typical functional has the form:

$$S[y] = \int_{x_1}^{x_2} L(x, y(x), y'(x)) \, dx$$

where L is called the Lagrangian and depends on the independent variable x, the function y(x), and its derivative y'(x).

Variation of a Functional

Consider a small perturbation $y(x) \to y(x) + \epsilon \eta(x)$ where η(x) is an arbitrary smooth function with $\eta(x_1) = \eta(x_2) = 0$ (fixed endpoints).

The first variation is:

$$\delta S = \frac{d}{d\epsilon}\bigg|_{\epsilon=0} S[y + \epsilon\eta]$$

The function y(x) that extremizes S satisfies $\delta S = 0$ for all η(x).

2. Euler-Lagrange Equation

The necessary condition for y(x) to be an extremum of S[y] is the Euler-Lagrange equation.

Derivation

Computing the first variation and integrating by parts:

$$\delta S = \int_{x_1}^{x_2} \left(\frac{\partial L}{\partial y} - \frac{d}{dx}\frac{\partial L}{\partial y'}\right) \eta(x) \, dx = 0$$

Since this must hold for arbitrary η(x), we obtain the Euler-Lagrange equation:

$$\frac{\partial L}{\partial y} - \frac{d}{dx}\frac{\partial L}{\partial y'} = 0$$

Example: Shortest Path

To find the shortest path between two points in a plane, minimize arc length:

$$S[y] = \int_{x_1}^{x_2} \sqrt{1 + (y')^2} \, dx$$

Applying Euler-Lagrange yields y'' = 0, so y = ax + b—a straight line.

Generalization to Multiple Variables

For a functional depending on n functions $y_1, \ldots, y_n$:

$$S[y_1, \ldots, y_n] = \int L(x, y_i, y_i') \, dx$$

We get n Euler-Lagrange equations:

$$\frac{\partial L}{\partial y_i} - \frac{d}{dx}\frac{\partial L}{\partial y_i'} = 0, \quad i = 1, \ldots, n$$

3. Action Principles in Classical Mechanics

Classical mechanics can be reformulated using the principle of least action: physical trajectories extremize the action functional.

Hamilton's Principle

The action is:

$$S[q] = \int_{t_1}^{t_2} L(q, \dot{q}, t) \, dt$$

where L = T - V (kinetic minus potential energy) is the Lagrangian. The Euler-Lagrange equations yield:

$$\frac{d}{dt}\frac{\partial L}{\partial \dot{q}_i} - \frac{\partial L}{\partial q_i} = 0$$

These are the Lagrange equations of motion, equivalent to Newton's F = ma.

Example: Harmonic Oscillator

For a mass m on a spring with spring constant k:

$$L = \frac{1}{2}m\dot{x}^2 - \frac{1}{2}kx^2$$

Euler-Lagrange gives:

$$m\ddot{x} + kx = 0 \quad \Rightarrow \quad \ddot{x} + \omega^2 x = 0, \quad \omega = \sqrt{k/m}$$

Advantages of Lagrangian Formalism

  • Coordinate-independent (works with any generalized coordinates)
  • Constraints can be handled naturally
  • Generalizes easily to field theory and relativity
  • Reveals symmetries via Noether's theorem

4. Hamiltonian Formalism

The Hamiltonian formalism is a reformulation of mechanics in terms of positions q and momenta p, using the Hamiltonian H instead of the Lagrangian.

Legendre Transform

Define the canonical momentum:

$$p_i = \frac{\partial L}{\partial \dot{q}_i}$$

The Hamiltonian is the Legendre transform of L:

$$H(q, p, t) = \sum_i p_i \dot{q}_i - L(q, \dot{q}, t)$$

where velocities $\dot{q}_i$ are expressed in terms of p_i.

Hamilton's Equations

The equations of motion become:

$$\dot{q}_i = \frac{\partial H}{\partial p_i}, \quad \dot{p}_i = -\frac{\partial H}{\partial q_i}$$

These are first-order differential equations in a 2n-dimensional phase space (q, p).

Poisson Brackets

For any observable f(q, p, t), its time evolution is:

$$\frac{df}{dt} = \{f, H\} + \frac{\partial f}{\partial t}$$

where the Poisson bracket is:

$$\{f, g\} = \sum_i \left(\frac{\partial f}{\partial q_i}\frac{\partial g}{\partial p_i} - \frac{\partial f}{\partial p_i}\frac{\partial g}{\partial q_i}\right)$$

Connection to Quantum Mechanics

Quantization replaces Poisson brackets with commutators:

$$\{f, g\} \to \frac{1}{i\hbar}[\hat{f}, \hat{g}]$$

The canonical commutation relation $[\hat{q}, \hat{p}] = i\hbar$ comes from $\{q, p\} = 1$.

5. Noether's Theorem

Noether's theorem states that every continuous symmetry of the action corresponds to a conserved quantity. This is one of the most profound results in theoretical physics.

Statement

If the action S is invariant under a continuous transformation parametrized by ε:

$$q_i \to q_i + \epsilon \, \delta q_i, \quad t \to t + \epsilon \, \delta t$$

then there exists a conserved quantity (Noether charge):

$$Q = \sum_i \frac{\partial L}{\partial \dot{q}_i} \delta q_i - H \delta t$$

with $\frac{dQ}{dt} = 0$ along solutions of the equations of motion.

Examples

Time translation symmetry (L doesn't depend explicitly on t):

$$\text{Conserved: Energy } E = \sum_i p_i \dot{q}_i - L = H$$

Spatial translation symmetry (L doesn't depend on absolute position):

$$\text{Conserved: Momentum } \vec{p} = \sum_i m_i \dot{\vec{r}}_i$$

Rotation symmetry (L is rotationally invariant):

$$\text{Conserved: Angular momentum } \vec{L} = \sum_i \vec{r}_i \times \vec{p}_i$$

Gauge symmetry in electromagnetism:

$$\text{Conserved: Electric charge } Q$$

Significance

Noether's theorem unifies conservation laws with symmetries, providing deep insight into the structure of physical theories. It applies to classical mechanics, field theory, General Relativity, and quantum mechanics.

6. Field Theory and Lagrangian Density

For fields φ(x, t) distributed continuously in space, we generalize from discrete coordinates q_i to field values φ(x).

Action for Fields

The action is:

$$S[\phi] = \int \mathcal{L}(\phi, \partial_\mu \phi) \, d^4x$$

where $\mathcal{L}$ is the Lagrangian density and $\partial_\mu = (\partial/\partial t, \nabla)$.

Euler-Lagrange Equation for Fields

Extremizing the action yields:

$$\frac{\partial \mathcal{L}}{\partial \phi} - \partial_\mu \frac{\partial \mathcal{L}}{\partial(\partial_\mu \phi)} = 0$$

Example: Scalar Field

A real scalar field φ with mass m has Lagrangian density:

$$\mathcal{L} = \frac{1}{2}\partial_\mu \phi \partial^\mu \phi - \frac{1}{2}m^2 \phi^2$$

The Euler-Lagrange equation is the Klein-Gordon equation:

$$\partial_\mu \partial^\mu \phi + m^2 \phi = 0 \quad \Leftrightarrow \quad (\Box + m^2)\phi = 0$$

Energy-Momentum Tensor

By Noether's theorem, spacetime translation symmetry leads to a conserved energy-momentum tensor:

$$T^{\mu\nu} = \frac{\partial \mathcal{L}}{\partial(\partial_\mu \phi)} \partial^\nu \phi - g^{\mu\nu} \mathcal{L}$$

with $\partial_\mu T^{\mu\nu} = 0$ (energy-momentum conservation).

7. General Relativity and Einstein-Hilbert Action

Einstein's field equations of General Relativity can be derived from an action principle—the Einstein-Hilbert action.

Einstein-Hilbert Action

$$S_{\text{EH}} = \frac{c^4}{16\pi G} \int R \sqrt{-g} \, d^4x$$

where R is the Ricci scalar, g = det(g_μν) is the metric determinant, and $\sqrt{-g} \, d^4x$ is the invariant volume element.

Including Matter

The full action includes a matter term:

$$S = S_{\text{EH}} + S_{\text{matter}} = \frac{c^4}{16\pi G} \int R \sqrt{-g} \, d^4x + \int \mathcal{L}_{\text{matter}} \sqrt{-g} \, d^4x$$

Variation with Respect to Metric

Varying S with respect to g_μν yields Einstein's field equations:

$$R_{\mu\nu} - \frac{1}{2} R g_{\mu\nu} = \frac{8\pi G}{c^4} T_{\mu\nu}$$

where $T_{\mu\nu} = \frac{-2}{\sqrt{-g}} \frac{\delta S_{\text{matter}}}{\delta g^{\mu\nu}}$ is the energy-momentum tensor.

Cosmological Constant

Adding a cosmological constant term:

$$S = \frac{c^4}{16\pi G} \int (R - 2\Lambda) \sqrt{-g} \, d^4x + S_{\text{matter}}$$

gives:

$$R_{\mu\nu} - \frac{1}{2} R g_{\mu\nu} + \Lambda g_{\mu\nu} = \frac{8\pi G}{c^4} T_{\mu\nu}$$

8. Applications to Quantum Field Theory

Path Integral Formulation

In quantum field theory, Feynman's path integral formulation sums over all field configurations weighted by e^(iS/ℏ):

$$\langle \phi_f | \phi_i \rangle = \int \mathcal{D}\phi \, e^{iS[\phi]/\hbar}$$

The classical trajectory (extremum of S) dominates in the classical limit ℏ → 0 (stationary phase approximation).

Standard Model Lagrangian

The entire Standard Model of particle physics is encoded in a Lagrangian density including:

  • Fermion kinetic terms and Yukawa couplings
  • Gauge field kinetic terms (F_μν F^μν)
  • Higgs potential and spontaneous symmetry breaking
  • Covariant derivatives encoding gauge interactions

Quantum Gravity

Attempts to quantize gravity start with the Einstein-Hilbert action. Approaches include:

  • Path integral formulation: Sum over all metrics g_μν
  • Loop quantum gravity: Canonical quantization using Ashtekar variables derived from a constrained Hamiltonian
  • String theory: Polyakov action for worldsheet, effective spacetime actions

Variational principles remain central to all modern approaches to quantum gravity.