FLINT3.7.0-dev

mpn_mod_is_zero, mpn_mod_is_one, mpn_mod_is_neg_one, mpn_mod_equal

Synopsis#include <flint/mpn_mod.h>
truth_t mpn_mod_is_zero(nn_srcptr x, gr_ctx_t ctx)source
truth_t mpn_mod_is_one(nn_srcptr x, gr_ctx_t ctx)source
truth_t mpn_mod_is_neg_one(gr_srcptr x, gr_ctx_t ctx)source
truth_t mpn_mod_equal(nn_srcptr x, nn_srcptr y, gr_ctx_t ctx)source

Return T_TRUE if x = 0, x = 1, x = n - 1 or x = y, and T_FALSE otherwise. Since residues are reduced, these compare limbs.

Cite this page

The FLINT team, “mpn_mod_is_zero, mpn_mod_is_one, mpn_mod_is_neg_one, mpn_mod_equal (mpn_mod.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/mpn_mod/mpn_mod_is_zero.html (generated 2026-10-20).