Encyclopedia Foundation Foundation Primitive Recognition Calculus Certified Analytic Transformers Rich T
ARTICLE 3 claims 3 theorems
Foundation Primitive Recognition Calculus Certified Analytic Transformers Rich T
A machine-checked theorem shows that even a richly expanded protocol registry still generates only a countable, fully witnessed set of values.
The closure theorem
In the Recognition Science framework, a protocol is a discrete record of recognition events, and a registry is a collection of rules for building new protocols from old ones. The declaration rich_transformer_closure is a theorem about a particular, richer kind of registry: one that starts with rational numbers, adds named constants, and allows both unary and binary transformers, which are operations that take one or two protocols and produce a new one. The theorem states that no matter how such a registry is configured, the set of all real-number values that its finite expressions can produce remains countable, meaning it can be put into a list, and every one of those values is witnessed by an actual protocol that realizes it.
The proof is a direct assembly of six previously established facts. The first is that the set of values is countable, because it is the image of a countable set of expressions. The second is that every value in that set has a protocol that produces it. The remaining four are algebraic identities: the value of a rational expression is that rational number, the value of an addition is the sum of the values, the value of a negation is the negation of the value, and the value of a subtraction is the difference of the values. The theorem bundles these six facts into a single statement, which is what makes it a closure result: it certifies that the richer registry does not escape the countable, protocol-witnessed world of the original framework.
The companion theorem certified_transformer_headline adds a structural fact about unary transformers: composing them is associative, meaning that applying f after g after h gives the same result whether you compose f with g first or g with h first. This is a purely formal property, true by definition of function composition, and it holds for any protocols whatsoever. The headline bundles this associativity with the countability and witnessing results, presenting the full picture in one statement.
What the theorem does not claim is just as important as what it proves. It does not say that every real number can be produced by some expression in the richer registry; on the contrary, it proves the set of producible values is countable, so almost all real numbers remain outside it. It also does not say that the binary transformers can combine to produce new unary transformers beyond finite compositions of registered ones; the theorem only covers finite expressions, not infinite limits or closures under arbitrary operations. The richer registry is richer, but it is still a countable, finitely generated world.
THEOREM rich_transformer_closure · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/CertifiedAnalyticTransformers.lean
/-- Rich certified-analytic closure: binary transformers and unary transformers
still generate only countably many display values, each protocol-witnessed. -/
theorem rich_transformer_closure (R : RichRegistry) :
(values R).Countable
∧ (∀ x : ℝ, x ∈ values R → ∃ p : Protocol, p.value = x)
∧ (∀ q : ℚ, value R (.rat q) = (q : ℝ))
∧ (∀ a b : RichExpr, value R (.add a b) = value R a + value R b)
∧ (∀ a : RichExpr, value R (.neg a) = - value R a)
∧ (∀ a b : RichExpr, value R (.sub a b) = value R a - value R b) :=
⟨values_countable R, every_value_has_protocol R, value_rat R, value_add R,
value_neg R, value_sub R⟩
THEOREM value_add · value_neg · value_sub · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/CertifiedAnalyticTransformers.lean
theorem value_add (R : RichRegistry) (a b : RichExpr) :
value R (.add a b) = value R a + value R b := by
simp [value, eval, Protocol.value_add]
theorem value_neg (R : RichRegistry) (a : RichExpr) :
value R (.neg a) = - value R a := by
simp [value, eval, Protocol.value_neg]
theorem value_sub (R : RichRegistry) (a b : RichExpr) :
value R (.sub a b) = value R a - value R b := by
simp [value, eval, Protocol.value_sub]
THEOREM composeUnary_assoc · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/CertifiedAnalyticTransformers.lean
theorem composeUnary_assoc (f g h : Protocol → Protocol) :
composeUnary (composeUnary f g) h = composeUnary f (composeUnary g h) := by
rfl
What this page does not claim
The richer registry can produce every real number; the theorem proves the opposite, that the producible values are countable. Binary transformers can generate new unary transformers beyond finite compositions of registered ones. The theorem covers infinite expressions or limits of finite expressions.
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/CertifiedAnalyticTransformers.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 additional closure properties would a registry need to generate an uncountable set of values?
- How does the countability result constrain which functions can be represented as protocols in the framework?
- What role do binary transformers play in the framework beyond the countability result?
- Does the associativity of unary composition extend to binary transformers in any natural way?
MACHINE LAYER · GROUNDED CLAIM TABLE · CLICK TO EXPAND
THEOREM rich_transformer_closure · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/CertifiedAnalyticTransformers.lean
/-- Rich certified-analytic closure: binary transformers and unary transformers still generate only countably many display values, each protocol-witnessed. -/ theorem rich_transformer_closure (R : RichRegistry) : (values R).Countable ∧ (∀ x : ℝ, x ∈ values R → ∃ p : Protocol, p.value = x) ∧ (∀ q : ℚ, value R (.rat q) = (q : ℝ)) ∧ (∀ a b : RichExpr, value R (.add a b) = value R a + value R b) ∧ (∀ a : RichExpr, value R (.neg a) = - value R a) ∧ (∀ a b : RichExpr, value R (.sub a b) = value R a - value R b) := ⟨values_countable R, every_value_has_protocol R, value_rat R, value_add R, value_neg R, value_sub R⟩The set of all real-number values that its finite expressions can produce remains countable, meaning it can be put into a list, and every one of those values is witnessed by an actual protocol that realizes it. rich_transformer_closure · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/CertifiedAnalyticTransformers.leanTHEOREM value_add · value_neg · value_sub · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/CertifiedAnalyticTransformers.lean
theorem value_add (R : RichRegistry) (a b : RichExpr) : value R (.add a b) = value R a + value R b := by simp [value, eval, Protocol.value_add]theorem value_neg (R : RichRegistry) (a : RichExpr) : value R (.neg a) = - value R a := by simp [value, eval, Protocol.value_neg]theorem value_sub (R : RichRegistry) (a b : RichExpr) : value R (.sub a b) = value R a - value R b := by simp [value, eval, Protocol.value_sub]The value of an addition is the sum of the values, the value of a negation is the negation of the value, and the value of a subtraction is the difference of the values. value_add · value_neg · value_sub · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/CertifiedAnalyticTransformers.leanTHEOREM composeUnary_assoc · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/CertifiedAnalyticTransformers.lean
theorem composeUnary_assoc (f g h : Protocol → Protocol) : composeUnary (composeUnary f g) h = composeUnary f (composeUnary g h) := by rflComposing them is associative, meaning that applying f after g after h gives the same result whether you compose f with g first or g with h first. composeUnary_assoc · IndisputableMonolith/Foundation/PrimitiveRecognitionCalculus/CertifiedAnalyticTransformers.lean