Skip to content

Commit e0213ab

Browse files
hyperpolymathclaude
andcommitted
echo-types: Bennett zero-cost on an arbitrary carrier (past Bishop-finite)
Steps 1-3 of the thermodynamic-bridge continuation, stacked on PR #58. 1. EchoThermodynamicsArbitrary: FiberSubsingleton (K-free, --without-K safe surrogate for fibre isProp) + injective⇒fiber-subsingleton for an arbitrary carrier A : Set a (no Fin, no FiniteDomain). 2. reversible-erasure-cost (occupancy-keyed) + bennett-reversible- arbitrary: Bennett zero-cost for every injective map on any carrier, no finiteness. Anti-vacuity: occupancy≡FiberSize-fin and bennett-arbitrary-refines-finite certify the structural cost coincides with PR #58's established count and strictly subsumes it. 3. cno-identity over the genuine infinite absolute-zero Program carrier; bennett-reversible-cno-identity makes 'a CNO dissipates zero Landauer energy' a real theorem, not the historically vacuous claim. EchoFiberCount: added FiberSize-fin-subsingleton (Headline 2c), the finite-domain anti-vacuity hook (FiberSize-fin-injective is its corollary; kept as-is upstream for pin stability). O-THERMO-∞ unchanged and NOT discharged: re-narrowed in docs to be specifically the quantitative-collapse functional on an infinite carrier (orthogonal to the now-closed Bennett zero direction). All --safe --without-K, zero postulates, zero escape pragmas. Smoke.agda + All.agda exit 0. Docs (ECHO-CNO-BRIDGE §Thermodynamic Bridge, STABILITY_ANALYSIS §3.3 ~90%/B-, MAP.adoc status tag) updated in the same PR per the MAP governance rule. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent a89f999 commit e0213ab

7 files changed

Lines changed: 370 additions & 25 deletions

File tree

docs/ECHO-CNO-BRIDGE.adoc

