FLINT3.7.0-dev

_nmod_poly_revert_series, nmod_poly_revert_series

Synopsis#include <flint/nmod_poly.h>
void _nmod_poly_revert_series(nn_ptr Qinv, nn_srcptr Q, slong Qlen, slong n, nmod_t mod)source
void nmod_poly_revert_series(nmod_poly_t Qinv, const nmod_poly_t Q, slong n)source

Set Qinv to the compositional inverse of the power series Q modulo x^n, so that Q(\mathit{Qinv}(x)) = \mathit{Qinv}(Q(x)) = x \bmod x^n. Requires Q_0 = 0 and Q_1 invertible; the non-underscore version throws FLINT_ERROR otherwise. The underscore version writes n coefficients and does not allow aliasing.

For n < 2500 the fast Lagrange inversion of [Joh2015b] is used, which divides by 1, \ldots, n - 1; if one of them is not invertible (small characteristic), and for larger n, Newton iteration with power series composition is used instead.

References#

Cite this page

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