FLINT3.7.0-dev

nmod_poly_set_trunc, nmod_poly_truncate

Synopsis#include <flint/nmod_poly.h>
void nmod_poly_set_trunc(nmod_poly_t res, const nmod_poly_t poly, slong len)source
void nmod_poly_truncate(nmod_poly_t poly, slong len)source

Set res to poly truncated to length len, that is, poly modulo x^{\mathit{len}}, and truncate poly in place. The result is normalised. Nothing happens if len is at least the length.

Cite this page

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