arithmetic

Natural number arithmetic

Latest on Hackage:1.6

This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow stackage.org to host generated Haddocks.

MIT licensed and maintained by Joe Leslie-Hurd

This package implements a library of natural number arithmetic, including Montgomery multiplication, the Miller-Rabin primality test, Lucas sequences, the Williams p+1 factorization method, continued fraction representations of natural number square roots, the Jacobi symbol, the Tonelli-Shanks algorithm for finding square roots modulo a prime, and the Chakravala method for solving the Pell equation.