#12292: charpoly is recomputed when called with a different variable
------------------------------------+---------------------------------------
       Reporter:  zimmerma          |         Owner:  jason, was     
           Type:  enhancement       |        Status:  needs_review   
       Priority:  minor             |     Milestone:  sage-5.0       
      Component:  linear algebra    |    Resolution:                 
       Keywords:  sd35.5            |   Work issues:                 
Report Upstream:  N/A               |     Reviewers:  Paul Zimmermann
        Authors:  Michael Orlitzky  |     Merged in:                 
   Dependencies:                    |      Stopgaps:                 
------------------------------------+---------------------------------------

Comment (by zimmerma):

 I agree with item 1 from comment [comment:6], but in Sage 4.8:
 {{{

 sage: A = random_matrix(QQ, 3)
 sage: A.charpoly()
 x^3 + x^2 + 5/4*x + 1/2
 sage: A._cache
 {'clear_denom': ([-1  2  0]
 [-2  0  0]
 [ 0 -1 -1], 2), 'charpoly_linbox_x': x^3 + x^2 + 5/4*x + 1/2}
 sage: A.charpoly('t')
 t^3 + t^2 + 5/4*t + 1/2
 sage: A._cache
 {'clear_denom': ([-1  2  0]
 [-2  0  0]
 [ 0 -1 -1], 2), 'charpoly_linbox_x': x^3 + x^2 + 5/4*x + 1/2,
 'charpoly_linbox_t': t^3 + t^2 + 5/4*t + 1/2}
 }}}
 thus calling {{{A._cache['charpoly_linbox']}}} might not be enough.

 Paul Zimmermann

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