FLINT3.7.0-dev

nmod_poly_randtest_trinomial_irreducible, nmod_poly_randtest_pentomial_irreducible

Synopsis#include <flint/nmod_poly.h>
int nmod_poly_randtest_trinomial_irreducible(nmod_poly_t poly, flint_rand_t state, slong len, slong max_attempts)source
int nmod_poly_randtest_pentomial_irreducible(nmod_poly_t poly, flint_rand_t state, slong len, slong max_attempts)source

Try up to max_attempts random trinomials, respectively pentomials, as above and return 1 as soon as one is irreducible, or 0 if none is. For max_attempts = 0 they try until they succeed, which does not terminate if there is no irreducible polynomial of that shape.

Cite this page

The FLINT team, “nmod_poly_randtest_trinomial_irreducible, nmod_poly_randtest_pentomial_irreducible (nmod_poly.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/nmod_poly/nmod_poly_randtest_trinomial_irreducible.html (generated 2026-10-20).