Skip to content

Commit 560f904

Browse files
committed
ordinal(buchholz): head-Ω inversion lemmas (option (b) for Slice 2-bplus)
Lands the two atomic-source inversion lemmas from option (b) of the Slice 2-bplus follow-on plan documented inline in `RankPow.agda`: * head-Ω-inv-bOmega : bOmega ν <ᵇ y → ν <Ω head-Ω y * head-Ω-inv-bpsi : bpsi ν α <ᵇ y → ν ≤Ω head-Ω y Strict on the Ω-source (the three constructors with `bOmega ν` LHS all carry strict `<Ω` witnesses); non-strict on the ψ-source (the `<ᵇ-ψΩ≤` constructor only carries `ν ≤Ω μ`, so the lemma tops out at `≤Ω` — lifted to a unified shape via `<Ω→≤Ω` at the `<ᵇ-ψΩ` case). Proof in each case: structural recursion on the `<ᵇ` derivation, with the `+`-side constructors recursing through their `<ᵇ` premise on the target's left summand. No funext, no postulates, no rank-mono dependency — that last is the load-bearing design choice this slice makes good on, per the dependency-graph invariant the inline comment in `RankPow.agda`'s Slice 2-bplus note flags. Lands as a new module `Ordinal.Buchholz.HeadOmegaInversion`, wired into `All.agda` and pinned in `Ordinal/Buchholz/Smoke.agda` under its own `using` block with a header comment per CLAUDE.md Working rules. The bplus-source inversion is OUT OF SCOPE for this slice (the three `<ᵇ-+_` constructors recurse on `x <ᵇ (target)` where x can be anything, so the natural inversion has to traverse arbitrary BT subterms — different proof structure). Deferred to a follow-on; the Slice 2-bplus consumer handles the bplus source by inducting on the WfCNF carrier and applying the atomic inversions at the leading subterm. `scripts/kernel-guard.sh`: PASS. No postulates introduced. No diff against `EchoIntegration.agda` / `EchoChoreo.agda` / `EchoGraded.agda` or any existing Echo*Bridge.agda. https://claude.ai/code/session_013nLEeKZXpvHnrDZMgRm19S
1 parent 0108705 commit 560f904

3 files changed

Lines changed: 137 additions & 0 deletions

File tree

