structural:expansion, linguistic:voice_change, structural:scholar_edition, quality:correction, information:classification
Example

A spherical pendulum consists of a mass m moving without friction on the surface of a sphere. The only forces acting on the mass are the reaction from the sphere and gravity. Spherical coordinates are used to describe the position of the mass in terms of (r, θ, φ), where r is fixed, r = ℓ.

The Lagrangian for this system is L = 1 2 m ℓ 2 (θ ˙ 2 + sin 2 θ φ ˙ 2) + m g ℓ cos θ. {\displaystyle L={\frac {1}{2}}m\ell ^{2}\left({\dot {\theta }}^{2}+\sin ^{2}\theta \ {\dot {\varphi }}^{2}\right)+mg\ell \cos \theta.}

Thus the Hamiltonian is H = P θ θ ˙ + P φ φ ˙ − L {\displaystyle H=P_{\theta }{\dot {\theta }}+P_{\varphi }{\dot {\varphi }}-L} where P θ = ∂ L ∂ θ ˙ = m ℓ 2 θ ˙ {\displaystyle P_{\theta }={\frac {\partial L}{\partial {\dot {\theta }}}}=m\ell ^{2}{\dot {\theta }}} and P φ = ∂ L ∂ φ ˙ = m ℓ 2 sin 2 θ φ ˙. {\displaystyle P_{\varphi }={\frac {\partial L}{\partial {\dot {\varphi }}}}=m\ell ^{2}\sin ^{2}\!\theta \,{\dot {\varphi }}.} In terms of coordinates and momenta, the Hamiltonian reads H = ⏟ T + ⏟ V = P θ 2 2 m ℓ 2 + P φ 2 2 m ℓ 2 sin 2 θ − m g ℓ cos θ. {\displaystyle H=\underbrace {\left} _{T}+\underbrace {{\Big }} _{V}={\frac {P_{\theta }^{2}}{2m\ell ^{2}}}+{\frac {P_{\varphi }^{2}}{2m\ell ^{2}\sin ^{2}\theta }}-mg\ell \cos \theta.} Hamilton's equations give the time evolution of coordinates and conjugate momenta in four first-order differential equations, θ ˙ = P θ m ℓ 2 φ ˙ = P φ m ℓ 2 sin 2 θ P θ ˙ = P φ 2 m ℓ 2 sin 3 θ cos θ − m g ℓ sin θ P φ ˙ = 0. {\displaystyle {\begin{aligned}{\dot {\theta }}&={P_{\theta } \over m\ell ^{2}}\\{\dot {\varphi }}&={P_{\varphi } \over m\ell ^{2}\sin ^{2}\theta }\\{\dot {P_{\theta }}}&={P_{\varphi }^{2} \over m\ell ^{2}\sin ^{3}\theta }\cos \theta -mg\ell \sin \theta \\{\dot {P_{\varphi }}}&=0.\end{aligned}}} Momentum P φ {\displaystyle P_{\varphi }}, which corresponds to the vertical component of angular momentum L z = ℓ sin θ × m ℓ sin θ φ ˙ {\displaystyle L_{z}=\ell \sin \theta \times m\ell \sin \theta \,{\dot {\varphi }}}, is a constant of motion. That is a consequence of the rotational symmetry of the system around the vertical axis. Being absent from the Hamiltonian, azimuth φ {\displaystyle \varphi } is a cyclic coordinate, which implies conservation of its conjugate momentum.