#17317: Add unit_group() method to IntegerModRing
-----------------------------+-------------------------------
   Reporter:  pbruin         |            Owner:
       Type:  enhancement    |           Status:  new
   Priority:  major          |        Milestone:  sage-6.4
  Component:  number theory  |         Keywords:  unit group
  Merged in:                 |          Authors:  Peter Bruin
  Reviewers:                 |  Report Upstream:  N/A
Work issues:                 |           Branch:
     Commit:                 |     Dependencies:  #17315
   Stopgaps:                 |
-----------------------------+-------------------------------
 This ticket implements a `unit_group()` method for '''Z'''/''n'''''Z'''.
 Example:
 {{{
 sage: A = Zmod(24)
 sage: G = A.unit_group(); G
 Multiplicative Abelian group isomorphic to C2 x C2 x C2
 sage: G.gens_orders()
 (2, 2, 2)
 sage: G.gens_values()
 (7, 13, 17)
 }}}

 At the moment, there is no new class for such groups; it uses
 `AbelianGroupWithValues`.  However, this could easily be changed in the
 future if required.

 The `unit_group()` method admits an optional `algorithm` argument
 (default: `'sage'`).  This can be set to `'pari'` to use PARI's `znstar()`
 function (see #17315).  This gives different generators in general.

 The ticket also makes the set of generators for ''n'' = 1 be the empty
 set, and makes Dirichlet characters modulo 1 and 2 print as
 {{{
 sage: DirichletGroup(1)[0]
 Dirichlet character modulo 1 of conductor 1
 sage: DirichletGroup(2)[0]
 Dirichlet character modulo 2 of conductor 1
 }}}
 i.e. without the `mapping ...` appearing in
 {{{
 sage: DirichletGroup(3)[1]
 Dirichlet character modulo 3 of conductor 1 mapping 2 |--> -1
 }}}

 See also:

 - #7234
 - https://groups.google.com/forum/#!topic/sage-devel/T5A_gwrtZT0

--
Ticket URL: <http://trac.sagemath.org/ticket/17317>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to