Encyclopedia Cosmology Cosmology Domain Coarsening2 D Row Cost Cons

ARTICLE 2 claims 2 theorems

Cosmology Domain Coarsening2 D Row Cost Cons

A new theorem shows how the cost of describing a two-dimensional grid can be counted row by row, and why the total depends on boundaries, not area.

A row-by-row cost

A two-dimensional grid, like a checkerboard or a map of cells, where each cell carries a charge. In recognition, the framework's term for the universe storing a discrete record of events, describing such a grid means grouping adjacent cells of equal charge into regions. The cost, the number of regions the record must carry, depends on how the grid is cut. The declaration rowCost_cons is a small but exact piece of that accounting: it states that the cost of a grid made of a first row plus the rest is simply the cost of that first row added to the cost of the rest.

This is a recursive rule, the kind that lets a machine or a mathematician break a large grid into smaller pieces. The theorem, proved in the framework's machine-checked library of formal theorems, says that for any list of rows r :: rs, the row-wise cost rowCost (r :: rs) equals runs r + rowCost rs. Here runs counts the super-regions in a single row, and rowCost sums those counts across all rows. The proof is a one-line simplification, but the rule it encodes is the backbone of a larger result.

That larger result, also in the same library, is the theorem rowwise_cost_eq. For any grid with nonempty rows, it proves that the total row-wise cost equals the total horizontal interface (the number of boundaries between different charges within each row) plus the number of rows. This is the exact two-dimensional analogue of the one-dimensional law that runs equal boundaries plus one. The key consequence is that this cost depends only on the interface and the row count, never on the row widths, meaning it is bounded by the perimeter of the regions, not by the area they cover.

The declaration rowCost_cons itself does not claim anything about the true two-dimensional component count, which also merges regions vertically. That full count is always at most the row-wise cost, a separate bound. The recursive rule is a building block, not the final edifice.

THEOREM rowCost_cons · IndisputableMonolith/Cosmology/DomainCoarsening2D.lean
theorem rowCost_cons (r : List α) (rs : List (List α)) :
    rowCost (r :: rs) = runs r + rowCost rs := by
  simp [rowCost]
THEOREM rowwise_cost_eq · IndisputableMonolith/Cosmology/DomainCoarsening2D.lean
/-- **The separable coarsening cost = horizontal interface + number of rows.** For any 2D grid whose rows are
all nonempty, coarsening each row independently carries exactly (the total horizontal interface) plus (the
number of rows) super-regions. This is the exact per-axis generalization of the 1D law `runs = boundaries + 1`
summed over rows, and it depends only on the interface and the row count, never on the row widths (the area).
The true 2D component coarsening merges vertically as well, so it carries at most this many super-regions. -/
theorem rowwise_cost_eq (rows : List (List α)) (h : ∀ r ∈ rows, r ≠ []) :
    rowCost rows = rowInterface rows + rows.length := by
  induction rows with
  | nil => simp
  | cons r rs ih =>
    rw [rowCost_cons, rowInterface_cons, runs_eq_of_ne_nil r (h r (List.mem_cons.mpr (Or.inl rfl)))]
    rw [ih (fun row hrow => h row (List.mem_cons.mpr (Or.inr hrow)))]
    simp [List.length_cons]
    ring

What this page does not claim

The declaration does not prove that the true 2D component count equals the row-wise cost; it only provides an upper bound. It does not establish any result for grids with empty rows. It does not address the physical recognition-to-linking bridge for 2D domains.

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/DomainCoarsening2D.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:

MACHINE LAYER · GROUNDED CLAIM TABLE · CLICK TO EXPAND