#17180: Move and fix rational reconstruction
-------------------------------------+-------------------------------------
       Reporter:  jdemeyer           |        Owner:
           Type:  enhancement        |       Status:  needs_info
       Priority:  major              |    Milestone:  sage-6.4
      Component:  basic arithmetic   |   Resolution:
       Keywords:                     |    Merged in:
        Authors:  Jeroen Demeyer     |    Reviewers:
Report Upstream:  N/A                |  Work issues:
         Branch:                     |       Commit:
  u/jdemeyer/ticket/17180            |  f9645edf887bb52bc984d2cb57b8921dc95f02cb
   Dependencies:  #16428             |     Stopgaps:
-------------------------------------+-------------------------------------

Comment (by jdemeyer):

 The `w1` and `w2` are not typos: they are "virtual" variables, see the
 lines above
 {{{
 mpz_submul(u1, q, v1) # w1 = u1 - q*v
 mpz_submul(u2, q, v2) # w2 = u2 - q*v2
 mpz_swap(u1, v1) # u1 = v1; v1 = w1
 mpz_swap(u2, v2) # u2 = v2; v2 = w2
 }}}

 Introducing actual variables `w1` and `w2` would be slower than reusing
 `u1` and `u2`. Perhaps this should be documented better, but it's not a
 mistake.

--
Ticket URL: <http://trac.sagemath.org/ticket/17180#comment:8>
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 unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to