FLINT3.7.0-dev

fmpz_init2

Synopsis#include <flint/fmpz.h>
void fmpz_init2(fmpz_t f, ulong limbs)source

Initialises f to zero with space for limbs limbs. If limbs is zero, this is fmpz_init; otherwise an mpz is attached and grown to limbs limbs, so that f is temporarily not in canonical form (its value is 0 in an mpz) until the first assignment. Only useful to avoid reallocations when the final size is known.

Cite this page

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