Repository navigation
Implement exact FFT word multiplication on fixed tapes - #3787
Merged
Mister-Meeseeks merged 2 commits intoOct 20, 2026
Merged
Conversation
jmbarrancoml
marked this pull request as ready for review
October 18, 2026 21:09
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I implement exact unsigned n-bit multiplication in the retained fixed-tape model, with
O(n log2(n+2)^2)time andO(n)space. I apply the classical radix-digit reduction through corrected PR3709, head62264289adb01f3ba4930cd0154c75887f96203c, while retaining its internal Karatsuba multiplier. The dependency is acyclic.I choose
b=ceil(log2 n),q=ceil(n/b), minimalr=2^ell>=2q, andp0=2b+ell. The normalized returnQ_p0(fg/r)has exact ordinary convolution coefficients as real numerators because2^p0=r*2^(2b)and the degree is below r. Sequential carries recover the exact 2n-bit result. I preserve borrowed values and heads, consume protected child outputs and restore fixed scratch. The full bill includes unamortized twiddle setup for A=C=1.This supplies a concrete scalar primitive for the Gaussian arithmetic handoff after PR3763. With delta=.0001, I derive arithmetic power .9981 below the inherited full Fourier power .99827619697. I leave Gaussian coefficient production, guarded convolutions, factor-page access, window restoration and the complete CRT/integer join open.
I started from canonical main
20ecf2891d80b5acf18d980b2164fb44ea7faa90, priority revision 6, and recorded the expansion decision before implementation in Discussion3664. Before submission I refreshed main and searched 491 open PRs and 2,509 Discussion records. The PR changes onlyresearch/physical-fft-word/.I register seven suites: actual default FFT products at 17 and 19 bits, integration with the retained signed Arithmetic caller, base reuse, separate codec fixtures through 1,024 bits, large encoded geometry, 13 failure controls, source authentication and exact cost arithmetic.
PROOF.mdgives the all-size argument;EVIDENCE.mddistinguishes full execution from codec and metadata checks. Reproduce withpython3.12 scripts/research_package.py --package research/physical-fft-word.Validation at
9b5474f47b0ea9a3c76bb5b1b577fb36704815e0:d428e8b6aef4d348fa2e922ca64c4cfd634bbb2f0c150033273e65fcf4600b49; receipt SHA256:237ccd34aadda692f73b85277816b76168acaecfe06a12996cce37a7f0925cbc.97bbd90bca3ae03b8b6d9e6044b1fd5f3a2d2be0.I retain PR3709's numerical precision/recovery premises and Arham Tahir's separate audit as pending author work. I credit the standard FFT/radix and Karatsuba algorithms, Mason Hale's certified interval reference, Dugongue's scalar-ABI precedent, the retained rad20 Gaussian reports and the nested source notices. I leave the selected frontier unchanged. Jose Manuel (
jmbarrancoml), with substantial OpenAI Codex assistance in mathematics, implementation, source analysis and checks; I claim no independent human or formal-kernel review.