#8344: Factor constant polynomials over QQbar
--------------------------------+-------------------------------------------
   Reporter:  boothby           |       Owner:  AlexGhitza
       Type:  defect            |      Status:  needs_info
   Priority:  critical          |   Milestone:  sage-4.3.4
  Component:  basic arithmetic  |    Keywords:            
     Author:                    |    Upstream:  N/A       
   Reviewer:                    |      Merged:            
Work_issues:                    |  
--------------------------------+-------------------------------------------

Comment(by cremona):

 Very sorry, it was a cut-and-paste error.  The lines defining f1 and f2
 should read
 {{{
 sage: f1 = Factorization([(x-r,e) for r,e in f.roots() if
 r.imag().is_zero()],unit=f.leading_coefficient())
 sage: f2 = Factorization([(x^2-(r+r.conjugate()).real()*x+r.norm(),e) for
 r,e in fr if r.imag()>0])
 }}}
 (there was a typo in the second one too).

 The trick of testing r.imag()>0 was just a way of picking exactly one
 conjugate of each pair of non-real conjugate roots.  I think that is quite
 cheap.  But a better way would be, for each element of AA or QQbar to have
 a function returning its minpoly over RR (currently the minpoly() function
 returns its minpoly over QQ).  And we have the norm of an element of QQbar
 which is the product of it with its CC/RR-conjugate (and not its norm down
 to QQ), but we do not have a trace:  another function I would like to add!

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