Problem converting IEEE 754 binary to double

Lars Rößiger lars.roessiger at d33.net
Thu Oct 27 15:49:33 CEST 2005


Hello!

I'm trying to convert this binary to a double:

0xEA82B0091FD02540

This binary is little endian, so I switched the bytes and are using this
binary instead:

0x4025D01F09B082EA

I played around with mpf_set_str() and mpf_get_d() without any success.
GMP never returns the correct corresponding double (which would be
around 10.9064868).

Can anyone point me into the right direction?

Thank you,
Lars


More information about the gmp-discuss mailing list