diff --git a/research/p104-follow-up-findings/NOTICE b/research/p104-follow-up-findings/NOTICE new file mode 100644 index 0000000000..75798f5520 --- /dev/null +++ b/research/p104-follow-up-findings/NOTICE @@ -0,0 +1,21 @@ +Apache-2.0. DreamingOfClouds with Claude Opus 5.5 (Anthropic), via Claude Code. The outside-session lanes TOY4 S2 +(Pin / Down-set No-Loss / Charge Corollary), CALLEROPEN, JUNKROLE and DECLIFT9 are DreamingOfClouds'; WEBS +(the Cut Lemma, shipped in #7606) is also his. + +data/base-7605-word.json.gz is aliromman's #7605 word (the same bytes vendored by our #7608, sha256 pinned in +clearform.py), used as data only; credit aliromman, and FanPUYen (#7604), SYLforge (#7603) and ToikY (#7546) for its +lineage. data/edits-7608.json is our #7608 edit list. data/invoice-7546.json, invoice-7605.json and invoice-7608.json +are the recursive invoices (#7113 caller x native) of those words, as shipped in #7606 / #7608. + +clearform.py reads research/p104-6372-clear-form-gap/inputs/candidate-WORD.json.gz (unpaidmoon's package, pinned in +SOURCES.json) as data only. sepgate.py reads research/shared-wire-split-composition/FULL-RESULT.json (the #7000 +selected record, CubeJerry) as data only. No code from either package is run. + +data/lines120.json (Gram and F2^9 labels of the 120 E8 lines, the first 104 being the P104 ports) is our derived data, +checked against research/complex-frame-pair-decoders/inputs/pr717/P104_HIT_flip_3a.txt in #7583/#7606; credit the +PR968 authors. + +Credit Rohan Arun for the #7113 signed caller, CubeJerry for the #6805 native (W6805) used by our caller and toy lanes, +and Clear1nsight, ToikY and the other contributors of the P104 price and replay lineage for the conventions. + +All checkers in this package are our own code; no code is imported from the repository or any other package. diff --git a/research/p104-follow-up-findings/PROOF.md b/research/p104-follow-up-findings/PROOF.md new file mode 100644 index 0000000000..a3f016465b --- /dev/null +++ b/research/p104-follow-up-findings/PROOF.md @@ -0,0 +1,444 @@ +# Proofs for the P104 follow-up package + +Each section gives the statement, its hypotheses and the proof. Numbering follows the README. Notation follows #7606 +(`research/p104-odd-unit-per-grading`): frames are subspaces of F₂^h with the standard dot, q_t is port t's label, +X_t is born on the line ⟨q_t⟩ and ends at V, Y_t ends at the hyperplane q_t^⊥, public MOVEs ascend, owned MOVEs pay +|Δdim|. G_s = {frames containing q_s}. The web-general **Cut Lemma** (WEBS, shipped in #7606 §I.3) is used throughout: +for an up-set G, rank(O mod Π) ≥ def(G) = dim(F + Π) − dim F, where Π is the public vectors entering G, O the owned +contents crossing into G and F the finals in G. Its births form: #owned moves entering G ≥ #{j : ⟨q_j⟩ ∈ G, q_j^⊥ ∉ G}. + +--- + +## 1. Owned CLEAR content (CLEARFORM) + +**1.1 Rank lemma ⇒ every CLEAR of an endpoint-exact word is lossless.** Work in the scalar projection: rows are linear +functionals of the n public input tokens, owned INIT is the zero row, and ADD/COPY/SCALE act literally (MOVE relabels +the chart). By `research/p104-shared-native-helper-splits/retained/compiler/PROOF.md:87-90`, conjugating each stream +by its chart makes this the exact endpoint on arbitrary full arrays, so it suffices to argue on rows. Let ρ_t be the +rank of the live rows after event t. + +- ADD r += c·s (s ≠ r live), SCALE by c ≠ 0 and MOVE are invertible maps of the live tuple, so ρ is unchanged. COPY into + a zero owned row and INIT add a vector already in the span (or 0), so ρ is unchanged. +- CLEAR of v lowers ρ by 1 iff v ∉ span(other live rows), and by 0 otherwise. +- ρ_0 = n and ρ never increases. If the final public rows are invertible (the endpoint), ρ_end = n, so ρ_t = n for every + t and no CLEAR lowers the rank: every erased row lies in the span of the other live rows at that moment. ∎ + +So "lossless" is implied by endpoint exactness, which every admitted word proves anyway. + +**1.2 Content theorem.** Let W, W′ be legal, endpoint-exact words with the same header and the same owned +INIT/MOVE/CLEAR events (fields, charts, chronology, lifetimes, peak). Then W′ satisfies `owned_erasure` iff W does, and +every cost term gets the same erasure contribution, whatever rows the two words erase. + +*Proof.* The retained contract behind `owned_erasure` (certificates/selected-result.json:95-97) consists of these clauses: + +- E1: FINITE-PRECOMPILATION.md:34-35, explicit initialisation and erasure. +- E2: FINITE-PRECOMPILATION.md:250-256, one bank per live unit, with erasure in the fixed scalar cost. +- E3: FINITE-PRECOMPILATION.md:264-268, "field-identity and chronological requirements"; a clear acts only after the + child unit completes. +- E4: notes/copied-centers-lemma.tex:29-35, erasure is linear in the stream volume. +- E5: research/kappa-rebuild/transfer-audit/h-branch/H-PRIMITIVE-AUDIT.md:51-62, "the discarded value is generally + nonzero" and no reversible uncompute is required. +- E6: retained/compiler/PROOF.md:97-99 and 333-337, dirty residuals count only through earlier ADD reads. + +Taking the clauses in turn: + +- E1–E3 depend only on the INIT/CLEAR/MOVE events and unit tags, which are identical in the two words. +- E2 and E4 price erasure by volume, which the chart and field fix. E5 excludes a content-dependent uncompute bill. +- Correctness is the endpoint, and by 1.1 both words are lossless at every CLEAR. +- The κ invoice is a function of paid MOVE ranks and productive targets and has no CLEAR term. The strictification gate + (§2) takes only the invoice. +- Precision (E6) depends on values held and read before the erase, not on the erased value. + +No clause names, limits or prices the erased value. ∎ + +Scope: + +- Owned fields only. Zeroing a public register without a live owned holder is a genuine loss (Rank lemma part 1, #7606). +- The theorem fails in a reversible-uncompute model, which E5 says the retained model is not. + +**1.3 The #7608 case** [C `clearform.py`]. + +- CLEAR #44 (owned 1557, chart 595) erases {451: −1, 1495: 1}. This is an exact Q-combination of 21 live rows (other + live rank 1501 = n_pub). +- #7605's row at the same CLEAR is the same combination plus −3/2·(x902 + x985). +- All other 73 CLEARs erase identical rows in the two words. + +With the identical owned events (DUALAUDIT, in #7608), 1.2 applies. + +--- + +## 2. Separation hypothesis (SEPAUDIT) + +FINITE-PRECOMPILATION.md:51-52 and :205-207 require r_max < k_min for the unit fed to the compiler. The admitted +strictification step (docs/research/pr-intake-evidence/pr4416/PROOF-REVIEW.md:139-185; theorem in +research/higher-moment-strictification README §2) takes a product power v, completes every target to ≥ b^v and splits +paid jobs into blocks ≤ c^v < b^v. The paid moment stays below 1 iff α, γ, δ < 1, and the selected #7000 record states +its raw invoice fails separation and strictifies with c = 11, b = 12, u = 1/7, v = 1920 +(retained/compiler/PROOF.md:195-198; interval_gate.py:52-83). So the hypothesis applies to the strictified unit, not +the raw invoice. The gate values for #7546, #7605 and #7608 are re-run in `sepgate.py`. + +--- + +## 3. t = −1 toys and hubs + +Model (WEBS toy): F₂^m, U-only targets X_t = x_t − y_t at V and Y_t = y_t at q_t^⊥. Helpers are arbitrary (any number, +any web), and owned rows are token-free. φ_d(u) := coef_{x_d}(u) + coef_{y_d}(u). A port s is **tight** if exactly +one owned move enters G_s. + +**3.1 Pin Lemma** (TOY4 S2, an outside-session lane of DreamingOfClouds'). If s is tight, every content held at a frame of G_s +lies in Π_s = F_s ⊕ ⟨x_s⟩. In particular φ_d = 0 there for every non-partner d of s. + +*Proof.* By the Cut Lemma, Σ_{G_s} ⊆ span(Π) + ⟨o⟩ with |Π| = dim F_s. Σ contains F_s + ⟨x_s⟩, of dimension +|F_s| + 1, because Y_s ends outside G_s. So equality holds. F_s holds x_d − y_d, and it holds y_d only if d is a +partner. ∎ + +**3.2 Time-cut basis.** Let D be a down-set with no owned move leaving it. Then (finals in D) ∪ (public vectors +crossing out of D) is a basis of B_D = span(tokens born in D). + +*Proof.* Contents of D-frames lie in B_D, because owned rows ascend. Project every final to B_D. The finals outside D +land in the span of the crossings (Cut Lemma with no owned crossing). All finals span T. For the count, every public +register born in D either ends in D or leaves it exactly once. ∎ + +**3.3 Down-set No-Loss (DNL).** Fix a frame g and let D be the closure of down(g) under owned departures. Suppose no +owned move arrives at g and no frame of D lies strictly above g. Then the public outputs of g (departures and finals) +form a basis of W_g. + +*Proof.* Apply 3.2 to D and to D′ = D − {g}, which is still closed. Then B_D = span(Rest + finals_{D′}) ⊕ W_g, and +|out_g| = dim W_g. ∎ + +DNL holds in real time and in the frame-memory relaxation, for any helper web. Its hypotheses are necessary: on 12,000 +random frame-memory programs that violate them, the finals still span 1,448 times [C-lane `dnl_test.py`]. + +**3.4 Charge Corollary.** Let d be a port with a tight non-partner, and let U_d be the union of G_s over tight +non-partners s. Then some frame g ∋ q_d with g ∉ U_d fails DNL. + +*Proof.* + +1. x_d ∈ W_{⟨q_d⟩}. At a frame satisfying DNL the outputs span W, so some output has φ_d ≠ 0. +2. That output is not a final: only Y_d's final has φ_d ≠ 0, and q_d^⊥ ∌ q_d. So it departs to a frame g′ ∋ q_d. +3. g′ lies outside U_d by 3.1. +4. Repeat from g′. V is pinned, so the chain stops at a frame that fails DNL. ∎ + +**3.5 The F₂³ decision.** Labels 1, 2, 4, 7, climb 3. In all 13 cut-feasible sets, ports 1, 2 and 4 are tight, so +U_7 = every frame strictly above ⟨7⟩. The frame ⟨7⟩ satisfies DNL in every set. By 3.4 no exact program exists, for +any helpers [C `toy4.py`]. + +An independent proof is TOY4 S1 (3.6–3.8) with the hand argument of TOY4 §2. Owned descents change nothing: a mass-3 +set containing a descent has ascent climb ≤ 2, which the Cut Lemma already kills. + +**3.6 Forwarding Lemma** (TOY4 S1). Let s₁ = #owned moves leaving {0}. For any set of label lines, +Σ_L [dim W_L − dim(Out(L) + F_L)] ≤ s₁. + +*Proof.* Let D = {0} ∪ lines. Public crossings out of D, births in its complement and finals in D number exactly dim T, +and every final lies in their span plus F_D. A register at L either ends there or leaves. ∎ + +**3.7 Union Lemma.** Let t's line forward, and let G_1..G_k be up-sets covering the frames above L_t that avoid L_t and +hyp_t. Then Σ_i sl(G_i) ≥ 1, where sl = o − def. + +*Proof.* The Cut Lemma gives τ(Σ_G) ⊆ legit(G) + (a space of dim ≤ sl(G)), with τ the quotient by +span{x_j − y_j} + H. Forwarding puts y_t = τ(x_t) in Σ τ(Σ_{G_i}) + τ(F_{L_t}), whose legit parts avoid y_t. ∎ + +**3.8 Duality Lemma.** O is feasible iff O^⊥ = {(b^⊥, a^⊥)} is feasible, with the same labels and climb. + +*Proof.* A frame-memory design is an acyclic linear network code. Transpose every local map, reverse the edges and +relabel f ↦ f^⊥ (inclusion reverses, so ascents stay ascents). The old X_t becomes a Y-type register and the old Y_t an +X-type register. Helpers stay helpers and owned edges stay token-free. ∎ + +The same map on whole words is the frame-perp transpose shipped in #7607 (`dualword.py`). + +**3.9 Pocket Lemma** (TOY5). Any helpers, born and ending anywhere; owned descents are allowed. ψ_t := coef(x_t) + +coef(y_t). A frame f is t-pinned if some tight up-set G′ ∋ f avoids L_t and hyp_t. Take an up-set G, a set of ports T +and N = Up(L_T) \ G. Let R ⊆ T be the ports with L_t ∈ N, hyp_t ∉ N and every frame of G above N t-pinned. Then +o(G) + #(owned moves entering N from outside) ≥ |R|. + +*Proof.* + +1. N's contents lie in span(births, public arrivals, owned arrivals). +2. N's public outputs (exits into G, finals in N) are killed by Ψ = span{ψ_t : t ∈ R}. Exits land at pinned frames, + where a tight G′ gives Σ_{G′} ⊆ span{x_j − y_j, y_j (j ∈ J)} + H with t ∉ J. The finals are x_j − y_j, h, or y_j with + j ∉ R. Ψ has rank |R| on the births x_t. +3. So the outputs have rank ≤ #inputs + owned_in − |R|. +4. F_D ∪ P_G ∪ B_G has dim T elements, spans T together with O_G, and contains every output of N, so its deficiency + is ≤ o(G). ∎ + +**3.10 Hub construction** (HUBCLASS). Pick A with A_tt = 1 and A_ts = 0 on non-partners, of rank k, and factor +A = ΛE. The k hubs gather Ey at {0} from the Y mains and move {0} → V. Each partner cell (t, s) gets one helper: + +1. at {0}: H += A_ts·Y_s; +2. at ⟨q_t⟩: X_t += H; +3. at q_s^⊥ (which contains q_t): H −= A_ts·Y_s; +4. at V: X_t −= H. + +At V, X_t −= Λ_t·hubs. Then X_t = x_t − y_t, Y_t = y_t and H = h, exactly. On P104, A = G/2 has rank 8 = α, so 8 hubs +(M = 72) realise the cut floor [C-lane exact replay, 41,265 events; the fit facts are re-run in `labels.py`]. + +**3.11 V-funnel lemma.** Suppose the only owned moves are k hubs {0} → V. + +- W_V's finals lie in span{x − y} + H, so dim τ(W_V) ≤ k. +- The arrivals' x-parts have rank n, and hubs carry no x. +- So the y-content riding public registers into V has rank ≥ n − k = 96 on P104. + +A public y → X layer of rank ≥ 96 is therefore forced. ∎ + +Clone interaction: sharing works only for additive y → X delivery. A killed departure content (the park) has no side +information, so the Rank/Clone lemma needs owned rank ≥ 96 there. + +**3.12 F₂⁴ hubs.** Hub total climb is ≥ n for every F₂⁴ label set. + +*Proof.* k ≥ α by the cut lemma, and α = 1 forces an orthonormal set (n ≤ 4), while n ≤ 8 always. ∎ + +**3.13 Piggyback lemma** (TOY5 §3). An unfed port d cannot piggyback on non-partners' private ascents +⟨q_s + q_d⟩ → ⟨q_s, q_d⟩. + +*Proof.* q_s + q_d is even, so it is never a label. No feeder enters G = ∪_s Up(q_s) ∪ Up(q_s + q_d), and each tight +G_s d-pins every landing. ∎ + +This assumes no owned move lands in Up(q_d) \ G. + +--- + +## 4. Callers + +Setting (CALLEROPEN, an outside-session lane of DreamingOfClouds', and SINGLEHUB): ρ = 2, K = WZᵀ, units T = I − 2xyᵀ, +product −I, HOST stages with t ≠ −1. Lemma S: G_ij = ±(WZᵀ)_ij. + +**4.1 Crossing Lemma.** Let k, k+1 be consecutive stages, S = Z_k ∩ Z_{k+1} ⊇ X_k, and let j be a witness stage with +(Z_k ∪ Z_{k+1}) ∩ Z_j ⊆ S. Then rank(Y_k, Y_{k+1} | S) = 4. Dually for X. + +*Proof.* + +1. Suppose cᵀY_{k+1} = aᵀY_k on S. +2. Pair with X_j. Both pairings live on S, and K[k, j], K[k+1, j] carry the same sign, so cᵀW_{k+1} = aᵀW_k. +3. Pair with X_k: aᵀ(K_kk − G_kk) = 0, and K_kk − G_kk = [[1, −2g], [0, 1]], so a = 0. +4. W_{k+1} is invertible (t ≠ −1), so c = 0. ∎ + +**4.2 Floor Lemma.** Let calls 0..k+1 precede a call r. Assume **nesting** (the X of calls 0..k lie in Z_k) and that +Z_r meets Z_j (j ≤ k+1) only inside H ⊆ Z_k. Then |Z_k| ≥ 2(k+1) + 2. + +*Proof.* The pairing matrix of {Y_j | Z_k} against {X_0..X_k, X_r | H} is [G[A+b, A] | G[A+b, r]] with b = k+1. + +1. Suppose (α, β) is a null vector. +2. Row b gives Z_Aᵀα = Z_rᵀβ. +3. Rows A give (K_AA − G_AA)α = 0, and K_AA − G_AA = I − 2U is unitriangular, so α = 0 and then β = 0. +4. Hence the 2(k+1) + 2 columns are independent in R^{Z_k}. ∎ + +**4.3 B in the nested two-arm family.** + +- The masks are bounded below by 4.2 and the caps follow from 4.1. +- Given the masks and caps, ending the youngest lines first majorises every feasible schedule (exchange argument, at + sketch level) and maximises Σ f(8l). That schedule is B's. + +Scope: two arms meeting only in the hubs, nested masks, ρ = 2, HOST t ≠ −1, PRICEKIT line model. + +**4.4 Shared D is illegal; SL without independence.** + +- Legality: rootcheck rejects a repeated stage variable, and the free ops are q-only. +- CALLEROUT's backward induction never uses one z per call, so SL holds per call with Z_k = roles whose target contains + that D. +- In a one-hub two-arm layout every cross pair must share its D. K_{8,9} is connected, so all calls share one D, every + role then has degree ≤ 1, and there is no hub. ∎ + +**4.5 Multi-centre ⇒ ρ ≥ 2c.** + +- Each piece has rank K_i = 2, so N_i ≥ |P_i| + 2 + rank(I − M_i^H). +- The hub blocks satisfy ∏ M_i^H = −I, so Σ rank(I − M_i^H) ≥ 2. ∎ + +**4.6 Junk role = dilated root** (JUNKROLE, an outside-session lane of DreamingOfClouds'). Put a = P[J, C], b = P[C, J] and +m = P[J, J]. Since det P = 1 and n_C is odd, m = −1 − a·b, and + + P = −(I − e_J ãᵀ)(I − b̃ e_Jᵀ), + +with ã, b̃ zero at J (expand the product). So a junk caller is a root on C + J with a virtual odd unit reading only J +before time 0 and one writing only J after the end. Mode (a) is ρ = 3 and mode (b) is ρ = 2. + +Mode (a): from K + y_J x_Jᵀ = WZᵀ, a stage that does not use J has W, Z of rank 2. So in every cross pair one stage uses +J, and the J-stages form a vertex cover of K_{8,9}: a whole arm. ∎ + +**4.7 Crossing Lemma for ρ ≥ 3** (RHO3CROSS). With witnesses j, u = cᵀW_{k+1} − aᵀW_k is orthogonal to the row space +of each Z_j. So the relation dimension is ≤ ρ − rank(Σ Z_j^witness), and the rest of 4.1 is unchanged. + +- At ρ = 3, two boundaries with δ ≥ 1 have witness sets covering all calls, each of Z-rank ≤ 2 and sharing a call, so + their total Z-rank is 2 < ρ. Hence δ = 1 only at the two outer boundaries. +- The Floor Lemma becomes |Z_k| ≥ 2(k+1) + 4 − ρ (null dimension ≤ ρ − 2). ∎ + +**4.8 β = 4g + 2** (BETA). Per port, D0 = Σ_T f(8d+1) − Σ_P f(8l). An arm field of degree j (two per j) cancels its idle +line P[8j] up to ln(8j) + 1, leaving 2 ln k from the interior. What stays uncancelled: + +- 2 hubs (degree k, rank 8k+1): 2g; +- 4 arm-top roles (degree k/2): 2g; +- the interior: 2. + +So β = 4g + 2 = 34. The per-stage lift 8 = h − 1 is the F₂⁸ frame dimension of each stage variable (rank 8·deg + 1). + +- Hub degree k is forced by 4.1, 4.2 and Theorem 1′. +- Arm-top degree k/2 is forced only under nesting (the hypothesis of 4.2). ∎ + +Also: c copies of C(k/c) give exactly κ(k/c), so multi-centre layouts move along the same curve. + +**4.9 Nesting, partial** (NESTPROOF). + +- L1 (from Lemma S alone): if v = X_E β is orthogonal to both y's of one later stage, then γ = Σβ_i z_i = 0 and v is + orthogonal to every later y. +- L2: prefix commutation splits V_k = C(P_k − I) along Z_k | N_k. +- L3: the outside part B_k lies in span(e_0..e_{k−2}), so b_k ≤ 2k − 2. P_k acts on R^{N_k} as the reflection + I − 2Π_B, and b_1 = 0. +- L4: restricting the Floor pairing matrix to Z_k loses rank ≤ b_k, so |Z_k| ≥ 2(k+1) + 2 − b_k (under hypothesis H, + that the early y are independent). + +Nesting ⇔ b_k = 0 for all k. ∎ + +**4.10 DYINGEXACT** (L = 4, left arm 3 stages, right arm 1 stage on {0, 1, 8, 9}, hubs {0, 1}, role 3 ∈ Z_1 \ Z_2). +This layout is infeasible for every t ≠ −1. + +*Proof.* The thin product gives rank(I + g) ≤ 4 with g = S_2 P_4 R. Stage commutation gives P_4 e_3 = c·e_3. + +- Lemma D: if c ≠ 1, then v ∈ span(e_4, e_5) exists with P_4 v = R v = v. +- Fx = fix(P_4 R) has dim ≥ 4, and (I + g)|Fx = (I + S_2)|Fx is injective, so Im(I + g) = (I + S_2)Fx. +- If c ∉ {±1}: (1 + c)e_3 is independent of that image, so the rank is ≥ 5. Contradiction. +- If c = ±1: three vectors of Fx have zero F-part (F = {8, 9}), so π_F(Im(I + g)) has dim ≤ 1. But [R_Fh | I + R_FF] has + rank 2. Contradiction. ∎ + +**4.11 DYINGGEN Theorem 1** (innermost stage, any m, r, any number of dying roles). Hypotheses: t_s ≠ −1, prefix +commutation, F-nondegeneracy. + +- rank(I + g) ≤ τ and the injection of fix(PR) force every inequality to be tight: rank(PR − I) = q + 2r, dim Fx = τ, + Im(I + g) = (I + S)Fx. +- Δ_F = 0, and P_D is a reflection (c = −1 is forced). +- dim K_0 ≤ |Z| − q − 2r + b, so |Z_{m−1}| ≥ q + 4 − b. + +Lemma 2: if the top index is m − 2, the new-role rows of Y are collinear, so |Z_{m−1}| ≥ q + 4 − b + (|E_{m−2} \ D| − 1). +With b = 1 and |E| = 2 this is DYINGEXACT. + +Gaps (not proved): + +- interior stages, where no induction is available; +- top index below m − 2; +- |E| ≤ 1; +- b ≥ 2. + +--- + +## 5. Decoders + +**5.1 Residual identity** (DECLIFT9, an outside-session lane of DreamingOfClouds'). Give each gathered atom x_s a residual +y = q_s. + +- At each unit descent f → g, fix π ∈ f \ g and split y = λπ + y′ with y′ ∈ g. +- Lifts and merges leave y unchanged. +- A deposit into t lies in q_t^⊥, so ⟨q_t, y_end⟩ = 0. + +Hence for every path s → t, Q[t, s] = Σ_{descents j} λ_j ⟨q_t, π_j⟩ mod 2. λ_j depends only on the path prefix and +⟨q_t, π_j⟩ only on t, so Σ_paths coef·(Σ_j b_j) = Σ_j a_j b_jᵀ: one rank-1 term per unit descent. + +- With odd denominators, M∘Q = I reduces mod 2, so n ≤ C. +- At half level (every path coefficient of 2-adic valuation ≥ −1), the mod-4 expansion gives + n ≤ Σ_i (1 + min(dim g_i/K_i, D_i)) ≤ Σ_{p=1..C} (1 + min(8, C − p)), so C ≥ 16. ∎ + +**5.2 Caller op X_p → Y_p.** A free op needs a common frame f with q_p ∈ f ⊆ q_p^⊥. That is impossible, because +q_p·q_p = 1. By 5.1, a free X_p → Y_p would give the identity decoder at cost 0 against n ≤ C. ∎ + +**5.3 H10 lower bound** (H10DEC). C_{h=10} = 1 + C(103 ports, P104 labels). + +*Proof.* M_88,88 ≠ 0 forces a row with 88 in both D and S. e₁₀ is orthogonal to every other label, so that row's pairing +rank is (rank restricted to the 103 ports) + 1, and restricting all rows gives a valid 103-port decoder. ∎ + +**5.4 Isolation sets** (FOOLSET). An isolation set in Q[D, S] has odd F₂ determinant, so its size is ≤ rank_F₂ Q[D, S] = +the row's climb (≤ 9 on P104). A partial-permutation certificate Z must carry the whole diagonal, so Z = I. ∎ + +**5.5 Lifted labels** (LIFTDEC). Under the lift q ↦ (q, 1) with form x·y + st, the pairing becomes G mod 2. + +- Under the bare row law, 13 disjoint orthogonal frames give M = Σ 1_F 1_Fᵀ at pairing rank 0, so cost 0. The lift + removes the constraint rather than cheapening the decoder. +- With nondegenerate owned frames, a row covering a clique W has f_start ⊆ f_end ∩ W^⊥ and f_start ∩ rad = 0, so its + climb is ≥ 2 dim W. Over cliques 2d/size ≥ 1, with equality only for full frames, so rectangle designs cost exactly + 104. ∎ + +**5.6 Mod 3 on F₂ labels** (MOD3DEC). 1/3 is a 2-adic unit, so 5.1 is unchanged. The labels carry no F₃ structure, so +there is no mod-3 identity. Rank-8 rows over Q have climb ≥ 7 (DECMINRANK, exhaustive), so C ≥ 56 over Z[1/6] for +rank-8 rows. ∎ + +**5.7 3-adic graded bound** (QDEC). Over F₃ the residual identity is exact. With max s/r = 2 over rectangles (attained by +A2⁴), the graded bound equals the Q-rank bound. ∎ + +--- + +## 6. Shape and framework + +**6.1 L(N) ≥ N^τ** (SHAPE Route A). Induction on FINITE-PRECOMPILATION.md:198, using (n − s)^τ + s^τ ≥ n^τ, with base +L(e) = e. Hence a(N) ≤ a* for every compiled N. ∎ + +**6.2 Bootstrap, Theorem A.** κ_{j+1} = min(K, ε + (1 − ε)κ_j). Self-application helps only if the products row binds +(ε < K). Here ε = 1 − 10⁻¹⁴ ≫ K, so Δκ = 0. The binding rows (main, router, Gaussian) make no multiplier call +(08-assembly.tex:913-918; 05-layers.tex:645). ∎ + +**6.3 Theorem B.** With per-level cost ≥ c·x^{1−a*} per bit and Σ x_i ≥ log n − O(L), concavity of x^{1−a*} (with value 0 +at 0) gives subadditivity. So one level is optimal, and an equal L-way split costs L^{a*} times more. ∎ + +**6.4 Slot knobs** (SLOTKNOB). a = 1 − ln(s/W)/ln m (05-layers.tex:645-650). At the frontier, m = N, W = B_N and +s = P_N, so the exponent is a(N) and 6.1 applies. The axis count f enters only through constants. ∎ + +**6.5 Symmetric-form fact** (NEWFRAME). Over F₂, the minimum number of terms vvᵀ summing to a symmetric B is rank B, +or rank B + 1 exactly when B is alternating and nonzero (an alternating form is not a sum of rank B squares, since each +vvᵀ has diagonal v). Over odd p every symmetric B is a sum of rank B terms c_j v_j v_jᵀ (diagonalise). [C +`oddradix.py`, exhaustive for small m.] ∎ + +**6.6 Lemma Q** (QUTRIT). At a character χ, det R(χ) = Δ(σχ)/Δ(χ) with Δ = det M. A λ-pseudo-reflection of image rank r +at every character needs Δ σ-homogeneous of degree e·r ≠ 0. A live plane with c, d ≠ 0 has Δ = cd − ab·k^{α+β}, which +is never homogeneous of nonzero degree. If α + β = 0, then det R = 1, which needs r ≡ 0 mod 3, impossible on a plane. ∎ + +**6.7 Endpoint wrappers** (SPECCHALLENGE, WRAPAUDIT). In odd p, K_{v,c}^j = r·D_a·P_s·K_{v,c}·D_b for every +non-isotropic v and j ≢ 0, with D chirps along v and P_s an F_p address scaling along v. The v-wrappers commute with +K_u for u ⊥ v. + +The word's map is block-diagonal by roles (the contract), so linearity gives A·T_e·B = T_uniform with a diagonal B at +the input and a monomial A at the output. Nothing is left for the parent. [C `oddradix.py` for the identities.] ∎ + +**6.8 Lemma Z** (O1SPLIT). Work in A = F[k]/(k³ − 1) and let T = ∏ c_j u_j c_j⁻¹ · G with constant conjugators. If +T₀ = 0 (every role has a nonzero exponent) and Σ o(u_j) = m, then every unit has rank(u_{j,0}) = m − o(u_j). + +Scope: each unit admits a free normalisation u′_j − I = X_j Ẑ_j(k) π_j with X_j: F^{o_j} → V_j an isomorphism and π_j +k-free. All catalogue units do; [[1, k], [0, k²]] does not. + +*Proof.* + +1. T − I = Σ_j (u′_j − I)·suffix_j, so Im(T(k) − I) ⊆ ΣV_j. Also (T − I)₀ = −I, so ΣV_j = F^m. Since Σ dim V_j = m, + F^m = ⊕V_j. +2. In the basis X = [X_1 … X_n], B := X⁻¹TX = ∏_j (I + E_j φ_j) with φ_j = Ẑ_j Π_{j·} and Π = πX k-free. This is a + Gauss–Seidel product. +3. Downward induction on j: row j of B is supported on block columns ≥ j, and for c ≤ j, (B_{j·})_c = δ_{jc}I + Ẑ_jΠ_{jc}. + Degree 0 with B₀ = 0 gives Ẑ_{j,0}Π_{jj} = −I (c = j) and Π_{jc} = 0 (c < j). +4. Then u′_{j,0}X_j = X_j(I + Ẑ_{j,0}Π_{jj}) = 0, so rank u_{j,0} ≤ m − o_j, with equality when u_0 − I has rank + ≤ o_j. rank(u_0) is invariant under k-free left and right multiplication. ∎ + +A real word must hit the target at two characters (ζ = 1 and ζ = ω) with the same constant conjugators. One character +with free conjugation is exact only in radix 2. + +**6.9 Radix-3 det argument** (C3NATIVE). N = G·N_rat·G⁻¹ with N_rat k-free gives det R = 1 per native. So o = 1 +admissible units (det R = ω^e, e ≠ 0) are illegal alone. The split swap diag(k, 1)·S·diag(k, 1)⁻¹ has det R = 1 and +o = 2. ∎ + +**6.10 Radix-3 target is H** (R3BUILD). + +- Lemma scalar-motifs (03-motifs.tex:89-115) requires the net map of every invocation to be I. +- A side wire s → t is lossless only if ⟨q_s⟩ ⊆ q_t^⊥ (03:402-405), so the centre is δ on every label-non-orthogonal + cell. +- With M_net = I and B_tt ≠ 0, MULTIHOP Thm B (rank_F₃(M̄∘B) ≤ total loss for 3-integral scalars) gives c ≥ v. ∎ + +**6.11 Thm B is vacuous with 1/3** (R3THIRD). With a 1/3 the scaled network computes 3M ≡ 0 mod 3 on every non-orthogonal +cell, so rank_F₃(3M∘B₃) = 0. What survives is rank_Q(M) ≥ 112/rank_Q G = 14, from rank(A∘B) ≤ rank A·rank B. ∎ + +**6.12 Free natives are not involutive** (RES-CONTRACT). Take M = [[a, bq], [c/q, d]] with q-free entries and +R = σ(M)M⁻¹. Then tr R = 2(1 + 2t), det R = 1 and R² = (tr R)R − I. R² = I forces abcd = 0 and ab(ad + bc) = 0, which +leaves only an even diagonal or the swap monomial. ∎ + +**6.13 No non-linear ingredient** (NONLIN). Native opcodes are MOVE/INIT/CLEAR/SCALE/COPY/ADD +(p104-main-wire-native/native.py:59-77). A product gate has zero degree-1 part, so deleting it leaves a linear program +with the same endpoint, and it cannot park or cancel the odd unit. ∎ + +**6.14 Single-step anchors are illegal** (ANCHOR9). The anchor relay must ADD the owned snapshot O_t. O_t lives on Y_t's +chain inside q_t^⊥ (dim ≤ 8), and ADD needs equal frames. So the relay needs a stop of dimension 1..8 after the X read, +i.e. ≥ 2 climb steps. ∎ + +**6.15 Node cut** (GRASSCUT). For a frame set U, every required non-helper state held in U lies in span(entries into U +from outside + helper arrivals into U), so arrivals(U) ≥ r_U. Helper transport is free, so pricing arrivals as stops +is unsound. The sound version charges each helper's single end stay. ∎ diff --git a/research/p104-follow-up-findings/README.md b/research/p104-follow-up-findings/README.md new file mode 100644 index 0000000000..7c49f8f671 --- /dev/null +++ b/research/p104-follow-up-findings/README.md @@ -0,0 +1,298 @@ +# P104 follow-up: κ(k) caller law, cut/pocket lemmas, radix-3 and spec-challenge results, CLEAR-content freedom (no κ) + +This package follows up #7606 (`research/p104-odd-unit-per-grading`), #7607 (`research/p104-toolkit-v3`) and #7608 +(`research/p104-dual-scan-drop-902`). It collects the results our lanes logged after #7606 shipped. Nothing that is +already in those three PRs is repeated here. Where we build on them, we cite them. + +It makes **no κ claim** and ships no word. The base word is ToikY's #7546 (κ 0.003648411294790). At the time of +writing, the frontier is aliromman's #7605 (κ 0.0036504442446), and our #7608 (κ 0.00365074956598) is conditional on +one CLEAR-content premise. §1 below discharges that premise. + +Tags: + +- **[P]** proved in [PROOF.md](PROOF.md). +- **[C]** exact computation, re-run by a checker in this package. +- **[C-lane]** exact computation by our lane code. The number is reported, but CI does not re-run it. +- **[C-param]** priced by our invoice tool PRICEKIT (`pricekit.py`, shipped in #7607). Its control reproduces #7546's + κ and S = 1424. +- **[N]** numerical. +- **[S]** judgement. + +Nothing tagged [N] or [S] is claimed as a result. A network-compiler effort (recompiling the helper layer from +requirements) is still in progress, and **nothing from it is claimed here**. Lanes that have not finished are listed +as in progress, with no claim. + +## Summary + +| # | result | tag | +|---|---|---| +| 1 | Under `owned_erasure`, the content of a lossless owned CLEAR is free, and every CLEAR of an endpoint-exact word is lossless. This discharges #7608's premise and answers the clear-form-gap package's Q1 with YES, with exact certificates | [P, C] | +| 2 | The compiler hypothesis r_max < k_min is not a gap. It applies after strictification, and the gate passes for #7546, #7605 and #7608 | [C] | +| 3 | t = −1 toys: the F₂³ toy is decided by two independent proofs, and every F₂⁴ climb-(n−1) survivor is refuted by the new Pocket Lemma | [P, C / C-lane] | +| 4 | On P104, 8 owned hubs realise the cut floor M = 72, so the conjecture "M ≥ n at t = −1" is false in the frame model. Hubs still do not pay: the V-funnel lemma forces a public y → X layer of rank ≥ 96 | [P, C-lane, C-param] | +| 5 | Callers: the Crossing and Floor Lemmas. B (#7113) is optimal among nested two-arm layouts. A junk role is a disguised ρ = 3 root. ρ ≥ 3 gains nothing. β = 4g + 2. Nesting is proved at the outermost and innermost stages only | [P, C, C-param] | +| 6 | Decoders: the residual identity gives C ≥ n for odd-denominator networks and C ≥ 16 at half level. The h = 10 decoder costs 57. Neither 1/3 nor fooling sets nor lifted labels go below 56 | [P, C, C-lane] | +| 7 | Shape and framework: κ is bounded in k, h and v. Self-application gives Δκ = 0 exactly, and one outer level is optimal. Slot knobs are a single compile number | [P, C-param] | +| 8 | Radix 3: A12 (binary radix) is the only over-conservative clause found. Endpoint wrappers exist in odd radix, but Lemma Z keeps the per-port +1. The radix-3 decoder target is H, so 3-integral decoders cost ≥ v = 112, and no radix-3 route crosses | [P, C, C-param] | +| 9 | Negatives: no resonance in any knob, no non-linear op, single-step anchors illegal, no usable symmetry, no new cut floor, and the dual scan rediscovers #7603–#7605 | [P, C-lane, C-param] | + +## How to verify + +``` +python3 -I -B research/p104-follow-up-findings/clearform.py # §1 CLEAR certificates PASS_CLEARFORM +python3 -I -B research/p104-follow-up-findings/sepgate.py # §2 strictification gate PASS_SEPARATION_GATE +python3 -I -B research/p104-follow-up-findings/toy4.py # §3 F2^3 decision, controls PASS_TOY4_DECISION +python3 -I -B research/p104-follow-up-findings/labels.py # §4, §6 E8/P104 label facts PASS_LABEL_FACTS +python3 -I -B research/p104-follow-up-findings/oddradix.py # §7, §8 forms, wrappers, Lemma Z PASS_ODD_RADIX +python3 scripts/research_package.py --package research/p104-follow-up-findings +``` + +- All checkers use the standard library only and finish in minutes. +- Each has positive and negative controls, listed in [VERIFY.json](VERIFY.json). + +--- + +## 1. Owned CLEAR content is free (CLEARFORM) + +| statement | tag | +|---|---| +| **Rank lemma ⇒ lossless.** Every event except CLEAR keeps the live rank, and a CLEAR lowers it by at most 1. An invertible endpoint forces rank n throughout, so **every CLEAR of an endpoint-exact word is lossless**. "Lossless" is implied by correctness; it is not an extra premise | [P] PROOF 1.1 | +| **Content theorem.** The retained contract behind `owned_erasure` has six clauses (E1–E6 in PROOF 1.2, each quoted with file:line). None names, limits or prices the erased value. So two endpoint-exact words with identical owned INIT/MOVE/CLEAR events either both satisfy the contract or both fail it, and pay identical erasure cost. The κ invoice and the strictification gate take no CLEAR input | [P] PROOF 1.2 | +| **#7608, CLEAR #44** (owned 1557, chart 595). The new row {451: −1, 1495: 1} is an exact Q-combination of 21 live rows (other live rank 1501 = n_pub). #7605's row is the same combination plus −3/2·(x902 + x985). The other 73 CLEARs are identical in the two words, and both endpoints have rank 1501 | [C] | +| **Swarm Q1** (`research/p104-6372-clear-form-gap`, README Q1). CLEARs 17755 (role 780) and 17756 (role 779) of the pinned candidate are lossless, each with an exact 97-term certificate (other live rank 770 = n_pub). Q1 resolves YES, subject only to the chronology clause E3, which is a field-identity check | [C, P] | + +Scope: + +- Owned fields only. Zeroing a public register without a live owned holder is a genuine loss. +- The result fails in a reversible-uncompute model, which the retained contract (E5) says it is not. +- [S] The contract is spread over retained notes. A maintainer could adopt a stricter "frozen content" reading, but no + quoted clause supports it. The selected BIT admission itself has 237 of 237 nonzero erasures. + +Consequence for #7608: its premise reduces to `owned_erasure` as written, with nothing extra [P + C]. The ruling stays +with the maintainers. + +## 2. The separation hypothesis is not a gap (SEPAUDIT) + +- **The flag.** Our PROFILECHK lane flagged that FINITE-PRECOMPILATION.md:51-52 requires r_max < k_min, while the + #7113-caller invoices have r_max = 64 and k_min = 1. +- **The scope.** The condition applies to the **strictified** unit fed to the compiler. The selected #7000 record + states that its raw invoice fails the condition and then strictifies it (c = 11, b = 12, u = 1/7, v = 1920; + `interval_gate.py`) [P, quoted in PROOF 2]. +- **[C] `sepgate.py`.** + - The #7000 control reproduces FULL-RESULT.json's γ and δ. + - #7546 gives γ 0.940836, δ 0.908148; #7605 gives 0.940920, 0.908149; #7608 gives 0.940932, 0.908149. All are below + 31/32. + - Each kappa root matches its published κ. + - Negative control: paid mass of rank ≥ 16 scaled by 1.10 fails the gate. +- **[C-lane]** #7601 gives γ 0.940861, δ 0.908148. +- **Verdict.** No contributor result is affected. + +## 3. t = −1 closures: toys + +The model is the WEBS toy: U-only targets, any helpers, owned ascents. The web-general Cut Lemma (WEBS, an +outside-session lane of DreamingOfClouds') shipped in #7606 §I.3, and #7606 listed the F₂³ question as open. + +| result | tag | +|---|---| +| **F₂³ decided.** Labels 1, 2, 4, 7. There are 8,261 owned multisets of climb 3 and 460 up-sets. 13 sets pass every cut, and all 13 are infeasible for any number of helpers. Owned climb ≥ 4 = n is needed. The 4-feeder control is realised exactly. Labels 1, 2, 7 at climb 2: the only cut-feasible set is also refuted. The Charge Corollary is not vacuous: it blocks 240 of the 2,074 cut-feasible climb-4 sets and leaves the 4-feeder set alone. The duality map permutes the 13 climb-3 sets | [P, C `toy4.py`] | +| **Proof S2** (outside-session, DreamingOfClouds'): the Pin Lemma, the time-cut basis and the Down-set No-Loss Lemma (DNL) give the **Charge Corollary**. The DNL hypotheses are necessary: violating them, the finals still span on 1,448 random programs | [P] PROOF 3.1–3.4; [C-lane] | +| **Proof S1** (ours): the **Forwarding**, **Union** (multi-commodity cut) and **Duality** (O feasible ⇔ O^⊥ = {(b^⊥, a^⊥)} feasible, X ↔ Y) Lemmas. A brute-force certificate covers all 460 up-sets | [P] PROOF 3.6–3.8; [C-lane `cert3.py`] | +| On F₂⁴, cuts + Charge + dual Charge + Union decide every 3-port set and the 4-port types (0,2,2,2) and (1,2,2,3). The survivors are path type (8 per set) and two-disjoint-pairs type (32 per set) | [C-lane, CP-SAT up-set ILPs] | +| **Pocket Lemma** (TOY5, any helpers, descents allowed): o(G) + #(owned moves into the pocket N) ≥ \|R\| | [P] PROOF 3.9 | +| The Pocket Lemma refutes **every** F₂⁴ survivor (44 at 4 ports, 128 at n = 5) and every cut-feasible climb-(n−1) set tested (3,801 sets, including 3,044 at n = 5). The two proofs are complementary: Pocket kills the S2 survivors, 256 of 256 on {1, 2, 7, 11}. Controls: one feeder per port survives, and 1,381 of 2,074 F₂³ climb-4 sets survive, so the test is not vacuous | [C-lane, CP-SAT] | +| On P104 these lemmas do **not** give M ≥ 104. Every P104 port has 200 of its 255 planes free of non-partner labels, and on pure {0} → V hubs the Pocket Lemma collapses to the cut lemma (α = 8, M ≥ 72) | [C-lane; P] | +| An unfed port cannot piggyback on non-partners' private ascents ⟨q_s + q_d⟩ → ⟨q_s, q_d⟩ (geometry-free) | [P] PROOF 3.13 | + +## 4. Hubs realise the cut floor but do not pay (HUBCLASS) + +| result | tag | +|---|---| +| Index-coding hub construction: k direct hubs {0} → V plus one helper per partner cell give X_t = x_t − y_t, Y_t = y_t exactly, with no helper bound needed | [P] PROOF 3.10 | +| P104, 8 hubs, A = G/2: **exact, M = 72 < n = 104** (41,265 events, 4,992 partner-cell helpers). So the conjecture "M ≥ n at t = −1" (#7606, tagged [S] there) is **false in the frame model**. The cut floor 72 is tight, and the minimum hub count is exactly 8 | [C-lane exact replay] | +| G104 is the optimal fit: integer, rank 8, diagonal 2, 0 on all 5,720 odd cells, ±1 on all 4,992 partner cells; α = 8. P104 has an exact cover by 13 disjoint orthogonal frames | [C `labels.py`] | +| F₂⁴: two hubs are exact (M = 8 = n) on TOY5's sets and on all 8 odd labels, and one hub fails the cuts. Hub total climb is ≥ n on every F₂⁴ label set | [C-lane; P] PROOF 3.12 | +| **V-funnel lemma.** With k hubs as the only owned moves, the public y-content into V has rank ≥ n − k = 96, so a public y → X layer of rank ≥ 96 is forced. Hubs share only additive y → X delivery; on the park side the Clone lemma still needs owned rank ≥ 96 | [P] PROOF 3.11 | +| Price, with S = 1248: 1.0856× at the flag-free LP floor (U = 1,235, not a build), 0.8234× at U = 7,127 and 0.7175× at the best built U = 10,730. The hub crossing needs U ≤ 2,817 D0/call | [C-param] | + +## 5. Caller theory + +### 5.1 Two-arm callers + +**Lemmas.** These come from CALLEROPEN (an outside-session lane of DreamingOfClouds'). + +| result | tag | +|---|---| +| **Crossing Lemma.** Idle lines lose 4 dimensions at every witnessed boundary. B's caps (0, 2, …, 14, …, 2, 0) are attained exactly at all 15 non-centre boundaries, at q₀ = 1 and q₀ = i. This kills the outer-boundary bonus (1.1272 / 1.1109) | [P] PROOF 4.1; [C-lane `cap_check.py`, shipped in #7607] | +| **Floor Lemma**, under nesting: \|Z_k\| ≥ 2(k+1) + 2. It is attained by B at every non-centre call | [P] PROOF 4.2 | +| **B is optimal among nested two-arm, two-hub layouts** at ρ = 2, at 1.0950 / 1.0031 / 0.9773 (twins deleted / shadows / shadows + 2 relays). The majorisation step is at sketch level | [P] PROOF 4.3; [C-param] | +| A shared D across calls, or a D-dependent free op, is illegal, and SL holds anyway | [P] PROOF 4.4 | +| Multi-centre layouts force ρ ≥ 2c and lose: 0.9930 / 0.9050 / 0.8804 at c = 2 | [P] PROOF 4.5; [C-param] | +| Single-shear-call callers on W6805 (CubeJerry's #6805 native) price ≤ 0.9237× | [C-param] | + +**Other layouts.** + +| result | tag | +|---|---| +| **The junk role is a disguised ρ = 3 caller** (JUNKROLE, an outside-session lane of DreamingOfClouds'). Dilation identity: P = −(I − e_J ãᵀ)(I − b̃ e_Jᵀ). The J-stages vertex-cover K_{8,9}. The honest D-free junk (JF1) prices exactly at SINGLEHUB's ρ = 3 ceiling, 1.0739 / 0.9796 / 0.9532, below B. A D-scaled junk does not cross | [P] PROOF 4.6; [N]; [C-param] | +| **ρ ≥ 3** (RHO3CROSS). Relation dim ≤ ρ − rank(Σ witness Z_j), so δ = 1 is possible only at the two outer boundaries. This is tight on SINGLEHUB's ρ = 3 root: 13 inner boundaries at 0, both outer boundaries at 1. Best prices: ρ = 3 one-hub 1.0612 / 0.9685 / 0.9426; ρ = 3 two-hub 1.0153 / 0.9301 / 0.9062; ρ = 4 chain 1.0242. All are below B | [P] PROOF 4.7; [C-lane]; [C-param] | +| **Arm trees** (ARMTREE). Block rank bound (sketch): #roles meeting stage sets A, B ≥ 2·rank sgn(a − b), so interleaving in time costs shared roles. Two-hub two-piece layouts violate it (337 violations at L = 8). A 4-hub tree toy at k = 8 prices 0.59× B(8). Not closed as a theorem | [P sketch; C-lane; C-param] | +| **β = 4g + 2 = 34** (BETA): 2 uncancelled hubs (2g), arm tops (2g) and the interior (+2). The per-stage lift 8 = h − 1 is the F₂⁸ frame dimension. The hub degree k is forced. **The arm-top degree k/2 is forced only under nesting** | [P] PROOF 4.8; [C-param] | +| The prize if the hubs were split per arm (an illegal layout): +5.2% on shadows. Halving the lift is not available | [C-param] | + +### 5.2 Nesting + +| result | tag | +|---|---| +| **NESTPROOF.** Lemma S gives a semiseparable Gram. The outside-mask part B_k of the early x has dim b_k ≤ 2k − 2 and is the −1 eigenspace of the prefix (a reflection block). b_1 = 0, so the outermost stage is nested. The Floor bound weakens to \|Z_k\| ≥ 2(k+1) + 2 − b_k without nesting | [P] PROOF 4.9 | +| **NEST5.** Nesting is **not** implied by Lemma S + prefix commutation. A one-arm L = 3 solution with a dying role (b_2 = 1, \|Z_2\| = 7) is certified by Newton to residual 1e−69. It lies outside the two-arm Floor setting, so it refutes only "nesting is forced", not B's optimality | [C-lane, mpmath] | +| **DYINGEXACT.** The L = 4 two-arm dying-role layout is infeasible for every t ≠ −1 (rank/eigenspace proof). The nested B(4,3) control is built exactly | [P] PROOF 4.10; [C-lane] | +| **DYINGGEN Theorem 1.** At the innermost stage, for any arm length and any number of dying roles: c = −1 is forced and \|Z_{m−1}\| ≥ 2(m−1) + 4 − b. Lemma 2 adds \|E_{m−2} \ D\| − 1 when the top index is m − 2 | [P] PROOF 4.11 | +| **Still open.** Nesting at interior stages, b ≥ 2 and \|E\| ≤ 1. β = 34, and B's optimality beyond the nested family, rest on these | open | +| Non-nested layouts: no sliding-window layout passes the exact rank checks (L = 8: 7,162 / 61 / 2 violations at w = 1 / 2 / 3). If such layouts were legal, they would price 1.339 / 1.204 / 1.167 at w = 1 | [C-lane; C-param] | +| The float-solver evidence (dying-role two-arm L = 4: 0 of 114 starts against a 4% control rate; non-nested L = 4: 0 of 24) is [N], superseded where DYINGEXACT applies | [N] | + +### 5.3 κ(k) law: extensions beyond #7607 + +The closed-form caller C(k), S(k) = 96k − 208, β = 2(2h − 1), κ* = 1/((2h − 1)k*), the Lambert-W k* and κ ~ ε/(β ln k) +shipped in #7607 §E1 (`kformula.py`). New here (KFORMULA, RES-REC): + +| result | tag | +|---|---| +| Dimension families with the same optimal caller, g = h − 1, native D ∝ g: BW16 κ* ≈ 0.00184, BW32 0.00085, P104⊗P104 0.00046. So κ*(h) = Θ((1 − c/v)/(h log h)), decreasing in h. The native-∝-g scaling is a modelling assumption | [C-param; S] | +| The buildable layout sweep (1,422 layouts) peaks flat at L ≈ 16–17. L = 16 sits +0.02% above L = 17, which is model noise, and matches the exact optimum k = 17 | [C-param] | +| A positive limit κ_∞ = ε/α would need bounded-header callers joined by tree nodes. No theorem excludes them outside one nested root, and no construction exists | [S] | + +## 6. Decoders + +| result | tag | +|---|---| +| **Residual identity** (DECLIFT9, an outside-session lane of DreamingOfClouds'): Q[t, s] = Σ path descents b_j mod 2, one rank-1 term per unit descent, whatever the lifts and merges. Hence **C ≥ n = 104** for odd-denominator networks and **C ≥ 16** at half level (the DEC-only floor was 21). Checked on 800 random networks | [P] PROOF 5.1; [C-lane] | +| Lifted kept chains void the ADICWALL partial-replacement bound. Merge-only relays are legal and cheaper, but reach only ports that need neither chain. All 124,146 merge configurations cost ≥ 57 | [P; C-lane] | +| The caller op X_p → Y_p needs a paid descent (q·q = 1) | [P] PROOF 5.2 | +| **H10DEC.** On the h = 10 labels (P104 on 103 ports, port 88 → e₁₀), an exact decoder costs **57** (8 E8 rows with 88 zeroed, plus one climb-1 row). C_{h=10} = 1 + C(103), so the true minimum lies in [1 + floor(103), 57]. The ASYMPORTS c = 50 was a floor artefact. h = 10 stays killed at its gate G2 (U packing) | [C-lane; P] PROOF 5.3 | +| **MOD3DEC.** On F₂ labels, 1/3 is a 2-adic unit, invisible to the residual identity. There is no mod-3 identity, and rank-8 rows climb ≥ 7, so there is no sub-56 decoder over Z[1/6]. The "70 vs 68" figure belonged to the radix-3 world and was a MILP catalogue bound, not a theorem | [P] PROOF 5.6 | +| **QDEC.** The 3-adic graded bound equals the Q-rank bound (max s/r = 2, attained by A2⁴), so it adds nothing | [P] PROOF 5.7; [C-lane] | +| **FOOLSET.** Isolation and fooling sets are capped by rank_F₂ = climb (≤ 9), and they give lower bounds where the certificate lemma needs upper bounds. Nothing new | [P] PROOF 5.4 | +| **ODDGRAPH.** The odd (orthogonal) graph is SRG(120,63,30,36), of degree 55 on P104. Q has GF(2) rank 9 and real rank 104. There are 2,025 orthogonal 8-frames, each orthogonal pair lies in 15 of them, and 759 lie inside P104. 56 is not a graph degree: 56 = rank_R(G) × climb = 8 × 7 | [C `labels.py`] | +| Climb-1 all-odd rectangle covers need 104 terms | [P] | +| **LIFTDEC.** Under the lift (q, 1), the bare row law makes the decoder free: 13 frames give pairing rank 0, a sign the target became wrong. With nondegenerate owned frames, a clique row costs ≥ 2 dim W, so rectangle designs cost exactly 104. No sound sub-56 lifted decoder exists | [P] PROOF 5.5; [C-lane] | +| **XDEC** (already in #7606 I7) and the merge/relay families are not repeated here | — | + +## 7. Shape and framework + +| result | tag | +|---|---| +| **SHAPE.** The (log n)^{1−κ} is p transform bits per coefficient, in one outer level. The saving is the inner width recursion, with κ = a* − O(g). A growing compiled template has L(N) ≥ N^τ for every N, so a(N) ≤ a*: at most the ~1e−15 gap is recoverable | [P] PROOF 6.1 | +| The k-family unrepaid mass is μ = S/M_T = 0.0051 (k = 8), 0.0048 (17), 0.0025 (64), 0.0008 (256): μ = Θ(1/(gk)) | [C-param] | +| **BOOTSTRAP.** Theorem A: self-application gives Δκ = 0 exactly, since the binding rows make no multiplier call. Theorem B: one outer level is optimal, by concavity of x^{1−a*} | [P] PROOF 6.2–6.3 | +| Self-application is legal after small clause changes; the stack discipline at unbounded depth is unwritten | [S] | +| **SLOTKNOB.** a = 1 − ln(s/W)/ln m. At the frontier, m, W and s are one compile number N, and f enters only through constants. No slot knob exceeds 1.0× | [P] PROOF 6.4 | +| **MUCENSUS.** Over 5,246 archived words with ledger-matched callers, max μ = 0.0103. Bounded-header (projective-plane) families give 0.0038–0.0050, decaying. Naive C(17) pairings up to 0.12 are artefacts of mismatched ledgers | [C-lane] | +| **NEWFRAME.** The char-2 walls trace to A12 (binary addresses, F₂ labels, Z/4 phases). Radix is not in SPEC. Over F₂, the minimum number of vvᵀ summing to B is rank B, or rank B + 1 iff B is alternating and nonzero; in odd characteristic it is always rank B | [P] PROOF 6.5; [C `oddradix.py`] | +| Generalised Lemma E′: unipotent natives never reach equality, in any characteristic | [P] | + +## 8. Radix 3 and the spec challenge + +| result | tag | +|---|---| +| **SPECCHALLENGE.** Of the clauses our walls rest on, only A12 (binary radix) is over-conservative with a κ lever. A28 (ascending-only MOVEs) is over-conservative but worth ≈ 0. Exactness → formal ε is worth ≤ 0. The constant template is worth ≤ 1e−15. One slot per child, common frames at gates, A29 credit and exact owned restore are necessary | [P / Q] | +| **QUTRIT.** Lemma Q: no live plane is a λ-pseudo-reflection, in any radix. Exhaustive 2×2 monomial tables cover both radices | [P] PROOF 6.6; [C-lane] | +| **Endpoint wrappers** (SPECCHALLENGE, audited by WRAPAUDIT). In odd p, K_{v,c}^j = r·D_a·P_s·K_{v,c}·D_b for every non-isotropic v and j ≢ 0, with chirps D and an F_p address scaling P_s. The wrappers commute with K_u for u ⊥ v. There is no solution on isotropic lines. The one-sided gauge K² is dense | [P] PROOF 6.7; [C `oddradix.py`] | +| **Lemma Z** (O1SPLIT): if T₀ = 0 and Σo = m, every unit has rank u₀ = m − o. H3, live planes and QUERY are not admissible. So **the per-port +1 survives in odd radix for every exponent pattern**: joint_mono needs ≥ 37 per A port per word. Admissible units: QSELF, park1 and C3 swap planes | [P] PROOF 6.8; [C `oddradix.py`] | +| An independent read-only audit of Lemma Z found it sound. The m = 2 tables are complete over F₇ and F₁₃, and the m = 4 search covered 548,000 conjugates | [C-lane] | +| **SPLITK.** The split K/K⁻¹ contract is not legal as written (SPEC pins K^{⊗e} per role). This verdict stands, but its pricing argument was replaced: see Corrections | [P] | +| **C3NATIVE.** By the radix-3 det argument, o = 1 admissible units are illegal alone. The split swap diag(k, 1)·S·diag(k, 1)⁻¹ is legal (det R = 1, o = 2) and reaches m. Whether it supplies the contract's crossing is open | [P] PROOF 6.9; [C-lane]; open | +| **R3BUILD.** The radix-3 decoder target is **H**, not N: the net map is I, and side wires are lossless only between label-orthogonal ports. So every 3-integral radix-3 decoder costs **c ≥ v = 112**, for any labels and any odd radix, and no radix-3 route crosses. Break-even is c ≈ 66.7–68.5 at ρ = 2 and ≈ 70.9–72.6 at ρ = 1 | [P] PROOF 6.10; [C-lane; C-param] | +| **R3THIRD.** With 1/3 denominators Thm B is vacuous, not weak. What survives is rank_Q M ≥ 14 (full-support rows ≥ 112). M = (G∘G − J)/3 fits H with rank 36, costing 288 in the row model. The cheapest verified decoder is 14 orthogonal frames of P112, at 112. Nothing below 112 was built | [P] PROOF 6.11; [C-lane] | +| SWAPJ (the ρ = 1 crossing) was stopped as moot unless a decoder below 71 appears. R3TILE (cancelling tilings) is in progress, with no claim | in progress | + +## 9. Other negatives (scoped) + +| lane | result | tag | +|---|---|---| +| RES-REC / RES-PORT / RES-LAYER / RES-CONTRACT | No resonance. All knobs are smooth: at κ ≈ 3.6e−3, S and D enter additively. Sensitivity at the crossing: one owned unit = −1.126% κ = 284 D0/call; 500 D0 = 1.98%; fan-out 0.4% per 100 D0; skipping one climb step everywhere is worth at most +4.3%. The ratio is monotone in n, and +1 in h ≈ ×0.8. Break-even ΔS on all-B is 32.8 | [C-param] | +| RES-CONTRACT | Free natives are never involutive (tr R = 2(1 + 2t), R² = (tr R)R − I), so the involution clause of classes C / D′ needs a paid odd diagonal | [P] PROOF 6.12 | +| NONLIN | No non-linear ingredient is admissible in a native. A product gate has zero degree-1 part and cannot park the odd unit | [P] PROOF 6.13 | +| ANCHOR9 | Single-step (9,) anchors are illegal, the (1,8) split is forced, and anchors stay at 327 D0 | [P] PROOF 6.14; [C-lane] | +| GRASSCUT | No new floor. Node/set cut: Σ r_F = 711 over 602 frames on #7546, and unions never beat singletons. Pricing every arrival as a stop (1,946.5) is unsound; the native violates it at frame 602. The sound bound is ≥ 551 D0, below the census 1,330.5 | [P] PROOF 6.15; [C-lane] | +| SYMMETRY | No usable symmetry. Stab(Z16) has order 384 and Stab(A, B) = 1. The best element maps 27% of helper routes (4.8% with contacts), and 1,095 of 1,101 helpers have distinct signatures | [C-lane] | +| DUALBUILD | Both exact rank-0 hits so far of the dual-side scan (166 skips F783; 134 skips F789) are exactly edits already in #7603–#7605 (SYLforge, FanPUYen, aliromman). The dual scan independently rediscovers the swarm's chart contractions, and there is nothing new to stack. The remaining stays are being scanned, with no claim | [C-lane] | +| LITSWEEP / LITSWEEP2 | Literature leads: minrank/Haemers, fooling sets, rigidity, subspace-code cut sets, quadric frame partitions. None bounds the decoder directly; the follow-ups above tested them | [S] | + +--- + +## Corrections of our own earlier statements + +1. **LITSWEEP2 had the two graphs swapped.** The decoder's "odd" cells (label dot 1) are the integer-orthogonal pairs, + SRG(120,63,30,36). The degree-56 graph is the label-even graph. LITSWEEP2 also said "135 frames, each orthogonal pair + in exactly one". In fact there are 2,025 orthogonal 8-frames and each orthogonal pair lies in 15 [C `labels.py`]. +2. **SPLITK and QUTRIT: the grade assumption.** + - Both priced the split contract as if free endpoint wrappers preserved σ-grade. That is true only in radix 2. + - WRAPAUDIT showed that the two-sided wrapper exists in odd radix, which reversed SPLITK's n_Y charge and QUTRIT's + "+1 survives" at the pricing step. + - O1SPLIT then showed that both lanes, and SPECCHALLENGE, checked a single character with freely conjugated + factors. A real word must hit the target at two characters with the same constant conjugators. + - With that, Lemma Z restores the +1 for every pattern. + - Net: QUTRIT's conclusion stands, for a different reason. SPECCHALLENGE's ×1.40 / ×1.32 / ×1.51 envelopes are + withdrawn. +3. **R3BUILD: target N was a porting error.** + - RADIX3, QDEC and QUTRIT copied binary's "M = G/2 on the mask". In radix 3 the invariant is "M = δ on the mask" + (target H). + - The "c = 64" frame decoder therefore really costs ≥ 176. + - QDEC's and QUTRIT's +2–7% radix-3 prices, which rested on target N, are void. +4. **HUBCLASS refutes the conjecture "M ≥ n at t = −1"** in the frame model. #7606 listed it as [S]: M = 72 is + attained on P104. +5. **CALLEROPEN's "B is optimal in the two-arm family"** holds for **nested** masks. Nesting is a Floor-Lemma + hypothesis, proved only at the outermost (b_1 = 0) and innermost (DYINGGEN Theorem 1) stages. The same applies to + the arm-top part of β = 34 in #7607's κ(k) law (§E1 there). +6. **PROFILECHK's "possible soundness gap" was a misread of scope** (§2). SLOTKNOB's and SHAPE's θ < 1 sandwich + applies to the strictified unit. +7. **RES-LAYER's "free single-step anchors" row is void** (ANCHOR9). +8. **The "70 vs 68" mod-3 decoder figure** belonged to the radix-3 world and was a catalogue MILP bound, not a theorem + (MOD3DEC). The ASYMPORTS h = 10 decoder c = 50 was a floor artefact; the real cost is 57 (H10DEC). +9. **MUCENSUS** and **GRASSCUT** each caught a first-pass artefact of their own: + - MUCENSUS: naive caller pairing gave μ up to 0.12. + - GRASSCUT: arrival-as-stop pricing gave 1,946.5. + Both are reported above only in their corrected form. + +## Open next questions + +1. **Interior nesting.** Prove b_k = 0 at interior stages of two-arm callers (gaps G1–G4 in PROOF 4.11). This would + make B's optimality and β = 34 unconditional. First step: an exact L = 5 two-arm search with one dying role at + stage 2. +2. **Hub U layer.** Does a one-plane public partner layer deliver (G/2 − I)y below 2,817 D0/call? That is the hub + crossing (§4). +3. **Radix-3 decoder.** Is there a cancelling tiling of spilled A2/HIT rectangles giving a target-H radix-3 decoder with + ΣΦ ≤ 67 (ρ = 2) or ≤ 71 (ρ = 1)? It is the last radix-3 escape (R3THIRD). +4. **h = 10.** Is C(103) = 56, which would make the h = 10 decoder exactly 57? +5. **Bounded headers.** Does a bounded-header caller stitched by tree nodes give κ(k) a positive limit? (This is also + #7607's open question 3.) + +## What is not included, and overlap + +- **Excluded as work in progress:** the network-compiler route (REBUILDKIT, NETC2–NETC7, NETCAUX), R3TILE, and the + continuing dual-side scan (DUALSCAN2). +- **Already in #7606:** the Cut Lemma (WEBS), XDEC, PARALLEL, KSLOT, MULTIMIX and BEAUTY100's all-B analysis. +- **Already in #7607:** dual-word price invariance (DUALWORD), the κ(k) core law, `layout_price`, `cap_check`, and the + main-902 drop found on the dual. +- **Already in #7608:** DUALAUDIT and REPAIR902. + +## Credits + +All checkers and lane code are ours (DreamingOfClouds with Claude Opus 5.5, via Claude Code). Four lanes are DreamingOfClouds' +outside-session lanes (DreamingOfClouds): the TOY4 S2 proof, CALLEROPEN, JUNKROLE and DECLIFT9; so is WEBS, whose Cut +Lemma shipped in #7606 and is used here. + +Swarm work referenced: + +- ToikY: #7546. +- Rohan Arun (rohanarun): #7113 signed caller. +- SYLforge: #7603. +- FanPUYen: #7604. +- aliromman: #7605, whose word is vendored as data. +- CubeJerry: #6805 W6805 native; #7000 selected record. +- Clear1nsight and the P104 price and replay lineage: conventions. +- unpaidmoon: `research/p104-6372-clear-form-gap`, whose pinned candidate is read as data. +- The PR968 authors: the P104 labels. + +See [NOTICE](NOTICE). diff --git a/research/p104-follow-up-findings/SOURCES.json b/research/p104-follow-up-findings/SOURCES.json new file mode 100644 index 0000000000..5ed36cb165 --- /dev/null +++ b/research/p104-follow-up-findings/SOURCES.json @@ -0,0 +1,36 @@ +{ + "schema_version": 1, + "base_commit": "e54523517d0f03e58352e647c403a5af3e525a57", + "files": [ + { + "path": "docs/research/agent-task-catalog.json", + "usage": "provenance", + "git_blob": "3404fbdd5e7529a0674eef26114b5071e4586cec", + "sha256": "ead6cdc9d0af6d58e8a49744d8ec8c7c15e13d2ba93c276c434bcf9b51b93a81" + }, + { + "path": "research/p104-6372-clear-form-gap/inputs/candidate-WORD.json.gz", + "usage": "input", + "git_blob": "0af79e58172f85c302c35b193205c0b185b09393", + "sha256": "e3b6f1c25d672b8c85433be97ebad77ae6a6972352ce2ff63507d30835fcb491" + }, + { + "path": "research/shared-wire-split-composition/FULL-RESULT.json", + "usage": "input", + "git_blob": "ff3256f0d3ffbfc56b062f9ec0fdbbc7b30e76d5", + "sha256": "d9ba709fa5dcefffe3f3abdcf34600ce188224703cfd743e6db8b58ba4816cb7" + }, + { + "path": "research/kappa-rebuild/architecture/FINITE-PRECOMPILATION.md", + "usage": "provenance", + "git_blob": "4badb40f0919c515823cb07e44c6470d4d6469ca", + "sha256": "4cb32f6b8e388ecf6ed41b5bbdeeb4539cb40c8424f194974afea58f7e0921e8" + }, + { + "path": "upstream/build/sections/05-layers.tex", + "usage": "provenance", + "git_blob": "5ce8b3c83c455f221bb84858a97230b0285644aa", + "sha256": "20cfc8d12099d4e4ed9e3e7eeb6162edd9b6e0e076f24693364cd24377252594" + } + ] +} diff --git a/research/p104-follow-up-findings/TASK.json b/research/p104-follow-up-findings/TASK.json new file mode 100644 index 0000000000..ca54a3a0b8 --- /dev/null +++ b/research/p104-follow-up-findings/TASK.json @@ -0,0 +1,135 @@ +{ + "schema_version": 1, + "task_id": "p104-side-correction", + "priority_revision": 8, + "base_commit": "e54523517d0f03e58352e647c403a5af3e525a57", + "original_card": { + "id": "p104-side-correction", + "question": "Can joint helper bases and a legal causal split improve the complete P104 productive/paid invoice?", + "starting_points": [ + "docs/research/current-priorities.md", + "docs/research/research-family-status.md", + "certificates/selected-result.json", + "docs/research/pr-intake-evidence/pr5599-completion/PROOF-REVIEW.md", + "research/p104-helper-subspace-splits/README.md", + "research/dyadic-helper-channel-capacity/README.md" + ], + "methods": [ + "Construct and independently check one source-bound instance of the stated first experiment.", + "Seek an exact counterexample or target-specific complete-budget obstruction to that same proposed change." + ], + "acceptance_gate": "An exact arbitrary-input identity, source/target frame availability and restoration at the chosen cut, plus the complete channel+correction+idle/hosting bill or an explicit favorable bound. The native channel alone is not a supplier. A scoped local result may be retained without a complete supplier. Expanding it into further construction rounds requires the family-level budget and obligation gate in research-family-status.md; an optimistic passing relaxation alone is not acceptance.", + "first_step": { + "command": [ + "python3", + "-B", + "scripts/research_selected_baseline.py" + ], + "expected": "PASS_RESEARCH_BASELINE_BINDINGS_ONLY", + "inspect": "Read revision 8, the selected review and live exact-source handoffs. Then follow this card's bounded first_experiment.", + "scope": "Source-bound orientation only, not a supplier replay or theorem proof." + }, + "first_experiment": "Start with the selected #5599 emitted word and review pending #5718 distinct input/output bases plus #5717/#5719 coverage before claiming work. Pick one uncovered source word, helper group and cut region. Prove the arbitrary-input relation and legal entry/exit corrections, then compare full target and paid profiles. Reject if completion, owned lifetimes or consumer costs repay the gain. A static pairing rank alone is not a physical split.", + "bottleneck_link": "Judge the actual current supplier contract and complete signed target/paid bill; frozen-profile ceilings require an applicability proof.", + "allowed_variations": [ + "One exact source head, helper/cut region or quantified proposition and changed hypothesis; check live handoffs first. Different seeds are not different scopes." + ], + "scope_change_triggers": [ + "Changing source head, helper/cut domain, operation alphabet or caller boundary without recording the new scope.", + "Treating an archived proposal or local numerical pass as complete supplier admission." + ], + "overlap_terms": [ + "P104", + "helper basis", + "helper split", + "5718", + "dyadic capacity" + ], + "existing_checks": [ + { + "scope": "PR #4133: literal-slot defect", + "evidence": "research/p104-literal-slot-defect/README.md", + "remaining": "Independently validate the stated scope or change its producer/consumer premise and pay the complete boundary.", + "status": "author-checked", + "source_commit": "88666f1dee93fbd85b31fd5d6f91a219e111b5f4", + "selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129" + }, + { + "scope": "PR #4136: uniform commutation gap", + "evidence": "research/p104-uniform-commutation-gap/README.md", + "remaining": "Independently validate the stated scope or change its producer/consumer premise and pay the complete boundary.", + "status": "author-checked", + "source_commit": "281ce601a8be9db470de630759179c23e1dfaa88", + "selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129" + }, + { + "scope": "PR #4140: uniform encoding gap", + "evidence": "research/p104-uniform-encoding-gap/README.md", + "remaining": "Independently validate the stated scope or change its producer/consumer premise and pay the complete boundary.", + "status": "author-checked", + "source_commit": "de25c6525aa866962309df5d107b32d55e6e5628", + "selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129" + }, + { + "scope": "PR #4153: source-chart shortcut exhausts its optimistic allowance", + "evidence": "research/p104-source-chart-shortcut/README.md", + "remaining": "Independently validate the stated scope or change its producer/consumer premise and pay the complete boundary.", + "status": "author-checked", + "source_commit": "9123241fea53df77e51ffe30d9aca1625d4bf3a8", + "selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129" + }, + { + "scope": "PR #4154: fiber-tag seam mismatch", + "evidence": "research/p104-fiber-tag-seam/README.md", + "remaining": "Independently validate the stated scope or change its producer/consumer premise and pay the complete boundary.", + "status": "author-checked", + "source_commit": "4ffcdaee5d6255a9cea1fe53a5424435068089d0", + "selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129" + }, + { + "scope": "Selected PR5599: complete helper-subspace construction and independent caller replay; five framework assumptions remain.", + "evidence": "docs/research/pr-intake-evidence/pr5599-completion/PROOF-REVIEW.md", + "remaining": "The next experiment must identify uncovered source-specific work. Successor archive intake does not transfer this admission.", + "status": "reviewed", + "source_commit": "09dd0965711ca7eeb169057a420abab1c9052137", + "selected_record_sha256": "2a0220e866417774606e0f991e41b9c1d26b1f43b97857238cf478dbc7d330b5" + } + ] + }, + "scope_status": "changed", + "actual_scope": "Follow-up to #7606/#7607/#7608 collecting the P104 results logged after #7606 (Nov 14): (1) lossless owned CLEAR content is free under owned_erasure and every CLEAR of an endpoint-exact word is lossless, with exact certificates for #7608's CLEAR #44 and for the clear-form-gap candidate (Q1 YES); (2) the r_max < k_min compiler hypothesis applies after strictification and the gate passes for #7546/#7605/#7608; (3) t = -1 toys: F2^3 decided by two independent proofs (Pin/DNL/Charge; Forwarding/Union/Duality), F2^4 survivors refuted by the Pocket Lemma; (4) 8 hubs realise the cut floor M = 72 on P104 (conjecture M >= n false in the frame model) but the V-funnel lemma forces a rank-96 public layer; (5) caller theory: Crossing and Floor Lemmas, B optimal among nested two-arm layouts, junk role = rho = 3, rho >= 3 no gain, beta = 4g+2, nesting proved at outermost/innermost stages only; (6) decoders: residual identity (C >= n odd denominators, >= 16 half level), h = 10 decoder 57, mod-3/fooling/lifted negatives, E8 odd-graph facts; (7) shape/framework: kappa bounded, Delta kappa = 0 under self-application, one outer level optimal; (8) radix 3 / spec challenge: endpoint wrappers exist in odd radix but Lemma Z keeps the per-port +1, decoder target H forces c >= v; (9) scoped negatives; plus explicit corrections of our earlier statements.", + "scope_change_reason": "The card asks for a constructive helper-basis or causal-split improvement. This package records theorems, scoped negative results and corrections on P104 (no kappa claim, no word) so that others can see which caller, decoder, t = -1, radix and framework routes are closed and why, and it discharges the CLEAR-content premise of #7608.", + "bottleneck_link": "The P104 invoice's fixed costs (owned decoder mass, the per-port odd unit, the caller header) are what every proposed redesign has hit; this package proves where they come from (Crossing/Floor lemmas, residual identity, Lemma Z, target H) and which escapes remain open.", + "budget_minutes": 240, + "stop_rule": "Every proved claim has a proof in PROOF.md; every finite fact quoted as [C] is re-run by a standard-library checker with positive and negative controls; lane-only numbers are tagged [C-lane] or [C-param]; open items stated as open; work in progress excluded; validator PASS.", + "outcome": "negative-result", + "evidence": "README.md, PROOF.md, clearform.py, sepgate.py, toy4.py, labels.py, oddradix.py, data/, VERIFY.json.", + "author": "DreamingOfClouds", + "ai_assistance": "Claude Opus 5.5 (Anthropic), via Claude Code; some lanes are DreamingOfClouds' outside-session lanes (see NOTICE).", + "open_questions": [ + { + "question": "Are interior stages of two-arm callers nested (b_k = 0 for 1 < k < m-1)?", + "why_it_matters": "B's optimality beyond the nested family and the arm-top part of beta = 34 rest on it.", + "first_step": "Exact L = 5 two-arm search with one dying role at stage 2, then extend DYINGGEN Theorem 1 by induction.", + "blocked_by": "Nothing." + }, + { + "question": "Can a one-plane public partner layer deliver (G/2 - I)y below 2,817 D0 per call?", + "why_it_matters": "That is the crossing point at which 8 owned hubs (M = 72) would beat the asc56 decoder.", + "first_step": "Price the hub-routed U layer with the flag-free LP and build its cheapest exact instance.", + "blocked_by": "Nothing." + }, + { + "question": "Is there a cancelling tiling of spilled A2/HIT rectangles giving a target-H radix-3 decoder with total cost <= 67 (rho = 2) or <= 71 (rho = 1)?", + "why_it_matters": "It is the last radix-3 escape; every 3-integral decoder costs >= 112.", + "first_step": "Search tilings of the P112 non-orthogonal cells by A2^4-type rectangles with exact F3 ranks.", + "blocked_by": "Nothing." + }, + { + "question": "Is C(103) = 56 on the P104 labels restricted to 103 ports?", + "why_it_matters": "It would make the h = 10 decoder exactly 57.", + "first_step": "Re-run the rank-8 rigidity argument on the 103-port label set.", + "blocked_by": "Nothing." + } + ] +} diff --git a/research/p104-follow-up-findings/VERIFY.json b/research/p104-follow-up-findings/VERIFY.json new file mode 100644 index 0000000000..e46b9e3313 --- /dev/null +++ b/research/p104-follow-up-findings/VERIFY.json @@ -0,0 +1,62 @@ +{ + "schema_version": 1, + "status": "ready", + "python": "3.12", + "requirements": [], + "inputs": [ + "research/p104-6372-clear-form-gap/inputs/candidate-WORD.json.gz", + "research/shared-wire-split-composition/FULL-RESULT.json" + ], + "commands": [ + { + "argv": [ + "{python}", + "-I", + "-B", + "{package}/clearform.py" + ], + "timeout_seconds": 300, + "checks": "Vendored #7605 word (sha256 pinned) + our #7608 edit list (every deleted event matched); exact Fraction replay of both words. Final public rows identical, rank 1501 = n_pub in both (with the Rank lemma: all 74 owned CLEARs lossless); 73/74 erased rows identical, only CLEAR #44 (owned 1557) differs; #7608 row {451:-1,1495:1} = exact 21-term Q-combination of the other live rows (rank 1501), #7605 row = 23-term combination, difference exactly -3/2(x902+x985). clear-form-gap candidate CLEARs 17755/17756 lossless with exact 97-term certificates (other live rank 770 = n_pub). Controls: lossy and lossless 3-register toys; a prepended COPY/zero/CLEAR of token 0 on the real word gives other live rank 1500, no certificate and endpoint rank 1500; a corrupted certificate coefficient is rejected. Prints PASS_CLEARFORM." + }, + { + "argv": [ + "{python}", + "-I", + "-B", + "{package}/sepgate.py" + ], + "timeout_seconds": 60, + "checks": "Decimal (60 digits). #7000 control: gamma and delta at its tested C equal FULL-RESULT.json to 1e-12, kappa root inside its raw bracket. #7546, #7605, #7608 invoices (sha256 pinned): kappa root matches the published kappa, raw r_max = 64 >= k_min = 1, max target < 153, strictification gate passes (alpha < 1, gamma 0.940836 / 0.940920 / 0.940932, delta 0.908148 / 0.908149 / 0.908149 < 31/32). Negative control: paid mass of rank >= 16 scaled by 1.10 fails the gate. Prints PASS_SEPARATION_GATE." + }, + { + "argv": [ + "{python}", + "-I", + "-B", + "{package}/toy4.py" + ], + "timeout_seconds": 60, + "checks": "Exact enumeration on F2^3, labels 1,2,4,7: 16 frames, 460 up-sets, 8,261 owned multisets of climb 3, 13 pass every births cut, Charge Corollary blocks all 13 (port 7); labels 1,2,7 climb 2: 1 cut-feasible set, blocked. Controls: 4 line feeders pass the cuts and are not blocked, 0 owned fails the cuts; climb 4: 2,074 cut-feasible, 240 blocked (non-vacuous), feeders not blocked; exact Fraction replay of the 4-feeder program (exact, owned climb 4); the duality map permutes the 13 climb-3 sets. Prints PASS_TOY4_DECISION." + }, + { + "argv": [ + "{python}", + "-I", + "-B", + "{package}/labels.py" + ], + "timeout_seconds": 60, + "checks": "Exact (stdlib) on data/lines120.json (sha256 pinned): orthogonal (label-odd) graph SRG(120,63,30,36), complement SRG(120,56,28,24); P104 degrees 55 / 48, 5,720 odd and 4,992 non-orthogonal cells; Q = A+I GF(2) rank 9, rational rank 120 / 104 (two primes agree), G mod 2 GF(2) rank 8; 2,025 orthogonal 8-frames, no 9-clique, each orthogonal pair in 15, all span dim 4, 759 inside P104; max pairwise-odd and pairwise-even sets on P104 = 8; exact cover of P104 by 13 disjoint frames with M = sum 1_F 1_F^T zero on all non-orthogonal cells; G104 rank 8, diagonal 2, 0 on odd cells, +-1 on non-orthogonal cells. Controls: flipped label breaks the SRG parameters, non-frame 8-sets rejected, random 8-sets not a cover. Prints PASS_LABEL_FACTS." + }, + { + "argv": [ + "{python}", + "-I", + "-B", + "{package}/oddradix.py" + ], + "timeout_seconds": 300, + "checks": "Exact. (A) minimal number of rank-1 symmetric terms = rank, or rank+1 iff alternating nonzero over F2: exhaustive (p,m) = (2,2..4),(3,2..3),(5,2..3), 0 mismatches, F2 m=4 table pinned. (B) endpoint wrappers in Z[zeta_p]: K^j = r D_a P_s K D_b for all non-isotropic lines, c, j (p=3 m=1,2,3: 4/4, 16/16, 36/36; p=5 m=1,2: 16/16, 64/64), wrappers commute with K_u for u perp v (12/12, 108/108, 12/12), no solution on isotropic lines, one-sided gauge K^2 not monomial. (C) Lemma Z admissibility (mod 7, k^3 = 1): H3, live planes, QUERY not admissible and QSELF, park1, swap admissible at m = 2, 4, 6, 36; positive controls: products of C3 swap planes reach the split target at cost m (m = 4, 6); m = 2 witness QUERY*H3 costs m+1. Prints PASS_ODD_RADIX." + } + ] +} diff --git a/research/p104-follow-up-findings/clearform.py b/research/p104-follow-up-findings/clearform.py new file mode 100644 index 0000000000..4909f20ae6 --- /dev/null +++ b/research/p104-follow-up-findings/clearform.py @@ -0,0 +1,248 @@ +#!/usr/bin/env python3 +"""CLEARFORM checker: every owned CLEAR of an endpoint-exact word is lossless (Rank lemma), with exact certificates. + +Own code (DreamingOfClouds with Claude Opus 5.5), standard library only. Data only is read from other authors: + data/base-7605-word.json.gz aliromman's #7605 word (bytes vendored by #7608, sha256 pinned below) + data/edits-7608.json our #7608 edit list (main 902 skips chart 595) + research/p104-6372-clear-form-gap/inputs/candidate-WORD.json.gz pinned candidate of the clear-form-gap package (data only) + +Checks + 1. #7608 word = #7605 + edit list (every deleted event matches). Exact Fraction replay of both words. + 2. CLEAR #44 (owned 1557, chart 595): the #7608 row {451:-1, 1495:1} and the #7605 row {451:-1, 902:-3/2, 985:-3/2, 1495:1} + are exact Q-combinations of the other live rows (21 and 23 terms); the two certificates differ by exactly -3/2(x902 + x985). + 3. All 74 owned CLEARs (73 dirty) of both words are lossless: the final public rows have rank 1501 = n_pub, and by the + Rank lemma (PROOF 1.1) the live rank never rises, so no CLEAR lowered it. 73 of the 74 erased rows are identical in + the two words; only CLEAR #44 differs. + 4. Swarm question Q1 (clear-form-gap): CLEARs 17755 and 17756 of the pinned candidate are lossless (other live rank 770 = n_pub), + with exact certificates. + Controls: a 3-register toy whose CLEAR is lossy is detected; a prepended COPY/zero/CLEAR of token 0 through owned 1557 makes a real-word CLEAR lossy + (other live rank 1500, endpoint rank 1500) and is detected; a corrupted certificate coefficient is rejected. +Prints PASS_CLEARFORM. +""" +import gzip, hashlib, json, os, sys +from fractions import Fraction as Q + +HERE = os.path.dirname(os.path.abspath(__file__)) +ROOT = os.path.abspath(os.path.join(HERE, '..', '..')) +P = (1 << 61) - 1 +PINS = { + 'data/base-7605-word.json.gz': '37358c493d18ebc6be386aebb4c17529b38883674731f7009ef4e96a5313467d', + 'data/edits-7608.json': '21516f556cfc8dca1e9a6938aca6a6e9453f7c7b8691324efdb634636343ff0a', +} +GAP = 'research/p104-6372-clear-form-gap/inputs/candidate-WORD.json.gz' +GAP_SHA = None # filled from SOURCES.json at run time + + +def fail(msg): + print('FAIL:', msg); sys.exit(1) + + +def expect(name, got, want): + ok = got == want + print(('ok ' if ok else 'FAIL ') + name + ': ' + str(got)) + if not ok: + fail('%s: got %r want %r' % (name, got, want)) + + +def raw(path, sha): + b = open(path, 'rb').read() + h = hashlib.sha256(b).hexdigest() + if sha is not None and h != sha: + fail('sha256 mismatch for %s: %s' % (path, h)) + return b + + +def load_gz(b): return json.loads(gzip.decompress(b)) + + +def apply_edits(program, E): + if len(program) != E['base_events']: fail('edit list base length') + dele = {} + for i, ev in E['delete']: + if program[i] != ev: fail('deleted event %d does not match' % i) + dele[i] = ev + ins = {} + for i, evs in E['insert_before']: ins.setdefault(i, []).extend(evs) + out = [] + for i, ev in enumerate(program): + out.extend(ins.get(i, [])) + if i not in dele: out.append(ev) + out.extend(ins.get(len(program), [])) + return out + E['append'] + + +def replay(W, program=None, want=()): + """Exact replay of the scalar projection. Returns (final rows, clears=[(event, field, erased row, others-snapshot)]). + The snapshot of the other live rows is taken only for CLEAR events listed in `want` (else None).""" + prog = W['program'] if program is None else program + n = W['public'] + rows = [{r: Q(1)} if r < n else {} for r in range(n + W['owned_fields'])] + live = set(range(n)); clears = [] + for i, e in enumerate(prog): + op, r = e[0], e[1] + if op == 'INIT': + if rows[r] or r in live: fail('INIT on live field') + live.add(r) + elif op == 'CLEAR': + snap = {k: dict(rows[k]) for k in live if k != r} if i in want else None + clears.append((i, r, dict(rows[r]), snap)) + rows[r] = {}; live.discard(r) + elif op == 'SCALE': + c = Q(e[2]) + if c == 0: fail('zero SCALE') + rows[r] = {k: v * c for k, v in rows[r].items()} + elif op in ('ADD', 'COPY'): + if op == 'COPY' and rows[r]: fail('COPY into nonzero field') + c = Q(e[3]); R = rows[r] + for k, v in list(rows[e[2]].items()): + nv = R.get(k, 0) + c * v + if nv: R[k] = nv + else: R.pop(k, None) + elif op != 'MOVE': + fail('unknown op ' + str(op)) + return rows, clears + + +def modp(x): return x.numerator % P * pow(x.denominator % P, P - 2, P) % P + + +def echelon(vecs): + """mod-p echelon with combination tracking; returns pivots {col: (row, combo)}.""" + piv = {} + for idx, v in enumerate(vecs): + w = {k: modp(c) for k, c in v.items()}; w = {k: a for k, a in w.items() if a}; combo = {idx: 1} + while w: + c = min(w) + if c not in piv: break + pr, pc = piv[c]; f = w[c] + for k, a in pr.items(): + t = (w.get(k, 0) - f * a) % P + if t: w[k] = t + else: w.pop(k, None) + for k, a in pc.items(): + t = (combo.get(k, 0) - f * a) % P + if t: combo[k] = t + else: combo.pop(k, None) + if w: + c = min(w); inv = pow(w[c], P - 2, P) + piv[c] = ({k: a * inv % P for k, a in w.items()}, {k: a * inv % P for k, a in combo.items()}) + return piv + + +def member(piv, target): + w = {k: modp(c) for k, c in target.items()}; w = {k: a for k, a in w.items() if a}; combo = {} + while w: + c = min(w) + if c not in piv: return None + pr, pc = piv[c]; f = w[c] + for k, a in pr.items(): + t = (w.get(k, 0) - f * a) % P + if t: w[k] = t + else: w.pop(k, None) + for k, a in pc.items(): + combo[k] = (combo.get(k, 0) + f * a) % P + return {k: a for k, a in combo.items() if a} + + +def ratrec(a): + r0, r1, s0, s1 = P, a, 0, 1 + B = int((P // 2) ** 0.5) + while r1 > B: + q = r0 // r1; r0, r1, s0, s1 = r1, r0 - q * r1, s1, s0 - q * s1 + return Q(r1, s1) if s1 else None + + +def certificate(snap, target): + """Exact certificate: dict field -> Fraction with sum c_k row_k == target, or None. Also the rank of the snapshot.""" + keys = sorted(snap); piv = echelon([snap[k] for k in keys]) + combo = member(piv, target) + if combo is None: return len(piv), None + cert = {keys[i]: ratrec(a) for i, a in combo.items()} + if any(v is None for v in cert.values()): return len(piv), None + return len(piv), cert + + +def verify_cert(snap, cert, target): + s = {} + for k, c in cert.items(): + for t, v in snap[k].items(): s[t] = s.get(t, 0) + c * v + return {t: v for t, v in s.items() if v} == {t: v for t, v in target.items() if v} + + +def toy_controls(): + # 2 public tokens, 1 owned field 2. Lossy: copy x0 into owned, zero public 0 using it, CLEAR owned. + W = {'public': 2, 'owned_fields': 1, 'program': [['INIT', 2], ['COPY', 2, 0, '1'], ['ADD', 0, 2, '-1'], ['CLEAR', 2]]} + _, cl = replay(W, None, {3}); i, r, t, snap = cl[0] + rk, cert = certificate(snap, t) + expect('toy control (lossy CLEAR): rank of other live rows / certificate exists', (rk, cert is not None), (1, False)) + W['program'] = [['INIT', 2], ['COPY', 2, 0, '1'], ['ADD', 1, 2, '1'], ['CLEAR', 2]] + _, cl = replay(W, None, {3}); i, r, t, snap = cl[0] + rk, cert = certificate(snap, t) + expect('toy control (lossless CLEAR): rank / certificate verified', (rk, cert is not None and verify_cert(snap, cert, t)), (2, True)) + + +def main(): + global GAP_SHA + src = json.load(open(os.path.join(HERE, 'SOURCES.json'))) + for f in src['files']: + if f['path'] == GAP: GAP_SHA = f['sha256'] + if GAP_SHA is None: fail('gap candidate not pinned in SOURCES.json') + toy_controls() + base = load_gz(raw(os.path.join(HERE, 'data/base-7605-word.json.gz'), PINS['data/base-7605-word.json.gz'])) + E = json.loads(raw(os.path.join(HERE, 'data/edits-7608.json'), PINS['data/edits-7608.json'])) + newprog = apply_edits(base['program'], E) + expect('edit list applies to #7605 (events before / after)', (len(base['program']), len(newprog)), (76636, 76631)) + n = base['public'] + rows_o, cl_o = replay(base, None, {42713}) + rows_n, cl_n = replay(base, newprog, {42708}) + expect('final public rows identical in #7605 and #7608', all(rows_o[r] == rows_n[r] for r in range(n)), True) + expect('owned fields all empty at the end (both words)', + (all(not rows_o[r] for r in range(n, len(rows_o))), all(not rows_n[r] for r in range(n, len(rows_n)))), (True, True)) + expect('CLEAR counts (#7605, #7608) and dirty counts', (len(cl_o), len(cl_n), sum(bool(c[2]) for c in cl_o), + sum(bool(c[2]) for c in cl_n)), (74, 74, 73, 73)) + diffs = [j for j in range(74) if cl_o[j][1] != cl_n[j][1] or cl_o[j][2] != cl_n[j][2]] + expect('CLEARs whose (field, erased row) differ between the words (0-based CLEAR index)', diffs, [44]) + j = 44 + io, fo, to, so = cl_o[j]; inn, fn, tn, sn = cl_n[j] + expect('CLEAR #44: field, #7605 event, #7608 event', (fo, fn, io, inn), (1557, 1557, 42713, 42708)) + expect('#7608 erased row', {k: str(v) for k, v in sorted(tn.items())}, {451: '-1', 1495: '1'}) + expect('#7605 erased row', {k: str(v) for k, v in sorted(to.items())}, {451: '-1', 902: '-3/2', 985: '-3/2', 1495: '1'}) + rkn, cn = certificate(sn, tn); rko, co = certificate(so, to) + expect('#7608 CLEAR #44: other live rows, rank, certificate verified over Q, terms', + (len(sn), rkn, cn is not None and verify_cert(sn, cn, tn), len(cn or {})), (1525, 1501, True, 21)) + expect('#7605 CLEAR #44: other live rows, rank, certificate verified over Q, terms', + (len(so), rko, co is not None and verify_cert(so, co, to), len(co or {})), (1525, 1501, True, 23)) + d = {k: co.get(k, 0) - cn.get(k, 0) for k in set(co) | set(cn)} + d = {k: str(v) for k, v in sorted(d.items()) if v} + expect('certificate difference (#7605 - #7608)', d, {902: '-3/2', 985: '-3/2'}) + bad = dict(cn); k0 = min(bad); bad[k0] += 1 + expect('negative control: corrupted certificate coefficient rejected', verify_cert(sn, bad, tn), False) + print(' #7608 certificate:', {k: str(v) for k, v in sorted(cn.items())}) + # all CLEARs, both words: by the Rank lemma (PROOF 1.1) the live rank never rises, so rank n_pub of the final public + # rows proves that no CLEAR lowered it, i.e. all 74 CLEARs are lossless. Checked mod p (prime 2^61-1). + for name, rows in (('#7605', rows_o), ('#7608', rows_n)): + expect(name + ': rank of the 1501 final public rows (=> every CLEAR lossless)', len(echelon(rows[:n])), n) + # real-word negative control (scalar model): prepend INIT 1557, COPY 1557 <- register 0, ADD 0 += -1557, CLEAR 1557. + # The CLEAR erases the only copy of token 0, so it is lossy and the endpoint becomes singular. + mut = [['INIT', 1557], ['COPY', 1557, 0, '1', 3], ['ADD', 0, 1557, '-1', 3], ['CLEAR', 1557]] + newprog + rows_m, clm = replay(base, mut, {3}) + i2, f2, t2, s2 = clm[0] + rk2 = len(echelon(list(s2.values()))) + _, c2 = certificate(s2, t2) + expect('negative control: prepended lossy CLEAR -> event, other live rank, certificate, final public rank', + (i2, rk2, c2 is not None, len(echelon(rows_m[:n]))), (3, 1500, False, 1500)) + # swarm Q1 + g = load_gz(raw(os.path.join(ROOT, GAP), GAP_SHA)) + _, clg = replay(g, None, {17755, 17756}) + for ev in (17755, 17756): + hit = [c for c in clg if c[0] == ev] + i, r, t, snap = hit[0] + rk, cert = certificate(snap, t) + expect('clear-form-gap candidate CLEAR %d (field %d): nonzero row, other live rank (n_pub %d), certificate verified, terms' + % (ev, r, g['public']), (bool(t), rk, cert is not None and verify_cert(snap, cert, t), len(cert or {})), + (True, g['public'], True, 97)) + print('PASS_CLEARFORM') + + +if __name__ == '__main__': + main() diff --git a/research/p104-follow-up-findings/data/base-7605-word.json.gz b/research/p104-follow-up-findings/data/base-7605-word.json.gz new file mode 100644 index 0000000000..0527ed3076 Binary files /dev/null and b/research/p104-follow-up-findings/data/base-7605-word.json.gz differ diff --git a/research/p104-follow-up-findings/data/edits-7608.json b/research/p104-follow-up-findings/data/edits-7608.json new file mode 100644 index 0000000000..eed30fa786 --- /dev/null +++ b/research/p104-follow-up-findings/data/edits-7608.json @@ -0,0 +1 @@ +{"base_events":76636,"delete":[[38292,["MOVE",902,3,595,false]],[38293,["ADD",1532,902,"2",595]],[38582,["ADD",1479,902,"-1/2",595]],[38583,["ADD",1255,902,"-1",595]],[38584,["ADD",1495,902,"-3/2",595]],[38586,["MOVE",902,595,618,false]]],"insert_before":[[38292,[["MOVE",902,3,618,false]]]],"append":[]} \ No newline at end of file diff --git a/research/p104-follow-up-findings/data/invoice-7546.json b/research/p104-follow-up-findings/data/invoice-7546.json new file mode 100644 index 0000000000..f496503472 --- /dev/null +++ b/research/p104-follow-up-findings/data/invoice-7546.json @@ -0,0 +1 @@ +{"schema": "integer-mult-recursive-invoice/v1", "contract": {"model": "mixed-target-unnormalized-power-v1", "rank_semantics": "H_r costs r^(1-C); debit surrendered productive fields", "ambient_rank": 145, "boundary": "complete signed #7113 caller application with 17 native calls"}, "paid": {"1": 68367, "2": 14484, "3": 14059, "4": 3791, "5": 5831, "6": 272, "7": 187, "8": 741, "9": 32, "16": 416, "24": 416, "32": 416, "40": 416, "48": 416, "56": 416, "64": 208}, "targets": {"1": 306, "2": 357, "3": 799, "4": 3825, "5": 1360, "6": 731, "7": 323, "8": 544, "9": 10888, "17": 416, "25": 416, "33": 416, "41": 416, "49": 416, "57": 416, "65": 416, "73": 208, "137": 208}} \ No newline at end of file diff --git a/research/p104-follow-up-findings/data/invoice-7605.json b/research/p104-follow-up-findings/data/invoice-7605.json new file mode 100644 index 0000000000..7f710a6a08 --- /dev/null +++ b/research/p104-follow-up-findings/data/invoice-7605.json @@ -0,0 +1,47 @@ +{ + "schema": "integer-mult-recursive-invoice/v1", + "contract": { + "model": "mixed-target-unnormalized-power-v1", + "rank_semantics": "H_r costs r^(1-C); debit surrendered productive fields", + "ambient_rank": 145, + "boundary": "complete signed #7113 caller application with 17 native calls" + }, + "paid": { + "1": 68265, + "2": 14433, + "3": 14076, + "4": 3808, + "5": 5848, + "6": 272, + "7": 187, + "8": 741, + "9": 32, + "16": 416, + "24": 416, + "32": 416, + "40": 416, + "48": 416, + "56": 416, + "64": 208 + }, + "targets": { + "1": 306, + "2": 357, + "3": 799, + "4": 3825, + "5": 1360, + "6": 731, + "7": 323, + "8": 544, + "9": 10888, + "17": 416, + "25": 416, + "33": 416, + "41": 416, + "49": 416, + "57": 416, + "65": 416, + "73": 208, + "137": 208 + } +} diff --git a/research/p104-follow-up-findings/data/invoice-7608.json b/research/p104-follow-up-findings/data/invoice-7608.json new file mode 100644 index 0000000000..0f629caf0c --- /dev/null +++ b/research/p104-follow-up-findings/data/invoice-7608.json @@ -0,0 +1 @@ +{"schema":"integer-mult-recursive-invoice/v1","contract":{"model":"mixed-target-unnormalized-power-v1","rank_semantics":"H_r costs r^(1-C); debit surrendered productive fields","ambient_rank":145,"boundary":"complete signed #7113 caller application with 17 native calls"},"paid":{"1":68248,"2":14416,"3":14093,"4":3808,"5":5848,"6":272,"7":187,"8":741,"9":32,"16":416,"24":416,"32":416,"40":416,"48":416,"56":416,"64":208},"targets":{"1":306,"2":357,"3":799,"4":3825,"5":1360,"6":731,"7":323,"8":544,"9":10888,"17":416,"25":416,"33":416,"41":416,"49":416,"57":416,"65":416,"73":208,"137":208}} \ No newline at end of file diff --git a/research/p104-follow-up-findings/data/lines120.json b/research/p104-follow-up-findings/data/lines120.json new file mode 100644 index 0000000000..5f455d1458 --- /dev/null +++ b/research/p104-follow-up-findings/data/lines120.json @@ -0,0 +1 @@ +{"labels":[11,19,35,131,259,13,21,37,69,133,261,41,73,265,49,145,161,193,321,385,14,22,38,70,134,26,74,138,50,146,274,194,322,386,28,44,140,84,148,276,100,292,196,324,388,56,88,152,168,296,200,328,392,112,176,304,208,336,400,224,352,416,508,506,502,494,478,446,382,254,505,501,493,477,445,381,253,499,475,443,379,251,487,471,439,375,247,463,431,367,239,415,351,223,319,191,81,98,164,262,268,273,280,290,42,266,25,137,7,67,448,104,76,82,162,97,289,127,52,491],"gram":[[2,-1,-1,1,1,-1,0,0,0,0,0,1,-1,-1,0,0,0,0,0,0,-1,0,0,0,0,-1,1,1,0,0,0,0,0,0,0,0,0,-1,-1,-1,1,1,1,-1,1,0,0,0,0,0,0,0,0,-1,1,1,1,1,1,1,1,-1,0,1,0,1,1,1,-1,1,1,0,-1,-1,-1,-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-1,1,1,0,0,0,0,0,0,0,1,0,1,1,0,0,0,1,0,-1,-1,0,0,0,1,0,1,-1,1,1,1,0,0,0,0,1,1,1,1,-1,1,0,0,0,0,1,0,0,0,0,0,0,-1,0,1,0,1,-1,0,0,0,0,0,0,0,2,0],[0,-1,0,0,0,1,0,1,1,-1,-1,0,0,0,1,-1,0,0,0,0,1,0,-1,-1,-1,-1,0,0,1,-1,1,0,0,0,0,-1,1,0,0,0,1,1,1,-1,1,1,1,1,0,0,0,0,0,1,-1,-1,-1,-1,-1,0,0,0,0,1,0,-1,0,0,0,0,1,0,1,0,0,0,0,1,-1,1,-1,1,-1,0,0,0,0,-1,-1,-1,-1,0,0,0,0,0,-1,0,1,-1,-1,-1,1,0,0,0,1,0,1,0,0,0,1,-1,0,0,0,0,0,2]]} \ No newline at end of file diff --git a/research/p104-follow-up-findings/labels.py b/research/p104-follow-up-findings/labels.py new file mode 100644 index 0000000000..54fb2b2752 --- /dev/null +++ b/research/p104-follow-up-findings/labels.py @@ -0,0 +1,244 @@ +#!/usr/bin/env python3 +"""LABELS checker: exact label/graph facts of the 120 E8 lines and the P104 port set. Tags: [C] exact. + +Own code (DreamingOfClouds with Claude Opus 5.5), standard library only. data/lines120.json (sha256 pinned below) is our +derived data from the PR968 P104 decoder input (research/complex-frame-pair-decoders/inputs/pr717/P104_HIT_flip_3a.txt), +as in #7583/#7606: 120 F2^9 labels (first 104 = P104 ports) and the integer Gram of the 120 E8 lines. +Convention: label dot q.q' = popcount(q&q') mod 2; "odd" cells (dot 1) are exactly the integer-orthogonal pairs (G=0). + +Checks + 1. Orthogonality (label-odd) graph on 120 is SRG(120,63,30,36), complement SRG(120,56,28,24) (direct counting; this corrects + LITSWEEP2's parameters); on P104 degrees 55 (orthogonal) and 48 (non-orthogonal); 104*55 = 5720 odd cells. + 2. Ranks: Q = A_odd + I has GF(2) rank 9 and rational rank 120 (120x120) / 104 (P104; exact mod two large primes); + G mod 2 has GF(2) rank 8. + 3. Orthogonal 8-frames: 2025 8-cliques on 120 lines, each orthogonal pair in exactly 15; max clique 8 (no 9-clique); + 759 frames inside P104; every frame's labels span a dim-4 F2 subspace. + 4. In P104 the max pairwise-odd set and the max pairwise-even set both have size 8. + 5. P104 is an exact cover by 13 pairwise-disjoint orthogonal 8-frames (found by DFS); M = sum 1_F 1_F^T has diagonal 1 and + is zero on all 4992 ordered non-orthogonal off-diagonal cells. + 6. G104 (104x104 Gram block): integer, rational rank 8, diagonal 2, 0 on all 5720 odd cells, +-1 on all 4992 non-orthogonal + cells; alpha = 8 = rank, so the minimum hub count is 8 (numbers only). + Controls: a one-label perturbation breaks the SRG parameters; a non-frame 8-set fails the clique test; a random 8-set is not a cover. +Prints PASS_LABEL_FACTS. +""" +import hashlib, json, os, random, sys + +HERE = os.path.dirname(os.path.abspath(__file__)) +PIN = '4a91033b56fe23feb897b90e6259b33dfbe428ff07ad7ce511a73835074f2708' +P1, P2 = (1 << 61) - 1, (1 << 31) - 1 + + +def fail(msg): + print('FAIL:', msg); sys.exit(1) + + +def expect(name, got, want): + ok = got == want + print(('ok ' if ok else 'FAIL ') + name + ': ' + str(got)) + if not ok: + fail('%s: got %r want %r' % (name, got, want)) + + +b = open(os.path.join(HERE, 'data', 'lines120.json'), 'rb').read() +if hashlib.sha256(b).hexdigest() != PIN: + fail('sha256 mismatch for lines120.json') +D = json.loads(b) +L, G = D['labels'], D['gram'] +N, NP = 120, 104 + + +def dot(a, c): return bin(a & c).count('1') & 1 + + +def adj_masks(labels, odd=True): + n = len(labels) + return [sum(1 << j for j in range(n) if j != i and (dot(labels[i], labels[j]) == 1) == odd) for i in range(n)] + + +def pc(x): return bin(x).count('1') + + +def srg(masks): + """return (set of degrees, set of lambda, set of mu) by direct counting""" + n = len(masks) + deg, lam, mu = set(), set(), set() + for i in range(n): + deg.add(pc(masks[i])) + for j in range(i + 1, n): + c = pc(masks[i] & masks[j]) + (lam if masks[i] >> j & 1 else mu).add(c) + return deg, lam, mu + + +def rank_f2(rows): + basis = [] + for r in rows: + for v in basis: + r = min(r, r ^ v) + if r: + basis.append(r) + return len(basis) + + +def rank_mod(M, p): + M = [[x % p for x in r] for r in M] + rk = 0 + nc = len(M[0]) + for c in range(nc): + piv = next((i for i in range(rk, len(M)) if M[i][c]), None) + if piv is None: continue + M[rk], M[piv] = M[piv], M[rk] + inv = pow(M[rk][c], p - 2, p) + M[rk] = [x * inv % p for x in M[rk]] + for i in range(len(M)): + if i != rk and M[i][c]: + f = M[i][c] + M[i] = [(x - f * y) % p for x, y in zip(M[i], M[rk])] + rk += 1 + return rk + + +def rrank(M): + a, b2 = rank_mod(M, P1), rank_mod(M, P2) + if a != b2: fail('rank disagreement mod primes %d %d' % (a, b2)) + return a + + +def cliques(masks, size, within=None): + """all `size`-cliques as tuples (bitset recursion, ascending order)""" + n = len(masks) + out = [] + full = (1 << n) - 1 if within is None else within + + def rec(cur, cand): + if len(cur) == size: + out.append(tuple(cur)); return + while cand: + v = (cand & -cand).bit_length() - 1 + cand &= cand - 1 + rec(cur + [v], cand & masks[v]) + rec([], full) + return out + + +def max_clique(masks, within=None): + best = [0] + n = len(masks) + + def rec(size, cand): + if size > best[0]: best[0] = size + while cand: + if size + pc(cand) <= best[0]: return + v = (cand & -cand).bit_length() - 1 + cand &= cand - 1 + rec(size + 1, cand & masks[v]) + rec(0, (1 << n) - 1 if within is None else within) + return best[0] + + +# ---- data sanity +expect('shape', (len(L), len(G), len(G[0])), (120, 120, 120)) +expect('symmetric Gram', all(G[i][j] == G[j][i] for i in range(N) for j in range(N)), True) +expect('diag G = 2', {G[i][i] for i in range(N)}, {2}) +expect('G entries', sorted({x for r in G for x in r}), [-1, 0, 1, 2]) +expect('labels in F2^9', all(0 <= q < 512 for q in L), True) +expect('label-odd == (G=0) off-diagonal', + all((dot(L[i], L[j]) == 1) == (G[i][j] == 0) for i in range(N) for j in range(N) if i != j), True) + +# ---- 1. SRG +odd = adj_masks(L, True) +even = adj_masks(L, False) +expect('1 odd graph (deg, lambda, mu)', tuple(map(sorted, srg(odd))), ([63], [30], [36])) +expect('1 even graph (deg, lambda, mu)', tuple(map(sorted, srg(even))), ([56], [28], [24])) +P = (1 << NP) - 1 +oddP = [m & P for m in odd[:NP]] +evenP = [m & P for m in even[:NP]] +expect('1 P104 odd degrees', sorted({pc(m) for m in oddP}), [55]) +expect('1 P104 non-orthogonal degrees', sorted({pc(m) for m in evenP}), [48]) +expect('1 odd cells on P104', sum(pc(m) for m in oddP), 5720) +expect('1 non-orthogonal ordered cells on P104', sum(pc(m) for m in evenP), 4992) + +# control: perturb one label +Lp = list(L); Lp[7] ^= 0b100000001 +bad = adj_masks(Lp, True) +expect('1 control: flipped label breaks SRG', tuple(map(sorted, srg(bad))) == ([63], [30], [36]), False) + +# ---- 2. ranks +Qm = [[(1 if (i == j or odd[i] >> j & 1) else 0) for j in range(N)] for i in range(N)] +expect('2 Q GF(2) rank (120)', rank_f2([sum(Qm[i][j] << j for j in range(N)) for i in range(N)]), 9) +expect('2 Q rational rank (120)', rrank(Qm), 120) +QP = [r[:NP] for r in Qm[:NP]] +expect('2 Q GF(2) rank (P104)', rank_f2([sum(r[j] << j for j in range(NP)) for r in QP]), 9) +expect('2 Q rational rank (P104)', rrank(QP), 104) +expect('2 G mod 2 GF(2) rank', rank_f2([sum((x & 1) << j for j, x in enumerate(r)) for r in G]), 8) + +# ---- 3. frames +fr = cliques(odd, 8) +expect('3 number of 8-cliques of odd graph', len(fr), 2025) +expect('3 no 9-clique (max clique)', max_clique(odd), 8) +cnt = {} +for f in fr: + for a in range(8): + for c in range(a + 1, 8): + cnt[(f[a], f[c])] = cnt.get((f[a], f[c]), 0) + 1 +expect('3 odd pairs covered by frames', len(cnt), 120 * 63 // 2) +expect('3 frames per orthogonal pair', sorted(set(cnt.values())), [15]) +expect('3 frame label span dims', sorted({rank_f2([L[v] for v in f]) for f in fr}), [4]) +frP = [f for f in fr if f[-1] < NP] +expect('3 frames inside P104', len(frP), 759) +nonframe = (0, 1, 2, 3, 4, 5, 6, 7) +expect('3 control: non-frame 8-set fails clique test', + all(odd[a] >> c & 1 for a in nonframe for c in nonframe if a != c) or nonframe in set(fr), False) +expect('3 control: a true frame passes', all(odd[a] >> c & 1 for a in fr[0] for c in fr[0] if a != c), True) + +# ---- 4. alpha +expect('4 max pairwise-odd set in P104', max_clique(oddP, P), 8) +expect('4 max pairwise-even set in P104', max_clique(evenP, P), 8) + +# ---- 5. exact cover +byel = [[] for _ in range(NP)] +fm = [sum(1 << v for v in f) for f in frP] +for k, m in enumerate(fm): + for v in frP[k]: + byel[v].append(k) + + +def cover(mask, chosen): + if mask == P: return chosen + v = (~mask & P & (mask + 1)).bit_length() - 1 # lowest uncovered + for k in byel[v]: + if not fm[k] & mask: + r = cover(mask | fm[k], chosen + [k]) + if r: return r + return None + + +ch = cover(0, []) +if ch is None: fail('no exact cover found') +expect('5 exact cover size', len(ch), 13) +expect('5 cover disjoint & complete', sorted(v for k in ch for v in frP[k]) == list(range(NP)), True) +M = [[0] * NP for _ in range(NP)] +for k in ch: + for a in frP[k]: + for c in frP[k]: + M[a][c] += 1 +expect('5 M diagonal', {M[i][i] for i in range(NP)}, {1}) +nonorth = [(i, j) for i in range(NP) for j in range(NP) if i != j and not oddP[i] >> j & 1] +expect('5 non-orthogonal ordered cells', len(nonorth), 4992) +expect('5 M zero on all non-orthogonal cells', {M[i][j] for i, j in nonorth}, {0}) +rnd = random.Random(1) +rs = rnd.sample(range(NP), 8) +expect('5 control: random 8-set is not a frame', all(oddP[a] >> c & 1 for a in rs for c in rs if a != c), False) +expect('5 control: 13 random 8-sets are not a cover', + sorted(sum((rnd.sample(range(NP), 8) for _ in range(13)), [])) == list(range(NP)), False) + +# ---- 6. G104 +G104 = [r[:NP] for r in G[:NP]] +expect('6 G104 rational rank', rrank(G104), 8) +expect('6 G104 diagonal', {G104[i][i] for i in range(NP)}, {2}) +oddcells = [(i, j) for i in range(NP) for j in range(NP) if i != j and oddP[i] >> j & 1] +expect('6 G104 zero on odd cells (count)', (len(oddcells), {G104[i][j] for i, j in oddcells}), (5720, {0})) +expect('6 G104 +-1 on non-orthogonal cells', (len(nonorth), sorted({G104[i][j] for i, j in nonorth})), (4992, [-1, 1])) +expect('6 alpha = rank = hub count', (max_clique(oddP, P), rrank(G104)), (8, 8)) + +print('PASS_LABEL_FACTS') diff --git a/research/p104-follow-up-findings/oddradix.py b/research/p104-follow-up-findings/oddradix.py new file mode 100644 index 0000000000..d5814704d7 --- /dev/null +++ b/research/p104-follow-up-findings/oddradix.py @@ -0,0 +1,300 @@ +#!/usr/bin/env python3 +"""ODDRADIX checker: odd-radix framework facts (symmetric rank-1 counts, endpoint wrapper identity, Lemma Z admissibility). + +Own code (DreamingOfClouds with Claude Opus 5.5), standard library only. Tags: [C] exact computation. +Lemma Z and the endpoint lemma are proved in PROOF.md; this script only checks instances. The exhaustive m=4 search +(548,000 rank-1 unit conjugates) and the m=2 complete tables over F_7/F_13 are lane computations not re-run here ([C-lane]). + +Checks + A. Minimal number of rank-1 symmetric terms c v v^T summing to a symmetric B over F_p equals rank B, except over F_2 where + it is rank B + 1 exactly when B is alternating and nonzero. Exhaustive BFS over all symmetric m x m matrices for + (p,m) in (2,2),(2,3),(2,4),(3,2),(3,3),(5,2),(5,3); 0 mismatches; F_2 m=4 table asserted. + B. Endpoint wrapper identity in exact Z[zeta_p] arithmetic: for every non-isotropic line v, c != 0, j != 0: + K_{v,c}^j = r D_a P_s K_{v,c} D_b (r = +-zeta^k). p=3 m=1 (4/4), p=3 m=2 (16/16), p=5 m=1 (16/16); + T2 wrappers along v commute with K_u for u perp v (p=3 m=2: 12/12); T5 K^2 is not monomial. + Default run also does p=3 m=3 (36/36, T2 108/108, T3) and p=5 m=2 (64/64, T2 12/12, T3); --quick skips those two (~3 s total). + T3: on an isotropic line no wrapper of this form exists (checked where an isotropic line exists: p=3 m=3 and p=5 m=2). + C. Lemma Z (parts a, e, f of the lane check) in pure-python mod-7 matrices, polynomials in k mod k^3 - 1, omega = 2: + admissibility table rank(u_0) vs m - o for H3 park, live planes, QUERY, QSELF, park1, C3 swap (m = 2, 4, 6, 36); + positive control (product of m/2 C3 swap planes under a random conjugation reaches the split target at cost m); + witness QUERY(row0 += -k row1) * H3 at m = 2 has cost m+1 = 3 and is a split target. +Prints PASS_ODD_RADIX. +""" +import itertools, random, sys + + +def fail(msg): + print('FAIL:', msg); sys.exit(1) + + +def expect(name, got, want): + ok = got == want + print(('ok ' if ok else 'FAIL ') + name + ': ' + str(got)) + if not ok: + fail('%s: got %r want %r' % (name, got, want)) + + +# ---------------------------------------------------------------- A +def rank_mod(M, p): + M = [[x % p for x in r] for r in M]; n = len(M); nc = len(M[0]); r = 0 + for c in range(nc): + piv = next((i for i in range(r, n) if M[i][c]), None) + if piv is None: continue + M[r], M[piv] = M[piv], M[r]; inv = pow(M[r][c], p - 2, p) + M[r] = [x * inv % p for x in M[r]] + for i in range(n): + if i != r and M[i][c]: + f = M[i][c]; M[i] = [(a - f * b) % p for a, b in zip(M[i], M[r])] + r += 1 + return r + + +def sqcount(p, m): + idx = [(i, j) for i in range(m) for j in range(i, m)] + terms = set() + for v in itertools.product(range(p), repeat=m): + if any(v): + for c in range(1, p): + terms.add(tuple(c * v[i] * v[j] % p for i, j in idx)) + terms = list(terms) + zero = tuple([0] * len(idx)) + dist = {zero: 0}; frontier = [zero] + while frontier: + nf = [] + for s in frontier: + for t in terms: + u = tuple((a + b) % p for a, b in zip(s, t)) + if u not in dist: dist[u] = dist[s] + 1; nf.append(u) + frontier = nf + bad = 0; stats = {} + for s, k in dist.items(): + M = [[0] * m for _ in range(m)] + for (i, j), x in zip(idx, s): M[i][j] = M[j][i] = x + r = rank_mod(M, p); alt = (p == 2 and all(M[i][i] == 0 for i in range(m)) and r > 0) + pred = r + 1 if alt else r + stats[(r, alt, k)] = stats.get((r, alt, k), 0) + 1 + bad += (k != pred) + return len(dist), bad, dict(sorted(stats.items())) + + +def part_a(): + print('== A. rank-1 symmetric decomposition counts') + for p, m in [(2, 2), (2, 3), (2, 4), (3, 2), (3, 3), (5, 2), (5, 3)]: + n, bad, stats = sqcount(p, m) + print(' p=%d m=%d: tables (rank,alternating,k):count = %s' % (p, m, stats)) + expect('A p=%d m=%d all %d symmetric matrices reached' % (p, m, p ** (m * (m + 1) // 2)), n, p ** (m * (m + 1) // 2)) + expect('A p=%d m=%d mismatches vs prediction' % (p, m), bad, 0) + if (p, m) == (2, 4): + expect('A F2 m=4 table', stats, {(0, False, 0): 1, (1, False, 1): 15, (2, False, 2): 105, (2, True, 3): 35, + (3, False, 3): 420, (4, False, 4): 420, (4, True, 5): 28}) + + +# ---------------------------------------------------------------- B +def wrapaudit(p, M, label_t3=True): + def add(a, b): return tuple(x + y for x, y in zip(a, b)) + def mul(a, b): + r = [0] * p + for i, x in enumerate(a): + if x: + for j, y in enumerate(b): + if y: r[(i + j) % p] += x * y + return tuple(r) + def norm(a): m = a[-1]; return tuple(x - m for x in a) + Z0 = tuple([0] * p) + def zp(k): r = [0] * p; r[k % p] = 1; return tuple(r) + def sc(k, a): return tuple(k * x for x in a) + A = list(itertools.product(range(p), repeat=M)); N = len(A); idx = {a: i for i, a in enumerate(A)} + dot = lambda x, y: sum(i * j for i, j in zip(x, y)) % p + def mm(X, Y): + R = [[Z0] * N for _ in range(N)] + for i in range(N): + Xi = X[i] + for k in range(N): + if Xi[k] != Z0: + xk = Xi[k]; Yk = Y[k] + R[i] = [add(R[i][j], mul(xk, Yk[j])) if Yk[j] != Z0 else R[i][j] for j in range(N)] + return R + def canon(X): return [[norm(e) for e in row] for row in X] + def eq_up_to(X, Y): + cx = canon(X) + for s in (1, -1): + for k in range(p): + if canon([[sc(s, mul(zp(k), e)) for e in row] for row in Y]) == cx: return (s, k) + return None + Fm = [[zp(dot(y, x)) for x in A] for y in A]; Fi = [[zp(-dot(y, x)) for x in A] for y in A] + def diag(f): return [[f(A[i]) if i == j else Z0 for j in range(N)] for i in range(N)] + def kern(v, c): return mm(mm(Fm, diag(lambda x: zp(c * dot(v, x) ** 2))), Fi) + def chirp(v, a): return diag(lambda x: zp(a * dot(v, x) ** 2)) + def Ps(v, s): + if dot(v, v) == 0: f = lambda x: tuple((s * xi) % p for xi in x) + else: + inv = pow(dot(v, v), -1, p) + f = lambda x: tuple((xi + (s - 1) * dot(v, x) * inv * vi) % p for xi, vi in zip(x, v)) + P = [[Z0] * N for _ in range(N)] + for a in A: P[idx[f(a)]][idx[a]] = zp(0) + return P + vecs = [v for v in A if any(v) and next(x for x in v if x) == 1] + noniso = [v for v in vecs if dot(v, v) != 0]; iso = [v for v in vecs if dot(v, v) == 0] + print(' p=%d m=%d: %d non-isotropic lines, %d isotropic lines' % (p, M, len(noniso), len(iso))) + Kc = {} + def K(v, c): + if (v, c) not in Kc: Kc[(v, c)] = kern(v, c % p) + return Kc[(v, c)] + def wrap(v, c, j): + T = K(v, j * c) + for s, a, b in itertools.product(range(1, p), range(p), range(p)): + W = mm(mm(mm(chirp(v, a), Ps(v, s)), K(v, c)), chirp(v, b)) + if eq_up_to(T, W): return (s, a, b) + return None + res = {} + cnt = ok = 0 + for v in noniso: + for c in range(1, p): + for j in range(1, p): + cnt += 1; ok += wrap(v, c, j) is not None + res['T1'] = (ok, cnt) + if iso: + res['T3'] = wrap(iso[0], 1, p - 1) # expected None (no solution) + res['T3line'] = iso[0] + if M >= 2: + c2 = g2 = 0 + for v in noniso: + s, a, b = wrap(v, 1, p - 1) + Ws = [chirp(v, a), chirp(v, b), Ps(v, s)] + for u in vecs: + if u != v and dot(u, v) == 0: + Ku = K(u, 1) + for W in Ws: + c2 += 1; g2 += canon(mm(W, Ku)) == canon(mm(Ku, W)) + res['T2'] = (g2, c2) + G = K(noniso[0], 2) + res['T5'] = max(sum(1 for e in row if norm(e) != Z0) for row in canon(G)) + return res + + +def part_b(quick): + print('== B. endpoint wrapper identity in Z[zeta_p]') + cases = [(3, 1, (4, 4), None, 3), (3, 2, (16, 16), (12, 12), 3), (5, 1, (16, 16), None, 5)] + if not quick: cases += [(3, 3, (36, 36), (108, 108), 3), (5, 2, (64, 64), (12, 12), 5)] + for p, M, t1, t2, t5 in cases: + r = wrapaudit(p, M) + expect('B p=%d m=%d T1 wrapper identity (ok/total)' % (p, M), r['T1'], t1) + if t2: expect('B p=%d m=%d T2 wrappers commute with K_u (ok/total)' % (p, M), r['T2'], t2) + if 'T3' in r: expect('B p=%d m=%d T3 isotropic line %s has no wrapper' % (p, M, r['T3line']), r['T3'], None) + else: print(' p=%d m=%d: no isotropic line, T3 not applicable' % (p, M)) + expect('B p=%d m=%d T5 K^2 max nonzeros/row (monomial would be 1)' % (p, M), r['T5'], t5) + if quick: print(' (--quick skipped p=3 m=3 and p=5 m=2, the only cases with isotropic lines / T3)') + + +# ---------------------------------------------------------------- C +P = 7; W3 = 2 + + +def zeros(m): return [[0] * m for _ in range(m)] +def eye(m): return [[int(i == j) for j in range(m)] for i in range(m)] +def mmul(A, B): + n = len(A); k = len(B); mcol = len(B[0]) + return [[sum(A[i][t] * B[t][j] for t in range(k) if A[i][t]) % P for j in range(mcol)] for i in range(n)] +def madd(A, B, f=1): return [[(a + f * b) % P for a, b in zip(r, s)] for r, s in zip(A, B)] +def mscale(A, f): return [[x * f % P for x in r] for r in A] +def minv(A): + n = len(A); M = [[x % P for x in r] + [int(i == j) for j in range(n)] for i, r in enumerate(A)] + for c in range(n): + q = next(r for r in range(c, n) if M[r][c]); M[c], M[q] = M[q], M[c] + iv = pow(M[c][c], P - 2, P); M[c] = [x * iv % P for x in M[c]] + for r in range(n): + if r != c and M[r][c]: + f = M[r][c]; M[r] = [(x - f * y) % P for x, y in zip(M[r], M[c])] + return [r[n:] for r in M] + + +def coeffs(entries, m, plane=(0, 1)): + U = [zeros(m) for _ in range(3)] + for i in range(m): + if i not in plane: U[0][i][i] = 1 + for a, i in enumerate(plane): + for b, j in enumerate(plane): + c, d = entries[a][b]; U[d % 3][i][j] = (U[d % 3][i][j] + c) % P + return U + + +def evals(U): + m = len(U[0]); out = [] + for t in range(3): + E = zeros(m) + for d in range(3): E = madd(E, U[d], pow(pow(W3, t, P), d, P)) + out.append(E) + return out + + +def o_of(U): + E = evals(U); m = len(E[0]); B = mmul(E[1], minv(E[0])) + return rank_mod(madd(B, eye(m), -1), P) + + +def pmul(A, B): + m = len(A[0]); C = [zeros(m) for _ in range(3)] + for i in range(3): + for j in range(3): C[(i + j) % 3] = madd(C[(i + j) % 3], mmul(A[i], B[j])) + return C + + +def conj(U, c, ci): return [mmul(mmul(c, x), ci) for x in U] + + +def target_kind(T): + E = evals(T); m = len(E[0]); E0i = minv(E[0]) + B1 = mmul(E[1], E0i); B2 = mmul(E[2], E0i) + if mmul(B1, B1) != B2: return None + I = eye(m) + a = m - rank_mod(madd(B1, I, -W3), P); b = m - rank_mod(madd(B1, I, -W3 * W3 % P), P) + return (a, b) if a + b == m else None + + +H3 = [[(1, 0), (-1, 1)], [(1, 2), (0, 0)]] +ALPHA = [ + ('H3', H3), ('live2', [[(1, 0), (1, 1)], [(1, 2), (2, 0)]]), ('live2b', [[(1, 0), (1, 1)], [(1, 1), (2, 0)]]), + ('live1', [[(1, 0), (1, 0)], [(1, 1), (3, 0)]]), ('QUERY', [[(1, 0), (0, 0)], [(1, 1), (1, 0)]]), + ('QSELF', [[(1, 1), (0, 0)], [(0, 0), (1, 0)]]), ('park1', [[(1, 0), (1, 0)], [(1, 1), (0, 0)]]), + ('swap', [[(0, 0), (1, 1)], [(1, 2), (0, 0)]]), +] +ADM_WANT = {'H3': False, 'live2': False, 'live2b': False, 'live1': False, 'QUERY': False, 'QSELF': True, 'park1': True, 'swap': True} + + +def part_c(): + print('== C. Lemma Z admissibility over F_7 (omega = 2)') + for m in (2, 4, 6, 36): + row = [] + for name, ent in ALPHA: + U = coeffs(ent, m); o = o_of(U); r0 = rank_mod(U[0], P); adm = (r0 == m - o) + row.append('%s:o=%d,rk0=%d,%s' % (name, o, r0, 'ADM' if adm else 'no')) + expect('C m=%d %s admissible' % (m, name), adm, ADM_WANT[name]) + if name == 'H3': expect('C m=%d H3 rank u0 = m-1' % m, (r0, o), (m - 1, 2)) + if name in ('live2', 'QUERY'): expect('C m=%d %s rank u0 = m' % (m, name), r0, m) + print(' m=%2d: ' % m + ' | '.join(row)) + rng = random.Random(1) + def rand_gl(m): + while True: + c = [[rng.randrange(P) for _ in range(m)] for _ in range(m)] + if rank_mod(c, P) == m: return c + sw = dict(ALPHA)['swap'] + for m in (4, 6): + T = [eye(m), zeros(m), zeros(m)]; cost = 0 + for j in range(m // 2): + U = coeffs(sw, m, plane=(2 * j, 2 * j + 1)); cost += o_of(U); T = pmul(T, U) + c = rand_gl(m); T = conj(T, c, minv(c)) + tk = target_kind(T) + expect('C(e) m=%d swap planes cost' % m, cost, m) + expect('C(e) m=%d eigen-split (#w,#w^2) sums to m' % m, tk is not None and sum(tk) == m, True) + print(' split = %s' % (tk,)) + Q = coeffs([[(1, 0), (0, 0)], [(-1, 1), (1, 0)]], 2, plane=(1, 0)); Hm = coeffs(H3, 2) + T = pmul(Q, Hm) + expect('C(f) m=2 witness cost m+1', o_of(Q) + o_of(Hm), 3) + tk = target_kind(T) + expect('C(f) m=2 witness is a split target', tk is not None, True) + print(' witness k-coeffs %s target %s' % (T, tk)) + + +if __name__ == '__main__': + part_a(); part_b('--quick' in sys.argv); part_c() + print('PASS_ODD_RADIX') diff --git a/research/p104-follow-up-findings/sepgate.py b/research/p104-follow-up-findings/sepgate.py new file mode 100644 index 0000000000..62782212f6 --- /dev/null +++ b/research/p104-follow-up-findings/sepgate.py @@ -0,0 +1,121 @@ +#!/usr/bin/env python3 +"""SEPAUDIT checker: the compiler's separation hypothesis r_max < k_min holds after strictification for the frontier invoices. + +Own code (DreamingOfClouds with Claude Opus 5.5), standard library only (decimal, 60 digits). + +FINITE-PRECOMPILATION.md:51-52 and :205-207 require r_max (largest paid child rank) < k_min (smallest productive target rank) +for the unit fed to the compiler. The raw #7113-caller invoices have r_max = 64 and k_min = 1, so they fail it literally. +The selected #7000 record applies the admitted strictification step instead (research/shared-wire-split-composition, +interval_gate.py: product power v = 1920, cutoff c = 11, completion floor b = 12, u = 1/7; the gate passes when +alpha = P_t/T_t < 1, gamma = P_{t+1/7}/(11^{1/7} T_t) < 31/32 and delta = 12*B/(11^C T_t) < 31/32, with t = 1 - C and B the +target count; the ambient cap needs max target < 153). + +Checks + 1. Control: the #7000 invoice in research/shared-wire-split-composition/FULL-RESULT.json at its tested C gives the + gamma and delta recorded there (to 1e-12), and its kappa root matches its raw bracket. + 2. For the #7546, #7605 and #7608 invoices (vendored data): the kappa root of sum (T_r - P_r) r^(1-C) = 0 reproduces the + published kappa; raw r_max = 64 >= k_min = 1 (the literal hypothesis fails); max target < 153; and the gate passes + (alpha < 1, gamma, delta < 31/32) at C = kappa - 7e-14. + Negative control: the #7546 invoice with every paid count of rank >= 16 multiplied by 1.10 fails the gate (gamma >= 31/32 + or alpha >= 1 at the same C). +Prints PASS_SEPARATION_GATE. +""" +import hashlib, json, os, sys +from decimal import Decimal as D, getcontext + +getcontext().prec = 60 +HERE = os.path.dirname(os.path.abspath(__file__)) +ROOT = os.path.abspath(os.path.join(HERE, '..', '..')) +PINS = { + 'data/invoice-7546.json': '151d26b47dce7567c349e5c6455740c10221226ba1f89aef58cf72e1ec8dc676', + 'data/invoice-7605.json': 'b38afd7ca590b5c4c301ee4fbe0e123f0c7220c2bd1f40c66adf208652e3ce15', + 'data/invoice-7608.json': '4d89c9e1dc564d420dee20e456f5bdfcfccd13ab1ee7d224ea388b3b8c5eae3c', +} +FULL = 'research/shared-wire-split-composition/FULL-RESULT.json' +KAPPA = { # published values (#7546 ToikY, #7605 aliromman, #7608 ours, conditional) + '7546': D('0.003648411294790845'), + '7605': D('0.0036504442446'), + '7608': D('0.00365074956598367712940081'), +} + + +def fail(msg): + print('FAIL:', msg); sys.exit(1) + + +def expect(name, got, want): + ok = got == want + print(('ok ' if ok else 'FAIL ') + name + ': ' + str(got)) + if not ok: fail(name) + + +def load(rel, sha): + b = open(os.path.join(ROOT if sha is None else HERE, rel), 'rb').read() + if sha is not None and hashlib.sha256(b).hexdigest() != sha: fail('sha256 mismatch ' + rel) + return json.loads(b) + + +def hist(h): return {int(k): D(v) for k, v in h.items() if int(v) > 0} + + +def mom(H, x): return sum(c * (D(r).ln() * x).exp() for r, c in H.items()) + + +def root(T, P): + lo, hi = D('0.001'), D('0.006') + f = lambda C: mom(T, 1 - C) - mom(P, 1 - C) + if not (f(lo) > 0 > f(hi)): fail('root not bracketed') + for _ in range(140): + mid = (lo + hi) / 2 + if f(mid) > 0: lo = mid + else: hi = mid + return lo + + +def gate(T, P, C): + t = 1 - C + Tt, Pt = mom(T, t), mom(P, t) + Pu = mom(P, t + D(1) / 7) + alpha = Pt / Tt + gamma = Pu / ((D(11).ln() / 7).exp() * Tt) + delta = 12 * sum(T.values()) / ((D(11).ln() * C).exp() * Tt) + return alpha, gamma, delta + + +def passes(a, g, d): return a < 1 and g < D(31) / 32 and d < D(31) / 32 + + +def main(): + full = load(FULL, None) + T, P = hist(full['invoice']['T']), hist(full['invoice']['P']) + tested = D(full['gate']['tested'].split('/')[0]) / D(full['gate']['tested'].split('/')[1]) + a, g, d = gate(T, P, tested) + expect('#7000 control: gamma, delta at its tested C agree with FULL-RESULT.json to 1e-12', + (abs(g - D(repr(full['gate']['gamma'][0]))) < D('1e-12'), abs(d - D(repr(full['gate']['delta'][0]))) < D('1e-12')), + (True, True)) + k0 = root(T, P) + lo, hi = [D(x.split('/')[0]) / D(x.split('/')[1]) for x in full['gate']['raw_bracket']] + expect('#7000 control: kappa root lies in the recorded raw bracket', lo - D('1e-25') <= k0 <= hi + D('1e-25'), True) + for name in ('7546', '7605', '7608'): + inv = load('data/invoice-%s.json' % name, PINS['data/invoice-%s.json' % name]) + T, P = hist(inv['targets']), hist(inv['paid']) + k = root(T, P) + digits = len(str(KAPPA[name]).split('.')[1]) - 1 + expect('#%s: kappa root matches the published kappa to %d digits' % (name, digits), + abs(k - KAPPA[name]) < D(10) ** (-digits), True) + rmax, kmin, kmax = max(P), min(T), max(T) + expect('#%s: raw r_max, k_min (literal r_max < k_min fails), max target < 153' % name, + (rmax, kmin, rmax < kmin, kmax < 153), (64, 1, False, True)) + C = k - D('7e-14') + a, g, d = gate(T, P, C) + print(' #%s: B %d, alpha %.12f, gamma %.6f, delta %.6f' % (name, sum(T.values()), a, g, d)) + expect('#%s: strictification gate passes (alpha < 1, gamma, delta < 31/32)' % name, passes(a, g, d), True) + if name == '7546': + P2 = {r: (c * D('1.10') if r >= 16 else c) for r, c in P.items()} + a2, g2, d2 = gate(T, P2, C) + expect('negative control: paid mass of rank >= 16 scaled by 1.10 fails the gate', passes(a2, g2, d2), False) + print('PASS_SEPARATION_GATE') + + +if __name__ == '__main__': + main() diff --git a/research/p104-follow-up-findings/toy4.py b/research/p104-follow-up-findings/toy4.py new file mode 100644 index 0000000000..b8557eb84b --- /dev/null +++ b/research/p104-follow-up-findings/toy4.py @@ -0,0 +1,187 @@ +#!/usr/bin/env python3 +"""TOY4 checker: owned-set enumeration on F2^3 with births cuts, Charge Corollary, controls, 4-feeder replay, duality. + +Own code (DreamingOfClouds with Claude Opus 5.5), standard library only. Tags: [C] exact enumeration. +The lemmas themselves (Pin, time-cut basis, Down-set No-Loss (DNL), Charge Corollary, Duality) are proved in PROOF.md; +this script only enumerates and applies them. The S2 proof is an outside-session lane of DreamingOfClouds'. + +Checks (F2^3, 16 subspaces as frames, standard dot product) + a. labels [1,2,4,7]: 8,261 owned multisets of ascending moves with total climb 3; 460 up-sets; 13 pass every births cut + (for every up-set G: #moves a notin G, b in G >= #{ports j: in G, q_j^perp notin G}). + b. Charge Corollary blocks all 13 (port 7). Labels [1,2,7], climb 2: exactly 1 cut-feasible set, blocked. + c. Controls: 4 line feeders {0}->q pass the cuts and the corollary is silent; 0 owned fails the cuts. + Climb 4: 2,074 cut-feasible sets; number blocked by the corollary is printed (asserted < 2,074, feeders not blocked). + d. Exact Fraction replay of the real-time 4-feeder program: exact, owned climb 4. + e. Duality O -> {(b^perp, a^perp)} permutes the 13 cut-feasible sets and preserves climb. +Prints PASS_TOY4_DECISION. +""" +import itertools, sys +from fractions import Fraction as Q + + +def fail(msg): + print('FAIL:', msg); sys.exit(1) + + +def expect(name, got, want): + ok = got == want + print(('ok ' if ok else 'FAIL ') + name + ': ' + str(got)) + if not ok: + fail('%s: got %r want %r' % (name, got, want)) + + +def span(vs): + S = {0} + for v in vs: S |= {x ^ v for x in S} + return frozenset(S) + + +def subspaces(m): + out = set() + for k in range(m + 1): + for B in itertools.combinations(range(1, 1 << m), k): out.add(span(B)) + return sorted(out, key=lambda s: (len(s), sorted(s))) + + +def dot(a, b): return bin(a & b).count('1') & 1 + + +def setup(m): + F = subspaces(m); return F, {f: i for i, f in enumerate(F)} + + +def down(F, g): return {i for i, f in enumerate(F) if f <= F[g]} + + +def dnl_fails(F, moves, g): + if any(b == g for a, b in moves): return True + D = down(F, g); ch = True + while ch: + ch = False + for a, b in moves: + if a in D and b not in D: D |= down(F, b); ch = True + return any(F[g] < F[x] for x in D) + + +def analyse(m, labels, moves): + """Charge Corollary. Returns list of blocked port indices.""" + F, idx = setup(m); n = len(labels) + cross = [[k for k, (a, b) in enumerate(moves) if q not in F[a] and q in F[b]] for q in labels] + tight = [len(c) == 1 for c in cross] + blocked = [] + for d in range(n): + T = [s for s in range(n) if s != d and tight[s] and dot(labels[s], labels[d])] + if not T: continue + cand = [g for g, f in enumerate(F) if labels[d] in f and not any(labels[s] in f for s in T)] + if not any(dnl_fails(F, moves, g) for g in cand): blocked.append(d) + return blocked + + +class Enum: + def __init__(self, m, labels): + self.m, self.labels = m, labels + F, idx = setup(m); self.F, self.idx = F, idx; nF = len(F) + self.dimf = [len(f).bit_length() - 1 for f in F] + up = [[j for j in range(nF) if F[i] <= F[j]] for i in range(nF)] + line = [idx[span([q])] for q in labels] + hyp = [idx[frozenset(x for x in range(1 << m) if dot(x, q) == 0)] for q in labels] + self.ups = [M for M in range(1 << nF) + if all(all((M >> j) & 1 for j in up[i]) for i in range(nF) if (M >> i) & 1)] + need = [(G, sum(1 for j in range(len(labels)) if (G >> line[j]) & 1 and not (G >> hyp[j]) & 1)) for G in self.ups] + self.need = [(G, d) for G, d in need if d] + self.mv = [(a, b, self.dimf[b] - self.dimf[a]) for a in range(nF) for b in range(nF) if a != b and F[a] <= F[b]] + + def cut_ok(self, ms): + return all(sum(1 for a, b, _ in ms if not (G >> a) & 1 and (G >> b) & 1) >= d for G, d in self.need) + + def sets(self, climb): + """(number of multisets of total climb == climb, list of cut-feasible ones)""" + total = 0; sols = [] + mv = self.mv + def rec(start, left, cur): + nonlocal total + if left == 0: + total += 1 + if self.cut_ok(cur): sols.append([(a, b) for a, b, _ in cur]) + return + for i in range(start, len(mv)): + if mv[i][2] <= left: rec(i, left - mv[i][2], cur + [mv[i]]) + rec(0, climb, []) + return total, sols + + +def perp_frame(m, f): return frozenset(x for x in range(1 << m) if all(dot(x, y) == 0 for y in f)) + + +def dual(E, moves): + F, idx = E.F, E.idx + return sorted((idx[perp_frame(E.m, F[b])], idx[perp_frame(E.m, F[a])]) for a, b in moves) + + +def main(): + m = 3; L = [1, 2, 4, 7] + E = Enum(m, L) + expect('a. frames', len(E.F), 16) + expect('a. up-sets of frame lattice', len(E.ups), 460) + tot, sols = E.sets(3) + expect('a. owned multisets with total climb 3', tot, 8261) + expect('a. cut-feasible climb-3 sets', len(sols), 13) + blk = [analyse(m, L, s) for s in sols] + expect('b. Charge Corollary blocked sets (of 13)', sum(1 for b in blk if b), 13) + expect('b. blocked port label(s) over all 13', sorted({L[d] for b in blk for d in b}), [7]) + E3 = Enum(m, [1, 2, 7]); t3, s3 = E3.sets(2) + expect('b. labels [1,2,7] climb 2 cut-feasible sets', len(s3), 1) + expect('b. labels [1,2,7] that set blocked', [bool(analyse(m, [1, 2, 7], s)) for s in s3], [True]) + # controls + F, idx = E.F, E.idx; Z = idx[span([])] + feed = [(Z, idx[span([q])]) for q in L] + expect('c. 4 line feeders: cut-feasible', E.cut_ok([(a, b, 1) for a, b in feed]), True) + expect('c. 4 line feeders: blocked ports', analyse(m, L, feed), []) + expect('c. 0 owned: cut-feasible', E.cut_ok([]), False) + t4, s4 = E.sets(4) + print(' climb-4 multisets enumerated:', t4) + expect('c. climb-4 cut-feasible sets', len(s4), 2074) + nb4 = sum(1 for s in s4 if analyse(m, L, s)) + print(' Charge Corollary blocks %d of %d climb-4 cut-feasible sets' % (nb4, len(s4))) + assert nb4 < 2074, 'corollary vacuous at climb 4' + expect('c. 4-feeder set among climb-4 cut-feasible', sorted(feed) in [sorted(s) for s in s4], True) + # d. exact replay (adapted from TOY4/control4.py) + Vf = span([1, 2, 4]); Zf = span([]) + perp = lambda q: frozenset(x for x in range(8) if dot(x, q) == 0) + dim = lambda f: len(f).bit_length() - 1 + regs = {}; cost = 0 + def new(name, frame, tok=None, owned=False): regs[name] = [frame, ({tok: Q(1)} if tok else {}), owned] + def move(r, b): + nonlocal cost + a = regs[r][0]; assert a < b, ('not ascending', r) + if regs[r][2]: cost += dim(b) - dim(a) + regs[r][0] = b + def add(r, s, c): + assert regs[r][0] == regs[s][0], ('no common frame', r, s) + R = regs[r][1] + for k, v in regs[s][1].items(): + R[k] = R.get(k, 0) + Q(c) * v + if R[k] == 0: del R[k] + for s, q in enumerate(L): + new('Y%d' % s, Zf, 'y%d' % s); new('T%d' % s, Zf, owned=True); new('X%d' % s, span([q]), 'x%d' % s) + add('T%d' % s, 'Y%d' % s, 1); move('T%d' % s, span([q])); add('X%d' % s, 'T%d' % s, -1) + l = next(x for x in sorted(perp(q)) if x) + move('Y%d' % s, span([l])); move('Y%d' % s, perp(q)) + pl = span([q, next(x for x in range(1, 8) if x != q)]); move('X%d' % s, pl); move('X%d' % s, Vf) + ok = all(regs['X%d' % s][1] == {'x%d' % s: 1, 'y%d' % s: -1} and regs['X%d' % s][0] == Vf and + regs['Y%d' % s][1] == {'y%d' % s: 1} and regs['Y%d' % s][0] == perp(L[s]) for s in range(4)) + expect('d. 4-feeder replay exact', ok, True) + expect('d. 4-feeder replay owned climb', cost, 4) + # e. duality + fam = sorted(sorted(s) for s in sols) + img = sorted(dual(E, s) for s in sols) + expect('e. dual image of the 13-set family = the family', img, fam) + perm = [fam.index(dual(E, s)) for s in sols] + expect('e. dual map is a permutation', sorted(perm), list(range(13))) + clm = lambda s: sum(E.dimf[b] - E.dimf[a] for a, b in s) + expect('e. climb preserved', all(clm(dual(E, s)) == 3 for s in sols), True) + print('PASS_TOY4_DECISION') + + +if __name__ == '__main__': + main()