Encyclopedia Foundation Foundation Magnitude Of Mismatch Equality Cost Single Valued
ARTICLE 3 claims 3 theorems
Foundation Magnitude Of Mismatch Equality Cost Single Valued
A comparison that gives one answer regardless of order is the same thing as a symmetric comparison, and the equality-induced cost is one such comparison.
The forced symmetry of comparison
In mathematics, a function of two arguments is symmetric when swapping the arguments leaves the result unchanged: f(x, y) equals f(y, x). A comparison operator that measures the cost or magnitude of mismatch between two entities is a function of this kind. The classical question is whether such an operator can be asymmetric, giving a different value when the order is reversed, while still being a single, well-defined function.
The answer, formalized in the machine-checked library of formal theorems, is no. A comparison that is single-valued on the unordered pair, meaning there is one function f such that the cost C x y equals f applied to the set {x, y}, must be symmetric. The proof is direct: if C factors through the unordered pair, then C x y and C y x both equal the same value f({x, y}), so they are equal. Conversely, any symmetric comparison factors through the unordered pair. The two properties are equivalent, and this equivalence is the theorem singleValued_iff_symmetric.
This equivalence has a sharp consequence for the equality-induced cost, the cost that measures how far two entities are from being equal. The framework proves that this cost is symmetric, via the non-contradiction principle that C x y equals C y x. By the equivalence, it follows immediately that the equality-induced cost is single-valued on the unordered pair. This is the declaration equalityCost_singleValued: it establishes that the canonical cost derived from equality is automatically in the single-valued shape, with no further interpretive choice needed.
In Recognition Science, this result removes a degree of freedom. The asymmetric reading of comparison, where C x y and C y x are allowed to differ, does not produce a single binary function; it produces two distinct directional functions. The framework's library shows that any such asymmetry splits the operator, and the single-valued reading is the unique one consistent with treating comparison as a predicate on a distinguished pair. The theorem is not a claim about any specific cost function, but about the structure of comparison itself.
What this does not claim is broader. It does not say that all comparisons in all contexts must be symmetric; it says that if a comparison is single-valued on the unordered pair, symmetry is forced. It does not derive the specific form of the equality-induced cost, only its symmetry and single-valuedness. And it does not claim that asymmetry is impossible, only that an asymmetric comparison is not a single function on pairs but a pair of directional functions.
THEOREM singleValued_iff_symmetric · IndisputableMonolith/Foundation/MagnitudeOfMismatch.lean
/-- **Equivalence: single-valuedness on the unordered pair is symmetry.** -/
theorem singleValued_iff_symmetric
{K Cost : Type*} (C : K → K → Cost) :
SingleValuedOnUnorderedPair C ↔ ∀ x y : K, C x y = C y x :=
⟨singleValued_implies_symmetric C,
fun h => symmetric_implies_factorsThrough C h⟩
THEOREM equalityCost_singleValued · IndisputableMonolith/Foundation/MagnitudeOfMismatch.lean
/-- The equality-induced cost is single-valued on the unordered pair. -/
theorem equalityCost_singleValued (K : Type*) (weight : ℝ) :
SingleValuedOnUnorderedPair (equalityCost K weight) :=
symmetric_implies_factorsThrough (equalityCost K weight)
(non_contradiction_from_equality K weight)
THEOREM asymmetric_not_singleValued · IndisputableMonolith/Foundation/MagnitudeOfMismatch.lean
/-- The negation: if `C` is asymmetric on at least one pair, it cannot
factor through the unordered pair. Single-valuedness fails the moment the
two orderings give different values.
This is the Lean form of Theorem 3 of the companion paper: asymmetry
splits a single binary function into two directional functions. -/
theorem asymmetric_not_singleValued
{K Cost : Type*} (C : K → K → Cost)
(h : ∃ x y : K, C x y ≠ C y x) :
¬ SingleValuedOnUnorderedPair C := by
rintro hSV
rcases h with ⟨x, y, hxy⟩
exact hxy (singleValued_implies_symmetric C hSV x y)
What this page does not claim
This does not claim that all comparison operators must be symmetric in every context. This does not derive the specific numerical form of the equality-induced cost. This does not claim that asymmetry is impossible, only that it is not a single function on pairs.
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/MagnitudeOfMismatch.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 specific form does the equality-induced cost take, and how is it derived from the primitive distinction?
- How does the symmetry of comparison relate to the logical principle of non-contradiction in the framework?
- What would a directed revision operator look like, and what additional structure would it require?
MACHINE LAYER · GROUNDED CLAIM TABLE · CLICK TO EXPAND
THEOREM singleValued_iff_symmetric · IndisputableMonolith/Foundation/MagnitudeOfMismatch.lean
/-- **Equivalence: single-valuedness on the unordered pair is symmetry.** -/ theorem singleValued_iff_symmetric {K Cost : Type*} (C : K → K → Cost) : SingleValuedOnUnorderedPair C ↔ ∀ x y : K, C x y = C y x := ⟨singleValued_implies_symmetric C, fun h => symmetric_implies_factorsThrough C h⟩A comparison operator is single-valued on the unordered pair if and only if it is symmetric. singleValued_iff_symmetric · IndisputableMonolith/Foundation/MagnitudeOfMismatch.leanTHEOREM equalityCost_singleValued · IndisputableMonolith/Foundation/MagnitudeOfMismatch.lean
/-- The equality-induced cost is single-valued on the unordered pair. -/ theorem equalityCost_singleValued (K : Type*) (weight : ℝ) : SingleValuedOnUnorderedPair (equalityCost K weight) := symmetric_implies_factorsThrough (equalityCost K weight) (non_contradiction_from_equality K weight)The equality-induced cost is single-valued on the unordered pair. equalityCost_singleValued · IndisputableMonolith/Foundation/MagnitudeOfMismatch.leanTHEOREM asymmetric_not_singleValued · IndisputableMonolith/Foundation/MagnitudeOfMismatch.lean
/-- The negation: if `C` is asymmetric on at least one pair, it cannot factor through the unordered pair. Single-valuedness fails the moment the two orderings give different values. This is the Lean form of Theorem 3 of the companion paper: asymmetry splits a single binary function into two directional functions. -/ theorem asymmetric_not_singleValued {K Cost : Type*} (C : K → K → Cost) (h : ∃ x y : K, C x y ≠ C y x) : ¬ SingleValuedOnUnorderedPair C := by rintro hSV rcases h with ⟨x, y, hxy⟩ exact hxy (singleValued_implies_symmetric C hSV x y)Any asymmetric comparison cannot factor through the unordered pair. asymmetric_not_singleValued · IndisputableMonolith/Foundation/MagnitudeOfMismatch.lean