Encyclopedia Cosmology Cosmology Domain Coarsening Runs Le Length
ARTICLE 4 claims 4 theorems
Cosmology Domain Coarsening Runs Le Length
A machine-checked theorem shows that storing a field of values costs only its boundaries, not its size, a fact with consequences for how the framework models cosmology.
The cost of carrying a field
In the Recognition Science framework, a ledger (a discrete record of events) can hold a field of values, like a list of charges along a line. The question is how much it costs to carry that field: does the cost grow with the number of entries, or with something smaller? The declaration runs_le_length proves a bound: the number of coarse regions the ledger must carry never exceeds the number of entries in the field. A field with a hundred entries is carried as at most a hundred super-regions, and often far fewer.
The key is how the field is divided. The framework defines a locked domain (a maximal run of equal values with no internal distinction) and counts these runs. The theorem runs_eq shows that for any nonempty field, the number of runs equals the number of adjacent unequal pairs (the forced distinctions) plus one. Two constant blocks of any size, for instance, have one distinction and are carried as two super-regions, no matter whether each block has ten entries or ten million. The carried cost tracks the interface between different values, not the volume of the field itself.
This is a structural fact about lists, proved in the framework's machine-checked library of formal theorems with no unproved assumptions beyond the standard three axioms of its logic. It does not, by itself, say anything about cosmology. The framework's larger claim, that the engine cost is sub-extensive in the volume, requires additional ingredients: a bound on how fast distinctions can change per cycle, and a model of open-system dynamics where the uniform blocks grow linearly while the active interface grows only diffusively. Those ingredients are separate theorems and models, not consequences of runs_le_length alone.
What the declaration does establish is a clean upper bound, useful on its own: a lossless representation of a field never needs more coarse regions than the field has entries. It is a minimality statement in disguise, since each distinction forces a new block, so the run count is also the minimum number of constant contiguous blocks any lossless cover can use. The reader can now see that the cost of carrying a field is governed by its boundaries, a fact that holds for any list of values with decidable equality, independent of the framework's cosmological ambitions.
THEOREM runs_le_length · IndisputableMonolith/Cosmology/DomainCoarsening.lean
/-- The carried super-region count never exceeds the volume: a field of length `n+1` is carried as at
most `n+1` super-regions, with equality only when every adjacent pair is a distinction. -/
theorem runs_le_length (l : List α) : runs l ≤ l.length := by
match l with
| [] => simp
| [a] => simp
| a :: b :: t =>
have ih := runs_le_length (b :: t)
show (if a = b then 0 else 1) + runs (b :: t) ≤ (a :: b :: t).length
rw [show (a :: b :: t).length = (b :: t).length + 1 from rfl]
by_cases h : a = b
· rw [if_pos h]; omega
· rw [if_neg h]; omega
THEOREM runs_eq · IndisputableMonolith/Cosmology/DomainCoarsening.lean
/-- **The coarsest lossless representation has size = forced distinctions + 1.** For every nonempty
charge field, the number of coarse super-regions the engine carries (`runs`) is exactly the number of
forced distinctions (`boundaries`) plus one. The right side depends only on the distinctions, not on
the run lengths, so two constant blocks of any size are carried as two super-regions. -/
theorem runs_eq (a : α) (l : List α) : runs (a :: l) = boundaries (a :: l) + 1 := by
induction l generalizing a with
| nil => simp
| cons b l ih =>
show (if a = b then 0 else 1) + runs (b :: l)
= ((if a = b then 0 else 1) + boundaries (b :: l)) + 1
rw [ih b]
by_cases h : a = b
· simp only [if_pos h]; omega
· simp only [if_neg h]; omega
THEOREM runs_eq · IndisputableMonolith/Cosmology/DomainCoarsening.lean
/-- **The coarsest lossless representation has size = forced distinctions + 1.** For every nonempty
charge field, the number of coarse super-regions the engine carries (`runs`) is exactly the number of
forced distinctions (`boundaries`) plus one. The right side depends only on the distinctions, not on
the run lengths, so two constant blocks of any size are carried as two super-regions. -/
theorem runs_eq (a : α) (l : List α) : runs (a :: l) = boundaries (a :: l) + 1 := by
induction l generalizing a with
| nil => simp
| cons b l ih =>
show (if a = b then 0 else 1) + runs (b :: l)
= ((if a = b then 0 else 1) + boundaries (b :: l)) + 1
rw [ih b]
by_cases h : a = b
· simp only [if_pos h]; omega
· simp only [if_neg h]; omega
THEOREM runs_le_length · IndisputableMonolith/Cosmology/DomainCoarsening.lean
/-- The carried super-region count never exceeds the volume: a field of length `n+1` is carried as at
most `n+1` super-regions, with equality only when every adjacent pair is a distinction. -/
theorem runs_le_length (l : List α) : runs l ≤ l.length := by
match l with
| [] => simp
| [a] => simp
| a :: b :: t =>
have ih := runs_le_length (b :: t)
show (if a = b then 0 else 1) + runs (b :: t) ≤ (a :: b :: t).length
rw [show (a :: b :: t).length = (b :: t).length + 1 from rfl]
by_cases h : a = b
· rw [if_pos h]; omega
· rw [if_neg h]; omega
What this page does not claim
This theorem alone does not establish the sub-extensive cosmological cost claim. It does not specify the dynamics of how distinctions change over time. It does not apply to fields without decidable equality on their values.
Verify this page
Every tagged claim above names its theorem. To check one yourself rather than trust this page, elaborate the source module with Lean 4 and audit its axiom basis:
$ lake env lean IndisputableMonolith/Cosmology/DomainCoarsening.lean
expected axiom basis: [propext, Classical.choice, Quot.sound] (the Lean kernel's standard three; no RS-specific axioms)
A page whose claims cannot be reproduced this way does not ship. In production, every anchor links to the exact declaration in the public source release, and this block carries the build receipt for the page itself.
Derived articles
This page is generated by a question-recursion engine: the questions its answers raise become the next pages. The current agenda, with open targets marked red:
- What additional theorems compose with runs_le_length to establish the sub-extensive cost claim?
- How does the framework model the open-system dynamics that make the interface grow diffusively?
- What is the cadence bound that limits how fast distinctions can change per cycle?
MACHINE LAYER · GROUNDED CLAIM TABLE · CLICK TO EXPAND
THEOREM runs_le_length · IndisputableMonolith/Cosmology/DomainCoarsening.lean
/-- The carried super-region count never exceeds the volume: a field of length `n+1` is carried as at most `n+1` super-regions, with equality only when every adjacent pair is a distinction. -/ theorem runs_le_length (l : List α) : runs l ≤ l.length := by match l with | [] => simp | [a] => simp | a :: b :: t => have ih := runs_le_length (b :: t) show (if a = b then 0 else 1) + runs (b :: t) ≤ (a :: b :: t).length rw [show (a :: b :: t).length = (b :: t).length + 1 from rfl] by_cases h : a = b · rw [if_pos h]; omega · rw [if_neg h]; omegaThe declaration runs_le_length proves a bound: the number of coarse regions the ledger must carry never exceeds the number of entries in the field. runs_le_length · IndisputableMonolith/Cosmology/DomainCoarsening.leanTHEOREM runs_eq · IndisputableMonolith/Cosmology/DomainCoarsening.lean
/-- **The coarsest lossless representation has size = forced distinctions + 1.** For every nonempty charge field, the number of coarse super-regions the engine carries (`runs`) is exactly the number of forced distinctions (`boundaries`) plus one. The right side depends only on the distinctions, not on the run lengths, so two constant blocks of any size are carried as two super-regions. -/ theorem runs_eq (a : α) (l : List α) : runs (a :: l) = boundaries (a :: l) + 1 := by induction l generalizing a with | nil => simp | cons b l ih => show (if a = b then 0 else 1) + runs (b :: l) = ((if a = b then 0 else 1) + boundaries (b :: l)) + 1 rw [ih b] by_cases h : a = b · simp only [if_pos h]; omega · simp only [if_neg h]; omegaThe theorem runs_eq shows that for any nonempty field, the number of runs equals the number of adjacent unequal pairs (the forced distinctions) plus one. runs_eq · IndisputableMonolith/Cosmology/DomainCoarsening.leanTHEOREM runs_eq · IndisputableMonolith/Cosmology/DomainCoarsening.lean
/-- **The coarsest lossless representation has size = forced distinctions + 1.** For every nonempty charge field, the number of coarse super-regions the engine carries (`runs`) is exactly the number of forced distinctions (`boundaries`) plus one. The right side depends only on the distinctions, not on the run lengths, so two constant blocks of any size are carried as two super-regions. -/ theorem runs_eq (a : α) (l : List α) : runs (a :: l) = boundaries (a :: l) + 1 := by induction l generalizing a with | nil => simp | cons b l ih => show (if a = b then 0 else 1) + runs (b :: l) = ((if a = b then 0 else 1) + boundaries (b :: l)) + 1 rw [ih b] by_cases h : a = b · simp only [if_pos h]; omega · simp only [if_neg h]; omegaTwo constant blocks of any size, for instance, have one distinction and are carried as two super-regions, no matter whether each block has ten entries or ten million. runs_eq · IndisputableMonolith/Cosmology/DomainCoarsening.leanTHEOREM runs_le_length · IndisputableMonolith/Cosmology/DomainCoarsening.lean
/-- The carried super-region count never exceeds the volume: a field of length `n+1` is carried as at most `n+1` super-regions, with equality only when every adjacent pair is a distinction. -/ theorem runs_le_length (l : List α) : runs l ≤ l.length := by match l with | [] => simp | [a] => simp | a :: b :: t => have ih := runs_le_length (b :: t) show (if a = b then 0 else 1) + runs (b :: t) ≤ (a :: b :: t).length rw [show (a :: b :: t).length = (b :: t).length + 1 from rfl] by_cases h : a = b · rw [if_pos h]; omega · rw [if_neg h]; omegaThis is a structural fact about lists, proved in the framework's machine-checked library of formal theorems with no unproved assumptions beyond the standard three axioms of its logic. runs_le_length · IndisputableMonolith/Cosmology/DomainCoarsening.lean