package alt-ergo-lib

  1. Overview
  2. Docs
type rounding_mode =
  1. | NearestTiesToEven
  2. | ToZero
  3. | Up
  4. | Down
  5. | NearestTiesToAway
  6. | Aw
  7. | Od
  8. | No
  9. | Nz
  10. | Nd
  11. | Nu
val fpa_rounding_mode : Ty.t
val rounding_mode_of_hs : Hstring.t -> rounding_mode
val integer_log_2 : Numbers.Q.t -> int

Integer part of binary logarithm for NON-ZERO POSITIVE number *

val float_of_rational : int -> int -> rounding_mode -> Numbers.Q.t -> Numbers.Q.t * Numbers.Z.t * int

float_of_rational prec exp mode x float approx of a rational constant. The function also returns the mantissa and the exponent. i.e. if res, m, e = float_of_rational prec exp mode x, then res = m * 2^e *

val round_to_integer : rounding_mode -> Numbers.Q.t -> Numbers.Q.t

round_to_integer mode x rounds the rational x to an integer depending on the rounding mode mode

val empty_cache : unit -> unit

Empties the module's inner cache

OCaml

Innovation. Community. Security.