Imports
/- Copyright (c) 2025 Joseph Tooby-Smith. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Joseph Tooby-Smith -/ module public import Physlib.QuantumMechanics.HarmonicOscillator.OneDimension.Eigenfunction

The time-independent Schrodinger equation

@[expose] public section

Derivatives of the eigenfunctions

Q:HarmonicOscillatorx:ℝh1:deriv (fun x => Complex.exp (-↑x ^ 2 / (2 * ↑Q.ξ ^ 2))) x = -↑x / ↑Q.ξ ^ 2 * Complex.exp (-↑x ^ 2 / (2 * ↑Q.ξ ^ 2))⊢ 1 / ↑√(√Real.pi * Q.ξ) * (-↑x / ↑Q.ξ ^ 2 * Complex.exp (-↑x ^ 2 / (2 * ↑Q.ξ ^ 2))) = -↑1 / ↑(Q.ξ ^ 2) * (↑x * (1 / ↑√(√Real.pi * Q.ξ) * Complex.exp (-↑x ^ 2 / (2 * ↑Q.ξ ^ 2)))) Q:HarmonicOscillatorx:ℝh1:deriv (fun x => Complex.exp (-↑x ^ 2 / (2 * ↑Q.ξ ^ 2))) x = -↑x / ↑Q.ξ ^ 2 * Complex.exp (-↑x ^ 2 / (2 * ↑Q.ξ ^ 2))⊢ (↑√Q.ξ)⁻¹ * (↑√√Real.pi)⁻¹ * (-↑x / ↑Q.ξ ^ 2 * Complex.exp (-↑x ^ 2 / (2 * ↑Q.ξ ^ 2))) = -1 / ↑Q.ξ ^ 2 * (↑x * ((↑√Q.ξ)⁻¹ * (↑√√Real.pi)⁻¹ * Complex.exp (-↑x ^ 2 / (2 * ↑Q.ξ ^ 2)))) All goals completed! 🐙Q:HarmonicOscillator⊢ ↑(-1 / Q.ξ ^ 2) • Complex.ofReal * Q.eigenfunction 0 = (-↑√2 / (2 * ↑Q.ξ)) • Q.eigenfunction 1 Q:HarmonicOscillatorx:ℝ⊢ (↑(-1 / Q.ξ ^ 2) • Complex.ofReal * Q.eigenfunction 0) x = ((-↑√2 / (2 * ↑Q.ξ)) • Q.eigenfunction 1) x Q:HarmonicOscillatorx:ℝ⊢ -1 / ↑Q.ξ ^ 2 * ↑x * ((↑√Q.ξ)⁻¹ * (↑√√Real.pi)⁻¹ * Complex.exp (-↑x ^ 2 / (2 * ↑Q.ξ ^ 2))) = -↑√2 / (2 * ↑Q.ξ) * ((↑√2)⁻¹ * ((↑√Q.ξ)⁻¹ * (↑√√Real.pi)⁻¹) * (2 * (↑x / ↑Q.ξ) * Complex.exp (-↑x ^ 2 / (2 * ↑Q.ξ ^ 2)))) Q:HarmonicOscillatorx:ℝ⊢ -((↑Q.ξ)⁻¹ ^ 2 * ↑x * (↑√Q.ξ)⁻¹ * (↑√√Real.pi)⁻¹ * Complex.exp ((↑Q.ξ)⁻¹ ^ 2 * ↑x ^ 2 * (-1 / 2))) = -((↑Q.ξ)⁻¹ ^ 2 * ↑x * (↑√Q.ξ)⁻¹ * (↑√√Real.pi)⁻¹ * Complex.exp ((↑Q.ξ)⁻¹ ^ 2 * ↑x ^ 2 * (-1 / 2)) * ↑√2 * (↑√2)⁻¹) All goals completed! 🐙Q:HarmonicOscillatorn:ℕx:ℝhd:DifferentiableAt ℝ (↑(physHermite n) ∘ fun x => x / Q.ξ) x⊢ ↑(deriv (↑(physHermite n)) (x / Q.ξ) * deriv (fun x => x / Q.ξ) x) = ↑(1 / Q.ξ) * 2 * ↑n * ↑(↑(physHermite (n - 1)) (x / Q.ξ)) Q:HarmonicOscillatorn:ℕx:ℝhd:DifferentiableAt ℝ (↑(physHermite n) ∘ fun x => x / Q.ξ) x⊢ 2 * ↑n * ↑(↑(physHermite (n - 1)) (x / Q.ξ)) * ↑(1 / Q.ξ) = ↑(1 / Q.ξ) * 2 * ↑n * ↑(↑(physHermite (n - 1)) (x / Q.ξ)) All goals completed! 🐙Q:HarmonicOscillatorn:ℕx:ℝ⊢ (↑√↑(n + 1)!)⁻¹ * (↑√(2 ^ (n + 1)))⁻¹ * (fun x => ↑(1 / Q.ξ) * 2 * ↑(n + 1) * ↑(↑(physHermite (n + 1 - 1)) (x / Q.ξ))) x * Q.eigenfunction 0 x + (↑√↑(n + 1)!)⁻¹ * (↑√(2 ^ (n + 1)))⁻¹ * ↑(↑(physHermite (n + 1)) (x / Q.ξ)) * (↑(-1 / Q.ξ ^ 2) • Complex.ofReal * Q.eigenfunction 0) x = (↑√↑(n + 1)!)⁻¹ * (↑√(2 ^ (n + 1)))⁻¹ * (↑Q.ξ)⁻¹ * ((2 * (↑n + 1) * ↑(↑(physHermite n) (x / Q.ξ)) - ↑x / ↑Q.ξ * ↑(↑(physHermite (n + 1)) (x / Q.ξ))) * Q.eigenfunction 0 x) Q:HarmonicOscillatorn:ℕx:ℝ⊢ (↑√↑(n + 1)!)⁻¹ * (↑√(2 ^ (n + 1)))⁻¹ * ((↑Q.ξ)⁻¹ * 2 * (↑n + 1) * ↑(↑(physHermite n) (x / Q.ξ))) * Q.eigenfunction 0 x + (↑√↑(n + 1)!)⁻¹ * (↑√(2 ^ (n + 1)))⁻¹ * ↑(↑(physHermite (n + 1)) (x / Q.ξ)) * (-1 / ↑Q.ξ ^ 2 * ↑x * Q.eigenfunction 0 x) = (↑√↑(n + 1)!)⁻¹ * (↑√(2 ^ (n + 1)))⁻¹ * (↑Q.ξ)⁻¹ * ((2 * (↑n + 1) * ↑(↑(physHermite n) (x / Q.ξ)) - ↑x / ↑Q.ξ * ↑(↑(physHermite (n + 1)) (x / Q.ξ))) * Q.eigenfunction 0 x) All goals completed! 🐙

