dirichlet_pairing, dirichlet_pairing_char
Synopsis
#include <flint/dirichlet.h>ulong dirichlet_pairing(const dirichlet_group_t G, ulong m, ulong n)sourceulong dirichlet_pairing_char(const dirichlet_group_t G, const dirichlet_char_t a, const dirichlet_char_t b)sourceReturn 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).
@misc{flint-doc-dirichlet-dirichlet-pairing,
author = {{The FLINT team}},
title = {{dirichlet\_pairing, dirichlet\_pairing\_char (dirichlet.h)}},
howpublished = {FLINT: Fast Library for Number Theory, documentation, version 3.7.0-dev},
year = {2026},
url = {https://flintlib.org/doc/dirichlet/dirichlet_pairing.html},
note = {Generated 2026-10-20}
}