Convert rational to fixed-point decimal number

James Cloos cloos at jhcloos.com
Sun Feb 28 01:10:38 CET 2010


>>>>> "Torbjorn" == Torbjorn Granlund <tg at gmplib.org> writes:

> I try to use mpq_ functions in my program. How can I convert mpq_t
> type to fixed-point decimal number without loss precision (without
> using double IEEE)?
  
Torbjorn> I am not sure what function you need.

It sounds like what he wants gmp_printf(3).

-JimC
-- 
James Cloos <cloos at jhcloos.com>         OpenPGP: 1024D/ED7DAEA6


More information about the gmp-discuss mailing list