module Rationals: sig
.. end
Operations on rational numbers, subset of the Ratio OCaml module.
type
ratio
val create_ratio : Integers.big_int -> Integers.big_int -> ratio
val create_normalized_ratio : Integers.big_int -> Integers.big_int -> ratio
val sign_ratio : ratio -> int
val abs_ratio : ratio -> ratio
val floor_ratio : ratio -> Integers.big_int
val ceiling_ratio : ratio -> Integers.big_int
val integer_ratio : ratio -> Integers.big_int
val round_ratio : ratio -> Integers.big_int
val normalize_ratio : ratio -> ratio
val is_integer_ratio : ratio -> bool
val numerator_ratio : ratio -> Integers.big_int
val denominator_ratio : ratio -> Integers.big_int
val null_denominator : ratio -> bool
val add_int_ratio : int -> ratio -> ratio
val add_big_int_ratio : Integers.big_int -> ratio -> ratio
val add_ratio : ratio -> ratio -> ratio
val minus_ratio : ratio -> ratio
val sub_ratio : ratio -> ratio -> ratio
val report_sign_ratio : ratio -> Integers.big_int -> Integers.big_int
val mult_ratio : ratio -> ratio -> ratio
val mult_int_ratio : int -> ratio -> ratio
val mult_big_int_ratio : Integers.big_int -> ratio -> ratio
val div_ratio : ratio -> ratio -> ratio
val div_int_ratio : int -> ratio -> ratio
val div_ratio_int : ratio -> int -> ratio
val div_big_int_ratio : Integers.big_int -> ratio -> ratio
val div_ratio_big_int : ratio -> Integers.big_int -> ratio
val eq_ratio : ratio -> ratio -> bool
val eq_big_int_ratio : Integers.big_int -> ratio -> bool
val compare_ratio : ratio -> ratio -> int
val compare_big_int_ratio : Integers.big_int -> ratio -> int
val int_of_ratio : ratio -> int
val ratio_of_int : int -> ratio
val big_int_of_ratio : ratio -> Integers.big_int
val ratio_of_big_int : Integers.big_int -> ratio
val float_of_ratio : ratio -> float
val string_of_ratio : ratio -> string
val ratio_of_string : string -> ratio
val approx_ratio_fix : int -> ratio -> string
val approx_ratio_exp : int -> ratio -> string