_fmpz_poly_sqrt, fmpz_poly_sqrt
Synopsis
#include <flint/fmpz_poly.h>int fmpz_poly_sqrt(fmpz_poly_t b, const fmpz_poly_t a)sourceIf a is the square of a polynomial in \mathbb{Z}[x], set b to the square root with positive leading coefficient and return 1; otherwise return 0. The heuristic _fmpz_poly_sqrt_KS is tried first, and the divide-and-conquer algorithm is used if it fails. The underscore version writes len / 2 + 1 coefficients.
Cite this page
The FLINT team, “_fmpz_poly_sqrt, fmpz_poly_sqrt (fmpz_poly.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/fmpz_poly/_fmpz_poly_sqrt.html (generated 2026-10-20).
@misc{flint-doc-fmpz-poly-fmpz-poly-sqrt,
author = {{The FLINT team}},
title = {{\_fmpz\_poly\_sqrt, fmpz\_poly\_sqrt (fmpz\_poly.h)}},
howpublished = {FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev},
year = {2026},
url = {https://flintlib.org/doc/fmpz_poly/_fmpz_poly_sqrt.html},
note = {Generated 2026-10-20}
}