PhysLean Documentation

PhysLean.ClassicalMechanics.HamiltonsEquations

Hamilton's equations #

In this module, given a Hamiltonian function H : Time → X → X → ℝ, we define the operator hamiltonEqOp whichn when equals zero implies hamilton's equations.

We show that the variational derivative of the action functional ∫ ⟪p, dq/dt⟫ - H(t, p, q) dt is equal to the hamiltonEqOp applied to (p, q).

noncomputable def ClassicalMechanics.hamiltonEqOp {X : Type} [NormedAddCommGroup X] [InnerProductSpace X] [CompleteSpace X] (H : TimeXX) (p q : TimeX) :
TimeX × X

Given a hamiltonian H : Time → X → X → ℝ the operator which when set to zero implies the Hamilton equations.

Equations
Instances For
    theorem ClassicalMechanics.hamiltonEqOp_eq {X : Type} [NormedAddCommGroup X] [InnerProductSpace X] [CompleteSpace X] (H : TimeXX) (p q : TimeX) :
    hamiltonEqOp H p q = fun (t : Time) => (Time.deriv q t + -gradient (fun (x : X) => H t x (q t)) (p t), -Time.deriv p t + -gradient (fun (x : X) => H t (p t) x) (q t))
    theorem ClassicalMechanics.hamiltonEqOp_eq_zero_iff_hamiltons_equations {X : Type} [NormedAddCommGroup X] [InnerProductSpace X] [CompleteSpace X] (H : TimeXX) (p q : TimeX) :
    hamiltonEqOp H p q = 0 (∀ (t : Time), Time.deriv q t = gradient (fun (x : X) => H t x (q t)) (p t)) ∀ (t : Time), Time.deriv p t = -gradient (fun (x : X) => H t (p t) x) (q t)
    theorem ClassicalMechanics.hamiltons_equations_varGradient {X : Type} [NormedAddCommGroup X] [InnerProductSpace X] [CompleteSpace X] (H : TimeXX) (pq : TimeX × X) (hp : ContDiff (↑) pq) (hL : ContDiff H) :
    varGradient (fun (pq' : TimeX × X) (t : Time) => inner (pq' t).1 (Time.deriv (Prod.snd pq') t) - H t (pq' t).1 (pq' t).2) pq = fun (t : Time) => hamiltonEqOp H (fun (t : Time) => (pq t).1) (fun (t : Time) => (pq t).2) t