_nmod_poly_pow_trunc, nmod_poly_pow_trunc, _nmod_poly_pow_trunc_binexp, nmod_poly_pow_trunc_binexp
Synopsis
#include <flint/nmod_poly.h>void nmod_poly_pow_trunc(nmod_poly_t res, const nmod_poly_t poly, ulong e, slong trunc)sourcevoid _nmod_poly_pow_trunc_binexp(nn_ptr res, nn_srcptr poly, ulong e, slong trunc, nmod_t mod)sourcevoid nmod_poly_pow_trunc_binexp(nmod_poly_t res, const nmod_poly_t poly, ulong e, slong trunc)sourceSet res to by binary exponentiation with truncated products; the two pairs of functions are the same. The underscore versions read exactly trunc coefficients of poly (zero-pad shorter inputs), require and , write trunc coefficients and do not allow aliasing.
For a power series with constant term 1 and much larger than trunc, with nmod_poly_log_series and nmod_poly_exp_series can be faster, provided the modulus is a prime larger than trunc.
Cite this page
The FLINT team, “_nmod_poly_pow_trunc, nmod_poly_pow_trunc, _nmod_poly_pow_trunc_binexp, nmod_poly_pow_trunc_binexp (nmod_poly.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/nmod_poly/_nmod_poly_pow_trunc.html (generated 2026-11-02).
@misc{flint-doc-nmod-poly-nmod-poly-pow-trunc,
author = {{The FLINT team}},
title = {{\_nmod\_poly\_pow\_trunc, nmod\_poly\_pow\_trunc, \_nmod\_poly\_pow\_trunc\_binexp, nmod\_poly\_pow\_trunc\_binexp (nmod\_poly.h)}},
howpublished = {FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev},
year = {2026},
url = {https://flintlib.org/doc/nmod_poly/_nmod_poly_pow_trunc.html},
note = {Generated 2026-11-02}
}