flint_mpn_gcd_full2, flint_mpn_gcd_full
Synopsis
#include <flint/mpn_extras.h>mp_size_t flint_mpn_gcd_full2(mp_ptr arrayg, mp_srcptr array1, mp_size_t limbs1, mp_srcptr array2, mp_size_t limbs2, mp_ptr temp)sourcemp_size_t flint_mpn_gcd_full(mp_ptr arrayg, mp_srcptr array1, mp_size_t limbs1, mp_srcptr array2, mp_size_t limbs2)sourceSet (\mathit{arrayg}, \ell) to the greatest common divisor of (\mathit{array1}, \mathit{limbs1}) and (\mathit{array2}, \mathit{limbs2}) and return its length \ell. Unlike GMP's mpn_gcd, the inputs need not be odd or ordered by size, and they are not destroyed; they must be nonzero with nonzero top limbs. temp must provide \mathit{limbs1} + \mathit{limbs2} limbs of scratch space, or be NULL. The common power of 2 is removed first and GMP's mpn_gcd is called on the odd parts.
Cite this page
The FLINT team, “flint_mpn_gcd_full2, flint_mpn_gcd_full (mpn_extras.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/mpn_extras/flint_mpn_gcd_full2.html (generated 2026-10-20).
@misc{flint-doc-mpn-extras-flint-mpn-gcd-full2,
author = {{The FLINT team}},
title = {{flint\_mpn\_gcd\_full2, flint\_mpn\_gcd\_full (mpn\_extras.h)}},
howpublished = {FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev},
year = {2026},
url = {https://flintlib.org/doc/mpn_extras/flint_mpn_gcd_full2.html},
note = {Generated 2026-10-20}
}