FLINT3.7.0-dev

dirichlet_pairing, dirichlet_pairing_char

Synopsis#include <flint/dirichlet.h>
ulong dirichlet_pairing(const dirichlet_group_t G, ulong m, ulong n)source
ulong dirichlet_pairing_char(const dirichlet_group_t G, const dirichlet_char_t a, const dirichlet_char_t b)source

Return the exponent of \chi_q(m, n) modulo G->expo, or DIRICHLET_CHI_NULL if m or n is not coprime to q. The pairing is symmetric: \chi_q(m, n) = \chi_q(n, m). The _char version takes both arguments as elements with their logs and needs no discrete logarithm; the other computes two.

Cite this page

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