physics2u
Depth
PU-201 / L24 · lecture

Canonical Transformations and Generating Functions

~6 min read · Tier toggle changes depth (T1 plain · T2 standard · T3 rigour)

BEFORE YOU START

You should be comfortable with Hamilton's equations of motion and the definition of the symplectic form in phase space. Familiarity with total differentials and partial derivatives of multivariable functions is essential.

Why this matters

Generating functions provide a systematic, algebraic method for finding new canonical coordinates that simplify complex dynamical systems.

In analytical mechanics, the choice of coordinates is not merely a convenience; it is a powerful tool for solving problems. While Newtonian mechanics relies on forces, Hamiltonian mechanics relies on the structure of phase space. A canonical transformation preserves the form of Hamilton's equations, allowing us to switch to variables where the dynamics are trivial, such as action-angle variables for periodic motion. The theory of generating functions classifies all possible such transformations, bridging the gap between the Lagrangian and Hamiltonian formalisms and laying the groundwork for the quantum mechanical correspondence principle.

The Geometric Intuition

Imagine phase space as a landscape where the "shape" of the terrain is defined by the symplectic structure. This structure dictates how positions and momenta interact. A canonical transformation is like rotating or reshaping this landscape without changing its fundamental geometric properties. The key requirement is that the "area" in phase space, represented by the product of position and momentum changes, must be preserved. This preservation ensures that the equations of motion retain their standard form. Instead of guessing new variables, we use a single scalar function, the generating function, to encode the relationship between the old and new variables. This function acts as a bridge, ensuring that the transformation is canonical by construction.

The Fundamental Condition

The criterion for a transformation \((q, p) \to (Q, P)\) to be canonical is the invariance of the Hamiltonian one-form. Specifically, the difference between the old and new momentum-position products must be an exact differential. This condition is expressed as:

\[ p\,dq - H\,dt = P\,dQ - K\,dt + dF \]

Here, \(H\) and \(K\) are the old and new Hamiltonians, respectively, and \(F\) is the generating function. The time dependence is handled by adding the term \(-H\,dt\) to account for the explicit time evolution. If we choose a generating function that depends on a mix of old and new variables, we can solve for the transformation relations. The most common choice is \(F_2(q, P, t)\), which depends on the old coordinates \(q\) and the new momenta \(P\).

Types of Generating Functions

There are four standard types of generating functions, each depending on a different combination of old and new variables. The most frequently used is \(F_2(q, P, t)\). For this type, the transformation equations are derived by taking partial derivatives of \(F_2\):

\[ p = \frac{\partial F_2}{\partial q}, \quad Q = \frac{\partial F_2}{\partial P} \]

Another common type is \(F_1(q, Q, t)\), which depends on the old coordinates \(q\) and the new coordinates \(Q\). The relations for this type are:

\[ p = \frac{\partial F_1}{\partial q}, \quad P = -\frac{\partial F_1}{\partial Q} \]

These relations ensure that the Jacobian determinant of the transformation is unity, preserving the symplectic volume. The choice of generating function is often dictated by the physical problem; for instance, if the new momenta are known functions of the old coordinates, \(F_2\) is the natural choice.

Infinitesimal Transformations

Many physically important transformations are infinitesimal, meaning the new variables differ from the old ones by a small amount. Consider a transformation where \(Q = q + \epsilon Q'(q, p)\) and \(P = p + \epsilon P'(q, p)\), with \(\epsilon\) being a small parameter. The generating function for such a transformation can be expanded in a power series of \(\epsilon\). The first-order term in this expansion is related to the Poisson bracket of the old variables with a function \(G(q, p)\), known as the generator of the transformation.

\[ Q \approx q + \epsilon \{q, G\}, \quad P \approx p + \epsilon \{p, G\} \]

This connection reveals that canonical transformations are generated by Poisson brackets. This insight is crucial for understanding the symmetry properties of physical systems, as Noether's theorem links continuous symmetries to conserved quantities, which in turn generate canonical transformations.

The derivation

◆ DERIVATION EMBED · D-135 · not re-derived here

Canonical Transformations and Generating Functions

