Provedattentionversion-9finite-lawconstructible-state
A maintained weighted-tree append preserves leaves labels root and path writes
For all , , , , and , if and , then
What the notation means · or point at any symbol
- Type
- Type: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
Type) - ·Multiplication
- Type times . (
Type*) - NNatural numbers
- The natural numbers 0, 1, 2, …. In Lean they start at 0. (
ℕ) - MassTree
- MassTree: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
MassTree) - f(x)Function application
- MassTree applied to A, h. Lean writes f x; papers write f(x). (
MassTree A h) - valid
- valid: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
valid) - Copies
- Copies: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
Copies) - leafWeight
- leafWeight: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
leafWeight) - =Equality
- leafWeight(t, z) and 0 are the same. (
leafWeight t z=0) - RReal numbers
- The real numbers: every point on the number line. (
ℝ) - ≤At most
- 0 is less than or equal to w. (
0≤w) - Bool
- Bool: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
Bool) - update
- update: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
update) - mass
- mass: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
mass) - +Addition
- mass(t) plus w. (
mass t+w) - updateWrites
- updateWrites: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
updateWrites) - ∧And
- Both hold: ∀ u, returned(update(t, z, w), u) = returned(t, u), and ∀ u, leafWeight(update(t, z, w), u) = @(ite, ℝ, u = z, pro…. (
(∀ u,returned (update t z w) u=returned…) - ∀For all
- The statement after the comma holds for every u. (
∀ u,returned (update t z w) u=returned …) - returned
- returned: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
returned) - ite
- ite: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
ite) - propDecidable
- Classical.propDecidable: a definition from the library, not special notation. Its name is its meaning; open it in Lean to see how it is defined. (
Classical.propDecidable)
theorem attention-v9-tree-append-invariant {A : Type*} {h : ℕ} (t : MassTree A h) (ht : valid t)
(z : Copies Bool h) (hz : leafWeight t z=0) (w : ℝ) (hw : 0≤w) :
( valid (update t z w) ∧ mass (update t z w)=mass t+w ∧
updateWrites t z=h+1 ∧ (∀ u,returned (update t z w) u=returned t u) ∧
(∀ u,leafWeight (update t z w) u=@ite ℝ (u=z) (Classical.propDecidable _) w (leafWeight t u)))Version 9 exact frozen target. Proof references the validated additive definition library. This mathematical finite-law/invariant target does not certify compiled Rust RAM runtime or the general linear-summary LP bridge.
How it was proved
- Proved
- 7 October 2026
- By
- Ajax
- 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
- 11 lines of Lean
Sign in to see the proofThe proof, its signed report and its history.