#9332: S_class_group() should return a group
-------------------------------------------------------------+--------------
   Reporter:  stankewicz                                     |       Owner:  
davidloeffler
       Type:  enhancement                                    |      Status:  
needs_work   
   Priority:  major                                          |   Milestone:     
          
  Component:  number fields                                  |    Keywords:     
          
     Author:  Jim Stankewicz, Erin Beyerstedt, Anna Haensch  |    Upstream:  
N/A          
   Reviewer:                                                 |      Merged:     
          
Work_issues:                                                 |  
-------------------------------------------------------------+--------------

Comment(by davidloeffler):

 The AttributeError comes up because attributes whose names start with an
 underscore are private, and ones with two underscores are "very private"
 -- so private that they aren't even accessible to subclasses. So when code
 in {{{FractionalIdealClass}}} sets {{{__ideal}}}, code in the subclass
 {{{SFractionalIdealClass}}}. In fact it is still accessible but under a
 mangled name: see [http://docs.python.org/tutorial/classes.html#private-
 variables].

 But there is another, deeper, bug which will be uncovered when you fix
 this. After my changes at #9244, a {{{FractionalIdealClass}}} stores both
 a representing ideal of that class, accessed via {{{self.ideal()}}}, and
 an expression for self in terms of the generators of its parent class
 group, accessed via {{{self.list()}}}. The way you've set this up,
 elements of an S-class group use the same data structure, but the data
 which {{{list()}}} uses is set completely wrongly: it's set to the
 exponents of the given ideal in terms of the generators of the class
 group, but it should be in terms of the generators of the **S-class
 group**. What you need to do is to store somewhere the expressions for the
 generators of the S-class group in terms of the generators of the class
 group (i.e. the matrix of the quotient map) and then multiply the output
 of {{{_ideal_class_log}}} by this.

 This is the sort of stuff that #6449 was intended to solve: quotients of
 abelian groups should be automatically handled by general code, rather
 than having to do it by hand in every specific example.

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/9332#comment:9>
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 post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sage-trac?hl=en.

Reply via email to