module Mpqf:GMP multi-precision rationals, functional versionsig..end
Mpq. These functions are less efficients, due to
the additional memory allocation neded for the result.type'att ='a Mpq.tt
typet =Mpq.f tt
val to_mpq : t -> 'a Mpq.ttval of_mpq : 'a Mpq.tt -> t
There is no sharing between the argument and the result.
val _mpq : t -> Mpq.tval _mpqf : Mpq.t -> t
Sharing between the argument and the result.
val print : Format.formatter -> 'a tt -> unitval of_string : string -> tval of_float : float -> tval of_int : int -> tval of_frac : int -> int -> tval of_mpz : 'a Mpz.tt -> tval of_mpz2 : 'a Mpz.tt -> 'b Mpz.tt -> tval to_string : 'a tt -> stringval to_float : 'a tt -> floatval to_mpzf2 : 'a tt -> Mpzf.t * Mpzf.tval add : 'a tt -> 'b tt -> tval sub : 'a tt -> 'b tt -> tval mul : 'a tt -> 'b tt -> tval div : 'a tt -> 'b tt -> tval neg : 'a tt -> tval abs : 'a tt -> tval inv : 'a tt -> tval equal : 'a tt -> 'b tt -> boolval cmp : 'a tt -> 'b tt -> intval cmp_int : 'a tt -> int -> intval cmp_frac : 'a tt -> int -> int -> intval sgn : 'a tt -> intval get_num : t -> Mpzf.tval get_den : t -> Mpzf.t