-
-
Notifications
You must be signed in to change notification settings - Fork 678
Open
Labels
Description
Steps To Reproduce
Run the following Sage file:
k = GF(2)
K = FunctionField(k, names=('x',))
x = K._first_ngens(1)[0]
R = PolynomialRing(K, names=('t',))
t = R._first_ngens(1)[0]
L = K.extension(t**2+t*x, names=('y',))
P = t**3+x
L_prime = L.extension(t**3+x, names=('z',))
print("Actual behaviour:")
print("True would be a bug:", L_prime.base_ring() is K)
print("False would be a bug:", L_prime.base_ring() is L)
L_another = L.extension(P.change_ring(L), names=('z',))
print("Expected behaviour:")
print("True would be a bug:", L_another.base_ring() is K)
print("False would be a bug:", L_another.base_ring() is L)
Expected Behavior
One would expect to see the following output:
Actual behaviour:
True would be a bug: False
False would be a bug: True
Expected behaviour:
True would be a bug: False
False would be a bug: True
Actual Behavior
One gets:
Actual behaviour:
True would be a bug: True
False would be a bug: False
Expected behaviour:
True would be a bug: False
False would be a bug: True
Additional Information
When creating a function field extension, it is never checked that the polynomial defining the extension is defined over that function field. Hence, the base ring of the polynomial ring is returned, and not the function field which called the method.
Environment
- OS: Debian 13.1
- Sage Version: 10.8.beta7
Checklist
- I have searched the existing issues for a bug report that matches the one I want to file, without success.
- I have read the documentation and troubleshoot guide