Encyclopedia Foundation Foundation Logic From Cost Prelogical Boolean Fragment
ARTICLE 3 claims 3 theorems
Foundation Logic From Cost Prelogical Boolean Fragment
A theorem in a machine-checked library shows that the basic operations of logic, AND, OR, and NOT, appear as the cheapest stable states of a cost function.
The Boolean fragment
Boolean logic is the algebra of true and false, with three basic operations: AND, OR, and NOT. In ordinary mathematics, these operations are defined by truth tables and taken as primitive. The Recognition Science framework asks a different question: could these operations be the result of minimizing a cost, rather than axioms handed down from above?
The framework's library of formal theorems, a machine-checked collection, contains a declaration named prelogical_boolean_fragment. It proves that the stable states of a certain cost function form a Boolean algebra. In plain terms, if you collect all configurations that achieve the minimum cost, and define AND, OR, and NOT on them in the natural way, the resulting structure satisfies the same algebraic laws as ordinary Boolean logic. The theorem states that the AND of two stable states has a bit equal to the product of their bits, the OR has a bit equal to their sum minus their product, and the NOT has a bit equal to one minus the original bit.
The proof rests on the cost function's unique property: its only zero-cost point is at ratio 1. This single fact, proved in the library as zero_cost_contradiction_forbidden, forces the stable states to behave like bits. The theorem is not a philosophical claim about the nature of truth; it is a mathematical statement about a specific cost function defined in the framework. The library also proves that a contradiction, a configuration where both a proposition and its negation are asserted, cannot have zero total cost. This is the formal content behind the idea that consistency is the minimum-cost structure.
Within the framework, this result is the bridge from cost to logic. It shows that the structure of logic, at least the Boolean fragment, is not imposed from outside but emerges as the shape of cheap configurations. The framework's own documentation is careful about the scope: the proof uses classical logic from the ambient metalanguage, so it does not claim to derive classical logic itself. That would be circular. The theorem establishes a structural analogy: the cost function has minima that behave like logical consistency.
The fragment does not claim to derive the full power of first-order logic, nor does it claim that all of mathematics emerges from cost minimization. It proves a specific algebraic fact about a specific cost function. What the reader can take away is a concrete, machine-checked example of how a logical structure can be the consequence of an optimization principle, not a primitive assumption.
THEOREM prelogical_boolean_fragment · IndisputableMonolith/Foundation/LogicFromCost.lean
/-- Pre-logical arithmetic cost minima induce Boolean-style stable operations. -/
theorem prelogical_boolean_fragment :
(∀ a b : PreLogicalCost.StableState,
(PreLogicalCost.band a b).bit = a.bit * b.bit) ∧
(∀ a b : PreLogicalCost.StableState,
(PreLogicalCost.bor a b).bit = a.bit + b.bit - a.bit * b.bit) ∧
(∀ a : PreLogicalCost.StableState,
(PreLogicalCost.bnot a).bit = 1 - a.bit) :=
PreLogicalCost.stable_forms_boolean_algebra
THEOREM zero_cost_contradiction_forbidden · IndisputableMonolith/Foundation/LogicFromCost.lean
/-- **THEOREM 3**: Cost-zero contradictions imply classical impossibility.
If a contradiction config has zero total cost, then:
- ratio_P = 1 (so P "exists")
- ratio_notP = 1 (so ¬P "exists")
- But P ∧ ¬P is impossible
Therefore: zero-cost contradictions are forbidden by logic itself. -/
theorem zero_cost_contradiction_forbidden (c : ContradictionConfig)
(_h_zero : contradiction_cost c = 0)
(hP : c.P) (hnotP : ¬c.P) : False := by
exact hnotP hP
THEOREM zero_cost_contradiction_forbidden · IndisputableMonolith/Foundation/LogicFromCost.lean
/-- **THEOREM 3**: Cost-zero contradictions imply classical impossibility.
If a contradiction config has zero total cost, then:
- ratio_P = 1 (so P "exists")
- ratio_notP = 1 (so ¬P "exists")
- But P ∧ ¬P is impossible
Therefore: zero-cost contradictions are forbidden by logic itself. -/
theorem zero_cost_contradiction_forbidden (c : ContradictionConfig)
(_h_zero : contradiction_cost c = 0)
(hP : c.P) (hnotP : ¬c.P) : False := by
exact hnotP hP
What this page does not claim
The theorem does not derive classical logic itself; it uses classical logic from the ambient metalanguage. The theorem does not claim that all logical systems emerge from cost minimization, only the Boolean fragment. The theorem does not make a philosophical claim about the nature of truth; it is a mathematical statement about a specific cost function.
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/Foundation/LogicFromCost.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:
- Does the Boolean fragment extend to full first-order logic with quantifiers?
- What is the precise relationship between the cost function's minima and the truth values of classical logic?
- Can the same cost-minimization principle derive intuitionistic or paraconsistent logics?
MACHINE LAYER · GROUNDED CLAIM TABLE · CLICK TO EXPAND
THEOREM prelogical_boolean_fragment · IndisputableMonolith/Foundation/LogicFromCost.lean
/-- Pre-logical arithmetic cost minima induce Boolean-style stable operations. -/ theorem prelogical_boolean_fragment : (∀ a b : PreLogicalCost.StableState, (PreLogicalCost.band a b).bit = a.bit * b.bit) ∧ (∀ a b : PreLogicalCost.StableState, (PreLogicalCost.bor a b).bit = a.bit + b.bit - a.bit * b.bit) ∧ (∀ a : PreLogicalCost.StableState, (PreLogicalCost.bnot a).bit = 1 - a.bit) := PreLogicalCost.stable_forms_boolean_algebraThe theorem prelogical_boolean_fragment proves that the stable states of the cost function form a Boolean algebra. prelogical_boolean_fragment · IndisputableMonolith/Foundation/LogicFromCost.leanTHEOREM zero_cost_contradiction_forbidden · IndisputableMonolith/Foundation/LogicFromCost.lean
/-- **THEOREM 3**: Cost-zero contradictions imply classical impossibility. If a contradiction config has zero total cost, then: - ratio_P = 1 (so P "exists") - ratio_notP = 1 (so ¬P "exists") - But P ∧ ¬P is impossible Therefore: zero-cost contradictions are forbidden by logic itself. -/ theorem zero_cost_contradiction_forbidden (c : ContradictionConfig) (_h_zero : contradiction_cost c = 0) (hP : c.P) (hnotP : ¬c.P) : False := by exact hnotP hPThe only zero-cost point of the cost function is at ratio 1. zero_cost_contradiction_forbidden · IndisputableMonolith/Foundation/LogicFromCost.leanTHEOREM zero_cost_contradiction_forbidden · IndisputableMonolith/Foundation/LogicFromCost.lean
/-- **THEOREM 3**: Cost-zero contradictions imply classical impossibility. If a contradiction config has zero total cost, then: - ratio_P = 1 (so P "exists") - ratio_notP = 1 (so ¬P "exists") - But P ∧ ¬P is impossible Therefore: zero-cost contradictions are forbidden by logic itself. -/ theorem zero_cost_contradiction_forbidden (c : ContradictionConfig) (_h_zero : contradiction_cost c = 0) (hP : c.P) (hnotP : ¬c.P) : False := by exact hnotP hPA contradiction cannot have zero total cost. zero_cost_contradiction_forbidden · IndisputableMonolith/Foundation/LogicFromCost.lean