FLINT3.7.0-dev

gr_generic_randtest_small

Synopsis#include <flint/gr_generic.h>
int gr_generic_randtest_small(gr_ptr x, flint_rand_t state, gr_ctx_t ctx)source

Sets x to ag+ba g + b with random integers a,b∈[−3,3]a, b \in [-3, 3], where gg is the generator of the ring if gr_gen succeeds and 0 otherwise, divided with probability 1/4 by a random integer in [1,4][1, 4] when the division succeeds; falls back to a small integer and then to zero.

Cite this page

The FLINT team, “gr_generic_randtest_small (gr_generic.h),” FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev, 2026. https://flintlib.org/doc/gr_generic/gr_generic_randtest_small.html (generated 2026-11-02).