Prove2Me
Navigate
DiscoverFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

The quadratic force in shifted, scaled form

Proved
QuadraticWell.force_shift

by ShapeZero · Sep 27, 2026 · Mathlib 0df444a (Lean v4.33.1)

golden-rationondimensionalizationordinary-differential-equations

Let r1≠r2r_1 \neq r_2r1​=r2​ be real, m=(r1+r2)/2m = (r_1 + r_2)/2m=(r1​+r2​)/2, and d=(r1−r2)/2d = (r_1 - r_2)/2d=(r1​−r2​)/2 or d=(r2−r1)/2d = (r_2 - r_1)/2d=(r2​−r1​)/2. Then for all real aaa and yyy,

−a (y−r1)(y−r2)=−a d2((y−md)2−1).-a\,(y - r_1)(y - r_2) = -a\,d^2\left(\left(\frac{y - m}{d}\right)^2 - 1\right).−a(y−r1​)(y−r2​)=−ad2((dy−m​)2−1).
Preamble
import Mathlib
Formal statement
namespace QuadraticWell

theorem force_shift (a r₁ r₂ d : ℝ) (hr : r₁ ≠ r₂)
    (hd : d = (r₁ - r₂) / 2 ∨ d = (r₂ - r₁) / 2) (y : ℝ) :
    -a * (y - r₁) * (y - r₂) = -a * d ^ 2 * (((y - (r₁ + r₂) / 2) / d) ^ 2 - 1) := by
  sorry

end QuadraticWell
Source
Motivated by the scaling analysis in the Shape Zero derivation (Shape Zero LLC): https://github.com/ShapeZeroSZ/shape-zero/blob/main/00_START_HERE/MODEL_SPEC.md §1b ; public references: Wikipedia, "Nondimensionalization": https://en.wikipedia.org/wiki/Nondimensionalization ; Wikipedia, "Golden ratio": https://en.wikipedia.org/wiki/Golden_ratio
Read-back

What the Lean code literally says, in plain math · claude-opus-5-5

QuadraticWell.force_shift. Let a,r1,r2,d∈Ra, r_1, r_2, d \in \mathbb{R}a,r1​,r2​,d∈R be arbitrary real numbers, and assume:

  • r1≠r2r_1 \neq r_2r1​=r2​;
  • ddd is half the gap between r1r_1r1​ and r2r_2r2​, with either sign:
d=r1−r22ord=r2−r12.d = \frac{r_1 - r_2}{2} \quad\text{or}\quad d = \frac{r_2 - r_1}{2}.d=2r1​−r2​​ord=2r2​−r1​​.

Then for every real number yyy the following equality of real numbers holds:

−a (y−r1)(y−r2)  =  −a d2((y−r1+r22d)2−1).-a\,(y - r_1)(y - r_2) \;=\; -a\, d^2 \left( \left( \frac{y - \frac{r_1 + r_2}{2}}{d} \right)^{2} - 1 \right).−a(y−r1​)(y−r2​)=−ad2((dy−2r1​+r2​​​)2−1).

Remarks on scope and edge cases:

  • No condition is placed on aaa: it may be positive, negative, or zero (when a=0a = 0a=0 both sides are 000).
  • No condition is placed on yyy; the equality is asserted for every real yyy, including y=r1y = r_1y=r1​, y=r2y = r_2y=r2​, and the midpoint y=r1+r22y = \frac{r_1+r_2}{2}y=2r1​+r2​​.
  • The division by ddd is real division as in Mathlib, where dividing by 000 gives 000. Under the stated hypotheses d≠0d \neq 0d=0, since r1≠r2r_1 \neq r_2r1​=r2​ forces r1−r22≠0\frac{r_1 - r_2}{2} \neq 02r1​−r2​​=0 and r2−r12≠0\frac{r_2 - r_1}{2} \neq 02r2​−r1​​=0. So the division-by-zero convention is never used, and the hypotheses on r1,r2,dr_1, r_2, dr1​,r2​,d can be satisfied (for example r1=0r_1 = 0r1​=0, r2=2r_2 = 2r2​=2, d=−1d = -1d=−1 or d=1d = 1d=1).
  • The divisions by 222 are ordinary real division.
  • The statement is a single universally quantified identity: it holds for all a,r1,r2,d,ya, r_1, r_2, d, ya,r1​,r2​,d,y meeting the two hypotheses above. It makes no claim about anything physical such as forces or wells; "QuadraticWell" is only the namespace name, and no project-specific definitions appear in the statement.
Human review
  • Endorsed by Shuze Chen · Sep 27, 2026

    Confirmed by the moderator at approval.

  • Endorsed by ShapeZero · Sep 27, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paper
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me