feat(real-roots-mathlib): checked root counts and a simpler Sturm API - #10101
Draft
kim-em wants to merge 6 commits into
Draft
feat(real-roots-mathlib): checked root counts and a simpler Sturm API#10101kim-em wants to merge 6 commits into
kim-em wants to merge 6 commits into
Conversation
kim-em
force-pushed
the
nauty-applications
branch
from
September 7, 2026 12:27
ede4b1a to
5561ec6
Compare
added 5 commits
September 7, 2026 12:29
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.
Add
by real_root_countand the term formreal_root_count ptoHexRealRootsMathlib. They certify the number of distinct real roots of a closed, squarefree integer-coefficient polynomial overℚof positive degree. Hex proposes a signed remainder chain; ordinary Lean proofs check the polynomial identities, positive factors, derivative relation, and variation count.This carries the mathematical and elaborator improvements from Mathlib #43512 back into the Hex source of truth:
roots.Nodup, and permit equal interval endpoints.ℝ.Hex.DensePoly.divMod, and add focused diagnostics and regression tests.scripts/check_sturm_sync.py /path/to/mathlibcompares the five library modules and both test modules after translating module paths, namespaces, and documentation markup. The README documents the new entry point, and the release test target includes both new test modules. The companion copies can become re-exports once Hex's Mathlib pin contains the development.Validation: full
lake build;lake build HexReleaseTests, including root-count, Sturm endpoint, and existing isolation regression tests; release-manifest validation; the seven-module sync check; andgit diff --check. The monorepo retains its pre-existingsorrywarnings in unrelated multivariate libraries and line-length warnings in the manual; this change introduces none. The corresponding Mathlib theorem and certificate axiom audits report onlypropext,Classical.choice, andQuot.sound.HexArith and HexModArith’s C build recipes set
TMPDIRto the object directory for each compiler process. This supports Mathlib’s Landlock sandbox, which allows writes inside.lakebut forbids/tmp, including whenccis a compiler wrapper. Release sync copies the selected recipes from the monorepo Lake file; its tests check preservation of the mirror skeleton, idempotence, and rejection of missing or ambiguous helpers. All three affected C objects were rebuilt under Landlock with/tmpunwritable.