Repository navigation
feat(arithmetic): add casting-out residues and delayed mod-17 reduction - #273
Conversation
Table-free modulo-15 residue of a canonical u4 vector (running and ladder schedules), a delayed-reduction modulo-17 schedule, and u32 residues modulo 255 and 65,535. Keeping the sum exact and reducing once saves 31% (mod 15) and 33% (mod 17) at 64 nibbles, 38% at 997, with the same peak. Evidence locally-reproduced; execution unclassified. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c45c797a60
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Review of The reproduction instructions pass two positional test filters to Cargo; that command fails before running tests. Split the mod15/mod17 commands. More importantly for the claimed The current CI is green; these are contract, boundary, or evidence gaps that those checks do not cover. |
# Conflicts: # knowledge/catalog.json # src/arithmetic/u4/README.md
|
Thanks, @RobinLinus! The reproduction commands now use separate Cargo filters, and tests pin both 997-nibble fragment sizes. I documented the terminal residue check and clean-stack obligation, and aligned the recorded metrics with execution of the exact policy-compiled fragments under the stated profile. Focused tests, metrics and knowledge validation pass on the merged base; CI is running and the full non-field suite is queued. |
Summary
u4::mod15(base-16 integer residue modulo 15, running and delayed-ladder schedules),u4::mod17::u4_nibbles_to_mod17_delayed(same residue as the existing fold, reduced once at the end), andu32::mersenne_residue(u32_mod255,u32_mod65535).u4_nibbles_to_mod17and its tests are unchanged; the delayed schedule is additive.Evidence
n+3); the running form wins only below four nibbles. u32 byte-sum residues: 87 (mod 255) and 115 (mod 65,535) bytes vs 100 for mod 65,537. Sizes pinned by tests.locally-reproduced; executionunclassified. No Bitcoin Core validation or deployability claim.Test plan
CARGO_PROFILE_DEV_OPT_LEVEL=1 CARGO_PROFILE_TEST_OPT_LEVEL=1 cargo test --locked -- --skip fields::(all suites pass)python3 tools/kb.py validate🤖 Generated with Claude Code