Classical mechanics · PhysLib theorem

Harmonic Oscillator Energy Conservation

For PhysLib's one-dimensional undamped oscillator, every smooth motion satisfying the equation of motion keeps its total energy equal to the initial value.

Provided by PhysLibLean checkedMeaning reviewed

What it says

What the theorem says

The energy is kinetic plus quadratic spring potential. The theorem assumes PhysLib's positive-mass, positive-spring-constant undamped oscillator and does not cover driving, damping, or quantum motion.

Context

Why it matters

The harmonic oscillator is the model behind vibrations, waves, and quantum modes; energy conservation makes its phase-space motion immediately visible.

Inside the proof

Proof architecture

The proof first shows that energy has zero time derivative along any sufficiently smooth trajectory satisfying the oscillator equation, then turns that differential fact into equality with the initial energy.

Step 1

Differentiate kinetic plus spring energy

A supporting lemma rewrites the energy derivative, substitutes Newton's equation of motion, and simplifies the linear restoring force until the derivative vanishes.

∂ₜ(S.energy xₜ) = 0

Show the Lean ingredients
energy_derivequationOfMotion_iff_newtons_2nd_lawforce_eq_linear

Step 2

Carry the zero derivative into the constant-energy theorem

The constant-energy theorem invokes the zero-derivative result, then rewrites the time derivative as the Fréchet derivative used by the next step.

h1 := S.energy_conservation_of_equationOfMotion xₜ hx h

Show the Lean ingredients
have h1 := S.energy_conservation_of_equationOfMotionunfold Time.deriv at h1

Step 3

A zero derivative makes the energy constant

Differentiability and the pointwise zero derivative satisfy the constant-function theorem, yielding equality between energy at arbitrary time t and at time zero.

S.energy xₜ t = S.energy xₜ 0

Show the Lean ingredients
is_const_of_fderiv_eq_zeroenergy_differentiablesimpa using h1 t

Authoritative formal type

Exact PhysLib statement

ClassicalMechanics.HarmonicOscillator.energy_conservation_of_equationOfMotion' (S : ClassicalMechanics.HarmonicOscillator) (xₜ : Time → EuclideanSpace ℝ (Fin 1)) (hx : ContDiff ℝ (↑⊤) xₜ) (h : S.EquationOfMotion xₜ) (t : Time) : S.energy xₜ t = S.energy xₜ 0

This is the theorem's exact Lean type. The diagrams and commentary are explanatory; the pinned statement and source are authoritative.

How PhysAtlas uses it

Also in the main atlas

This page points directly to PhysLib's theorem. PhysAtlas has reviewed the narrow one-dimensional undamped-oscillator interpretation; the formal proof remains PhysLib's.

View this theorem in the main PhysAtlas: Harmonic Oscillator Energy Conservation

Recorded connections

How this result fits

A one-step view of the published results directly connected to this page.

6 direct connections

Only recorded public relationships are shown. A shared topic does not imply a dependency, and this is not a complete Lean proof-term dependency graph.

Open this result in the full theorem map6 direct connections

Provenance and verification

Sources and technical checks

Show declaration provenance and Lean checks
PhysLib declarationClassicalMechanics.HarmonicOscillator.energy_conservation_of_equationOfMotion'
Source modulePhyslib.ClassicalMechanics.HarmonicOscillator.Basic
Source footprint16 nonempty lines in this declaration · 709 nonempty lines in its module
Checked commit6bd0b4b99d3d
Reported Lean axiomspropext, Classical.choice, Quot.sound
Unresolved placeholdersNo sorryAx reported

View theorem in PhysLib ↗

The declaration footprint describes source layout, not proof difficulty or the size of its dependencies. The pinned checks verify the cited Lean theorem; semantic review remains a separate PhysAtlas judgment.

Expanded visual

Explanatory image · not evidence.

Open original in a new tab