Skip to content

Commit 04da76e

Browse files
pinterbangetclaude
andcommitted
research: #4436 direct exponent gate reduces to a uniform boundary-exit share (lemma + p7 scan)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 parent 2a13eb1 commit 04da76e

5 files changed

Lines changed: 323 additions & 0 deletions

File tree

Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
# #4436's direct-exponent gate reduces to a uniform boundary-exit share
2+
3+
**Claim type:** a written conditional lemma plus numerical evidence. **No new κ, and no proof of the
4+
uniform bound.** It addresses zxv's [#4436](https://github.com/CrocSwap/integer-mult-bounds/pull/4436)
5+
open exponent gate. #4436 notes that its direct flow for overlapping ranks creates *boundary exits*
6+
of rank greater than `k_min·n/m`, "near the upper boundary", which "cannot be assigned the old bound".
7+
8+
## Lemma (conditional)
9+
10+
The setting is #4436's direct flow at top rank `n ≥ m`, with an exponent `t` above the unit's mixed
11+
root and `z0 = t + δ`. Assume:
12+
13+
- **(A) Potential.** `Σ_e x_e e^t ≤ Σ_s w_s s^t` over all exits. This holds because matched jobs
14+
cancel and each unit's paid `t`-potential is at most its target potential.
15+
- **(B) Ranks.** Sources satisfy `n/m < s ≤ n`. Boundary exits satisfy `e ≤ r_max·n/m`. Leaf exits
16+
satisfy `e ≤ E(n) = r_max(n/m)^θ`.
17+
- **(C) Boundary share.** `Σ_boundary x_e e^t ≤ β Σ_s w_s s^t`, uniformly in `n`.
18+
19+
Then the exit coefficient obeys
20+
21+
κ(n) = Σ_e x_e e^(z0) / Σ_s w_s s^(z0) ≤ β·r_max^δ + (m E(n)/n)^δ.
22+
23+
**Proof.** Boundary part:
24+
`Σ_b x_e e^(z0) ≤ (r_max n/m)^δ Σ_b x_e e^t ≤ (r_max n/m)^δ β Σ w_s s^t ≤ β r_max^δ Σ w_s s^(z0)`,
25+
using `s > n/m`. Leaf part: `Σ_l x_e e^(z0) ≤ E^δ Σ_l x_e e^t ≤ E^δ Σ w_s s^t ≤ (mE/n)^δ Σ w_s s^(z0)`,
26+
using (A). ∎
27+
28+
#4405's refined induction needs only `κ(n) ≤ η = z0·m^(z0−1)` for all `n` beyond an explicit
29+
threshold. Since `(mE/n)^δ → 0`, the induction closes if `β·r_max^δ < η`, and the direct flow then
30+
attains every saving below the unit's root, with an explicit finite rank. For raw p7, `m = 121`,
31+
`r_max = 48` and `η ≈ 0.984`, so the condition is roughly `β < 0.98`.
32+
33+
So the gate reduces to proving a **uniform boundary-exit share bound** (C) with `β < η·r_max^{−δ}`.
34+
35+
## Evidence for (C) on raw p7
36+
37+
`verify.py` uses an independent implementation of #4436's flow, the same as in my #4456. It scans
38+
3,394 ranks: every `N` from 121 to 3,000, plus a 1% geometric grid up to 495,968. At each rank it
39+
checks exactly that exits are at most `r_max·N/m`, that leaf exits are at most `r_max^(G+1)`, and the
40+
rank-one potential identity. It then computes `β(N)` at `t = 1 − 0.0026865`:
41+
42+
| | value |
43+
| --- | --- |
44+
| maximum `β(N)` | **0.1545**, at `N = 1089` |
45+
| typical `β(N)` for `N ≥ 10⁴` | 0.075–0.11 |
46+
| maximum `exit/N` | 0.39669 = 48/121, the bound attained |
47+
48+
The observed `β` sits far below the roughly 0.98 that the lemma needs. These are finite floating-point
49+
measurements, not a proof.
50+
51+
## Not covered
52+
53+
- **A proof of (C)**, which needs counting the omitted Pascal terms at the top boundary.
54+
- **The explicit rank and outer ledger** for a direct-flow endpoint.
55+
- **Native premises.**
56+
57+
## Reproduce
58+
59+
```sh
60+
python3.12 -B scripts/research_package.py --package research/direct-flow-boundary-share --check-only
61+
python3.12 -B scripts/research_package.py --package research/direct-flow-boundary-share
62+
```
63+
64+
The verifier prints `PASS_DIRECT_FLOW_BOUNDARY_SHARE` in about 50 seconds, using only the standard
65+
library.
66+
67+
## Open next questions
68+
69+
1. **Prove a uniform bound on the boundary-exit `t`-potential share.**
70+
- *Why it matters:* it would close #4436's exponent gate, giving the direct saving without
71+
tensoring.
72+
- *First step:* boundary exits occur at points `b` with `m·ρ·r·c(b)/k > n` for some `k`. Bound
73+
their `u(b)`-weighted potential by the multinomial mass of the last layer.
74+
75+
## Credit
76+
77+
- The direct flow and the gate are zxv's (#4436).
78+
- The refined induction is 1337isnot1337's (#4405).
79+
- The lockstep construction is Jacob Alan Sussman's Theorem 1G.
80+
81+
Prepared by Ryanson Jonathan with substantial Claude Code (Claude Opus 5.5) assistance.
82+
Apache-2.0.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"schema_version": 1,
3+
"base_commit": "2a13eb1827784206202db90e5dc8327cf8a250db",
4+
"files": [
5+
{
6+
"path": "certificates/selected-result.json",
7+
"usage": "provenance",
8+
"git_blob": "ed33caef5c5827693e9572d252a66f99cbb73d40",
9+
"sha256": "5732707cc1e460b090b53f2463162749ad860de878a18f7408938671d295a9d9"
10+
},
11+
{
12+
"path": "docs/research/agent-task-catalog.json",
13+
"usage": "provenance",
14+
"git_blob": "64bfc5af6709ed9811171e0a2108f05e1219cb65",
15+
"sha256": "352a6184713b8843d96fd2c2071eb7aeaa655906b7c51d45ad444912666c8a96"
16+
}
17+
]
18+
}
Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,100 @@
1+
{
2+
"schema_version": 1,
3+
"task_id": "independent-moment",
4+
"priority_revision": 7,
5+
"base_commit": "2a13eb1827784206202db90e5dc8327cf8a250db",
6+
"original_card": {
7+
"id": "independent-moment",
8+
"question": "Does a new paid-profile or mixture-ceiling claim have independent source-bound coverage of its actual changed ledger?",
9+
"starting_points": [
10+
"docs/research/research-family-status.md",
11+
"certificates/selected-result.json",
12+
"research/staged544-mixed-fourth-entry/README.md",
13+
"research/staged-fourth-mixture-ceiling/README.md",
14+
"research/r437-two-window-carrier/README.md"
15+
],
16+
"methods": [
17+
"Independently reconstruct one changed paid ledger or pooled dual with exact source and model binding.",
18+
"Check a genuinely uncovered moment implication with a different enclosure method and semantic controls."
19+
],
20+
"acceptance_gate": "Demonstrate independence, source binding, positive cases and semantic failure controls. Name the existing checks and the missing coverage. More digits or another equivalent evaluation of an unchanged root is not by itself new verification coverage.",
21+
"first_step": {
22+
"command": [
23+
"python3",
24+
"-B",
25+
"scripts/research_baseline.py"
26+
],
27+
"expected": "PASS_RESEARCH_BASELINE_BINDINGS_ONLY",
28+
"inspect": "Choose one uncovered implication in #4088 literal mixed fill, #4091 pooled dual/model binding or #4067 changed frame/host bill. #4091 pins an earlier #4088 head: validate word, capacity and stock equivalence before applying that ceiling to the later fill.",
29+
"scope": "Source-binding orientation only; no scientific replay, theorem acceptance or supplier admission. Budget any heavy replay separately."
30+
},
31+
"first_experiment": "Independently reconstruct one changed ledger or pooled certificate with a positive case and a semantic failure control. Compare exact sources and name what existing checks miss. Keep this separate from supplier-boundary-audit (ordinary/outer dispatch) and uniform-transfer-audit (all-size proof). Stop after the chosen implication; more digits of an unchanged root are not additional mechanism coverage.",
32+
"bottleneck_link": "Independent pricing prevents unsupported frontier claims and can reveal genuine accounting slack.",
33+
"allowed_variations": [
34+
"Reconstruct either a source ledger or a numeric enclosure with a different method."
35+
],
36+
"scope_change_triggers": [
37+
"Importing the primary function and calling its output independent verification.",
38+
"Calling an aggregate histogram or source archive an independently accepted physical supplier."
39+
],
40+
"overlap_terms": [
41+
"independent moment",
42+
"rank histogram",
43+
"exact enclosure",
44+
"2979",
45+
"rank7 joint endframes",
46+
"paired extraction",
47+
"joint lowering",
48+
"4088",
49+
"4091",
50+
"4067",
51+
"staged544-mixed-fourth-entry",
52+
"staged-fourth-mixture-ceiling",
53+
"r437-two-window-carrier"
54+
],
55+
"existing_checks": [
56+
{
57+
"scope": "PR #4088: mixed local/owner/phase ledger and moment reported.",
58+
"evidence": "research/staged544-mixed-fourth-entry/README.md",
59+
"remaining": "Independent binding of changed construction to paid histogram, distinct from full admission.",
60+
"status": "author-checked",
61+
"source_commit": "72d7efc181edb21806a878f174847c96dd410ab0",
62+
"selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129"
63+
},
64+
{
65+
"scope": "PR #4091: sharp pooled ceiling proposed for fixed THREE/FOUR words and inventory.",
66+
"evidence": "research/staged-fourth-mixture-ceiling/README.md",
67+
"remaining": "Validate dual, exhaustive pattern scope and exact source equivalence before applying to newer fills.",
68+
"status": "author-checked",
69+
"source_commit": "a29bdd8f56cd18b805917775cdec09ff935eddc4",
70+
"selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129"
71+
},
72+
{
73+
"scope": "PR #4067: paid (2,2) to (1,3) exchange and fixed OQ4 host reported.",
74+
"evidence": "research/r437-two-window-carrier/README.md",
75+
"remaining": "Independent full cost delta; remaining caller/precision/stock obligations are separate.",
76+
"status": "author-checked",
77+
"source_commit": "a95f11c52e3ca1e4c5171b3c20d8f4b0815aee2e",
78+
"selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129"
79+
}
80+
]
81+
},
82+
"scope_status": "refined",
83+
"actual_scope": "Reduce #4436's open direct-exponent gate to a uniform boundary-exit t-potential share bound (written lemma) and measure that share on raw p7.",
84+
"scope_change_reason": "Follow-up to #4456; #4436 left the direct exponent gate open.",
85+
"bottleneck_link": "A direct-flow exponent would remove the tensor/padding step behind the kappa ~0.0027-0.0030 claims.",
86+
"budget_minutes": 30,
87+
"stop_rule": "Stop at the conditional lemma and measurements.",
88+
"outcome": "completed",
89+
"evidence": "Lemma: kappa_exit <= beta r_max^delta + (mE/n)^delta, so the refined induction closes if beta r_max^delta < eta (~0.984 for p7). Measured max beta 0.1545 over 3,394 ranks to 5e5.",
90+
"author": "Ryanson Jonathan, with Claude Code (Claude Opus 5.5) assistance",
91+
"ai_assistance": "Substantial Claude Code (Claude Opus 5.5) assistance; no independent human review.",
92+
"open_questions": [
93+
{
94+
"question": "Prove a uniform bound on the boundary-exit t-potential share.",
95+
"why_it_matters": "It would close #4436's exponent gate.",
96+
"first_step": "Bound the u(b)-weighted potential of boundary points by the last-layer multinomial mass.",
97+
"blocked_by": "None."
98+
}
99+
]
100+
}
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"schema_version": 1,
3+
"status": "ready",
4+
"python": "3.12",
5+
"requirements": [],
6+
"inputs": [],
7+
"commands": [
8+
{
9+
"argv": [
10+
"{python}",
11+
"-B",
12+
"{package}/verify.py"
13+
],
14+
"timeout_seconds": 300,
15+
"checks": "Independent #4436 direct flow on raw p7 at 3,394 ranks (121..495,968): exits <= r_max N/m, leaf exits <= r_max^(G+1), exact potential identity; maximum boundary-exit t-potential share below 0.16 (observed 0.1545)."
16+
}
17+
]
18+
}
Lines changed: 105 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,105 @@
1+
#!/usr/bin/env python3
2+
"""Boundary-exit potential share in #4436's direct p7 flow (evidence for a conditional reduction).
3+
4+
Using an independent implementation of #4436's partially matched flow (the same as research/pr4436-direct-flow-check),
5+
for every rank 121 <= N <= 3000 and a 1%-geometric grid up to 5*10^5 this computes
6+
beta(N) = sum over boundary exits x_e e^t / sum over sources w_s s^t, t = 1 - 0.0026865,
7+
and checks: every exit is at most r_max N / m (r_max = 48, m = 121), every leaf exit is at most r_max^(G+1), the
8+
exact rank-one potential identity holds, and max beta < 0.16 (observed 0.1545). Floating-point shares are
9+
numerical evidence for the README's conditional lemma, not a proof of a uniform bound.
10+
Ryanson Jonathan with Claude Code (Claude Opus 5.5) assistance. Apache-2.0.
11+
"""
12+
import json
13+
import sys
14+
15+
from fractions import Fraction as Q
16+
from math import factorial
17+
def multis(n_types, size):
18+
if n_types == 0:
19+
if size == 0: yield ()
20+
return
21+
for x in range(size + 1):
22+
for rest in multis(n_types - 1, size - x): yield (x,) + rest
23+
def flow(N, W, P):
24+
ks = sorted(W); m = ks[-1]; kmin = ks[0]
25+
def c(a):
26+
v = 1
27+
for k, x in zip(ks, a): v *= k ** x
28+
return v
29+
def u(a):
30+
v = factorial(sum(a))
31+
for k, x in zip(ks, a): v = v // factorial(x) * W[k] ** x
32+
return v
33+
G = 0
34+
while kmin ** (G + 1) <= N // m: G += 1
35+
F = [{1: 1}]
36+
for d in range(1, G + 1):
37+
nxt = {}
38+
for rho, cnt in F[d - 1].items():
39+
for r, pr in P.items():
40+
if m * rho * r <= N: nxt[rho * r] = nxt.get(rho * r, 0) + cnt * pr
41+
F.append(nxt)
42+
S, X, BX = {}, {}, {}
43+
col = units = matched = 0
44+
add = lambda D, k, v: D.__setitem__(k, D.get(k, 0) + v)
45+
present = lambda rho, a: m * rho * c(a) <= N
46+
for d in range(G + 1):
47+
for rho, cnt in F[d].items():
48+
for b in multis(len(ks), G - d):
49+
if not present(rho, b): continue
50+
units += cnt * u(b); col += cnt * u(b) * rho * c(b)
51+
for r, pr in P.items():
52+
issued = cnt * pr * u(b); rank = r * rho * c(b)
53+
if d == G:
54+
add(X, rank, issued); continue
55+
D = sum(W[k] * u(tuple(x - (i == j) for j, x in enumerate(b)))
56+
for i, k in enumerate(ks) if b[i] > 0 and present(rho * r, tuple(x - (i == j) for j, x in enumerate(b))))
57+
matched += cnt * pr * D
58+
if issued - cnt * pr * D:
59+
add(X, rank, issued - cnt * pr * D); add(BX, rank, issued - cnt * pr * D)
60+
for a in multis(len(ks), G):
61+
if present(1, a):
62+
for k in ks: add(S, k * c(a), W[k] * u(a))
63+
for d in range(1, G + 1):
64+
for rho, cnt in F[d - 1].items():
65+
for r, pr in P.items():
66+
for a in multis(len(ks), G - d):
67+
if not present(rho * r, a): continue
68+
for i, k in enumerate(ks):
69+
b = list(a); b[i] += 1
70+
if not present(rho, tuple(b)):
71+
add(S, rho * r * c(tuple(b)), cnt * pr * u(a) * W[k])
72+
return dict(G=G, S=S, X=X, BX=BX, col=col, units=units, matched=matched)
73+
74+
75+
def need(condition, message):
76+
if not condition:
77+
raise AssertionError(message)
78+
79+
80+
def main():
81+
W = {5: 420, 6: 270, 7: 840, 8: 1395, 9: 3195, 25: 448, 41: 448, 57: 448, 121: 224}
82+
P = {1: 37305, 2: 10695, 3: 3360, 4: 1530, 5: 300, 8: 1464, 16: 448, 32: 448, 48: 448}
83+
m, rmax, surplus = 121, 48, 608
84+
t = 1 - 0.0026865
85+
Ns = sorted(set(list(range(121, 3001)) + [int(121 * 1.01 ** k) for k in range(0, 850)]))
86+
Ns = [n for n in Ns if n <= 500000]
87+
best, at = 0.0, None
88+
for N in Ns:
89+
r = flow(N, W, P)
90+
need(all(e * m <= rmax * N for e in r["X"]), f"N={N}: exits <= r_max N/m")
91+
need(all(e <= rmax ** (r["G"] + 1) or e in r["BX"] for e in r["X"]), f"N={N}: leaf exits <= r_max^(G+1)")
92+
need(sum(s * v for s, v in r["S"].items()) - sum(e * v for e, v in r["X"].items()) == surplus * r["col"],
93+
f"N={N}: potential identity")
94+
st = sum(v * s ** t for s, v in r["S"].items())
95+
bt = sum(v * e ** t for e, v in r["BX"].items())
96+
if bt / st > best:
97+
best, at = bt / st, N
98+
need(best < 0.16, "max boundary share below 0.16")
99+
print(json.dumps({"status": "PASS_DIRECT_FLOW_BOUNDARY_SHARE", "ranks_scanned": len(Ns), "max_N": Ns[-1],
100+
"max_boundary_share": round(best, 6), "at_N": at, "eta_reference": 0.984,
101+
"new_kappa_claimed": False}, indent=1))
102+
103+
104+
if __name__ == "__main__":
105+
sys.exit(main())

0 commit comments

Comments
 (0)