Hex
hex is executable computer algebra for Lean 4: finite and number fields,
polynomial factorization, root isolation, and lattice reduction. The
computational core is Mathlib-free; theory companions state correspondence
contracts and, for mature libraries, supply their proofs.
Contents
- 1. HexBasic: shared dependency-free utilities
- 2. HexTruncatedSeries: power series to a fixed precision
- 3. HexArith: low-level arithmetic foundations
- 4. HexModular: Chinese remaindering and rational reconstruction
- 5. HexPrimality: certified primality at scale
- 6. HexECPP: proving primality with elliptic curves
- 7. HexPoly: normalized dense polynomials
- 8. HexPolyFast: fast dense polynomials
- 9. HexMvPoly: executable sparse multivariate polynomials
- 10. HexSparsePoly: sparse univariate polynomials
- 11. HexModArith: machine-word modular arithmetic
- 12. HexPolyFp: prime-field dense polynomials
- 13. HexPolyZ: integer dense polynomials
- 14. HexGFqRing: executable Fₚ quotient ring
- 15. HexHensel: executable Hensel lifting
- 16. HexRoots: certified complex-root isolation
- 17. HexRealRoots: certified real-root isolation
- 18. HexRCF: a decision procedure for univariate real arithmetic
- 19. HexMatrix: dense matrices and arithmetic
- 20. HexRowReduce: Gauss-Jordan reduction, span, and nullspace
- 21. HexBerlekamp: factorization over finite fields
- 22. HexGF2: packed GF(2) polynomials and GF(2ⁿ) fields
- 23. HexGFqField: executable GF(pⁿ)
- 24. HexConway: verified Conway-polynomial lookup
- 25. HexGFq: canonical finite-field constructors
- 26. HexDeterminant: the Leibniz determinant and cofactor theory
- 27. HexBareiss: the fraction-free determinant
- 28. HexResultant: subresultants and discriminants
- 29. HexGramSchmidt: Gram-Schmidt orthogonalization
- 30. HexLLL: lattice basis reduction
- 31. HexBerlekampZassenhaus: factorization over the integers
-
32.
factor_polyandirreducibility: certified factoring - 33. HexNumberField: exact algebraic numbers
- 34. HexNumberFieldTower: successive algebraic extensions
- 35. HexPermGroup: computing with permutation groups
- 36. HexGraphIso: coloured graph canonical labelling
-
37. The
nautycanonical labelling algorithm - 38. Tutorials
- 39. Draft sections for unreleased libraries