Skip to content

Give native output prefixes optimal unbiased variance (no κ) - #6573

Open
petalas wants to merge 1 commit into
CrocSwap:mainfrom
petalas:research/w5-1102h-shear-obstruction
Open

petalas wants to merge 1 commit into
CrocSwap:mainfrom
petalas:research/w5-1102h-shear-obstruction

Conversation

@petalas

@petalas petalas commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Scoped mathematical proof with exact finite corroboration. The Gaussian native coarse-grid codec can give every fixed output prefix its minimum possible unbiased variance, at most h^2/4, with the same seed length and residue capacity as PR6540.

carry = fresh_uniform_seed
for numerator in fixed_output_order:
    quotient, carry = divmod(numerator + carry, denominator)
    emit quotient

The new step is the translation-compatible native codec, simultaneous prefix optimum and explicit scan cost. Cumulative rounding and scalar variance inequalities are classical. This contribution was produced by Nick Petalas. It builds on Ali Romman's PR6540 at 5f7c893b6af9a75cb19ad22c6db06ed22eea6f54; that source's quotient and native-grid results are cited premises, not audit deliverables. Its exact proof and origin hash are retained. The Dugongue, Ali Romman, Nick Petalas, Cinna Davis, DreamingOfClouds and earlier Gaussian/native/compiler lineage retain credit. Knuth and Doerr, Friedrich, Klein and Osbild retain controlled-rounding credit.

Evidence

Before: on the canonical 512-coordinate rank-eight half-grid input, PR6540's shared threshold gives the sum of real components variance 262144*h^2. After: the same reader is exact, with zero variance. The new uniform bound h^2/4 is attained on a separate input. Individual coordinate marginals and minimum Euclidean mean squared error are unchanged. Both codecs use 5,120 retained bits and nine seed bits in this example. This comparison executes the displayed threshold formula; no predecessor scientific suite was replayed.

The standard-library verifier checks 5,050 complete small residue vectors, 38,860 seed vectors, 10,100 signed translations, 3,264 new codec endpoints, all 1,920 seeds for eight canonical native ranks, 48 additional fine/coarse round trips and twelve controls. A direct floor-of-prefix oracle checks the carry implementation. Generated receipts bind all nine package-file hashes to the computed results.

Local CPython 3.12.15 normal/optimized checks passed, timed separately at 1.054 and 1.085 seconds for the CI deadline check. These are not speedup measurements. Registered package replay, metadata, in-memory syntax compilation, whitespace, committed bytes/source history and official export integrity pass at 64f90d7a7ca010c8c3bf77ca9b3663ee5e957055. An optimized read-only Git-free export replay with empty PATH passes and preserves all ten exported files.

From the repository root:

/Users/nick/git/integer-mult-bounds/.venv/bin/python3.12 -W error -B research/native-prefix-balanced-coarsening/verify.py
/Users/nick/git/integer-mult-bounds/.venv/bin/python3.12 -O -W error -B research/native-prefix-balanced-coarsening/verify.py
/Users/nick/git/integer-mult-bounds/.venv/bin/python3.12 -B scripts/research_package.py --package research/native-prefix-balanced-coarsening
/Users/nick/git/integer-mult-bounds/.venv/bin/python3.12 -B scripts/check_research_commit.py --package research/native-prefix-balanced-coarsening --check-source-history

Any CPython 3.12 path can substitute. Expected markers are PASS_NATIVE_PREFIX_BALANCED_COARSENING, PASS_REGISTERED_RESEARCH_PACKAGE and PASS_RESEARCH_COMMIT_BYTES. Start with research/native-prefix-balanced-coarsening/PROOF.md and README.md.

Limitations

This changes the centre-path-sharing card to a numerical boundary side result. The reader order is fixed before a fresh seed is drawn. Arbitrary later linear readers, adaptive seed reuse and whole-word error are outside the result. The finite implementation instantiates canonical C axes; the written proof covers the cited Gaussian-unit monomial recipes and all tensor widths.

