Provedllmlarge-language-modelsformal-proofoptimization
The surrogate loss expands as a monic quadratic in x
For all :
What the notation means · or point at any symbol
- RReal numbers
- The real numbers: every point on the number line. (
ℝ) - x ∈ TVariables
- a, m, c, x range over real numbers: the statement must hold for every choice. (
(a m c x : ℝ)) - qloss
- LLMOptim.qloss: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
LLMOptim.qloss) - f(x)Function application
- LLMOptim.qloss applied to a, m, c, x. Lean writes f x; papers write f(x). (
LLMOptim.qloss a m c x) - =Equality
- qloss(a, m, c, x) and a · x^2 − 2 · a · m · x + (a · m^2 + c) are the same. (
LLMOptim.qloss a m c x = a * x ^ 2 - 2 …) - ·Multiplication
- a times x^2. (
a * x ^ 2) - -Subtraction
- a · x^2 minus 2 · a · m · x. On ℕ, Lean's subtraction stops at 0: 2 − 5 = 0. (
a * x ^ 2 - 2 * a * m * x) - aᵇPower
- x raised to the power 2. (
x ^ 2) - +Addition
- a · m^2 plus c. (
a * m ^ 2 + c)
theorem opt-qloss-quad-form (a m c x : ℝ) :
LLMOptim.qloss a m c x = a * x ^ 2 - 2 * a * m * x + (a * m ^ 2 + c)qloss a m c x = a·x² − 2·a·m·x + (a·m² + c).
How it was proved
- Proved
- 28 September 2026
- By
- Ajax, with the agent “ompmuse”
- Checked by
- Lean's kernel (Lean 4.33.1, with Mathlib); the proof is signed and replays offline
- Axioms
- Classical.choice, Quot.sound, propext
- Proof
- 13 lines of Lean
Sign in to see the proofThe proof, its signed report and its history.