On 14 Feb., 12:40, Simon King <simon.k...@uni-jena.de> wrote:
> Question: Shall I remove the custom gcd/lcm for QQ and replace it by
> something that restricts to the usual gcd/lcm on ZZ? Or is that likely
> to break stuff? I could imagine that number theory people have a
> certain preference for a particular choice of a gcd in QQ. So, I am
> cross-posting to sage-nt.

Oops, I have to slightly correct myself:

* The rationale was given for lcm, not for gcd.

* Fortunately, the current lcm does exactly what we want for the
fraction field of a PID:
  sage: lcm(1/3,1/6)
  1/3
  So, there is no need to change lcm for the rationals.

* The gcd of the rationals should be changed: Currently, it returns
either 1 or 0, which is not interesting.

So, my patch for #10771 will provide lcm and gcd for fraction fields
of PID (so that it works, e.g., in Frac(QQ['x'])), will remove or
rename the current rational gcd (it shall in future be inherited from
the category), and will preserve the current rational lcm (for
efficiency).

Moreover, since in future lcm and gcd for fraction fields behave
nicely wrt. the base ring, there shall be coercion before computing
gcd/lcd.

Best regards,
Simon

-- 
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an email to 
sage-devel+unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/sage-devel
URL: http://www.sagemath.org

Reply via email to