An encode/decode round trip adds 4N remainder extractions, two carry initializations and a k+ceil(rf/2)-bit live carry. The scan is serial. Reversible temporary cleanup, sampling, physical routing, seed/residue lifetimes, tape work, accelerated recursive pricing and actual selected-consumer applicability remain open. No new kappa, selected-frontier change, physical supplier or complete multiplication theorem is claimed. All five framework assumptions remain. Selected cold replay, Lean, Docker, complete native admission, independent human review and formal proof-kernel review are unrun or unclaimed.

Canonical main 7c49fe32c55de02c2c873655c804b16e4c3fef0a, revision 8 and selected6030 were refreshed before submission. Live handoffs/open PRs, reservations and main/merged formula/object searches were checked. The broader overlap snapshot covers 521 open PRs and 6,527 Discussion records. Sparse notes, arbitrary historical diffs, unpublished work and non-atomic concurrent changes remain limits. The investigation stopped at the first verified improvement.

Open next questions

  • Bind one selected native event and enumerate its actual consumer readers. Determine whether a fixed prefix order changes its complete precision budget. The missing consumer and full error invoice are blockers.
  • Lower one 512-coordinate round trip with its 2,048 added remainder steps, carry cleanup and seed/residue lifetimes. Physical routing, reversible gates and a complete paid invoice remain blockers.

Related open work

  • PR6540 is the direct predecessor, supplying common-threshold coarsening and the Gaussian residue codec; the new result changes spatial correlation and retains its coordinate law and capacity.

  • PR6532 gives an actual same-grid stochastic butterfly preserving pair sums; this result coarsens a full native output and optimizes every ordered coordinate prefix, without inheriting its selected binding.

  • PR6509 preserves Gaussian pair and spectator sums deterministically; this result concerns stochastic fine-to-coarse prefix variances and retains an explicit residue label.

  • PR6534 fuses deterministic two-axis rounding; no competing deterministic block-error or addition-count optimum is claimed here.

  • PR6536 gives deterministic three-axis coset rounding; this result supplies neither its nearest-grid classification nor a larger-block counterpart.

  • PR6546 constructs the complete same-grid stochastic caller; this result supplies a different local coarse-grid contract and transfers none of its caller error constants.

  • PR6526 bounds errors at temporal prefixes of the selected word; the prefixes here run across coordinates within one native output.

  • PR6523 binds a rounded width-one child to MOVE9896; this result has no selected source-event binding or competing physical count.

  • PR6438 constructs a same-grid unbiased planar rotation ensemble; this result uses a coarse-period residue representation and answers no extension question about that ensemble.

  • PR6418 bounds adaptive bias from seed reuse; this result explicitly requires a fresh input-independent seed for each forward call.

  • PR6561 optimizes deterministic equivariant frame rounding; this result concerns unbiased prefix variance and asserts no competing equivariance radius.

  • PR6480 supplies exact zero-padding return for rounded spectator rows; no padding-return contract is transferred to this changed codec.

  • PR4017 supplies a reversible native macro with dirty scratch; this result leaves physical gate and workspace pricing open.

  • PR6574 constructs a deterministic same-grid four-axis Gaussian bijection with a block-error optimum; this contribution gives stochastic fine-to-coarse prefix variances and retains a residue label, with no competing block-error optimum.

The completion refresh screened six other account open PRs created since the advance CLAIM: #6571, #6572 and #6574 through #6577. PR6574 is the additional adjacent Gaussian-rounding entry above. The other five concern scalar correction, phase metadata, atom-power tariffs, ADDRESS coefficients and parity fanout. No extra computations were run to audit or compare those results, and no conflicting value of this contribution's prefix variance was identified.

CI notes

Both hosted checks, plan and replay (research/native-prefix-balanced-coarsening), passed at head 64f90d7a7ca010c8c3bf77ca9b3663ee5e957055 in run 41616742809. Plan took 3m51s and the registered replay took 1m25s. The completed checks were read once; run metadata confirms completed success and the matching head. Hosted replay executes both registered normal and optimized commands. Local registered/direct replays, metadata, committed bytes/source history and read-only export checks also passed. These checks certify execution of the scoped finite checks and source bindings; independent mathematical acceptance remains separate.

Advance CLAIM.

Merge danger

Door: two-way. Blast radius: isolated. Only nine new files under research/native-prefix-balanced-coarsening/; the retained source proof is byte-exact. No shared implementation or selected-frontier files change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant