#9423: Gap interface for number fields
--------------------------+-------------------------------------------------
   Reporter:  SimonKing   |       Owner:  was                       
       Type:  defect      |      Status:  new                       
   Priority:  major       |   Milestone:  sage-4.5                  
  Component:  interfaces  |    Keywords:  gap interface number field
     Author:  Simon King  |    Upstream:  N/A                       
   Reviewer:              |      Merged:                            
Work_issues:              |  
--------------------------+-------------------------------------------------
 Originally motivated by work on #5618, I found two bugs in the Gap
 interface for number fields, reported [http://groups.google.com/group
 /sage-devel/browse_thread/thread/6518e7f30c02e534 here].

 #8909 has a positive review and seems partially relevant here, so, I
 started work with the patch from #8909 applied.

 With the new patch, the following works (and is doctested):
 {{{
 sage: L.<tau> = NumberField(x^3-2)
 sage: gap(tau)^3  # note the exclamation mark used by GAP
 !2
 sage: L(gap(tau)^3) # this used to fail
 2
 }}}
 {{{
 sage: P.<z> = QQ[]  # Note: The var'name is z, not x
 sage: K.<zeta> = NumberField(z^2 - 2)
 sage: k = gap(K)  # this used to fail, as only var'name x was accepted
 }}}

 Fixing the second problem, it is needed to avoid a conflict with an
 internal variable name of a GAP function, namely "E". This tests that the
 conflict is indeed avoided:
 {{{
 sage: P.<E> = QQ[]
 sage: L.<tau> = NumberField(E^3-2)
 sage: gap(L)
 <algebraic extension over the Rationals of degree 3>
 }}}

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