HORIZON HASKELLDocslts/ghc-10.0.x2b276322026-10-31Search packagesCtrl K
Theme: |

GHC 10.0.0.20260917 · lts/ghc-10.0.x · 2b27632 · 2026-10-31

Modulecryptonite-0.30Haskell2010

Crypto.Number.Basic

Synopsis
  • Packagecryptonite-0.30
  • Exports7
  • LanguageHaskell2010
  • LicenceBSD-3-Clause
  • SourceBasic.hs
valuesqrti :: Integer -> (Integer, Integer)

sqrti returns two integers (l,b) so that l <= sqrt i <= b. The implementation is quite naive, use an approximation for the first number and use a dichotomy algorithm to compute the bound relatively efficiently.