proofs/agda/All.agda

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ open import Ordinal.Buchholz.RankPow
110110
open import Ordinal.Buchholz.RankAdm
111111
open import Ordinal.Buchholz.RankLex
112112
open import Ordinal.Buchholz.HeadOmega
113+
open import Ordinal.Buchholz.HeadOmegaInversion
113114
open import Ordinal.Buchholz.RankMonoUmbrella
114115
open import Ordinal.Buchholz.RecursiveSurfaceOrder
115116
open import Ordinal.Buchholz.RecursiveSurfaceBudget
Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,124 @@
1+
{-# OPTIONS --safe --without-K #-}
2+
3+
-- Head-Ω inversion for the original Buchholz `_<ᵇ_` order. Companion
4+
-- module to `Ordinal.Buchholz.HeadOmega` (Slice 1) and `RankPow.agda`
5+
-- Slice 2; option (b) of the Slice 2-bplus follow-on plan from
6+
-- `RankPow.agda`'s preamble.
7+
--
8+
-- ## What this gives
9+
--
10+
-- Two inversion lemmas: from an `<ᵇ` derivation whose source is
11+
-- atomic (`bOmega ν` or `bpsi ν α`), extract a bound on the target
12+
-- term's leading Ω-marker `head-Ω y`.
13+
--
14+
-- * `head-Ω-inv-bOmega : bOmega ν <ᵇ y → ν <Ω head-Ω y`
15+
-- * `head-Ω-inv-bpsi : bpsi ν α <ᵇ y → ν ≤Ω head-Ω y`
16+
--
17+
-- The strict-vs-non-strict asymmetry tracks the `<ᵇ-ψΩ≤` constructor:
18+
-- `bpsi ν α <ᵇ bOmega μ` only requires `ν ≤Ω μ`, not strict, so the
19+
-- ψ-source lemma can only conclude `≤Ω` against the target head. The
20+
-- Ω-source lemma is strict because the three constructors with
21+
-- `bOmega ν` on the left (`<ᵇ-ΩΩ`, `<ᵇ-Ωψ`, `<ᵇ-Ω+`) all carry a
22+
-- strict `<Ω` witness on the target's leading Ω-marker.
23+
--
24+
-- ## Why this lemma family
25+
--
26+
-- Option (b) from `RankPow.agda`'s Slice 2-bplus follow-on plan: a
27+
-- head-Ω inversion path that does NOT transitively depend on
28+
-- rank-mono. The bplus-target case of `<ᵇ-+1` joint-bplus needs to
29+
-- bound `rank-pow source <′ rank-pow target` where `target = bplus y₁
30+
-- y₂` and `rank-pow y₁` is not additive principal in general. The
31+
-- recovery: use additive-principal-`ω-rank-pow {head-Ω y₁}` (always
32+
-- additive principal) as the closure, and bound the source's rank
33+
-- by `ω-rank-pow-succ (head-Ω y₁)` via Slice 2's domination + this
34+
-- inversion family pulling `head-Ω` information from the `<ᵇ` premise.
35+
--
36+
-- Keeping this inversion family in its own module — rather than
37+
-- threading it through `RankMonoUmbrella`'s `_<ᵇ⁰_` carrier or any
38+
-- rank-mono primitive — preserves the dependency-graph invariant
39+
-- the inline comment in `RankPow.agda`'s Slice 2-bplus note flags:
40+
-- a future signature change to `rank-pow-mono-≤ᵇ` cannot silently
41+
-- break `rank-pow-dominated-by-head-Ω` (or vice versa), because the
42+
-- inversion family talks only about `<Ω` / `≤Ω` on Ω-markers, not
43+
-- about ranks at all.
44+
--
45+
-- ## Out of scope
46+
--
47+
-- The bplus-source inversion (`bplus x y <ᵇ z → head-Ω x ?? head-Ω
48+
-- z`) is structurally different: the three `<ᵇ-+_` constructors all
49+
-- recurse on `x <ᵇ (target)` where x can be anything, so the natural
50+
-- inversion would have to traverse arbitrary BT subterms. Deferred
51+
-- to a follow-on slice; for the Slice 2-bplus consumer, the bplus
52+
-- source is handled by inducting on the WfCNF carrier and applying
53+
-- the atomic inversions at the leading subterm.
54+
--
55+
-- ## Headlines (pin in `Ordinal/Buchholz/Smoke.agda`)
56+
--
57+
-- * `head-Ω-inv-bOmega`
58+
-- * `head-Ω-inv-bpsi`
59+
60+
module Ordinal.Buchholz.HeadOmegaInversion where
61+
62+
open import Ordinal.OmegaMarkers using
63+
( OmegaIndex
64+
; _<Ω_
65+
; _≤Ω_
66+
; <Ω→≤Ω
67+
)
68+
open import Ordinal.Buchholz.Syntax using
69+
( BT
70+
; bzero
71+
; bOmega
72+
; bplus
73+
; bpsi
74+
)
75+
open import Ordinal.Buchholz.Order using
76+
( _<ᵇ_
77+
; <ᵇ-ΩΩ
78+
; <ᵇ-Ωψ
79+
; <ᵇ-ψΩ
80+
; <ᵇ-ψΩ≤
81+
; <ᵇ-Ω+
82+
; <ᵇ-ψ+
83+
)
84+
open import Ordinal.Buchholz.HeadOmega using (head-Ω)
85+
86+
----------------------------------------------------------------------
87+
-- bOmega-source inversion: strict bound on the target's leading Ω
88+
----------------------------------------------------------------------
89+
90+
-- For each constructor of `_<ᵇ_` that can produce a `bOmega ν <ᵇ y`
91+
-- derivation, the target's leading Ω-marker strictly dominates ν:
92+
--
93+
-- * `<ᵇ-ΩΩ p`: y = bOmega ν', head-Ω y = ν', p : ν <Ω ν'.
94+
-- * `<ᵇ-Ωψ p`: y = bpsi ν' α', head-Ω y = ν', p : ν <Ω ν'.
95+
-- * `<ᵇ-Ω+ p`: y = bplus x' y', head-Ω y = head-Ω x',
96+
-- recurse on p : bOmega ν <ᵇ x'.
97+
--
98+
-- Termination: the `<ᵇ-Ω+` recursion goes through `p`, a structurally
99+
-- smaller `<ᵇ` derivation.
100+
101+
head-Ω-inv-bOmega : {ν y} bOmega ν <ᵇ y ν <Ω head-Ω y
102+
head-Ω-inv-bOmega (<ᵇ-ΩΩ p) = p
103+
head-Ω-inv-bOmega (<ᵇ-Ωψ p) = p
104+
head-Ω-inv-bOmega (<ᵇ-Ω+ p) = head-Ω-inv-bOmega p
105+
106+
----------------------------------------------------------------------
107+
-- bpsi-source inversion: non-strict bound on the target's leading Ω
108+
----------------------------------------------------------------------
109+
110+
-- For each constructor of `_<ᵇ_` that can produce a `bpsi ν α <ᵇ y`
111+
-- derivation, the target's leading Ω-marker dominates ν (non-strict —
112+
-- the `<ᵇ-ψΩ≤` constructor only carries `ν ≤Ω μ`):
113+
--
114+
-- * `<ᵇ-ψΩ p`: y = bpsi ν' β', head-Ω y = ν', p : ν <Ω ν'.
115+
-- Lift to `≤Ω` via `<Ω→≤Ω`.
116+
-- * `<ᵇ-ψΩ≤ p`: y = bOmega μ, head-Ω y = μ, p : ν ≤Ω μ.
117+
-- Pass through directly.
118+
-- * `<ᵇ-ψ+ p`: y = bplus x' y', head-Ω y = head-Ω x',
119+
-- recurse on p : bpsi ν α <ᵇ x'.
120+
121+
head-Ω-inv-bpsi : {ν α y} bpsi ν α <ᵇ y ν ≤Ω head-Ω y
122+
head-Ω-inv-bpsi (<ᵇ-ψΩ p) = <Ω→≤Ω p
123+
head-Ω-inv-bpsi (<ᵇ-ψΩ≤ p) = p
124+
head-Ω-inv-bpsi (<ᵇ-ψ+ p) = head-Ω-inv-bpsi p

proofs/agda/Ordinal/Buchholz/Smoke.agda

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -418,3 +418,15 @@ open import Ordinal.Buchholz.RankPow using
418418
; rank-pow-bOmega-via-head-Ω
419419
; rank-pow-bpsi-via-head-Ω
420420
)
421+
422+
-- Lane 3 head-Ω inversion (own block per CLAUDE.md Working rules):
423+
-- option (b) of the Slice 2-bplus follow-on plan from `RankPow.agda`'s
424+
-- preamble. Two atomic-source inversions pulling `head-Ω` bounds
425+
-- from an `<ᵇ` premise WITHOUT going through rank-mono — keeps the
426+
-- domination lemma's dependency-graph clean against future signature
427+
-- changes to `rank-pow-mono-≤ᵇ`. Strict on the Ω-source, non-strict
428+
-- on the ψ-source (tracks the `<ᵇ-ψΩ≤` constructor).
429+
open import Ordinal.Buchholz.HeadOmegaInversion using
430+
( head-Ω-inv-bOmega
431+
; head-Ω-inv-bpsi
432+
)

0 commit comments

Comments
 (0)