#3214: [with patch, needs review] gcd needs improved coercion
------------------------------+---------------------------------------------
 Reporter:  novoselt          |        Owner:  somebody
     Type:  defect            |       Status:  reopened
 Priority:  critical          |    Milestone:  sage-3.4
Component:  basic arithmetic  |   Resolution:          
 Keywords:                    |  
------------------------------+---------------------------------------------
Changes (by AlexGhitza):

  * summary:  gcd needs improved coersion => [with patch, needs review] gcd
              needs improved coercion

Comment:

 It is indeed not coercion-related.  The computation of the gcd is done in
 a loop, from which one exits as soon as a gcd of 1 is obtained (ignoring
 the rest of the elements).  In the case of elements with denominators
 (such as rational numbers or rational functions) this gives rise to the
 wrong answers reported above.

 The attached trivial patch fixes this so that correct answers are
 returned.

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/3214#comment:5>
Sage <http://sagemath.org/>
Sage - Open Source Mathematical Software: Building the Car Instead of 
Reinventing the Wheel
--~--~---------~--~----~------------~-------~--~----~
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