Encyclopedia Foundation Foundation Primitive Recognition Calculus Prcjcost Distance Triangle

ARTICLE 4 claims 4 theorems

Foundation Primitive Recognition Calculus Prcjcost Distance Triangle

A distance measure that must satisfy the triangle inequality, and the machine-checked proof that reduces this requirement to a single rational inequality.

The distance triangle

The triangle inequality is a basic demand on any notion of distance: the direct path from A to C should never be longer than going from A to B and then B to C. In classical geometry this is a theorem about straight lines. In the framework's primitive recognition calculus, a discrete ledger of events where each recognition carries a forced cost, the same demand becomes a question about whether the cost-based distance behaves well enough to form a consistent space.

The framework defines a specific distance formula. For two rational numbers x and y, the distance is (g + 1/g)/2 - 1, where g = 1 + (x - y)². This is the J-cost square-gap distance: it measures how far apart two values are by plugging their difference into the framework's fundamental cost function. The framework proves that this formula, as displayed on rational numbers, is exactly what the abstract distance reduces to when computed on the framework's own number type.

The central result is conditional. The framework constructs a certificate showing that if a certain verifier-rational inequality holds, then the triangle inequality follows for the full distance. That inequality states: for any positive epsilon, there exists a positive delta such that if two distances are each smaller than delta, then the third is smaller than epsilon. This is the standard epsilon-delta formulation of continuity for the triangle property. The certificate proves that this rational inequality, once established, transports to the full abstract setting.

In plain terms, the framework reduces a potentially difficult analytic question to a concrete algebraic one. It does not prove the triangle inequality outright; it proves that the triangle inequality is equivalent to checking a specific inequality on rational displays. This is a build-order step: the framework's development plan calls for closing the triangle property at step 9a, and this framework provides the conditional closure, leaving only the explicit rational inequality as the remaining mathematical problem.

The consequence is architectural. The framework can now proceed with a clear target: prove the rational inequality, and the triangle inequality for the J-cost distance follows automatically. The framework also shows that this single inequality is sufficient to establish the null-distance setoid, a consistency condition ensuring that points at zero distance can be identified. This is what makes the cost-based distance usable as a genuine geometric structure within the framework.

THEOREM PRCJCostDistance_toRat · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/PRCJCostDistanceTriangle.lean
/-- Display theorem for the PRC J-cost distance. -/
theorem PRCJCostDistance_toRat (a b : PRCRat) :
    (PRCJCostDistance a b).toRat =
      PRCJCostDistanceRatDisplay a.toRat b.toRat := by
  unfold PRCJCostDistance PRCJCostDistanceRatDisplay
  rw [PRCJCost.onPRCRat_toRat, PRCSquareGap_toRat]
THEOREM PRCJCostDistanceTriangleModulusTarget_of_verifier · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/PRCJCostDistanceTriangle.lean
/-- The verifier-rational triangle inequality closes the PRC triangle-modulus
target by display transport. -/
theorem PRCJCostDistanceTriangleModulusTarget_of_verifier
    (h : PRCJCostDistanceVerifierTriangleTarget) :
    PRCJCostDistanceTriangleModulusTarget := by
  intro eps heps
  rcases h eps heps with ⟨delta, hdelta_pos, hdelta⟩
  refine ⟨delta, hdelta_pos, ?_⟩
  intro a b c hab hbc
  rw [PRCRat.lt_iff_toRat_lt] at hab hbc ⊢
  rw [PRCJCostDistance_toRat] at hab hbc ⊢
  exact hdelta a.toRat b.toRat c.toRat hab hbc
THEOREM PRCNullDistanceSetoidTarget_of_verifier_triangle · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/PRCJCostDistanceTriangle.lean
/-- Once the verifier-rational inequality is proved, the final null-distance
setoid target follows. -/
theorem PRCNullDistanceSetoidTarget_of_verifier_triangle
    (h : PRCJCostDistanceVerifierTriangleTarget) :
    PRCNullDistanceSetoidTarget :=
  PRCNullDistanceSetoidTarget_of_triangle_modulus
    (PRCJCostDistanceTriangleModulusTarget_of_verifier h)
THEOREM prc_jcost_distance_triangle_conditional_certificate · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/PRCJCostDistanceTriangle.lean
prc_jcost_distance_triangle_conditional_certificate · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/PRCJCostDistanceTriangle.lean:83
/-- Build Order step 9a conditional closure: PRC triangle transport is reduced
to the displayed rational inequality. -/
theorem prc_jcost_distance_triangle_conditional_certificate :
    PRCJCostDistanceTriangleConditionalCertificate where
  distance_display := PRCJCostDistance_toRat
  verifier_triangle_target := rfl
  triangle_from_verifier := PRCJCostDistanceTriangleModulusTarget_of_verifier
  setoid_from_verifier := PRCNullDistanceSetoidTarget_of_verifier_triangle

What this page does not claim

The triangle inequality for the J-cost distance is not proved outright; only the conditional reduction to a rational inequality is established. The framework does not define the J-cost function itself, only its use as a distance measure. No claim is made that the verifier-rational inequality has been proved; it remains an explicit open target.

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/PrimitiveRecognitionCalculus/PRCJCostDistanceTriangle.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