A change of phase-space variables (q,p) → (Q,P) preserves the form of Hamilton's equations if and only if there exists a generating function F such that p q̇ − H = P Q̇ − K + dF/dt. Choosing F to depend on one old and one new variable yields exactly four types — F1(q,Q,t), F2(q,P,t), F3(p,Q,t), F4(p,P,t) — whose partial derivatives supply the transformation equations and the new Hamiltonian K = H + ∂F/∂t.

F1(q,Q): p=∂qF1, P=−∂QF1  •   F2(q,P): p=∂qF2, Q=∂PF2
F3(p,Q): q=−∂pF3, P=−∂QF3  •   F4(p,P): q=−∂pF4, Q=∂PF4
and in all four cases   K = H + ∂F/∂t
Open full derivation →
Tier 3 · watch out

A common pitfall is assuming that any function \(F(q, Q)\) can serve as a generating function. For \(F_1\) to be valid, the Hessian matrix of second derivatives \(\partial^2 F_1 / \partial q_i \partial Q_j\) must be non-singular. If this determinant vanishes, the transformation is not locally invertible, and the canonical structure breaks down. This singularity often occurs at caustics or turning points in classical trajectories, where the mapping from old to new coordinates becomes multi-valued. C

Worked example

Problem. For the oscillator \(H = \frac{p^2}{2m} + \frac{1}{2}m\omega^2 q^2\), use the type-1 generating function \(F_1(q, Q) = \frac{1}{2} m\omega q^2 \cot Q\) to find the new variables, the new Hamiltonian and the motion. Then take \(m = 2.0\ \mathrm{kg}\), \(\omega = 2.0\ \mathrm{rad/s}\) (that is \(k = 8.0\ \mathrm{N/m}\)) and energy \(E = 4.0\ \mathrm{J}\).

  1. Old momentum: \(p = \partial F_1/\partial q = m\omega q \cot Q\). New momentum: \(P = -\partial F_1/\partial Q = \dfrac{m\omega q^2}{2\sin^2 Q}\).
  2. Solve for the old variables: \(q = \sqrt{2P/(m\omega)}\,\sin Q\) and \(p = \sqrt{2m\omega P}\,\cos Q\).
  3. New Hamiltonian (\(F_1\) has no explicit time dependence, so \(K = H\)): \(K = \omega P(\cos^2 Q + \sin^2 Q) = \omega P\). \(Q\) is cyclic.
  4. Hamilton's equations: \(\dot P = -\partial K/\partial Q = 0\) and \(\dot Q = \partial K/\partial P = \omega\), so \(P = E/\omega\) and \(Q = \omega t + \varphi\).
  5. Numbers: \(P = 4.0/2.0 = 2.0\ \mathrm{J\,s}\); amplitude \(\sqrt{2P/(m\omega)} = \sqrt{4.0/4.0} = 1.0\ \mathrm{m}\); check \(\tfrac{1}{2}k(1.0)^2 = 4.0\ \mathrm{J} = E\).
\[ K = \omega P,\quad q(t) = (1.0\ \mathrm{m})\,\sin(2.0\,t + \varphi),\quad P = 2.0\ \mathrm{J\,s} \]

Units check. \(F_1\) has units \(\mathrm{kg\,s^{-1}\,m^2} = \mathrm{J\,s}\), like \(p\,q\); \(Q\) is an angle, so \(P = -\partial F_1/\partial Q\) is in \(\mathrm{J\,s}\) (an action) and \(K = \omega P\) is in joules. Here \(P\) is exactly the action variable \(J = E/\omega\) of a later lecture.

CHECK YOURSELF

Three quick tests

  1. What is the primary condition for a transformation to be canonical?
    AnswerThe difference between the old and new Hamiltonian one-forms must be an exact differential.
  2. For a generating function \(F_2(q, P)\), what is the expression for the new coordinate \(Q\)?
    Answer\(Q = \frac{\partial F_2}{\partial P}\).
  3. Why is the non-singularity of the Hessian matrix important for \(F_1\)?
    AnswerIt ensures the transformation is locally invertible, preserving the canonical structure.
PROBLEMS

Problem set for PU-201 →

Each derivation in this unit ends with five graded problems with full solutions.

NOTES

Lecture notes drafted with a local model and checked line by line by the editor; every number in the worked example was recomputed.

Derivations cited: D-135 · Threads: force, energy, symmetry