Second derivatives of the eigenfunctions.

Q:HarmonicOscillatorx:ℝ⊢ -(↑1 / ↑(Q.ξ ^ 2)) * (1 * Q.eigenfunction 0 x + ↑x * (↑(-1 / Q.ξ ^ 2) • Complex.ofReal * Q.eigenfunction 0) x) = -1 / ↑Q.ξ ^ 2 * (1 + -1 / ↑Q.ξ ^ 2 * ↑x ^ 2) * Q.eigenfunction 0 x Q:HarmonicOscillatorx:ℝ⊢ -(↑1 / ↑(Q.ξ ^ 2) * (1 * Q.eigenfunction 0 x + ↑x * (-↑1 / ↑(Q.ξ ^ 2) * ↑x * Q.eigenfunction 0 x))) = -1 / ↑Q.ξ ^ 2 * (1 + -1 / ↑Q.ξ ^ 2 * ↑x ^ 2) * Q.eigenfunction 0 x Q:HarmonicOscillatorx:ℝ⊢ -(1 / ↑Q.ξ ^ 2 * (1 * Q.eigenfunction 0 x + ↑x * (-1 / ↑Q.ξ ^ 2 * ↑x * Q.eigenfunction 0 x))) = -1 / ↑Q.ξ ^ 2 * (1 + -1 / ↑Q.ξ ^ 2 * ↑x ^ 2) * Q.eigenfunction 0 x All goals completed! 🐙Q:HarmonicOscillatorn:ℕx:ℝ⊢ 2 * (↑n + 1) * deriv (fun x => ↑(↑(physHermite n) (x / Q.ξ))) x - (deriv (fun x => ↑x / ↑Q.ξ) x * ↑(↑(physHermite (n + 1)) (x / Q.ξ)) + ↑x / ↑Q.ξ * deriv (fun x => ↑(↑(physHermite (n + 1)) (x / Q.ξ))) x) + (2 * (↑n + 1) * ↑(↑(physHermite n) (x / Q.ξ)) - ↑x / ↑Q.ξ * ↑(↑(physHermite (n + 1)) (x / Q.ξ))) * (-↑1 / ↑(Q.ξ ^ 2)) * ↑x = 2 * (↑n + 1) * deriv (fun x => ↑(↑(physHermite n) (x / Q.ξ))) x + -((↑Q.ξ ^ 2)⁻¹ * 4 * (↑n + 1) * ↑x * ↑(↑(physHermite n) (x / Q.ξ))) + -((↑Q.ξ)⁻¹ * (1 + -((↑Q.ξ ^ 2)⁻¹ * ↑x ^ 2)) * ↑(↑(physHermite (n + 1)) (x / Q.ξ))) Q:HarmonicOscillatorn:ℕx:ℝ⊢ 2 * (↑n + 1) * deriv (fun x => ↑(↑(physHermite n) (x / Q.ξ))) x - ((↑Q.ξ)⁻¹ * ↑(↑(physHermite (n + 1)) (x / Q.ξ)) + ↑x / ↑Q.ξ * deriv (fun x => ↑(↑(physHermite (n + 1)) (x / Q.ξ))) x) + (2 * (↑n + 1) * ↑(↑(physHermite n) (x / Q.ξ)) - ↑x / ↑Q.ξ * ↑(↑(physHermite (n + 1)) (x / Q.ξ))) * (-1 / ↑Q.ξ ^ 2) * ↑x = 2 * (↑n + 1) * deriv (fun x => ↑(↑(physHermite n) (x / Q.ξ))) x + -((↑Q.ξ ^ 2)⁻¹ * 4 * (↑n + 1) * ↑x * ↑(↑(physHermite n) (x / Q.ξ))) + -((↑Q.ξ)⁻¹ * (1 + -((↑Q.ξ ^ 2)⁻¹ * ↑x ^ 2)) * ↑(↑(physHermite (n + 1)) (x / Q.ξ))) Q:HarmonicOscillatorn:ℕx:ℝ⊢ 2 * (↑n + 1) * deriv (fun x => ↑(↑(physHermite n) (x / Q.ξ))) x - ((↑Q.ξ)⁻¹ * ↑(↑(physHermite (n + 1)) (x / Q.ξ)) + ↑x / ↑Q.ξ * (fun x => ↑(1 / Q.ξ) * 2 * ↑(n + 1) * ↑(↑(physHermite (n + 1 - 1)) (x / Q.ξ))) x) + (2 * (↑n + 1) * ↑(↑(physHermite n) (x / Q.ξ)) - ↑x / ↑Q.ξ * ↑(↑(physHermite (n + 1)) (x / Q.ξ))) * (-1 / ↑Q.ξ ^ 2) * ↑x = 2 * (↑n + 1) * deriv (fun x => ↑(↑(physHermite n) (x / Q.ξ))) x + -((↑Q.ξ ^ 2)⁻¹ * 4 * (↑n + 1) * ↑x * ↑(↑(physHermite n) (x / Q.ξ))) + -((↑Q.ξ)⁻¹ * (1 + -((↑Q.ξ ^ 2)⁻¹ * ↑x ^ 2)) * ↑(↑(physHermite (n + 1)) (x / Q.ξ))) Q:HarmonicOscillatorn:ℕx:ℝ⊢ 2 * (↑n + 1) * deriv (fun x => ↑(↑(physHermite n) (x / Q.ξ))) x - ((↑Q.ξ)⁻¹ * ↑(↑(physHermite (n + 1)) (x / Q.ξ)) + ↑x / ↑Q.ξ * ((↑Q.ξ)⁻¹ * 2 * (↑n + 1) * ↑(↑(physHermite n) (x / Q.ξ)))) + (2 * (↑n + 1) * ↑(↑(physHermite n) (x / Q.ξ)) - ↑x / ↑Q.ξ * ↑(↑(physHermite (n + 1)) (x / Q.ξ))) * (-1 / ↑Q.ξ ^ 2) * ↑x = 2 * (↑n + 1) * deriv (fun x => ↑(↑(physHermite n) (x / Q.ξ))) x + -((↑Q.ξ ^ 2)⁻¹ * 4 * (↑n + 1) * ↑x * ↑(↑(physHermite n) (x / Q.ξ))) + -((↑Q.ξ)⁻¹ * (1 + -((↑Q.ξ ^ 2)⁻¹ * ↑x ^ 2)) * ↑(↑(physHermite (n + 1)) (x / Q.ξ))) All goals completed! 🐙Q:HarmonicOscillatorn✝:ℕx:ℝn:ℕ⊢ ↑(1 / √(2 ^ (n + 1) * ↑(n + 1)!)) * (-1 / ↑Q.ξ ^ 2 * (2 * (↑n + 1) + (1 + -1 / ↑Q.ξ ^ 2 * ↑x ^ 2)) * ↑(↑(physHermite (n + 1)) (x / Q.ξ)) * Q.eigenfunction 0 x) = -1 / ↑Q.ξ ^ 2 * (2 * ↑(n + 1) + 1 + -1 / ↑Q.ξ ^ 2 * ↑x ^ 2) * (fun x => ↑(1 / √(2 ^ (n + 1) * ↑(n + 1)!)) * ↑(↑(physHermite (n + 1)) (x / Q.ξ)) * Q.eigenfunction 0 x) x Q:HarmonicOscillatorn✝:ℕx:ℝn:ℕ⊢ (↑√↑(n + 1)!)⁻¹ * (↑√(2 ^ (n + 1)))⁻¹ * (-1 / ↑Q.ξ ^ 2 * (2 * (↑n + 1) + (1 + -1 / ↑Q.ξ ^ 2 * ↑x ^ 2)) * ↑(↑(physHermite (n + 1)) (x / Q.ξ)) * Q.eigenfunction 0 x) = -1 / ↑Q.ξ ^ 2 * (2 * (↑n + 1) + 1 + -1 / ↑Q.ξ ^ 2 * ↑x ^ 2) * ((↑√↑(n + 1)!)⁻¹ * (↑√(2 ^ (n + 1)))⁻¹ * ↑(↑(physHermite (n + 1)) (x / Q.ξ)) * Q.eigenfunction 0 x) All goals completed! 🐙

