FLINT3.7.0-dev

gr_init, gr_clear

Synopsis#include <flint/gr.h>
void gr_init(gr_ptr res, gr_ctx_t ctx)source
void gr_clear(gr_ptr res, gr_ctx_t ctx)source

Initialise res, which must point to ctx->sizeof_elem bytes of memory, to the zero element of the ring; respectively clear it, freeing any memory the element owns but not the memory it occupies.

Cite this page

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