Imports
/-
Copyright (c) 2025 Tomas Skrivan. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Tomas Skrivan, Joseph Tooby-Smith
-/
module
public import Physlib.Mathematics.VariationalCalculus.HasVarGradient
public import Physlib.SpaceAndTime.Time.DerivativesEuler-Lagrange equations
In this module we define the Euler-Lagrange operator eulerLagrangeOp,
and prove the that the variational derivative of the action functional
∫ L(t, q(t), dₜ q(t)) dt is equal to the Euler-Lagrange operator applied to the trajectory q.
@[expose] public sectionlemma eulerLagrangeOp_eq (L : Time → X → X → ℝ) (q : Time → X) :
eulerLagrangeOp L q = fun t => gradient (L t · (∂ₜ q t)) (q t)
- ∂ₜ (fun t' => gradient (L t' (q t') ·) (∂ₜ q t')) t := X:Typeinst✝²:NormedAddCommGroup Xinst✝¹:InnerProductSpace ℝ Xinst✝:CompleteSpace XL:Time → X → X → ℝq:Time → X⊢ eulerLagrangeOp L q = fun t =>
gradient (fun x => L t x (∂ₜ q t)) (q t) - ∂ₜ (fun t' => gradient (fun x => L t' (q t') x) (∂ₜ q t')) t All goals completed! 🐙lemma eulerLagrangeOp_zero (q : Time → X) :
eulerLagrangeOp (fun _ _ _ => 0) q = fun _ => 0 := X:Typeinst✝²:NormedAddCommGroup Xinst✝¹:InnerProductSpace ℝ Xinst✝:CompleteSpace Xq:Time → X⊢ eulerLagrangeOp (fun x x_1 x_2 => 0) q = fun x => 0
All goals completed! 🐙e_a.e_f X:Typeinst✝²:NormedAddCommGroup Xinst✝¹:InnerProductSpace ℝ Xinst✝:CompleteSpace XL:Time → X → X → ℝq:Time → Xhq:ContDiff ℝ ∞ qhL:ContDiff ℝ ∞ ↿Lt✝:Timet:Time⊢ DifferentiableAt ℝ ↿(L t) (q t, (fderiv ℝ q t) 1)e_a.e_f X:Typeinst✝²:NormedAddCommGroup Xinst✝¹:InnerProductSpace ℝ Xinst✝:CompleteSpace XL:Time → X → X → ℝq:Time → Xhq:ContDiff ℝ ∞ qhL:ContDiff ℝ ∞ ↿Lt✝:Timet:Time⊢ DifferentiableAt ℝ (fun x => L t (q t) x) ((fderiv ℝ q t) 1) <;> e_a.e_f X:Typeinst✝²:NormedAddCommGroup Xinst✝¹:InnerProductSpace ℝ Xinst✝:CompleteSpace XL:Time → X → X → ℝq:Time → Xhq:ContDiff ℝ ∞ qhL:ContDiff ℝ ∞ ↿Lt✝:Timet:Time⊢ DifferentiableAt ℝ ↿(L t) (q t, (fderiv ℝ q t) 1)e_a.e_f X:Typeinst✝²:NormedAddCommGroup Xinst✝¹:InnerProductSpace ℝ Xinst✝:CompleteSpace XL:Time → X → X → ℝq:Time → Xhq:ContDiff ℝ ∞ qhL:ContDiff ℝ ∞ ↿Lt✝:Timet:Time⊢ DifferentiableAt ℝ (fun x => L t (q t) x) ((fderiv ℝ q t) 1)
apply ContDiff.differentiable (n := ∞) (by X:Typeinst✝²:NormedAddCommGroup Xinst✝¹:InnerProductSpace ℝ Xinst✝:CompleteSpace XL:Time → X → X → ℝq:Time → Xhq:ContDiff ℝ ∞ qhL:ContDiff ℝ ∞ ↿Lt✝:Timet:Time⊢ ContDiff ℝ ∞ fun x => L t (q t) x fun_prop All goals completed! 🐙) (by X:Typeinst✝²:NormedAddCommGroup Xinst✝¹:InnerProductSpace ℝ Xinst✝:CompleteSpace XL:Time → X → X → ℝq:Time → Xhq:ContDiff ℝ ∞ qhL:ContDiff ℝ ∞ ↿Lt✝:Timet:Time⊢ ∞ ≠ 0 simp All goals completed! 🐙)