MindFormal v1.0.0One Mind

MindFormal.Chapters.Ch10.L82.FiniteBattery

The finite word-mask and cached-pattern bills used by LM1.6. All reads share their declared joint law. A repeated occurrence of a query reads its cached mask; it never adds an independence hypothesis or a trial.

def MindFormal.Logic.L82.bitMismatch {Ω : Type u_1} {B : Type u_2} (actual : Ω → B → Bool) (reference : B → Bool) (b : B) :
Set Ω
Equations
Instances For
    theorem MindFormal.Logic.L82.cached_bit_bill {Ω : Type u_1} {B : Type u_2} [MeasurableSpace Ω] {μ : MeasureTheory.Measure Ω} (s : Finset B) (actual : Ω → B → Bool) (reference : B → Bool) (ε : B → ℝ) (hε : ∀ b ∈ s, μ.real (bitMismatch actual reference b) ≤ ε b) :
    μ.real {ω : Ω | ∃ b ∈ s, actual ω b ≠ reference b} ≤ ∑ b ∈ s, ε b

    Each distinct bit is charged once, even when a test mentions it several times in different premises or conclusions.

    theorem MindFormal.Logic.L82.repeated_occurrences_bill {Ω : Type u_1} {B : Type u_2} [MeasurableSpace Ω] {μ : MeasureTheory.Measure Ω} [DecidableEq B] (occurrences : List B) (actual : Ω → B → Bool) (reference : B → Bool) (ε : B → ℝ) (hε : ∀ b ∈ occurrences, μ.real (bitMismatch actual reference b) ≤ ε b) :
    μ.real {ω : Ω | ∃ b ∈ occurrences, actual ω b ≠ reference b} ≤ ∑ b ∈ occurrences.toFinset, ε b
    theorem MindFormal.Logic.L82.cached_pattern_bill {Ω : Type u_1} {B : Type u_2} [MeasurableSpace Ω] {μ : MeasureTheory.Measure Ω} [MeasureTheory.IsFiniteMeasure μ] (s : Finset B) (actual : Ω → B → Bool) (reference : B → Bool) (test : (B → Bool) → Bool) (locality : ∀ (x y : B → Bool), (∀ b ∈ s, x b = y b) → test x = test y) (ε : B → ℝ) (hε : ∀ b ∈ s, μ.real (bitMismatch actual reference b) ≤ ε b) :
    μ.real {ω : Ω | test (actual ω) ≠ test reference} ≤ ∑ b ∈ s, ε b

    A Boolean rule pattern may inspect the same cached input arbitrarily many times. Agreement at its finite input set fixes the entire pattern.

    theorem MindFormal.Logic.L82.reference_pattern_holds_bill {Ω : Type u_1} {B : Type u_2} [MeasurableSpace Ω] {μ : MeasureTheory.Measure Ω} [MeasureTheory.IsFiniteMeasure μ] (s : Finset B) (actual : Ω → B → Bool) (reference : B → Bool) (violation : (B → Bool) → Bool) (locality : ∀ (x y : B → Bool), (∀ b ∈ s, x b = y b) → violation x = violation y) (hholds : violation reference = false) (ε : B → ℝ) (hε : ∀ b ∈ s, μ.real (bitMismatch actual reference b) ≤ ε b) :
    μ.real {ω : Ω | violation (actual ω) = true} ≤ ∑ b ∈ s, ε b
    theorem MindFormal.Logic.L82.reference_pattern_fails_bill {Ω : Type u_1} {B : Type u_2} [MeasurableSpace Ω] {μ : MeasureTheory.Measure Ω} [MeasureTheory.IsProbabilityMeasure μ] (s : Finset B) (actual : Ω → B → Bool) (reference : B → Bool) (violation : (B → Bool) → Bool) (locality : ∀ (x y : B → Bool), (∀ b ∈ s, x b = y b) → violation x = violation y) (hfails : violation reference = true) (ε : B → ℝ) (hε : ∀ b ∈ s, μ.real (bitMismatch actual reference b) ≤ ε b) :
    1 - ∑ b ∈ s, ε b ≤ μ.real {ω : Ω | violation (actual ω) = true}
    noncomputable def MindFormal.Logic.L82.nativeMask {Ω : Type u_1} [MeasurableSpace Ω] {N n : ℕ} {T : Type u_3} {Λ : Type u_4} {J : Type u_5} [Fintype T] [Fintype Λ] [Fintype J] (E : StateExperiment Ω N n T Λ J) (t : ↑(HorizonTime ↑E.horizon)) (bar : ℝ) (ω : Ω) :
    Equations
    Instances For
      noncomputable def MindFormal.Logic.L82.referenceMask {N : ℕ} (bar : ℝ) (r : Fin N → ℝ) :
      Equations
      Instances For
        theorem MindFormal.Logic.L82.nativeMask_mem {Ω : Type u_1} [MeasurableSpace Ω] {N n : ℕ} {T : Type u_3} {Λ : Type u_4} {J : Type u_5} [Fintype T] [Fintype Λ] [Fintype J] (E : StateExperiment Ω N n T Λ J) (t : ↑(HorizonTime ↑E.horizon)) (bar : ℝ) (ω : Ω) (i : Fin N) :
        i ∈ nativeMask E t bar ω ↔ bar ≤ mindActivity ((ownGlobal E ω).state ↑t) i
        theorem MindFormal.Logic.L82.referenceMask_mem {N : ℕ} (bar : ℝ) (r : Fin N → ℝ) (i : Fin N) :
        i ∈ referenceMask bar r ↔ bar ≤ r i
        theorem MindFormal.Logic.L82.native_mask_mismatch {Ω : Type u_1} [MeasurableSpace Ω] {N n : ℕ} {T : Type u_3} {Λ : Type u_4} {J : Type u_5} [Fintype T] [Fintype Λ] [Fintype J] (E : StateExperiment Ω N n T Λ J) (t : ↑(HorizonTime ↑E.horizon)) (bar : ℝ) (r : Fin N → ℝ) :
        {ω : Ω | nativeMask E t bar ω ≠ referenceMask bar r} = ⋃ (i : Fin N), readDisagreement E i t bar (r i)

        Both conclusion bits of a word belong to one mask; this identity does not factor their joint distribution.

        theorem MindFormal.Logic.L82.native_mask_bill {Ω : Type u_1} [MeasurableSpace Ω] {μ : MeasureTheory.Measure Ω} {N n : ℕ} {T : Type u_3} {Λ : Type u_4} {J : Type u_5} [Fintype T] [Fintype Λ] [Fintype J] (E : StateExperiment Ω N n T Λ J) (t : ↑(HorizonTime ↑E.horizon)) (bar : ℝ) (r ε : Fin N → ℝ) (hε : ∀ (i : Fin N), μ.real (readDisagreement E i t bar (r i)) ≤ ε i) :
        μ.real {ω : Ω | nativeMask E t bar ω ≠ referenceMask bar r} ≤ ∑ i : Fin N, ε i
        theorem MindFormal.Logic.L82.native_word_battery_bill {Ω : Type u_1} [MeasurableSpace Ω] {μ : MeasureTheory.Measure Ω} {N n : ℕ} {T : Type u_3} {Λ : Type u_4} {J : Type u_5} [Fintype T] [Fintype Λ] [Fintype J] (words : Finset (List (Fin N))) (E : List (Fin N) → StateExperiment Ω N n T Λ J) (t : (w : List (Fin N)) → ↑(HorizonTime ↑(E w).horizon)) (bar : ℝ) (r : List (Fin N) → Fin N → ℝ) (ε : List (Fin N) → ℝ) (hε : ∀ w ∈ words, μ.real {ω : Ω | nativeMask (E w) (t w) bar ω ≠ referenceMask bar (r w)} ≤ ε w) :
        μ.real {ω : Ω | ∃ w ∈ words, nativeMask (E w) (t w) bar ω ≠ referenceMask bar (r w)} ≤ ∑ w ∈ words, ε w

        A finite family of whole masks is unioned by words. A per-word certificate that already controls its whole mask is charged just once.

        theorem MindFormal.Logic.L82.native_word_battery_event {Ω : Type u_1} [MeasurableSpace Ω] {μ : MeasureTheory.Measure Ω} {N n : ℕ} {T : Type u_3} {Λ : Type u_4} {J : Type u_5} [Fintype T] [Fintype Λ] [Fintype J] [MeasureTheory.IsProbabilityMeasure μ] (words : Finset (List (Fin N))) (E : List (Fin N) → StateExperiment Ω N n T Λ J) (t : (w : List (Fin N)) → ↑(HorizonTime ↑(E w).horizon)) (bar : ℝ) (r : List (Fin N) → Fin N → ℝ) (ε : List (Fin N) → ℝ) (hε : ∀ w ∈ words, μ.real {ω : Ω | nativeMask (E w) (t w) bar ω ≠ referenceMask bar (r w)} ≤ ε w) :
        ∃ (good : Set Ω), MeasurableSet good ∧ 1 - min 1 (∑ w ∈ words, ε w) ≤ μ.real good ∧ ∀ ω ∈ good, ∀ w ∈ words, nativeMask (E w) (t w) bar ω = referenceMask bar (r w)

        An explicit measurable joint certificate, using the declared joint draw without independence. No correct-table event is a field of the input; the measurable event is constructed from the already bounded native errors.