Repository navigation
Learn modulo a prime whether the elimination over the rationals declines - #2007
Merged
Merged
Conversation
TrySolveOverPolynomials' reading and Bareiss elimination now run first on the system's image modulo 2^31 - 1: the same readings, pivots, products and exact divisions, in residues that cost a machine multiplication where a minor's rationals cost a greatest common divisor. The intermediates are minors, so each image has no monomial the rational one lacks, and a product past the term bound, an exponent past the degree bound, a refused entry or a row reducing to 0 = c there is one over Q too. The solve over Q is then declined at once. Anything else says nothing, and the solve runs as before; nothing is answered on the strength of the images. The Hermite reductions of Rubi's 1/(a + b cosh(x) + c sinh(x))^n under u = e^x are twenty-row systems whose minors pass four thousand terms by the sixth pivot, and they spent seconds each before declining. Pocket of 1,951 rows: verdicts identical, 1,889 solved on both. Over the 1,886 solved on both, allocation 654 -> 429 GB, time 812 -> 733 s; 6.7.1:866 21.6 s -> 3.4 s (57.7 -> 1.3 GB), 880 16.0 s -> 1.6 s. Samples of every family unchanged. The five rows that moved, re-run alone: 6.7.1:921 and 929 timeout -> 2.0 s and 2.8 s; the other three identical in allocation. No row's allocation grew past 1.3x. Part of #233. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura
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.
Part of #233.
TrySolveOverPolynomials' reading and Bareiss elimination now run first on the system's image modulo2^31 - 1. These are the same readings, pivots, products and exact divisions, but in residues, where a multiplication costs one machine instruction and a minor's rationals cost a greatest common divisor. The intermediates are minors, so an image has no monomial that the rational one lacks. Any of these on the image is therefore one over Q too, and the solve over Q is declined at once:MaxIntermediateTerms;MaxDegree;0 = c.Anything else says nothing, such as an image that does not exist or a division that does not come out, and the solve runs as before. Nothing is ever answered on the strength of the images.
The images can mislead only where a nonzero polynomial of the elimination vanishes modulo the prime, i.e. every coefficient a multiple of
2^31 - 1. That would decline a system that would otherwise be solved. None of the measured rows does.The Hermite reductions of Rubi's
1/(a + b cosh(x) + c sinh(x))^nunderu = e^xare twenty-row systems whose minors pass four thousand terms by the sixth pivot. They spent seconds each before declining, and the rule reached after the decline answers in milliseconds.Measured against master 20a4b39, then rebased onto a567c8b:
The five rows that moved, re-run alone:
No row solved on both grew its allocation past 1.3×. The one wrong in the pocket, 6.1.5:94, is wrong on master too.
Answers are unchanged, so there is no BREAKING-CHANGES entry. Master a567c8b answers 921 and 929 too, given 60 s, and the answers are identical character for character: 23.1 s and 49.8 GB, and 27.4 s and 61.3 GB, there; 3.9 s and 1.2 GB, and 5.7 s and 1.5 GB, here.
🤖 Generated with Claude Code
https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura