pith. machine review for the scientific record. sign in

IndisputableMonolith.RecogGeom.Connectivity

IndisputableMonolith/RecogGeom/Connectivity.lean · 156 lines · 11 declarations

show as:
view math explainer →

open module explainer GitHub source

Explainer status: pending

   1import Mathlib
   2import IndisputableMonolith.RecogGeom.Quotient
   3
   4/-!
   5# Recognition Geometry: Connectivity and Local Regularity (RG5)
   6
   7This module develops the notion of "recognition connectivity"—when two
   8configurations can be connected by a path that stays within a single
   9resolution cell.
  10
  11## The Core Question
  12
  13When is a recognition geometry "regular" enough to support smooth structure?
  14
  15The answer involves local regularity (RG5): recognition preimages should be
  16"connected" within neighborhoods. This ensures that resolution cells don't
  17fragment pathologically.
  18
  19## Key Definitions
  20
  21- `IsRecognitionConnected`: When a set is connected (all points equivalent)
  22- `IsLocallyRegular`: RG5 - preimages are connected in neighborhoods
  23- `SatisfiesRG5`: The full RG5 axiom
  24
  25## Physical Interpretation
  26
  27Recognition connectivity captures the idea that "nearby" configurations
  28(in the recognition sense) should form coherent clusters, not scattered
  29points. This is what allows smooth physics to emerge from discrete recognition.
  30
  31-/
  32
  33namespace IndisputableMonolith
  34namespace RecogGeom
  35
  36variable {C E : Type*}
  37
  38/-! ## Recognition Connectivity -/
  39
  40/-- A set S is recognition-connected for recognizer r if all elements of S
  41    are mutually indistinguishable.
  42
  43    This is a strong notion: every point sees the same event. -/
  44def IsRecognitionConnected (r : Recognizer C E) (S : Set C) : Prop :=
  45  ∀ c₁ c₂, c₁ ∈ S → c₂ ∈ S → Indistinguishable r c₁ c₂
  46
  47/-- The empty set is vacuously recognition-connected -/
  48theorem isRecognitionConnected_empty (r : Recognizer C E) :
  49    IsRecognitionConnected r ∅ := by
  50  intro c₁ c₂ h₁ _
  51  exact absurd h₁ (Set.not_mem_empty c₁)
  52
  53/-- A singleton set is recognition-connected -/
  54theorem isRecognitionConnected_singleton (r : Recognizer C E) (c : C) :
  55    IsRecognitionConnected r {c} := by
  56  intro c₁ c₂ h₁ h₂
  57  simp only [Set.mem_singleton_iff] at h₁ h₂
  58  rw [h₁, h₂]
  59  exact Indistinguishable.refl r c
  60
  61/-- A resolution cell is recognition-connected by definition -/
  62theorem isRecognitionConnected_resolutionCell (r : Recognizer C E) (c : C) :
  63    IsRecognitionConnected r (ResolutionCell r c) := by
  64  intro c₁ c₂ h₁ h₂
  65  simp only [ResolutionCell, Set.mem_setOf_eq] at h₁ h₂
  66  exact Indistinguishable.trans r h₁ (Indistinguishable.symm' r h₂)
  67
  68/-- A subset of a recognition-connected set is recognition-connected -/
  69theorem isRecognitionConnected_subset (r : Recognizer C E) {S T : Set C}
  70    (hST : S ⊆ T) (hT : IsRecognitionConnected r T) :
  71    IsRecognitionConnected r S := by
  72  intro c₁ c₂ h₁ h₂
  73  exact hT c₁ c₂ (hST h₁) (hST h₂)
  74
  75/-! ## Local Regularity (RG5) -/
  76
  77/-- A recognizer is locally regular at c if the preimage of r(c) is
  78    recognition-connected within some neighborhood of c.
  79
  80    This means: nearby configurations that produce the same event
  81    are actually "coherently" grouped together. -/
  82def IsLocallyRegular (L : LocalConfigSpace C) (r : Recognizer C E) (c : C) : Prop :=
  83  ∃ U ∈ L.N c, IsRecognitionConnected r (r.R ⁻¹' {r.R c} ∩ U)
  84
  85/-- A recognizer is locally regular everywhere -/
  86def IsRegular (L : LocalConfigSpace C) (r : Recognizer C E) : Prop :=
  87  ∀ c : C, IsLocallyRegular L r c
  88
  89/-- **RG5**: Local Regularity Axiom.
  90
  91    A recognition geometry satisfies RG5 if every recognizer is locally regular.
  92    This ensures that resolution cells form coherent "blobs" within neighborhoods,
  93    not scattered fragments. -/
  94structure SatisfiesRG5 (L : LocalConfigSpace C) (r : Recognizer C E) : Prop where
  95  locally_regular : IsRegular L r
  96
  97/-! ## Consequences of Local Regularity -/
  98
  99/-- If a recognizer is locally regular at c, the resolution cell intersected
 100    with some neighborhood is still recognition-connected. -/
 101theorem locally_regular_cell_connected (L : LocalConfigSpace C) (r : Recognizer C E)
 102    (c : C) (h : IsLocallyRegular L r c) :
 103    ∃ U ∈ L.N c, IsRecognitionConnected r (ResolutionCell r c ∩ U) := by
 104  obtain ⟨U, hU, hconn⟩ := h
 105  use U, hU
 106  -- ResolutionCell r c = r.R ⁻¹' {r.R c} by definition of Indistinguishable
 107  intro c₁ c₂ h₁ h₂
 108  simp only [ResolutionCell, Set.mem_inter_iff, Set.mem_setOf_eq] at h₁ h₂
 109  -- c₁, c₂ both in preimage of {r.R c} ∩ U
 110  have hc₁ : c₁ ∈ r.R ⁻¹' {r.R c} ∩ U := ⟨h₁.1, h₁.2⟩
 111  have hc₂ : c₂ ∈ r.R ⁻¹' {r.R c} ∩ U := ⟨h₂.1, h₂.2⟩
 112  exact hconn c₁ c₂ hc₁ hc₂
 113
 114/-- A constant recognizer is locally regular everywhere. -/
 115theorem constant_recognizer_regular (L : LocalConfigSpace C) (r : Recognizer C E)
 116    (hconst : ∀ c₁ c₂, r.R c₁ = r.R c₂) :
 117    IsRegular L r := by
 118  intro c
 119  obtain ⟨U, hU⟩ := L.N_nonempty c
 120  use U, hU
 121  intro c₁ c₂ _ _
 122  exact hconst c₁ c₂
 123
 124/-! ## The Role of RG5 in Geometry -/
 125
 126/-- **Intuition**: RG5 ensures that "resolution cells don't fragment".
 127
 128    Without RG5, a resolution cell could look like a Cantor set:
 129    infinitely fragmented within any neighborhood. With RG5, resolution
 130    cells are locally "blob-like"—they stay together coherently.
 131
 132    This is what allows smooth geometric structure to emerge:
 133    resolution cells become the "atoms" of recognition geometry,
 134    and RG5 ensures these atoms are well-behaved. -/
 135
 136/-! ## Module Status -/
 137
 138def connectivity_status : String :=
 139  "✓ IsRecognitionConnected: connected sets defined\n" ++
 140  "✓ isRecognitionConnected_empty: empty set connected\n" ++
 141  "✓ isRecognitionConnected_singleton: singletons connected\n" ++
 142  "✓ isRecognitionConnected_resolutionCell: resolution cells connected\n" ++
 143  "✓ isRecognitionConnected_subset: subsets inherit connectivity\n" ++
 144  "✓ IsLocallyRegular: local regularity at a point (RG5)\n" ++
 145  "✓ IsRegular: global regularity\n" ++
 146  "✓ SatisfiesRG5: RG5 axiom structure\n" ++
 147  "✓ locally_regular_cell_connected: consequence of RG5\n" ++
 148  "✓ constant_recognizer_regular: constants are regular\n" ++
 149  "\n" ++
 150  "CONNECTIVITY & LOCAL REGULARITY (RG5) COMPLETE"
 151
 152#eval connectivity_status
 153
 154end RecogGeom
 155end IndisputableMonolith
 156

source mirrored from github.com/jonwashburn/shape-of-logic