FLINT3.7.0-dev

fq_default_pow, fq_default_pow_ui

Synopsis#include <flint/fq_default.h>
void fq_default_pow(fq_default_t rop, const fq_default_t op1, const fmpz_t e, const fq_default_ctx_t ctx)source
void fq_default_pow_ui(fq_default_t rop, const fq_default_t op, const ulong e, const fq_default_ctx_t ctx)source

Set rop to ope\mathit{op}^e, with 00=10^0 = 1. In fq_default_pow the exponent may be negative if op is nonzero; 0e0^e with e<0e < 0 throws FLINT_ERROR.

The power is computed by gr_pow_fmpz or gr_pow_ui for the representation. The polynomial representations reduce ee modulo q−1q - 1 when e≥pe \ge p and use binary exponentiation, which costs O(log⁡min⁡(e,q))O(\log \min(e, q)) multiplications in Fq\mathbb{F}_q; the Zech representation needs one multiplication of the discrete logarithm by ee modulo q−1q - 1.

Guides#

Cite this page

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