#10667: Morphisms and Objects of Categories
----------------------------------+-----------------------------------------
   Reporter:  SimonKing           |          Owner:  nthiery                    
  
       Type:  enhancement         |         Status:  needs_work                 
  
   Priority:  major               |      Milestone:  sage-5.0                   
  
  Component:  categories          |       Keywords:  objects morphisms 
containment
Work_issues:  Cartesian products  |       Upstream:  N/A                        
  
   Reviewer:                      |         Author:  Simon King                 
  
     Merged:                      |   Dependencies:  #9138, #11115, #11780      
  
----------------------------------+-----------------------------------------

Comment(by nthiery):

 Replying to [comment:43 SimonKing]:
 > Just a status report: I got rid of the `__new__` method. Instead, I
 produce a `__classcall__` method,

 Sounds good. I guess I had not yet implemented __classcall__ when I
 wrote the __new__ workarounds.

 > similar to what is done in `UniqueRepresentation` (and in fact I make
 `sage.categories.rings.Rings.HomCategory.ParentClass` inherit from
 `UniqueRepresentation`).

 I am not absolutely sure about this: as for parents, it is recommended
 for Homsets to have unique representation, but I am not sure this is
 currently *required* and *enforced*. So this may open a larger can of
 worm than this ticket can handle. This might be the issue you
 encountered with polynomials.

 > After my patches and the addition of the base_ring method to Cartesian
 product categories, the problem arose with `__init_extra__` method in
 `sage.categories.algebras.Algebras.ParentMethods`: The Cartesian product
 of algebras over a ring R is an algebra over R (apparently acting
 diagonally). The `__init_extra__` tries to create a coercion from the R to
 the cartesian product. However, that ended in an infinite recursion. I
 solved it by adding a `from_base_ring` method, that is understood by
 `__init_extra__`.

 Cool!

 > The remaining problem concerns summation of elements of Cartesian
 products. Multiplication is defined, via
 `sage.categories.magmas.Magmas.CartesianProduct.ParentMethods.product`.
 But summation is missing. I guess it should be implemented in
 `sage.categories.AdditiveMagmas.CartesianProduct.ParentMethods.summation`.

 Thanks for implementing this missing piece!

 Cheers,
                      Nicolas

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/10667#comment:50>
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