FLINT3.7.0-dev

flint_mpn_factor_trial

Synopsis#include <flint/mpn_extras.h>
int flint_mpn_factor_trial(mp_srcptr x, mp_size_t xsize, slong start, slong stop)source

Searches for a factor of (x,xsize)(x, \mathit{xsize}) among the primes flint_primes[i] for start ≤i<\le i < stop. Returns the first such ii for which the prime divides xx, and 0 if there is none. Requires start ≥1\ge 1, so that 0 is never a valid index.

Cite this page

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