FLINT3.7.0-dev

flint_mpn_get_d

Synopsis#include <flint/mpn_extras.h>
double flint_mpn_get_d(mp_srcptr ptr, mp_size_t size, mp_size_t sign, long exp)source

Returns the double nearest towards zero to ±(ptr,size)⋅2exp\pm (\mathit{ptr}, \mathit{size}) \cdot 2^{\mathit{exp}}, where the sign is that of sign. Requires size ≥0\ge 0 and a nonzero top limb if size >0> 0. Overflow gives an infinity of the right sign and underflow (below the denormal range) gives zero. This is a copy of GMP's internal mpn_get_d.

Cite this page

The FLINT team, “flint_mpn_get_d (mpn_extras.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/mpn_extras/flint_mpn_get_d.html (generated 2026-11-02).