#10174: relative norm in relative number fields is slow
-----------------------------+----------------------------------------------
   Reporter:  thome          |       Owner:  davidloeffler
       Type:  defect         |      Status:  new          
   Priority:  minor          |   Milestone:               
  Component:  number fields  |    Keywords:               
     Author:                 |    Upstream:  N/A          
   Reviewer:                 |      Merged:               
Work_issues:                 |  
-----------------------------+----------------------------------------------
 There seems to be no relative_norm or absolute_norm method for elements of
 relative number fields (while there is for ideals). norm() works with an
 optional base parameter, which can be set to the base field for obtaining
 the relative norm.

 However it's dog slow.

 sage: K.<v>=NumberField(x^4 + 514*x^2 + 64321)
 sage: L.<w>,e=K.galois_closure(map=True)
 sage: R.<r,v>=L.relativize(e)
 sage: time _=r.norm(K)
 CPU times: user 0.44 s, sys: 0.00 s, total: 0.44 s
 Wall time: 0.45 s

 The attached patch changes the matrix() method to identify the base field
 as a trivial case, so that r.norm(K) computes the relative norm quickly:

 sage: K.<v>=NumberField(x^4 + 514*x^2 + 64321)
 sage: L.<w>,e=K.galois_closure(map=True)
 sage: R.<r,v>=L.relativize(e)
 sage: time _=r.norm(K)
 CPU times: user 0.00 s, sys: 0.00 s, total: 0.00 s
 Wall time: 0.00 s

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