#12964: multiply matrix of matrices by a scalar: boom
-----------------------------------+----------------------------------------
       Reporter:  jhpalmieri       |         Owner:  jason, was    
           Type:  defect           |        Status:  closed        
       Priority:  major            |     Milestone:  sage-5.1      
      Component:  linear algebra   |    Resolution:  fixed         
       Keywords:                   |   Work issues:                
Report Upstream:  N/A              |     Reviewers:  Mike Hansen   
        Authors:  Robert Bradshaw  |     Merged in:  sage-5.1.beta6
   Dependencies:                   |      Stopgaps:                
-----------------------------------+----------------------------------------

Comment (by robertwb):

 Thanks, Mike, for revewing this.

 Replying to [comment:5 jhpalmieri]:
 > Robert: after your patch, regarding `__mul__` and `_mul_` for matrices
 in `element.pyx`: what are their roles? In what order do they get called?

 To close the loop on this, `a.__mul__(b)` is called by Python when a * b
 is encountered. `a._mul_(b)` is called by the coercion model when
 `parent(a) is parent(b)` to actually do the arithmetic. Full details at
 http://www.sagemath.org/doc/reference/coercion.html

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