mirror of
https://github.com/vale981/arb
synced 2025-03-04 17:01:40 -05:00
add dirichlet_char_is_primitive
This commit is contained in:
parent
4128a16951
commit
4227e0b0a8
2 changed files with 10 additions and 0 deletions
|
@ -144,6 +144,12 @@ dirichlet_char_is_real(const dirichlet_group_t G, const dirichlet_char_t chi)
|
|||
return G->q <= 4 || (nmod_mul(chi->n, chi->n, G->mod) == 1);
|
||||
}
|
||||
|
||||
DIRICHLET_INLINE int
|
||||
dirichlet_char_is_primitive(const dirichlet_group_t G, const dirichlet_char_t chi)
|
||||
{
|
||||
return (dirichlet_conductor_char(G, chi) == G->q);
|
||||
}
|
||||
|
||||
ulong dirichlet_chi(const dirichlet_group_t G, const dirichlet_char_t chi, ulong n);
|
||||
|
||||
void dirichlet_vec_set_null(ulong *v, const dirichlet_group_t G, slong nv);
|
||||
|
|
|
@ -224,6 +224,10 @@ level of *number* and *char* object. Both case require no discrete log computati
|
|||
|
||||
Returns 1 if *chi* is a real character (iff it has order `\leq 2`).
|
||||
|
||||
.. function:: int dirichlet_char_is_primitive(const dirichlet_group_t G, const dirichlet_char_t chi)
|
||||
|
||||
Returns 1 if *chi* is primitive (iff its conductor is exactly *q*).
|
||||
|
||||
Character evaluation
|
||||
-------------------------------------------------------------------------------
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue