Mode of #cas
dsolve
The general solution of a linear differential equation, or the solution of an initial-value problem, with a theorem.
#cas [dsolve y x] eq#cas [dsolve y x, y x₀ = v₀, y' x₀ = v₁, …] eqdsolve finds the general solution of a supported linear differential equation, and what I wanted from it is the complete statement, not only that the printed family solves the equation. The theorem is an equivalence about every function y : ℝ → ℝ with enough derivatives: y solves the equation exactly when it is a member of the printed family. So there are no other solutions, and with initial values the printed solution is the only one.
With rational constant coefficients the equation may have any order, and the family comes from the roots of the characteristic polynomial, exact or enclosed. A right side of polynomials, exponentials, sines and cosines gets a particular solution. A first-order equation y' + p * y = q whose coefficients depend on is solved by an integrating factor, when the checked integrator finds the primitives it needs. Coefficients that depend on are taken in first order only.
Examples (23)#
Basic Examples (2)
A second-order equation with two real characteristic roots, and the theorem that every solution is in the family:
#cas [dsolve y x] (y'' + 3*y' + 2*y = 0)
order 2, characteristic roots: -1, -2
y(x) = c₁*exp(-x) + c₂*exp(-(2*x))- Input (linear equation of order 2 with constant coefficients)
(y'' + 3*y' + 2*y = 0)
Checked by Lean’s kernel: The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 2 y x + 3 * deriv y x + 2 * y x = 0) ↔ ∃ c₁ c₂, ∀ (x : ℝ), y x = c₁ * Real.exp (-x) + c₂ * Real.exp (-(2 * x)))
The certificate: 1 checked step
The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 2 y x + 3 * deriv y x + 2 * y x = 0) ↔ ∃ c₁ c₂, ∀ (x : ℝ), y x = c₁ * Real.exp (-x) + c₂ * Real.exp (-(2 * x)))
With initial values, the only solution:
#cas [dsolve y x, y 0 = 1, y' 0 = 0] (y'' + y = 0)
order 2, characteristic roots: ±i
y(x) = cos(x)- Input (linear equation of order 2 with constant coefficients)
(y'' + y = 0)
Checked by Lean’s kernel: The unique solution of the initial-value problem
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 2 y x + y x = 0) ∧ y 0 = 1 ∧ deriv y 0 = 0 ↔ ∀ (x : ℝ), y x = Real.cos x)
The certificate: 1 checked step
The unique solution of the initial-value problem
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 2 y x + y x = 0) ∧ y 0 = 1 ∧ deriv y 0 = 0 ↔ ∀ (x : ℝ), y x = Real.cos x)
Scope (9)
A double root, and a pair of complex roots:
#cas [dsolve y x] (y'' - 2*y' + y = 0)
order 2, characteristic roots: 1 (multiplicity 2)
y(x) = c₁*exp(x) + c₂*x*exp(x)- Input (linear equation of order 2 with constant coefficients)
(y'' - 2*y' + y = 0)
Checked by Lean’s kernel: The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 2 y x - 2 * deriv y x + y x = 0) ↔ ∃ c₁ c₂, ∀ (x : ℝ), y x = c₁ * Real.exp x + c₂ * (x * Real.exp x))
The certificate: 1 checked step
The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 2 y x - 2 * deriv y x + y x = 0) ↔ ∃ c₁ c₂, ∀ (x : ℝ), y x = c₁ * Real.exp x + c₂ * (x * Real.exp x))
#cas [dsolve y x] (y'' + 2*y' + 5*y = 0)
order 2, characteristic roots: -1 ± 2 i
y(x) = c₁*exp(-x)*cos(2*x) + c₂*exp(-x)*sin(2*x)- Input (linear equation of order 2 with constant coefficients)
(y'' + 2*y' + 5*y = 0)
Checked by Lean’s kernel: The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 2 y x + 2 * deriv y x + 5 * y x = 0) ↔ ∃ c₁ c₂, ∀ (x : ℝ), y x = c₁ * (Real.exp (-x) * Real.cos (2 * x)) + c₂ * (Real.exp (-x) * Real.sin (2 * x)))
The certificate: 1 checked step
The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 2 y x + 2 * deriv y x + 5 * y x = 0) ↔ ∃ c₁ c₂, ∀ (x : ℝ), y x = c₁ * (Real.exp (-x) * Real.cos (2 * x)) + c₂ * (Real.exp (-x) * Real.sin (2 * x)))
Irrational roots from a quadratic factor:
#cas [dsolve y x] (y'' - 2*y = 0)
order 2, characteristic roots: ±√2
y(x) = c₁*exp(sqrt(2)*x) + c₂*exp(-(sqrt(2)*x))- Input (linear equation of order 2 with constant coefficients)
(y'' - 2*y = 0)
Checked by Lean’s kernel: The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 2 y x = 2 * y x) ↔ ∃ c₁ c₂, ∀ (x : ℝ), y x = c₁ * Real.exp (√2 * x) + c₂ * Real.exp (-(√2 * x)))
The certificate: 1 checked step
The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 2 y x = 2 * y x) ↔ ∃ c₁ c₂, ∀ (x : ℝ), y x = c₁ * Real.exp (√2 * x) + c₂ * Real.exp (-(√2 * x)))
A right side gets a particular solution. At resonance it has a factor :
#cas [dsolve y x] (y'' + y = sin x)
order 2, characteristic roots: ±i
y(x) = -(1/2*x*cos(x)) + c₁*cos(x) + c₂*sin(x)- Input (linear equation of order 2 with constant coefficients)
(y'' + y = sin x)
Checked by Lean’s kernel: The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 2 y x + y x = Real.sin x) ↔ ∃ c₁ c₂, ∀ (x : ℝ), y x = -(1 / 2 * x * Real.cos x) + c₁ * Real.cos x + c₂ * Real.sin x)
The certificate: 1 checked step
The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 2 y x + y x = Real.sin x) ↔ ∃ c₁ c₂, ∀ (x : ℝ), y x = -(1 / 2 * x * Real.cos x) + c₁ * Real.cos x + c₂ * Real.sin x)
#cas [dsolve y x] (2*y'' + y = cos x * exp x)
order 2, characteristic roots: ±1/2√2 i
y(x) = exp(x)*(1/17*cos(x) + 4/17*sin(x)) + c₁*cos(1/2*sqrt(2)*x) + c₂*sin(1/2*sqrt(2)*x)- Input (linear equation of order 2 with constant coefficients)
(2*y'' + y = cos x * exp x)
Checked by Lean’s kernel: The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), 2 * iteratedDeriv 2 y x + y x = Real.cos x * Real.exp x) ↔ ∃ c₁ c₂, ∀ (x : ℝ), y x = Real.exp x * (1 / 17 * Real.cos x + 4 / 17 * Real.sin x) + c₁ * Real.cos (1 / 2 * √2 * x) + c₂ * Real.sin (1 / 2 * √2 * x))
The certificate: 1 checked step
The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 2, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), 2 * iteratedDeriv 2 y x + y x = Real.cos x * Real.exp x) ↔ ∃ c₁ c₂, ∀ (x : ℝ), y x = Real.exp x * (1 / 17 * Real.cos x + 4 / 17 * Real.sin x) + c₁ * Real.cos (1 / 2 * √2 * x) + c₂ * Real.sin (1 / 2 * √2 * x))
A first-order equation with a polynomial right side:
#cas [dsolve y x] (y' + 2*y = x)
order 1, characteristic roots: -2
y(x) = -(1/4) + 1/2*x + c₁*exp(-(2*x))- Input (linear equation of order 1 with constant coefficients)
(y' + 2*y = x)
Checked by Lean’s kernel: The general solution, and every solution has this form
∀ (y : ℝ → ℝ), Differentiable ℝ y → ((∀ (x : ℝ), deriv y x + 2 * y x = x) ↔ ∃ c₁, ∀ (x : ℝ), y x = -(1 / 4) + 1 / 2 * x + c₁ * Real.exp (-(2 * x)))
The certificate: 1 checked step
The general solution, and every solution has this form
∀ (y : ℝ → ℝ), Differentiable ℝ y → ((∀ (x : ℝ), deriv y x + 2 * y x = x) ↔ ∃ c₁, ∀ (x : ℝ), y x = -(1 / 4) + 1 / 2 * x + c₁ * Real.exp (-(2 * x)))
Third order, with three rational roots:
#cas [dsolve y x] (y''' - 6*y'' + 11*y' - 6*y = 0)
order 3, characteristic roots: 1, 2, 3
y(x) = c₁*exp(x) + c₂*exp(2*x) + c₃*exp(3*x)- Input (linear equation of order 3 with constant coefficients)
(y''' - 6*y'' + 11*y' - 6*y = 0)
Checked by Lean’s kernel: The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 3, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 3 y x - 6 * iteratedDeriv 2 y x + 11 * deriv y x = 6 * y x) ↔ ∃ c₁ c₂ c₃, ∀ (x : ℝ), y x = c₁ * Real.exp x + c₂ * Real.exp (2 * x) + c₃ * Real.exp (3 * x))
The certificate: 1 checked step
The general solution, and every solution has this form
∀ (y : ℝ → ℝ), (∀ k < 3, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 3 y x - 6 * iteratedDeriv 2 y x + 11 * deriv y x = 6 * y x) ↔ ∃ c₁ c₂ c₃, ∀ (x : ℝ), y x = c₁ * Real.exp x + c₂ * Real.exp (2 * x) + c₃ * Real.exp (3 * x))
Initial values for an equation of order 3:
#cas [dsolve y x, y 0 = 0, y' 0 = 1, y'' 0 = 0] (y''' + y' = 0)
order 3, characteristic roots: 0, ±i
y(x) = sin(x)- Input (linear equation of order 3 with constant coefficients)
(y''' + y' = 0)
Checked by Lean’s kernel: The unique solution of the initial-value problem
∀ (y : ℝ → ℝ), (∀ k < 3, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 3 y x + deriv y x = 0) ∧ y 0 = 0 ∧ deriv y 0 = 1 ∧ iteratedDeriv 2 y 0 = 0 ↔ ∀ (x : ℝ), y x = Real.sin x)
The certificate: 1 checked step
The unique solution of the initial-value problem
∀ (y : ℝ → ℝ), (∀ k < 3, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 3 y x + deriv y x = 0) ∧ y 0 = 0 ∧ deriv y 0 = 1 ∧ iteratedDeriv 2 y 0 = 0 ↔ ∀ (x : ℝ), y x = Real.sin x)
The roots of are enclosed, and the theorem states their enclosures first:
#cas [dsolve y x] (y'''' + y = 0)
order 4, the roots of r^4 + 1 = 0: z₁ = α ± iβ, α ∈ [-0.70710680, -0.70710676], β ∈ [0.70710676, 0.70710680], z₂ = α ± iβ, α ∈ [0.70710676, 0.70710680], β ∈ [0.70710676, 0.70710680]
y(x) = c₁*exp(re(z₁)*x)*cos(im(z₁)*x) + c₂*exp(re(z₁)*x)*sin(im(z₁)*x) + c₃*exp(re(z₂)*x)*cos(im(z₂)*x) + c₄*exp(re(z₂)*x)*sin(im(z₂)*x)- Input (linear equation of order 4 with constant coefficients)
(y'''' + y = 0)
Checked by Lean’s kernel: The roots of the characteristic factor without closed form, by certified enclosures, and the general solution
let z₁ := CAS.AlgRoot.complex [1, 0, 0, 0, 1] (-0.70710678) 0.70710678 2e-8; let z₂ := CAS.AlgRoot.complex [1, 0, 0, 0, 1] 0.70710678 0.70710678 2e-8; (z₁.re ∈ Set.Icc (-0.70710680) (-0.70710676) ∧ z₁.im ∈ Set.Icc 0.70710676 0.70710680 ∧ z₁ ^ 4 + 1 = 0) ∧ (z₂.re ∈ Set.Icc 0.70710676 0.70710680 ∧ z₂.im ∈ Set.Icc 0.70710676 0.70710680 ∧ z₂ ^ 4 + 1 = 0) ∧ ∀ (y : ℝ → ℝ), (∀ k < 4, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 4 y x + y x = 0) ↔ ∃ c₁ c₂ c₃ c₄, ∀ (x : ℝ), y x = c₁ * (Real.exp (z₁.re * x) * Real.cos (z₁.im * x)) + c₂ * (Real.exp (z₁.re * x) * Real.sin (z₁.im * x)) + c₃ * (Real.exp (z₂.re * x) * Real.cos (z₂.im * x)) + c₄ * (Real.exp (z₂.re * x) * Real.sin (z₂.im * x)))
The certificate: 1 checked step
The roots of the characteristic factor without closed form, by certified enclosures, and the general solution
let z₁ := CAS.AlgRoot.complex [1, 0, 0, 0, 1] (-0.70710678) 0.70710678 2e-8; let z₂ := CAS.AlgRoot.complex [1, 0, 0, 0, 1] 0.70710678 0.70710678 2e-8; (z₁.re ∈ Set.Icc (-0.70710680) (-0.70710676) ∧ z₁.im ∈ Set.Icc 0.70710676 0.70710680 ∧ z₁ ^ 4 + 1 = 0) ∧ (z₂.re ∈ Set.Icc 0.70710676 0.70710680 ∧ z₂.im ∈ Set.Icc 0.70710676 0.70710680 ∧ z₂ ^ 4 + 1 = 0) ∧ ∀ (y : ℝ → ℝ), (∀ k < 4, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 4 y x + y x = 0) ↔ ∃ c₁ c₂ c₃ c₄, ∀ (x : ℝ), y x = c₁ * (Real.exp (z₁.re * x) * Real.cos (z₁.im * x)) + c₂ * (Real.exp (z₁.re * x) * Real.sin (z₁.im * x)) + c₃ * (Real.exp (z₂.re * x) * Real.cos (z₂.im * x)) + c₄ * (Real.exp (z₂.re * x) * Real.sin (z₂.im * x)))
A coefficient that depends on , by an integrating factor, without and with an initial value:
#cas [dsolve y x] (y' + 2*x*y = x)
integrating factor e ^ P
y(x) = (1/2*exp(x^2) + C)*exp(-x^2)- Input (linear equation of order one with a variable coefficient)
(y' + 2*x*y = x)
Checked by Lean’s kernel: The general solution by the integrating factor, and every solution has this form
∀ (y : ℝ → ℝ), Differentiable ℝ y → ((∀ (x : ℝ), deriv y x + 2 * x * y x = x) ↔ ∃ C, ∀ (x : ℝ), y x = (1 / 2 * Real.exp (x ^ 2) + C) * Real.exp (-x ^ 2))
The certificate: 1 checked step
The general solution by the integrating factor, and every solution has this form
∀ (y : ℝ → ℝ), Differentiable ℝ y → ((∀ (x : ℝ), deriv y x + 2 * x * y x = x) ↔ ∃ C, ∀ (x : ℝ), y x = (1 / 2 * Real.exp (x ^ 2) + C) * Real.exp (-x ^ 2))
#cas [dsolve y x, y 0 = 1] (y' - 2*x*y = 0)
integrating factor e ^ P
y(x) = exp(x^2)- Input (linear equation of order one with a variable coefficient)
(y' - 2*x*y = 0)
Checked by Lean’s kernel: The unique solution of the initial-value problem
∀ (y : ℝ → ℝ), Differentiable ℝ y → ((∀ (x : ℝ), deriv y x = 2 * x * y x) ∧ y 0 = 1 ↔ ∀ (x : ℝ), y x = Real.exp (x ^ 2))
The certificate: 1 checked step
The unique solution of the initial-value problem
∀ (y : ℝ → ℝ), Differentiable ℝ y → ((∀ (x : ℝ), deriv y x = 2 * x * y x) ∧ y 0 = 1 ↔ ∀ (x : ℝ), y x = Real.exp (x ^ 2))
A first-order equation with a parameter. The theorem has the hypothesis , since the family divides by :
#cas [dsolve y x] (y' + k * y = exp (2 * x))
integrating factor e ^ (p x)
y(x) = (exp((k + 2)*x)/(k + 2) + C)*exp(-(k*x))- Input (linear equation of order one with symbolic coefficients)
(y' + k * y = exp (2 * x))- Conditions
Checked by Lean’s kernel: The general solution by the integrating factor, and every solution has this form
∀ (k : ℝ), k + 2 ≠ 0 → ∀ (y : ℝ → ℝ), Differentiable ℝ y → ((∀ (x : ℝ), deriv y x + k * y x = Real.exp (2 * x)) ↔ ∃ C, ∀ (x : ℝ), y x = (Real.exp ((k + 2) * x) / (k + 2) + C) * Real.exp (-(k * x)))
The certificate: 1 checked step
The general solution by the integrating factor, and every solution has this form
∀ (k : ℝ), k + 2 ≠ 0 → ∀ (y : ℝ → ℝ), Differentiable ℝ y → ((∀ (x : ℝ), deriv y x + k * y x = Real.exp (2 * x)) ↔ ∃ C, ∀ (x : ℝ), y x = (Real.exp ((k + 2) * x) / (k + 2) + C) * Real.exp (-(k * x)))
Options (1)
An external system can propose a family, here for an equation whose leading coefficient is . Lean checks that the family solves the equation, and the report says that its completeness is not checked:
#cas [dsolve y x, oracle := sympy] (x * y' + y = 0)
Quoted from tests/oracle/Oracles.lean, where #guard_msgs pins the output (the part shown).
a family of solutions (checked); that it is the general solution is not
y(x) = c1/xApplications (1)
A member of the family of y' + 2*y = x in a proof. cas proves that it satisfies y' = x - 2*y, and only the three standard axioms are used:
theorem dsolve_solution (c₁ x : ℝ) : HasDerivAt (fun x ↦ -(1 / 4) + 1 / 2 * x + c₁ * Real.exp (-(2 * x))) (x - 2 * (-(1 / 4) + 1 / 2 * x + c₁ * Real.exp (-(2 * x)))) x := by cas #print axioms dsolve_solution
dsolve_solution depends on the axioms propext, Classical.choice, Quot.sound.
Properties and Relations (1)
The laplace transform turns y'' + y = sin x with y 0 = 0 and y' 0 = 0 into , and inverseLaplace gives back the solution, the member of the family under Scope with and :
#cas [inverseLaplace s t] (1 / (s ^ 2 + 1) ^ 2)
an inverse Laplace transform (its transform is F for s > σ; uniqueness is not claimed)
1/2*sin(t) - 1/2*t*cos(t)- Domain
s > 0- Input (proper rational function of s)
(1 / (s ^ 2 + 1) ^ 2)
Checked by Lean’s kernel: Inverse Laplace transform
∀ (s : ℝ), 0 < s → MeasureTheory.IntegrableOn (fun t ↦ Real.exp (-(s * t)) * (1 / 2 * Real.sin t - 1 / 2 * (t * Real.cos t))) (Set.Ioi 0) MeasureTheory.volume ∧ ∫ (t : ℝ) in Set.Ioi 0, Real.exp (-(s * t)) * (1 / 2 * Real.sin t - 1 / 2 * (t * Real.cos t)) = 1 / (s ^ 2 + 1) ^ 2
The certificate: 1 checked step
Inverse Laplace transform
∀ (s : ℝ), 0 < s → MeasureTheory.IntegrableOn (fun t ↦ Real.exp (-(s * t)) * (1 / 2 * Real.sin t - 1 / 2 * (t * Real.cos t))) (Set.Ioi 0) MeasureTheory.volume ∧ ∫ (t : ℝ) in Set.Ioi 0, Real.exp (-(s * t)) * (1 / 2 * Real.sin t - 1 / 2 * (t * Real.cos t)) = 1 / (s ^ 2 + 1) ^ 2
Possible Issues (8)
Coefficients that depend on are taken in first order only:
#cas [dsolve y x] (y'' + x*y = 0)
Error
dsolve: the coefficient of the derivative of order 0 is not a rational constant
The integrating factor of y' + x*y = 1 is , which has no elementary primitive:
#cas [dsolve y x] (y' + x*y = 1)
Error
dsolve: the checked integrator found no primitive of e ^ P times the right side
The primitive of the coefficient is a logarithm, which the integrator proves away from only. The mode does not treat such conditions:
#cas [dsolve y x] (y' + y/x = 0)
Error
dsolve: the primitive of the coefficient holds only under domain conditions, which this command does not treat
Parameters are taken in first order only:
#cas [dsolve y x] (y'' + k*y = 0)
Error
dsolve: symbolic coefficients are treated for first-order equations
The equation must be linear in y and its derivatives:
#cas [dsolve y x] (y' * y = 1)
Error
dsolve: the equation is not linear in y and its derivatives
The equation must be about the function named in the brackets. Here it is z, so write #cas [dsolve z x]:
#cas [dsolve y x] (z'' + z = 0)
Error
dsolve: the equation has no derivative of y
The initial values must be given at one point. For a boundary-value problem, fit the constants of the general solution:
#cas [dsolve y x, y 0 = 1, y 1 = 2] (y'' + y = 0)
Error
dsolve: the initial values must be given at one point
With enclosed characteristic roots, only the general solution is given:
#cas [dsolve y x, y 0 = 1, y' 0 = 0, y'' 0 = 0] (y''' - 2 * y = 0)
Error
dsolve: initial values are not treated when some characteristic roots are known only by enclosures
Neat Examples (1)
The fifth roots of unity: , and the four complex roots are enclosed:
#cas [dsolve y x] (y''''' - y = 0)
order 5, characteristic roots: 1 and the roots of r^4 + r^3 + r^2 + r + 1 = 0: z₁ = α ± iβ, α ∈ [-0.80901701, -0.80901697], β ∈ [0.58778523, 0.58778527], z₂ = α ± iβ, α ∈ [0.30901697, 0.30901701], β ∈ [0.95105650, 0.95105654]
y(x) = c₁*exp(x) + c₂*exp(re(z₁)*x)*cos(im(z₁)*x) + c₃*exp(re(z₁)*x)*sin(im(z₁)*x) + c₄*exp(re(z₂)*x)*cos(im(z₂)*x) + c₅*exp(re(z₂)*x)*sin(im(z₂)*x)- Input (linear equation of order 5 with constant coefficients)
(y''''' - y = 0)
Checked by Lean’s kernel: The roots of the characteristic factor without closed form, by certified enclosures, and the general solution
let z₁ := CAS.AlgRoot.complex [1, 1, 1, 1, 1] (-0.80901699) 0.58778525 2e-8; let z₂ := CAS.AlgRoot.complex [1, 1, 1, 1, 1] 0.30901699 0.95105652 2e-8; (z₁.re ∈ Set.Icc (-0.80901701) (-0.80901697) ∧ z₁.im ∈ Set.Icc 0.58778523 0.58778527 ∧ z₁ ^ 4 + z₁ ^ 3 + z₁ ^ 2 + z₁ + 1 = 0) ∧ (z₂.re ∈ Set.Icc 0.30901697 0.30901701 ∧ z₂.im ∈ Set.Icc 0.95105650 0.95105654 ∧ z₂ ^ 4 + z₂ ^ 3 + z₂ ^ 2 + z₂ + 1 = 0) ∧ ∀ (y : ℝ → ℝ), (∀ k < 5, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 5 y x = y x) ↔ ∃ c₁ c₂ c₃ c₄ c₅, ∀ (x : ℝ), y x = c₁ * Real.exp x + c₂ * (Real.exp (z₁.re * x) * Real.cos (z₁.im * x)) + c₃ * (Real.exp (z₁.re * x) * Real.sin (z₁.im * x)) + c₄ * (Real.exp (z₂.re * x) * Real.cos (z₂.im * x)) + c₅ * (Real.exp (z₂.re * x) * Real.sin (z₂.im * x)))
The certificate: 1 checked step
The roots of the characteristic factor without closed form, by certified enclosures, and the general solution
let z₁ := CAS.AlgRoot.complex [1, 1, 1, 1, 1] (-0.80901699) 0.58778525 2e-8; let z₂ := CAS.AlgRoot.complex [1, 1, 1, 1, 1] 0.30901699 0.95105652 2e-8; (z₁.re ∈ Set.Icc (-0.80901701) (-0.80901697) ∧ z₁.im ∈ Set.Icc 0.58778523 0.58778527 ∧ z₁ ^ 4 + z₁ ^ 3 + z₁ ^ 2 + z₁ + 1 = 0) ∧ (z₂.re ∈ Set.Icc 0.30901697 0.30901701 ∧ z₂.im ∈ Set.Icc 0.95105650 0.95105654 ∧ z₂ ^ 4 + z₂ ^ 3 + z₂ ^ 2 + z₂ + 1 = 0) ∧ ∀ (y : ℝ → ℝ), (∀ k < 5, Differentiable ℝ (iteratedDeriv k y)) → ((∀ (x : ℝ), iteratedDeriv 5 y x = y x) ↔ ∃ c₁ c₂ c₃ c₄ c₅, ∀ (x : ℝ), y x = c₁ * Real.exp x + c₂ * (Real.exp (z₁.re * x) * Real.cos (z₁.im * x)) + c₃ * (Real.exp (z₁.re * x) * Real.sin (z₁.im * x)) + c₄ * (Real.exp (z₂.re * x) * Real.cos (z₂.im * x)) + c₅ * (Real.exp (z₂.re * x) * Real.sin (z₂.im * x)))
