FLINT3.7.0-dev

gr_generic_is_square, gr_generic_sqrt, gr_generic_rsqrt

Synopsis#include <flint/gr_generic.h>
truth_t gr_generic_is_square(gr_srcptr x, gr_ctx_t ctx)source
int gr_generic_sqrt(gr_ptr res, gr_srcptr x, gr_ctx_t ctx)source
int gr_generic_rsqrt(gr_ptr res, gr_srcptr x, gr_ctx_t ctx)source

Handle 0 and 1 (and for gr_generic_rsqrt, compute 1/\sqrt{x} from gr_sqrt and gr_inv when both succeed; 1/\sqrt{0} is GR_DOMAIN), and return GR_UNABLE or T_UNKNOWN otherwise.

Cite this page

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