Legendre Transform

From Canonica AI

Introduction

The Legendre transform is a mathematical operation that is widely used in various fields such as thermodynamics, classical mechanics, and optimization. It is a technique that transforms one set of variables into another, often simplifying the mathematical treatment of a problem. The transform is named after the French mathematician Adrien-Marie Legendre, who made significant contributions to the field of mathematics in the 18th and 19th centuries.

Mathematical Definition

The Legendre transform is defined for a real-valued convex function \( f(x) \) of a real variable \( x \). The transform produces a new function \( g(p) \), where \( p \) is the derivative of \( f \) with respect to \( x \). The Legendre transform is given by:

\[ g(p) = \sup_{x} \{ px - f(x) \} \]

where \( \sup \) denotes the supremum. The function \( g(p) \) is the Legendre transform of \( f(x) \), and it is also a convex function. The variable \( p \) is often referred to as the conjugate variable.

Properties of the Legendre Transform

The Legendre transform has several important properties:

1. **Involution**: The Legendre transform is an involution, meaning that applying the transform twice returns the original function. Mathematically, if \( g(p) \) is the Legendre transform of \( f(x) \), then \( f(x) \) is the Legendre transform of \( g(p) \).

2. **Convexity**: The Legendre transform preserves convexity. If \( f(x) \) is a convex function, then its Legendre transform \( g(p) \) is also convex.

3. **Duality**: The Legendre transform establishes a duality between the original function and its transform. This duality is particularly useful in optimization problems, where it can simplify the problem by transforming constraints into dual variables.

Applications in Physics

The Legendre transform is extensively used in physics, particularly in the formulation of thermodynamics and classical mechanics.

Thermodynamics

In thermodynamics, the Legendre transform is used to switch between different thermodynamic potentials. For example, the internal energy \( U(S, V) \) as a function of entropy \( S \) and volume \( V \) can be transformed into the Helmholtz free energy \( F(T, V) \) as a function of temperature \( T \) and volume \( V \) using the Legendre transform. This transformation is crucial for analyzing systems at constant temperature and volume.

Classical Mechanics

In classical mechanics, the Legendre transform is used to derive the Hamiltonian from the Lagrangian. The Lagrangian \( L(q, \dot{q}, t) \) is a function of generalized coordinates \( q \), their time derivatives \( \dot{q} \), and time \( t \). The Hamiltonian \( H(q, p, t) \) is obtained by performing a Legendre transform with respect to \( \dot{q} \), where \( p \) is the conjugate momentum defined as \( p = \frac{\partial L}{\partial \dot{q}} \).

Mathematical Examples

Consider the function \( f(x) = \frac{1}{2} x^2 \). Its derivative is \( f'(x) = x \), so the conjugate variable \( p = x \). The Legendre transform is:

\[ g(p) = \sup_{x} \{ px - \frac{1}{2} x^2 \} \]

Setting the derivative with respect to \( x \) to zero gives \( p = x \), so:

\[ g(p) = p^2 - \frac{1}{2} p^2 = \frac{1}{2} p^2 \]

Thus, the Legendre transform of \( f(x) = \frac{1}{2} x^2 \) is \( g(p) = \frac{1}{2} p^2 \).

Advanced Topics

Legendre Transform in Optimization

In optimization, the Legendre transform is used to convert a primal problem into a dual problem. This is particularly useful in convex optimization, where the dual problem often provides insights into the properties of the primal problem.

Legendre-Fenchel Transform

The Legendre-Fenchel transform generalizes the Legendre transform to non-convex functions. It is defined as:

\[ g(p) = \sup_{x} \{ px - f(x) \} \]

for any real-valued function \( f(x) \). The Legendre-Fenchel transform is widely used in functional analysis and optimization.

Image

See Also