module Mpqf:sig
..end
Mpq
. These functions are less efficients, due to
the additional memory allocation neded for the result.type
t
val to_mpq : t -> Mpq.t
val of_mpq : Mpq.t -> t
There is no sharing between the argument and the result.
val mpq : t -> Mpq.t
val mpqf : Mpq.t -> t
The argument and the result actually share the same number: be cautious !
val print : Format.formatter -> t -> unit
val of_string : string -> t
val of_float : float -> t
val of_int : int -> t
val of_frac : int -> int -> t
val of_mpz : Mpz.t -> t
val of_mpz2 : Mpz.t -> Mpz.t -> t
val of_mpzf : Mpzf.t -> t
val of_mpzf2 : Mpzf.t -> Mpzf.t -> t
val to_string : t -> string
val to_float : t -> float
val to_mpzf2 : t -> Mpzf.t * Mpzf.t
val add : t -> t -> t
val sub : t -> t -> t
val mul : t -> t -> t
val div : t -> t -> t
val neg : t -> t
val abs : t -> t
val inv : t -> t
val equal : t -> t -> bool
val cmp : t -> t -> int
val cmp_int : t -> int -> int
val cmp_frac : t -> int -> int -> int
val sgn : t -> int
val get_num : t -> Mpzf.t
val get_den : t -> Mpzf.t