Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gap interface for number fields #9423

Closed
simon-king-jena opened this issue Jul 4, 2010 · 7 comments
Closed

Gap interface for number fields #9423

simon-king-jena opened this issue Jul 4, 2010 · 7 comments

Comments

@simon-king-jena
Copy link
Member

Originally motivated by work on #5618, I found two bugs in the Gap interface for number fields, reported 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>

Component: interfaces

Keywords: gap interface number field

Author: Simon King

Reviewer: Luis Felipe Tabera Alonso

Merged: sage-4.6.2.alpha2

Issue created by migration from https://trac.sagemath.org/ticket/9423

@simon-king-jena
Copy link
Member Author

Fixing two bugs (doctested) in the GAP interface of number fields

@simon-king-jena
Copy link
Member Author

comment:1

Attachment: trac_9423_gap_for_numberfields.patch.gz

@lftabera
Copy link
Contributor

lftabera commented Dec 4, 2010

comment:2

The code corrects a couple of bugs in the gap interface of number fields. Since ! cannot be part of the name of a generator of a number field, then eliminating "!" from the gap representation is correct.

The solution to the "E" variable problem is correct, althought there should be a more system-wide solution to this kind of problems.

I will not give it a positive review until #5618 is also ready to merge, since this patch eliminates a doctest that after #5618 will be obsolete.

@lftabera
Copy link
Contributor

lftabera commented Dec 4, 2010

Reviewer: Luis Felipe Tabera Alonso

@lftabera
Copy link
Contributor

Attachment: trac_9423_gap_for_numberfields.2.patch.gz

Updated headers

@lftabera
Copy link
Contributor

comment:3

Positive review, I have only updated the patch header to add the ticket number

Apply:

trac_9423_gap_for_numberfields.2.patch

Note to the release manager: ticket #5618 depends on this. This ticket should be merged together with #5618.

@jdemeyer
Copy link

Merged: sage-4.6.2.alpha2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants