Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions research/staged-fourth-mixture-ceiling/NOTICE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Sources and credit

This contribution: Ross Richardson, with substantial OpenAI GPT-6.1 Sol
assistance in derivation, implementation and mathematical specialist review.
Apache-2.0. AI team review is not independent human or formal-kernel review.

The exact source subset in source4088/ is from Cinna Davis's PR4088,
head 76088d49e3ed4142a958659aa996b0ca4da5e88e. Its word and literal fill are
predecessor contributions, not new constructions here. SOURCE-EXPORT.json
records original paths and byte pins. source4088/NOTICE.md retains the complete
source-specific credit and scope.

The unchanged binary-basis ledger and rational enclosure engine were retained
through Dugongue/PR3945 and Rohan Arun/PR4076. The primary certificate reuses
that rational engine; the separate independent checker does not import it.
The staged-entry mechanism credits Ross Richardson/PR3605 and dataisfire/PR3734;
ChaloupeMusic and Erwan Secousses/PR3949/3815 supply the general staging and
T360 pattern/Hall lineage. Receiver sharing, native/owner closure and the
predecessor all-character proof credit Dugongue and David Ganz/PR4085,
Nick Petalas, Marius-Paul Dumitrean, Sagar Thakrar, roger-sato, zxv and the
earlier geometry/compiler/transfer contributors named in the source notices.

The new result is the exact pooled mixture optimum and its complete-cost
ceiling, with a piecewise primal/dual proof and a separately implemented
arithmetic check. No chronological fill, supplier admission, kappa improvement
or selected-frontier update is claimed.
257 changes: 257 additions & 0 deletions research/staged-fourth-mixture-ceiling/PROOF.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,257 @@
# Pooled whole-helper ceiling for the fixed PR4088 words

Prepared with OpenAI Codex assistance. Apache-2.0.

## Scope and source premises

This result fixes PR4088, Cinna Davis, head
`76088d49e3ed4142a958659aa996b0ca4da5e88e`, and its THREE/FOUR word interfaces.
The source inherits the PR4085 receiver-sharing words and PR4076 staged-entry
lineage. Its native, hosting, restoration, precision, controller and outer
transfer premises remain source premises; this calculation does not discharge
them. Source file digests used here are in `RESULT.json`.

Let `a` be the exponent saving and `H_r(a)=r^(1-a)`, with `H_0=0`. There are
3240 calls, and `x` of them use FOUR. The local profiles are fixed as

```
L3 = 2487 H1 + 713 H2 + 224 H3 + 102 H4 + 20 H5 + 8 H8,
d = L4-L3 = 2 H1 + 3 H3 - 3 H4.
```

For THREE the whole-helper widths per call are
`{5:28,6:18,7:56,8:93,9:213}`. FOUR changes helper 601 from width 8 to width 7
and leaves every other helper width unchanged. Thus the pooled demand is

```
(N5,N6,N7,N8,N9) = (90720,58320,181440+x,301320-x,690120).
```

The source TEMPLATE has 2016 entries, already including all 112 ports. Its
capacity counts are `{8:672,16:448,32:448,48:448}`. Equivalently there are 18
distinct child slots per port, with counts `{8:6,16:4,32:4,48:4}`. Multiplying
the TEMPLATE counts by 360, once, gives

```
(B8,B16,B32,B48) = (241920,161280,161280,161280),
total bins = 725760, total capacity = 17418240.
```

The pooled model ignores source windows, chronology, call identity, repeated
physical-family exclusions and any other restrictions on where a helper may
be hosted. It allows real nonnegative pattern multiplicities and real
`0<=x<=3240`. Each pattern still contains whole helpers. This is an explicitly
optimistic relaxation of a legal source owner fill. The result gives a lower
bound on the paid bill of every such fill, including any nonuniform dispatch
of these fixed words. It does not construct a changed supplier.

## Complete finite pattern program

A pattern is `(c,n5,n6,n7,n8,n9)` with
`n_w>=0` integral and `sum_w w*n_w<=c`. Its residual rank is
`r=c-sum_w w*n_w`. There are exactly 841 patterns: 5 at capacity8,21 at 16,
158 at 32 and 657 at 48. Empty patterns are included.

For pattern multiplicities `y>=0`, require exactly `B_c` bins of each capacity
and exactly the demands above. The paid objective is the complete expression

```
3240 L3 + x d + sum_patterns y_pattern H_residual.
```

Every admissible source allocation maps to such a feasible point. No idle bin
is discarded. The helper rank mass is `10695240-x`, the local rank mass is
`16708680-x`, and the residual rank mass is `6723000+x`. Consequently the full
paid rank mass is always 23431680, or `65088*360`. This is distinct from the
comparison stock mass `(896*360)*73=23546880`.

## Exact optimum and dual certificate

For every `a` in `[0.00173,0.00174]`, the unique optimal mixture is `x=1080`.
An integral optimum of the pooled program is:

| Capacity | Whole helpers in each bin | Multiplicity | Residual |
| --- | --- | ---: | ---: |
| 8 | 8 | 241920 | 0 |
| 16 | 7+9 | 161280 | 0 |
| 32 | 9+9+9 | 1620 | 5 |
| 32 | 7+7+9+9 | 10620 | 0 |
| 32 | 6+8+9+9 | 58320 | 0 |
| 32 | 5+9+9+9 | 90720 | 0 |
| 48 | empty | 138492 | 48 |
| 48 | 9+9+9+9+9 | 22788 | 3 |

Thus the optimal residual profile is

```
I* = 22788 H3 + 1620 H5 + 138492 H48.
```

Here is a dual certificate, written as exact rational linear combinations of
the functions `H_r`, rather than rounded decimal prices. Set

```
v9 = (H3-H48)/5,
v7 = (v9-H5)/2,
v8 = v7+d,
v6 = 2v7-v8,
v5 = -H5,
u8 = -v8,
u16 = -v7-v9,
u32 = H5-3v9,
u48 = H48.
```

For every pattern the checker proves

```
u_c + sum_w n_w v_w <= H_residual.
```

The eight displayed patterns give exact symbolic equality. All other 833
constraints have strictly positive slack throughout the stated interval;
the certified minimum of slack divided by `a` is greater than
`0.696988114241`. The mixture coefficient is identically
`d+v7-v8=0`. Weak duality therefore gives the same lower bound for every real
`x` and every feasible pattern allocation. Equality is attained by the table.

Because every other pattern has positive slack, an optimum uses only the
eight displayed patterns. The nine bin/item equations, including variable
`x`, have determinant `-10`. Their solution is the displayed table and
`x=1080`, proving uniqueness in the pooled program. One can also see the
mixture directly: width 5 fixes 90720 bins of pattern `5+9+9+9`; width 6 fixes
58320 bins of `6+8+9+9`. Width 8 balance then forces
`241920+58320=301320-x`, hence `x=1080`.

## A genuine mixture breakpoint

The fixed-mixture optimum can also be stated for every real `x` in the full
range. Let `t=x-1080`, and begin with the table above. Keep the capacity8,
capacity16 and `5+9+9+9` rows fixed.

For `-1080<=t<=0`, replace the affected multiplicities by

```
cap32, 9+9+9: 1620-t/4,
cap32, 7+8+8+9: -t/2,
cap32, 7+7+9+9: 10620+3t/4,
cap32, 6+8+9+9: 58320,
cap48, empty: 138492+t/20,
cap48, five9: 22788-t/20.
```

For `0<=t<=2160`, use

```
cap32, 9+9+9: 1620+t/2,
cap32, 7+7+9+9: 10620+t/2,
cap32, 6+8+9+9: 58320-t,
cap48, empty: 138492,
cap48, five9: 22788-t/2,
cap48, 6+6+9+9+9+9: t/2.
```

All multiplicities are nonnegative on their segments, and all constraints
hold as exact affine identities. These are witnesses in the relaxation.
They do not assert chronological or physical-family feasibility.

For the left segment replace `v8` by `(v7+v9)/2`; for the right segment set
`v6=(-H48-4v9)/2` and `v8=2v7-v6`. Keep the other dual formulas. The checker
certifies all 841 inequalities for each dual over the same exponent interval,
and each corresponding affine witness is complementary to its dual.
Consequently the optimum complete bill has slopes

```
s_left = d-H3/20-H5/4+H48/20,
s_right = d+(H5-H3)/2.
```

Throughout the exponent interval, exact bounds give
`s_left/a` in `[-0.348857711147,-0.348494057120]` and `s_right/a` in
`[4.365719222915,4.365911868442]`, using outward rounded displayed bounds.
Thus the bill strictly decreases to 1080 fourth calls and strictly increases
after 1080. Increasing the fourth-call frequency beyond PR4088's one-third
mixture cannot improve even this optimistic pooled bill.

## Exact root ceiling and remaining headroom

The complete optimum profile is

```
8060040 H1 + 2310120 H2 + 751788 H3 + 327240 H4
+ 66420 H5 + 25920 H8 + 138492 H48.
```

Compare this with the same source stock `(896*360) H73`. Rational logarithm
and exponential remainder bounds, imported unchanged from the source engine,
give a strict root bracket

```
0.001730980255989036959962 < a* < 0.001730980255989036959963.
```

The lower and upper signed moment intervals have signs negative and positive,
respectively; the exact endpoints are in `RESULT.json`. Approximate values are
`-1.73328*10^-17` and `+4.89396*10^-17`. Every positive rank in any feasible
complete profile is less than 73. After division by `73^(1-a)`, its complete
moment is strictly increasing in `a`. Therefore positivity of the pooled lower
bound at the upper endpoint excludes any feasible fixed-word owner allocation
having a larger moment root, including exponents outside the interval where
the displayed dual was certified. The pooled table attains `a*`, so this is a
sharp ceiling for the relaxation.

PR4088's literal chronological fill already has 1080 FOUR calls. Its residual
profile is `22785 H3+1625 H5+H16+2H32+138490 H48`. Literal minus pooled optimum
is exactly

```
D(p) = -3*3^p + 5*5^p + 16^p + 2*32^p - 2*48^p, p=1-a.
```

This difference is strictly positive for every `0<p<1`. Indeed, for its
coefficients `c_r`, the piecewise linear function
`S(t)=sum_r c_r min(r,t)` has values 9,21,32,32,0 at the knots 3,5,16,32,48;
it is nonnegative everywhere and positive on an interval. The identity

```
D(p) = p(1-p) integral_0^infinity S(t) t^(p-2) dt
```

proves strict positivity. The source literal root bracket and the new rational
bracket show that the entire remaining root headroom lies within

```
[1.950913151266531*10^-9, 1.950913151266533*10^-9].
```

This is a limit on the fixed words, capacities and paid-profile comparison,
not a new kappa or supplier claim. Reaching even this small headroom still
requires a legal chronological distinct-family fill (or a changed interface
with its own fully charged costs). New words, capacities, stock or transfer
interfaces fall outside the bound.

## Verification level and reproduction

`verify.py` uses only the Python standard library and the unchanged source
rational enclosure engine. No floating optimizer is part of the certificate.
It independently rescans binary frame dimensions in all four raw words,
checks source widths, declared local profiles and template multiplicities, checks exact
primal balance, enumerates all 841 patterns for three exact duals, certifies
the uniform real exponent interval, checks the root signs, and rejects altered
mixture, primal, pattern-coverage, dual and paid-profile controls.

```
python3.12 -I -B verify.py --source source4088 --controls
```

By default recomputation is compared with the saved `RESULT.json`; it does not
rewrite it. `--output PATH` explicitly writes a regenerated certificate.

The 841-pattern coverage and rational enclosure computation are finite exhaustive
checks. The accompanying affine/weak-duality argument and monotonicity proof
cover every real mixture in `[0,3240]` and every exponent in the stated
interval; the monotonicity argument gives the claimed global root ceiling.
This is a written proof backed by exact finite arithmetic, not a formal kernel
proof and not an all-size multiplication theorem. Source native and operator
claims remain attributed conditional premises; the source's complete owner and
operator replay has not been repeated by this relaxation checker.
82 changes: 82 additions & 0 deletions research/staged-fourth-mixture-ceiling/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
# Sharp pooled ceiling for a fourth staged entry

For the exact THREE/FOUR words in [PR4088](https://github.com/CrocSwap/integer-mult-bounds/pull/4088)
at `76088d49e3ed4142a958659aa996b0ca4da5e88e`, the best pooled complete moment
uses **1,080 fourth-entry calls out of 3,240**. This is the same one-third
fraction as its literal construction. Every real mixture is allowed in this
relaxation, and all whole-helper patterns and residual children are charged.

The sharp pooled root lies in

```
[0.001730980255989036959962,
0.001730980255989036959963].
```

Thus any improvement to the pinned literal fill within this fixed two-provider
invoice is **less than 1.951e-9 in the complete-moment root**. This is an upper
bound on remaining headroom, not an achieved supplier or a new kappa.

The proof certifies all 841 bin patterns, three duals and a piecewise affine
optimum for every real staging count `0 <= x <= 3240` and every exponent
`0.00173 <= a <= 0.00174`. An eight-pattern **integer pooled** witness attains
the optimum at `x=1080`; it is not a chronological owner map. Its idle profile
is `{3:22788,5:1620,48:138492}`. The literal fill exceeds it by
`-3 H3 + 5 H5 + H16 + 2 H32 - 2 H48`, a strictly positive power cost for
`H_r=r^(1-a)` and `0<a<1`.

## Reproduction and evidence

From the repository root with standard-library Python 3.12:

```sh
python3.12 -B scripts/research_package.py --package research/staged-fourth-mixture-ceiling
python3.12 -B scripts/check_research_commit.py --package research/staged-fourth-mixture-ceiling --check-source-history
```

`source_binding.py` re-executes the credited predecessor binary-frame cost
ledger on all four words and extracts the current 360-replica bins.
`verify.py` checks the exact primal/dual and complete invoice.
`independent/check.py` uses a separately implemented fixed-point rational enclosure
engine and pattern enumeration; `independent/review_broad.py` separately checks the whole exponent interval and affine fills. The normal and optimized commands retain
explicit rejecting controls. `RESULT.json` and `PROOF.md` give the exact
certificate and derivation. No optimizer is needed for replay. All four standalone commands in `VERIFY.json` also run from the official committed export, with `{package}` replaced by the exported package path; add `-O` for optimized replay. The metadata commands above require Git.

Fourteen predecessor files are retained byte-for-byte. `SOURCE-EXPORT.json`
records their original head, path, Git blob and SHA256; `SOURCES.json` binds
their committed local freeze so a cold checkout needs no pending-PR objects.
The original template contains historical 37-replica material: only its
original child-port capacities are used, with the current `ORDER.json`
supplying all 360 replicas. No historical replica factor is silently reused.

## Scope and limits

The model fixes the two local invoices, width-5 through width-9 whole helpers,
all original capacity-8/16/32/48 bins, one paid residual per bin, width 73 and
stock `896*360`. It drops chronology, helper identity, family exclusions,
offsets and integral pattern multiplicities to obtain a lower cost bound.
Additional implementation costs cannot improve that bound. Changed words,
capacities, cross-slot operator fusions or stock conventions require a new model.

The mathematical result combines a written linear-program dual argument with
finite exhaustive pattern coverage and exact rational interval certificates.
There is no formal-kernel or independent human review. The predecessor ledger
is reused and freshly executed for local costs; dirty-state identities, native
phases, physical hosting, mixed-provider full release, precision, tape, BIT and
outer transfer are not freshly verified here. The selected record is unchanged.

## Open next questions

Can legal exchanges attain the pooled eight-pattern inventory? Inspect the
literal fill's one rank-16 and two rank-32 residual bins, preserve all source
windows and physical-family constraints, and require complete owner/phase and
release validation. The maximum possible gain is now explicit. A larger change
must alter a named provider or interface premise and reprice its complete cost.
Structured questions and blockers are in `TASK.json`.

Prepared for Ross Richardson with substantial GPT-6.1 Sol assistance, including
two mathematical specialists. Credit Cinna Davis/PR4088; Rohan Arun/PR4076;
Dugongue and David Ganz/PR4085/3945; Nick Petalas; dataisfire/PR3734;
ChaloupeMusic and Erwan Secousses/PR3949/3815; the staged-release, solver,
native, owner and transfer lineage. See `NOTICE.md` and the retained source
notice. Apache-2.0.
Loading