Lines changed: 66 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ Absolute Zero defines CNOs with four properties:
140140
| `FinalState(p, σ) = σ` | `Echo p σ` contains `(σ, refl)` |
141141
| `NoSideEffects(p)` | `Echo p σ` is singleton (only `σ` maps to `σ`) |
142142
| `ThermodynamicallyReversible(p)` | `Echo p σ ≃ Echo id σ` |
143-
| `ThermodynamicOptimality(p)` | `fiber-erasure-bound p σ _≟_ T ≡ 0` _(proved for every injective `p` on any Bishop-finite carrier — Theorem 4; infinite-carrier case = falsifiable obligation O-THERMO-∞)_ |
143+
| `ThermodynamicOptimality(p)` | `reversible-erasure-cost p σ d T ≡ 0` _(proved for every injective `p` on **any** carrier — Bishop-finite via `fiber-erasure-bound`, arbitrary/infinite incl. the `Program` CNO via `reversible-erasure-cost` — Theorem 4; the quantitative-collapse functional on an infinite carrier is the falsifiable obligation O-THERMO-∞)_ |
144144
| `InformationPreservation(p)` | _no formalised analogue — `echo-information-loss` was never defined; see Theorem 5_ |
145145
| `UniversalCNO(p)` | `∀ σ → Echo p σ ≃ Echo id σ` (NEW) |
146146
| `ModelIndependence(p)` | `Echo f y ≃ Echo f' y'` across isomorphic models (NEW) |
@@ -290,11 +290,64 @@ landauer-collapse-finite :
290290
fiber-erasure-bound-fin fd f y _≟_ T ≡ k * T * ⌊log₂ card fd ⌋
291291
```
292292

293+
**Proved — Bennett zero-cost on an _arbitrary_ carrier, past
294+
Bishop-finite (`EchoThermodynamicsArbitrary`).** The finiteness in the
295+
two results above is an artefact of routing cost through
296+
`FiberSize-fin` (an enumeration); the *physical content* of Bennett —
297+
a reversible map has no fan-in — needs no finiteness at all. An
298+
injective `f : A → B` has a subsingleton fiber for *any* `A : Set a`.
299+
Keying the Bennett cost on a decidable-inhabitation occupancy instead
300+
of an enumeration discharges this with no finiteness hypothesis,
301+
`--safe --without-K`, zero postulates:
302+
303+
```agda
304+
FiberSubsingleton f y = (p q : Echo f y) → proj₁ p ≡ proj₁ q -- K-free
305+
306+
injective⇒fiber-subsingleton : -- any A
307+
(inj : ∀ {x x′} → f x ≡ f x′ → x ≡ x′) → FiberSubsingleton f y
308+
309+
bennett-reversible-arbitrary : -- A : Set a arbitrary; no Fin, no ≃
310+
(inj : ∀ {x x′ : A} → f x ≡ f x′ → x ≡ x′)
311+
(d : Dec (Echo f y)) (T : Temperature) →
312+
reversible-erasure-cost f y d T ≡ 0
313+
```
314+
315+
This is **not** a vacuous re-definition: `occupancy≡FiberSize-fin`
316+
proves the occupancy *coincides with* the established honest count
317+
`FiberSize-fin` on every finite restriction under the subsingleton
318+
hypothesis, and `bennett-arbitrary-refines-finite` shows it strictly
319+
subsumes the `Fin n` result of PR&nbsp;#58. The `--without-K` reason
320+
for the first-projection form (not full fiber `isProp`) is recorded in
321+
the module header: full `isProp` needs `B` an h-set / UIP, unavailable
322+
under `--without-K`; the projection form is K-free provable from
323+
injectivity and is exactly what the count needs.
324+
325+
**The real CNO theorem, on the infinite carrier.** `cno-identity :
326+
Program → Program` (the absolute-zero `Program = List Instruction`
327+
carrier — *infinite*, the very `ProgramState`-flavoured type the
328+
original companion remarks disclaimed) is injective, so
329+
`bennett-reversible-cno-identity` gives erasure cost `≡ 0` at every
330+
fiber and temperature. "A CNO dissipates zero Landauer energy" is now
331+
a *real* theorem for the identity/injective CNO over the genuine
332+
infinite carrier — no longer the vacuous claim the deleted
333+
`ECHO-CNO-BRIDGE-SUMMARY.md` made.
334+
293335
### Open obligation O-THERMO-∞ (precise, falsifiable — not softened)
294336

337+
NOTE: O-THERMO-∞ is **unchanged and not discharged** by the
338+
arbitrary-carrier result above. The Bennett *zero-cost* direction no
339+
longer needs finiteness; O-THERMO-∞ is now sharpened to be
340+
specifically about the *quantitative* `fiber-erasure-bound` /
341+
`landauer-collapse` functional — the **count/collapse** direction —
342+
on an infinite carrier. That is a strictly different functional from
343+
the occupancy-keyed Bennett cost (occupancy is capped at 1; the
344+
collapse cost grows as `⌊log₂ N⌋` with the fiber count). Nothing below
345+
is softened to "future work".
346+
295347
The infinite carrier (`ProgramState = ℕ → ℕ`, or any `A` with no
296-
`A ≃ Fin n`) does **not** generalise, and the reason is now stated
297-
sharply enough to be refuted:
348+
`A ≃ Fin n`), for the **quantitative collapse functional**, does
349+
**not** generalise, and the reason is now stated sharply enough to be
350+
refuted:
298351

299352
> **O-THERMO-∞.** There is no function
300353
> `cost : (ℕ → B) → (y : B) → DecidableEquality B → Temperature → Energy`
@@ -332,11 +385,16 @@ sharply enough to be refuted:
332385
and `fiber-erasure-bound`; now at the full Bishop-finite-carrier
333386
level, not merely `Fin n`.
334387
2. **Thermodynamic Reversibility (shape)**: proved for *every*
335-
injective map (`bennett-reversible-injective`) and lifted to any
336-
Bishop-finite carrier (`bennett-reversible-finite`).
337-
`bennett-reversible-id-zero` is now a corollary. The infinite
338-
`ProgramState` case is the single, falsifiable obligation
339-
O-THERMO-∞ above — `[OPEN]`, with a stated kill condition.
388+
injective map (`bennett-reversible-injective`), lifted to any
389+
Bishop-finite carrier (`bennett-reversible-finite`), and now to an
390+
*arbitrary* carrier with no finiteness at all
391+
(`bennett-reversible-arbitrary`), including the genuine infinite
392+
`Program` CNO (`bennett-reversible-cno-identity`).
393+
`bennett-reversible-id-zero` is a corollary. The remaining
394+
falsifiable obligation O-THERMO-∞ above is now specifically the
395+
*quantitative collapse* functional on an infinite carrier —
396+
`[OPEN]`, with a stated kill condition; the Bennett zero direction
397+
is closed for all carriers.
340398
3. **Information Theory**: not bridged. Open work — see
341399
`docs/echo-types/roadmap.md`.
342400

docs/STABILITY_ANALYSIS.md

Lines changed: 21 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -79,24 +79,35 @@ Echo {A = A} f y = Σ A (λ x → f x ≡ y)
7979
**Stability:** New but well-grounded in existing echo type theory
8080

8181
#### 3.3 Thermodynamic Models: B- (was C+; advanced 2026-05-18)
82-
**Proofs:** `EchoThermodynamics.agda`, `EchoFiberCount.agda`, `EchoThermodynamicsFinite.agda`
82+
**Proofs:** `EchoThermodynamics.agda`, `EchoFiberCount.agda`, `EchoThermodynamicsFinite.agda`, `EchoThermodynamicsArbitrary.agda`
8383
- Landauer bound *shape* `k·T·⌊log₂ N⌋` (honest fiber count, no hardcode)
8484
- Bennett zero-cost for **every injective map** (`bennett-reversible-injective`),
8585
not just `id` at index zero — `bennett-reversible-id-zero` is now a corollary
8686
- Lifted off `Fin n` to **any Bishop-finite carrier** by transport along an
8787
explicit bijection (`FiniteDomain`, `bennett-reversible-finite`,
8888
`landauer-collapse-finite`) — `--safe --without-K`, zero postulates
89+
- Bennett zero-cost lifted further to an **arbitrary carrier — no finiteness
90+
at all** (`bennett-reversible-arbitrary`, occupancy-keyed; K-free
91+
subsingleton route), certified faithful vs. the established count
92+
(`occupancy≡FiberSize-fin`, `bennett-arbitrary-refines-finite`), and
93+
instantiated on the genuine **infinite** absolute-zero `Program` CNO
94+
(`bennett-reversible-cno-identity`) — the historically vacuous
95+
"CNO dissipates zero energy" is now a real theorem
8996
- Landauer worst-case collapse (`landauer-collapse[-finite]`)
9097

9198
**Stability:** The C+ ~70% rating was driven by one concrete gap — the only
92-
proved zero-cost instance was the identity at index zero. That gap is closed:
93-
optimality now holds for every injective map on every Bishop-finite carrier.
94-
The *single* remaining open item is the infinite-carrier case
95-
(`ProgramState = ℕ → ℕ`), now pinned as the **precise, falsifiable obligation
96-
O-THERMO-∞** with a stated kill condition (see
97-
`docs/ECHO-CNO-BRIDGE.adoc` §"Thermodynamic Bridge"). Not "needs more
98-
development" — one named obligation, refutable by exhibiting a total
99-
`--safe` cost functional or by mechanising its impossibility.
99+
proved zero-cost instance was the identity at index zero. That gap is fully
100+
closed: the Bennett zero-cost direction now holds for every injective map on
101+
**every carrier** — Bishop-finite *and* arbitrary/infinite, including the
102+
genuine infinite `Program` CNO. The *single* remaining open item is narrower
103+
than before: it is now specifically the **quantitative collapse functional**
104+
(`fiber-erasure-bound` / `landauer-collapse`) on an infinite carrier — pinned
105+
as the **precise, falsifiable obligation O-THERMO-∞** with a stated kill
106+
condition (see `docs/ECHO-CNO-BRIDGE.adoc` §"Thermodynamic Bridge"). Not
107+
"needs more development" — one named obligation, refutable by exhibiting a
108+
total `--safe` cost functional or by mechanising its impossibility. Grade
109+
held at **B-** per the standing rule (no re-rate above B- until O-THERMO-∞ is
110+
discharged or refuted), though scope of the residual has materially shrunk.
100111

101112
### 4. Proof Ecosystem Stability: B+
102113

@@ -111,7 +122,7 @@ development" — one named obligation, refutable by exhibiting a total
111122
| Relational | 80% | B |
112123
| CNO Integration | 98% | A- |
113124
| JanusKey Bridge | 90% | B+ |
114-
| Thermodynamics | 85% | B- |
125+
| Thermodynamics | 90% | B- |
115126

116127
**Proof Quality Indicators:**
117128
- ✅ All core theorems have constructive proofs

docs/echo-types/MAP.adoc

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -55,16 +55,23 @@ remainder of information-losing computation: for `f : A → B`,
5555
=== Thermodynamic — Landauer/Bennett energy bounds `[REAL*]`
5656
Landauer/Bennett bound *shape*; `ThermodynamicallyReversible(p)
5757
≙ Echo p σ ≃ Echo id σ`. Zero-cost (Bennett) proved for *every
58-
injective map* on *any Bishop-finite carrier* (transport along an
59-
explicit bijection); the identity-at-zero instance is now a corollary.
60-
Sole residual is the infinite-carrier case, pinned as the falsifiable
61-
obligation **O-THERMO-∞** (kill condition stated). Re-rated B- / ~85%
62-
in STABILITY_ANALYSIS §3.3 (was C+ / ~70%, 2026-05-18). Stays `[REAL*]`
63-
— real, still partial — until O-THERMO-∞ is discharged or refuted.
58+
injective map* on *any Bishop-finite carrier*, and now lifted to an
59+
*arbitrary carrier with no finiteness at all* (K-free subsingleton /
60+
occupancy route), certified faithful against the established count and
61+
instantiated on the genuine *infinite* absolute-zero `Program` CNO —
62+
so "a CNO dissipates zero Landauer energy" is now a real theorem, not
63+
the historically vacuous claim. The residual is narrower: only the
64+
*quantitative collapse* functional on an infinite carrier, pinned as
65+
the falsifiable obligation **O-THERMO-∞** (kill condition stated,
66+
unchanged, *not* discharged by the arbitrary-carrier Bennett result).
67+
Re-rated B- / ~90% in STABILITY_ANALYSIS §3.3 (was C+ / ~70%,
68+
2026-05-18). Stays `[REAL*]` — real, still partial — grade held at B-
69+
per the standing rule until O-THERMO-∞ is discharged or refuted.
6470

6571
* Proofs: `proofs/agda/EchoThermodynamics.agda`,
6672
`proofs/agda/EchoFiberCount.agda`,
67-
`proofs/agda/EchoThermodynamicsFinite.agda`.
73+
`proofs/agda/EchoThermodynamicsFinite.agda`,
74+
`proofs/agda/EchoThermodynamicsArbitrary.agda`.
6875
* Docs: `docs/ECHO-CNO-BRIDGE.adoc` §"Thermodynamic Bridge",
6976
`docs/STABILITY_ANALYSIS.md` §3.3, `docs/WORK_PLAN.md` §5,
7077
`docs/adjacency/hott-fibers.adoc`.

proofs/agda/All.agda

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ open import Dyadic
2929
open import DyadicEchoBridge
3030
open import EchoThermodynamics
3131
open import EchoThermodynamicsFinite
32+
open import EchoThermodynamicsArbitrary
3233
open import EchoStabilityTests
3334
open import VecRotation
3435

proofs/agda/EchoFiberCount.agda

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,42 @@ FiberSize-fin-injective {n = ℕ.suc m} f y _≟_ inj (suc i′) hit
174174
... | no _ = FiberSize-fin-injective (f ∘ suc) y _≟_
175175
(λ eq Fin-suc-inj (inj eq)) i′ hit
176176

177+
----------------------------------------------------------------------
178+
-- Headline 2c — FiberSize-fin-subsingleton
179+
--
180+
-- The fiber-local hypothesis behind the arbitrary-carrier Bennett
181+
-- result. If the fiber over `y` is a *subsingleton* — any two hitting
182+
-- indices coincide — and *some* index `i₀` hits, then the count is
183+
-- exactly 1. This is strictly weaker as a hypothesis than global
184+
-- injectivity: it only constrains the indices over `y`. Indeed
185+
-- `FiberSize-fin-injective` is the corollary obtained by feeding
186+
-- `ss i j fi fj = inj (trans fi (sym fj))` (kept as-is upstream for
187+
-- pin stability; this lemma is the honest generalisation).
188+
--
189+
-- The proof walks the `FiberSize-fin` recursion in lock-step with the
190+
-- witness exactly as the injective version does, but discharges the
191+
-- "no other hit" obligation from subsingleton-ness rather than from
192+
-- injectivity.
193+
----------------------------------------------------------------------
194+
195+
FiberSize-fin-subsingleton :
196+
{b} {B : Set b} {n : ℕ}
197+
(f : Fin n B) (y : B) (_≟_ : (y₁ y₂ : B) Dec (y₁ ≡ y₂))
198+
(ss : (i j : Fin n) f i ≡ y f j ≡ y i ≡ j)
199+
(i₀ : Fin n) f i₀ ≡ y
200+
FiberSize-fin f y _≟_ ≡ ℕ.suc ℕ.zero
201+
FiberSize-fin-subsingleton {n = ℕ.suc m} f y _≟_ ss zero hit
202+
with f zero ≟ y
203+
... | yes _ = cong ℕ.suc
204+
(FiberSize-fin-no-hit (f ∘ suc) y _≟_
205+
(λ j fsj≡y suc≢zero-Fin j (ss (suc j) zero fsj≡y hit)))
206+
... | no ¬p = ⊥-elim (¬p hit)
207+
FiberSize-fin-subsingleton {n = ℕ.suc m} f y _≟_ ss (suc i′) hit
208+
with f zero ≟ y
209+
... | yes p = ⊥-elim (suc≢zero-Fin i′ (sym (ss zero (suc i′) p hit)))
210+
... | no _ = FiberSize-fin-subsingleton (f ∘ suc) y _≟_
211+
(λ i j fi fj Fin-suc-inj (ss (suc i) (suc j) fi fj)) i′ hit
212+
177213
----------------------------------------------------------------------
178214
-- Headline 3 — FiberSize-fin ≡ 0 ⟺ ¬ Echo (split into two halves).
179215
--

0 commit comments

Comments
 (0)