|
| 1 | +{-# OPTIONS --safe --without-K #-} |
| 2 | +-- SPDX-License-Identifier: MPL-2.0 |
| 3 | +-- SPDX-FileCopyrightText: 2025-2026 Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk> |
| 4 | + |
| 5 | +-- Doubled-ladder rank monotonicity — additive-principality of the |
| 6 | +-- Ω-block target + the `<ᵇ-+Ω` primitive (2026-06-14). |
| 7 | +-- |
| 8 | +-- ## Why this exists |
| 9 | +-- |
| 10 | +-- The bplus-ON-LEFT constructors (`<ᵇ-+Ω`, `<ᵇ-+ψ`, `<ᵇ-+1`) compare |
| 11 | +-- a SUM `rank2 x ⊕ rank2 y` against the target rank. Closing them |
| 12 | +-- needs the target to ABSORB the sum — i.e. additive principality of |
| 13 | +-- the target rank. This slice supplies that for the Ω-block target |
| 14 | +-- `ω-rank-pow-succ (double μ) = rank2 (bOmega μ)`, and uses it to |
| 15 | +-- discharge the first of the three, `<ᵇ-+Ω`. |
| 16 | +-- |
| 17 | +-- `RankPow.additive-principal-ω-rank-pow` already gives additive |
| 18 | +-- principality for the ψ-block target `ω-rank-pow μ`. The Ω-block |
| 19 | +-- target `ω-rank-pow-succ μ` needs its own proof: |
| 20 | +-- |
| 21 | +-- * fin branch — `ω-rank-pow-succ (fin n) = ω^(suc (suc n))` is a |
| 22 | +-- clean ω-power, so the existing `OmegaPow.additive-principal` |
| 23 | +-- (additive principality of `ω^(suc k)`) applies at `k = suc n`. |
| 24 | +-- * ω branch — `ω-rank-pow-succ ω = olim (λ n → ω-rank-pow ω ·ℕ n)` |
| 25 | +-- (= ω^(ω+1)) has the SAME limit shape `olim (λ k → B ·ℕ k)` that |
| 26 | +-- `OmegaPow.additive-principal` exploits, only with base |
| 27 | +-- `B = ω-rank-pow ω` instead of `ω^ n`. The proof there is |
| 28 | +-- generic in the base (it uses only `·ℕ-add-≤ {B}` and the `⊕` |
| 29 | +-- monotonicities), so this module re-states it once as |
| 30 | +-- `additive-principal-base` over an arbitrary base and instantiates |
| 31 | +-- at `B = ω-rank-pow ω`. |
| 32 | +-- |
| 33 | +-- ## Honest scope |
| 34 | +-- |
| 35 | +-- Lands `additive-principal-base`, `additive-principal-ω-rank-pow-succ`, |
| 36 | +-- and the `<ᵇ-+Ω` rank2-mono primitive `rank2-mono-+Ω`. The two |
| 37 | +-- remaining bplus-on-left cases (`<ᵇ-+ψ`, `<ᵇ-+1`) have NON-ω-power |
| 38 | +-- targets (a ψ-block sum / a bplus sum) and need the tail-ordering |
| 39 | +-- machinery (`y ≤ᵇ x` → rank bound) — deferred to the umbrella slice. |
| 40 | +-- |
| 41 | +-- ## Headlines (pin in `Ordinal/Buchholz/Smoke.agda`) |
| 42 | +-- |
| 43 | +-- * `additive-principal-ω-rank-pow-succ` |
| 44 | +-- * `rank2-mono-+Ω` |
| 45 | + |
| 46 | +module Ordinal.Buchholz.RankDoubledLadderAddPrincipal where |
| 47 | + |
| 48 | +open import Data.Nat using (ℕ; suc; _+_) |
| 49 | +open import Data.Product.Base using (_,_) |
| 50 | + |
| 51 | +open import Ordinal.Brouwer using (Ord; osuc; olim) |
| 52 | +open import Ordinal.Brouwer.Phase13 using |
| 53 | + ( _<′_ |
| 54 | + ; _≤′_ |
| 55 | + ; ≤′-trans |
| 56 | + ; ≤′-self-osuc |
| 57 | + ; ⊕-mono-≤-left |
| 58 | + ; ⊕-mono-<-right |
| 59 | + ) |
| 60 | +open import Ordinal.Brouwer.Arithmetic using (_⊕_) |
| 61 | +open import Ordinal.Brouwer.OmegaPow using (_·ℕ_; ·ℕ-add-≤; additive-principal) |
| 62 | +open import Ordinal.OmegaMarkers using (OmegaIndex; fin; ω) |
| 63 | +open import Ordinal.Buchholz.Syntax using (BT; bOmega; bplus) |
| 64 | +open import Ordinal.Buchholz.RankPow using (ω-rank-pow; ω-rank-pow-succ) |
| 65 | +open import Ordinal.Buchholz.RankDoubledLadder using (rank2; double) |
| 66 | + |
| 67 | +---------------------------------------------------------------------- |
| 68 | +-- Base-generic additive principality of `olim (λ k → B ·ℕ k)` |
| 69 | +---------------------------------------------------------------------- |
| 70 | + |
| 71 | +-- A re-statement of `OmegaPow.additive-principal` over an ARBITRARY |
| 72 | +-- base `B`. The original proof at `OmegaPow.agda:361` uses only |
| 73 | +-- `·ℕ-add-≤ {B}` and the `⊕`-monotonicities — nothing specific to |
| 74 | +-- `B = ω^ n` — so it transfers verbatim with `ω^ n ↦ B`. Needed for |
| 75 | +-- the ω-marker Ω-block target `ω-rank-pow-succ ω = |
| 76 | +-- olim (λ n → ω-rank-pow ω ·ℕ n)`. |
| 77 | +additive-principal-base : ∀ {B α β} |
| 78 | + → α <′ olim (λ k → B ·ℕ k) |
| 79 | + → β <′ olim (λ k → B ·ℕ k) |
| 80 | + → α ⊕ β <′ olim (λ k → B ·ℕ k) |
| 81 | +additive-principal-base {B} {α} {β} (kα , sα) (kβ , sβ) = kβ + kα , proof |
| 82 | + where |
| 83 | + α≤′kα : α ≤′ B ·ℕ kα |
| 84 | + α≤′kα = ≤′-trans {α} {osuc α} {B ·ℕ kα} (≤′-self-osuc α) sα |
| 85 | + |
| 86 | + step1 : α ⊕ β ≤′ (B ·ℕ kα) ⊕ β |
| 87 | + step1 = ⊕-mono-≤-left {α} {B ·ℕ kα} {β} α≤′kα |
| 88 | + |
| 89 | + step2 : osuc ((B ·ℕ kα) ⊕ β) ≤′ (B ·ℕ kα) ⊕ (B ·ℕ kβ) |
| 90 | + step2 = ⊕-mono-<-right {B ·ℕ kα} {β} {B ·ℕ kβ} sβ |
| 91 | + |
| 92 | + step3 : (B ·ℕ kα) ⊕ (B ·ℕ kβ) ≤′ B ·ℕ (kβ + kα) |
| 93 | + step3 = ·ℕ-add-≤ {B} kα kβ |
| 94 | + |
| 95 | + proof : osuc (α ⊕ β) ≤′ B ·ℕ (kβ + kα) |
| 96 | + proof = |
| 97 | + ≤′-trans |
| 98 | + {osuc (α ⊕ β)} {(B ·ℕ kα) ⊕ (B ·ℕ kβ)} {B ·ℕ (kβ + kα)} |
| 99 | + (≤′-trans |
| 100 | + {osuc (α ⊕ β)} {osuc ((B ·ℕ kα) ⊕ β)} {(B ·ℕ kα) ⊕ (B ·ℕ kβ)} |
| 101 | + step1 step2) |
| 102 | + step3 |
| 103 | + |
| 104 | +---------------------------------------------------------------------- |
| 105 | +-- Additive principality of the Ω-block target `ω-rank-pow-succ μ` |
| 106 | +---------------------------------------------------------------------- |
| 107 | + |
| 108 | +-- The Ω-block analogue of `RankPow.additive-principal-ω-rank-pow`. |
| 109 | +-- fin: reuse `OmegaPow.additive-principal` at the doubled successor |
| 110 | +-- exponent; ω: instantiate `additive-principal-base` at the base |
| 111 | +-- `ω-rank-pow ω`. |
| 112 | +additive-principal-ω-rank-pow-succ : ∀ {μ α β} |
| 113 | + → α <′ ω-rank-pow-succ μ |
| 114 | + → β <′ ω-rank-pow-succ μ |
| 115 | + → α ⊕ β <′ ω-rank-pow-succ μ |
| 116 | +additive-principal-ω-rank-pow-succ {fin n} pα pβ = |
| 117 | + additive-principal {suc n} pα pβ |
| 118 | +additive-principal-ω-rank-pow-succ {ω} pα pβ = |
| 119 | + additive-principal-base {ω-rank-pow ω} pα pβ |
| 120 | + |
| 121 | +---------------------------------------------------------------------- |
| 122 | +-- The `<ᵇ-+Ω` rank2-mono primitive |
| 123 | +---------------------------------------------------------------------- |
| 124 | + |
| 125 | +-- `<ᵇ-+Ω : x <ᵇ bOmega μ → bplus x y <ᵇ bOmega μ`. The whole sum |
| 126 | +-- `rank2 x ⊕ rank2 y` lands below the Ω-block target when BOTH |
| 127 | +-- summands do — the left bound is the IH on the sub-derivation |
| 128 | +-- `x <ᵇ bOmega μ`, the right bound is the tail bound (from `y ≤ᵇ x`, |
| 129 | +-- supplied by the umbrella consumer). Stated relation-agnostically: |
| 130 | +-- both bounds are premises. |
| 131 | +rank2-mono-+Ω : ∀ {x y μ} |
| 132 | + → rank2 x <′ rank2 (bOmega μ) |
| 133 | + → rank2 y <′ rank2 (bOmega μ) |
| 134 | + → rank2 (bplus x y) <′ rank2 (bOmega μ) |
| 135 | +rank2-mono-+Ω {x} {y} {μ} px py = |
| 136 | + additive-principal-ω-rank-pow-succ {double μ} px py |
0 commit comments