Physlib.ClassicalMechanics.Pendulum.SimplePendulum.Hamiltonian
The Hamiltonian formulation of the simple pendulum
i. Overview
This module gives the Hamiltonian formulation of the simple gravity pendulum, on the same one-dimensional Euclidean lift of the angle as `SimplePendulum.Basic`. The canonical momentum conjugate to the angle is the gradient of the Lagrangian in the angular velocity, the angular momentum `p = I θ̇` about the pivot; since the moment of inertia is positive, taking the canonical momentum is a linear equivalence between velocities and momenta. The Hamiltonian is the Legendre transform `H = ⟪p, θ̇⟫ - L` of the Lagrangian, which works out to the energy written on momentum-angle phase space, `H(t, p, θ) = ½ (1/I) ‖p‖² + V(θ)`; along any lift of the angle it is the energy of the lift. Hamilton's equations for the pendulum are packaged, as for the harmonic oscillator, into the vanishing of an operator on phase space, and for a smooth lift of the angle they are equivalent to the equation of motion of `SimplePendulum.Basic`.
ii. Key results
- `SimplePendulum.canonicalMomentum` is the canonical momentum `p = ∂L/∂θ̇ = I θ̇`, as a linear equivalence between velocities and momenta, with its value recorded by `canonicalMomentum_eq`. - `SimplePendulum.hamiltonian` is the Legendre transform of the Lagrangian, computed by `hamiltonian_eq` to be `½ (1/I) ‖p‖² + V(θ)`, smooth by `hamiltonian_contDiff`, with the two partial gradients `gradient_hamiltonian_position_eq` and `gradient_hamiltonian_momentum_eq`. - `SimplePendulum.hamiltonian_eq_energy` identifies the Hamiltonian, evaluated along any lift of the angle on its canonical momentum, with the energy of the lift. - `SimplePendulum.hamiltonEqOp` is the operator on momentum-angle phase space whose vanishing is Hamilton's equations, and `SimplePendulum.equationOfMotion_iff_hamiltonEqOp_eq_zero` proves that, for a smooth lift of the angle, Hamilton's equations are equivalent to the equation of motion. - `SimplePendulum.equationOfMotion_tfae` gathers the formulations into a single equivalence: for a smooth lift of the angle the equation of motion, its scalar form `θ̈ + ω² sin θ = 0`, Hamilton's equations, and the Lagrangian and Hamiltonian variational principles are all equivalent.
iii. Table of contents
- A. The canonical momentum and the Hamiltonian - A.1. The canonical momentum - A.2. The Hamiltonian - A.2.1. Equality for the Hamiltonian - A.2.2. Smoothness of the Hamiltonian - A.2.3. Gradients of the Hamiltonian - A.3. Relation between Hamiltonian and energy - A.4. Hamilton equation operator - A.5. Equation of motion if and only if Hamilton's equations - B. Equivalences between the formulations
iv. References
References for the Hamiltonian formulation of the simple pendulum include: - Landau & Lifshitz, Mechanics, 3rd ed., §40, for the canonical momentum, the Hamiltonian as the Legendre transform of the Lagrangian, and Hamilton's equations. - The module `Physlib.ClassicalMechanics.Pendulum.SimplePendulum.Basic`, whose Lagrangian, energy and equation of motion this module reformulates.
A. The canonical momentum and the Hamiltonian
We now turn to the Hamiltonian formulation of the simple pendulum. We define the canonical momentum and the Hamiltonian, relate the Hamiltonian to the energy, and show that the equation of motion is equivalent to Hamilton's equations.
A.1. The canonical momentum
We define the canonical momentum as the gradient of the Lagrangian with respect to the angular velocity. By `gradient_lagrangian_velocity_eq` this is the angular momentum `I θ̇` about the pivot, and since the moment of inertia is positive it is a linear equivalence between velocities and momenta.
A.2. The Hamiltonian
The Hamiltonian is defined as a function of time, canonical momentum and angle, as the Legendre transform ``` H = ⟪p, θ̇⟫ - L(t, θ, θ̇) ``` where the angular velocity `θ̇` is a function of `p` and `θ` through the inverse of the canonical momentum.
#### A.2.1. Equality for the Hamiltonian
We prove a simple equality for the Hamiltonian, to help in computations: it is the kinetic energy written in terms of the momentum, plus the potential energy.
#### A.2.2. Smoothness of the Hamiltonian
We show that the Hamiltonian is smooth in all its arguments jointly.
#### A.2.3. Gradients of the Hamiltonian
We now write down the gradients of the Hamiltonian with respect to the angle and the momentum. These are the two sides of Hamilton's equations.
A.3. Relation between Hamiltonian and energy
We show that the Hamiltonian, evaluated along any lift of the angle on the canonical momentum of the lift, is the energy. This is independent of whether the lift satisfies the equation of motion or not.
A.4. Hamilton equation operator
We define the operator on momentum-angle phase space whose vanishing is equivalent to Hamilton's equations.
A.5. Equation of motion if and only if Hamilton's equations
We show that, for a smooth lift of the angle, the equation of motion is equivalent to Hamilton's equations for the lift and its canonical momentum, that is to the vanishing of the Hamilton equation operator on the pair. The equation for the angle recovers the angular velocity, and the equation for the momentum is the balance of the rate of change of the angular momentum against the torque.
B. Equivalences between the formulations
We gather the formulations of the dynamics of the simple pendulum into a single equivalence. For a smooth lift of the angle the equation of motion, its scalar form, Hamilton's equations, the Lagrangian variational principle and the Hamiltonian variational principle are all equivalent. The equation of motion is itself the Newtonian formulation: the pointwise law is the rotational form of Newton's second law, so, unlike for the harmonic oscillator, no separate entry restates it. The equivalence of the equation of motion with the vanishing of the variational derivative of the action lives in section G.1 of the `Basic` module; the fourth entry states the same variational principle through the variational calculus directly.
11 declarations
Canonical momentum linear equivalence for a simple pendulum
For a simple pendulum at time and angular position in a one-dimensional Euclidean space , the canonical momentum is defined as the linear equivalence between the space of angular velocities and the space of angular momenta (both represented by ). The mapping takes a velocity to the momentum via the gradient of the Lagrangian with respect to velocity: where is the moment of inertia. The inverse of this map is given by .
Canonical Momentum of a Simple Pendulum
For a simple pendulum at time with angular position and angular velocity , the canonical momentum is equal to , where is the moment of inertia of the pendulum.
Hamiltonian of a simple pendulum
The Hamiltonian of a simple pendulum is a function of time , canonical momentum , and angular position (modeled in a one-dimensional Euclidean space). It is defined as the Legendre transform of the Lagrangian : where the angular velocity is obtained from the momentum via the inverse of the canonical momentum linear equivalence at time and position .
The Hamiltonian of a simple pendulum is
The Hamiltonian of a simple pendulum, as a function of time , canonical momentum , and angular position (represented in a one-dimensional Euclidean space), is equal to the kinetic energy expressed in terms of the momentum plus the potential energy . Specifically, it is given by: where is the moment of inertia of the pendulum, is the potential energy function, and denotes the standard inner product on the one-dimensional Euclidean space.
The Hamiltonian of the Simple Pendulum is Smooth ()
For any , the Hamiltonian of the simple pendulum is -times continuously differentiable () with respect to time , canonical momentum , and angular position jointly.
for the simple pendulum
For a simple pendulum with Hamiltonian and potential energy , the gradient of the Hamiltonian with respect to the angular position at any time and momentum is equal to the gradient of the potential energy with respect to : Physically, this gradient represents the negative of the torque acting on the pendulum.
for the Simple Pendulum
For a simple pendulum with moment of inertia , the gradient of the Hamiltonian with respect to the canonical momentum at any time and angular position is given by where and are represented as elements of a one-dimensional Euclidean space . This gradient corresponds to the angular velocity recovered from the momentum.
The Hamiltonian of the simple pendulum equals the energy along any trajectory
For any trajectory of the angular position of a simple pendulum, let be the canonical momentum at time corresponding to the angular velocity , defined by the linear equivalence (where is the moment of inertia). The Hamiltonian evaluated along this trajectory and its canonical momentum is equal to the total energy of the trajectory: This equality holds for any trajectory , regardless of whether it satisfies the pendulum's equation of motion.
Hamilton equation operator of the simple pendulum
For a momentum trajectory and an angular position trajectory of a simple pendulum, the Hamilton equation operator is the function mapping each time to the pair: where is the Hamiltonian of the simple pendulum, and are the time derivatives of the trajectories, and and are the gradients of the Hamiltonian with respect to momentum and position, respectively. The vanishing of this operator characterizes the trajectories that satisfy the classical Hamilton's equations.
for the Simple Pendulum
Let be a smooth () trajectory representing the angular position of a simple pendulum. Let be the canonical momentum trajectory defined by , where is the moment of inertia. Then, satisfies the pendulum's equation of motion if and only if the Hamilton equation operator vanishes on the pair , which corresponds to the satisfaction of Hamilton's equations: where is the Hamiltonian of the system.
Equivalence of Dynamical Formulations for the Simple Pendulum
Let be a smooth trajectory of a simple pendulum. The following formulations of the dynamics are equivalent: 1. **Newtonian Equation of Motion:** The pointwise rotational Newton law balancing the rate of change of angular momentum against the gravitational torque: . 2. **Scalar Equation of Motion:** The mass-independent second-order differential equation: , where is the angular frequency. 3. **Hamilton's Equations:** The vanishing of the Hamilton equation operator for the trajectory and its conjugate canonical momentum . 4. **Lagrangian Variational Principle:** The vanishing of the variational gradient of the action integral , where is the Lagrangian of the system. 5. **Hamiltonian Variational Principle:** The vanishing of the variational gradient of the phase-space action , evaluated at the pair of the canonical momentum and the trajectory .