Application of the schrodingerOperator

The nth eigenfunction satisfies the time-independent Schrodinger equation with respect to the nth eigenvalue. That is to say for Q a harmonic oscillator,

Q.schrodingerOperator (Q.eigenfunction n) x = Q.eigenValue n * Q.eigenfunction n x.

The proof of this result is done by explicit calculation of derivatives.

Q:HarmonicOscillatorn:ℕx:ℝhm':↑Q.m ≠ 0hℏ':↑↑ℏ ≠ 0⊢ ↑↑ℏ ^ 2 / (2 * ↑Q.m) * (-(-1 / ↑Q.ξ ^ 2 * (2 * ↑n + 1 + -1 / ↑Q.ξ ^ 2 * ↑x ^ 2) * Q.eigenfunction n x) + (↑Q.ξ ^ 2)⁻¹ ^ 2 * ↑x ^ 2 * Q.eigenfunction n x) = ↑((↑n + 1 / 2) * ↑ℏ * Q.ω) * Q.eigenfunction n x Q:HarmonicOscillatorn:ℕx:ℝhm':↑Q.m ≠ 0hℏ':↑↑ℏ ≠ 0⊢ ↑(↑ℏ ^ 2) / (2 * ↑Q.m) * (-(-1 / ↑(↑ℏ / (Q.m * Q.ω)) * (2 * ↑n + 1 + -1 / ↑(↑ℏ / (Q.m * Q.ω)) * ↑(x ^ 2)) * Q.eigenfunction n x) + (↑(↑ℏ / (Q.m * Q.ω)))⁻¹ ^ 2 * ↑(x ^ 2) * Q.eigenfunction n x) = ↑((↑n + 1 / 2) * ↑ℏ * Q.ω) * Q.eigenfunction n x Q:HarmonicOscillatorn:ℕx:ℝhm':↑Q.m ≠ 0hℏ':↑↑ℏ ≠ 0⊢ ↑↑ℏ ^ 2 / (2 * ↑Q.m) * (-(-1 / (↑↑ℏ / (↑Q.m * ↑Q.ω)) * (2 * ↑n + 1 + -1 / (↑↑ℏ / (↑Q.m * ↑Q.ω)) * ↑x ^ 2) * Q.eigenfunction n x) + (↑Q.m * ↑Q.ω / ↑↑ℏ) ^ 2 * ↑x ^ 2 * Q.eigenfunction n x) = (↑n + 2⁻¹) * ↑↑ℏ * ↑Q.ω * Q.eigenfunction n x Q:HarmonicOscillatorn:ℕx:ℝhm':↑Q.m ≠ 0hℏ':↑↑ℏ ≠ 0⊢ Q.eigenfunction n x * (↑↑ℏ * (2 * ↑n + 1) + -(↑Q.m * ↑Q.ω * ↑x ^ 2) + ↑Q.m * ↑Q.ω * ↑x ^ 2) = ↑↑ℏ * (2 * ↑n + 1) * Q.eigenfunction n x All goals completed! 🐙