_arf_mpn_cinv_approx, _arf_mpn_cdiv_approx, _arf_mpn_csqrt_approx, _arf_mpn_crsqrt_approx
#include <flint/arf.h>void _arf_mpn_cinv_approx(nn_ptr re, slong * reexp, nn_ptr im, slong * imexp, nn_srcptr a, slong an, slong ea, nn_srcptr b, slong bn, slong eb, slong prec)sourcevoid _arf_mpn_cdiv_approx(nn_ptr re, slong * reexp, int * reneg, nn_ptr im, slong * imexp, int * imneg, nn_srcptr a, slong an, slong ea, int sa, nn_srcptr b, slong bn, slong eb, int sb, nn_srcptr c, slong cn, slong ec, int sc, nn_srcptr d, slong dn, slong ed, int sd, slong prec)sourcevoid _arf_mpn_csqrt_approx(nn_ptr re, slong * reexp, nn_ptr im, slong * imexp, nn_srcptr a, slong an, slong ea, int sa, nn_srcptr b, slong bn, slong eb, slong prec)sourcevoid _arf_mpn_crsqrt_approx(nn_ptr re, slong * reexp, nn_ptr im, slong * imexp, nn_srcptr a, slong an, slong ea, int sa, nn_srcptr b, slong bn, slong eb, slong prec)sourceThe reciprocal, the quotient, the square root and the reciprocal square root of complex numbers given as mantissa/exponent pairs: a part is with a normalised mantissa, a nonzero magnitude and an slong exponent far from overflow (the callers scale extreme operands). The _approx flavour writes limbs per part, each within about an ulp of the magnitude of the result (the parts truncated), with the exponents of the parts (WORD_MIN for an exactly cancelled part of the quotient); the outputs are the magnitudes of the parts, the signs being the caller's unless stated. The reciprocal is with , written as and . The quotient with , and takes the signs of the operands and returns those of the parts. The square root is with for and for (the imaginary part has the sign of ); the reciprocal square root is resp. with and (the imaginary part has the sign opposite to ). The outputs may alias the operands' limbs.
The compositions of nfloat_complex on the _approx kernels, every intermediate held at limbs (the guard limb keeps the few ulps of the compositions below the ulp of the output, as the of acf's callers requires) and each kernel within an ulp: from two approximate squares and a truncated sum, one reciprocal shared by the two parts of a quotient (a division costs several products), by the exact root, the larger part of a root first so that nothing cancels.
The FLINT team, “_arf_mpn_cinv_approx, _arf_mpn_cdiv_approx, _arf_mpn_csqrt_approx, _arf_mpn_crsqrt_approx (arf.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/arf/_arf_mpn_cinv_approx.html (generated 2026-11-20).
@misc{flint-doc-arf-arf-mpn-cinv-approx,
author = {{The FLINT team}},
title = {{\_arf\_mpn\_cinv\_approx, \_arf\_mpn\_cdiv\_approx, \_arf\_mpn\_csqrt\_approx, \_arf\_mpn\_crsqrt\_approx (arf.h)}},
howpublished = {FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev},
year = {2026},
url = {https://flintlib.org/doc/arf/_arf_mpn_cinv_approx.html},
note = {Generated 2026-11-20}
}