sagemath / sage

Main repository of SageMath. Now open for Issues and Pull Requests.
https://www.sagemath.org
Other
1.2k stars 413 forks source link

No coercion for Galois group elements in different subgroups #18308

Open jdemeyer opened 9 years ago

jdemeyer commented 9 years ago

This is essentially #4105 but for Galois group elements.

sage: K.<a> = NumberField(x^6 + 40*x^3 + 1372)
sage: G = K.galois_group()
sage: L = [G.artin_symbol(Q) for Q in K.primes_above(5)]
sage: L[0] * L[1]
TypeError: unsupported operand parent(s) for '*': 'Subgroup [(), (1,5)(2,4)(3,6)] of Galois group of Number Field in a with defining polynomial x^6 + 40*x^3 + 1372' and 'Subgroup [(), (1,2)(3,4)(5,6)] of Galois group of Number Field in a with defining polynomial x^6 + 40*x^3 + 1372'

This also causes a doctest failure in src/doc/en/thematic_tutorials/explicit_methods_in_number_theory/nf_galois_groups.rst (marked as random for now):

    sage: P = K.primes_above(2)[0]
    sage: G.inertia_group(P)
    Subgroup [(), (1,4,6)(2,5,3), (1,6,4)(2,3,5)] of Galois group of Number Field in alpha with defining polynomial x^6 + 40*x^3 + 1372
    sage: sorted([G.artin_symbol(Q) for Q in K.primes_above(5)])  # random order, see Trac #18308
    [(1,3)(2,6)(4,5), (1,2)(3,4)(5,6), (1,5)(2,4)(3,6)]

Component: number fields

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

jdemeyer commented 9 years ago

Description changed:

--- 
+++ 
@@ -7,3 +7,12 @@
 sage: L[0] * L[1]
 TypeError: unsupported operand parent(s) for '*': 'Subgroup [(), (1,5)(2,4)(3,6)] of Galois group of Number Field in a with defining polynomial x^6 + 40*x^3 + 1372' and 'Subgroup [(), (1,2)(3,4)(5,6)] of Galois group of Number Field in a with defining polynomial x^6 + 40*x^3 + 1372'

+ +This also causes the following doctest (removed in #17890) to fail: + + +sage: K.<a> = NumberField(x^6 + 40*x^3 + 1372) +sage: G = K.galois_group() +sage: sorted([G.artin_symbol(Q) for Q in K.primes_above(5)]) +[(1,2)(3,4)(5,6), (1,3)(2,6)(4,5), (1,5)(2,4)(3,6)] +

jdemeyer commented 9 years ago

Description changed:

--- 
+++ 
@@ -8,11 +8,12 @@
 TypeError: unsupported operand parent(s) for '*': 'Subgroup [(), (1,5)(2,4)(3,6)] of Galois group of Number Field in a with defining polynomial x^6 + 40*x^3 + 1372' and 'Subgroup [(), (1,2)(3,4)(5,6)] of Galois group of Number Field in a with defining polynomial x^6 + 40*x^3 + 1372'

-This also causes the following doctest (removed in #17890) to fail: +This also causes a doctest failure in src/doc/en/thematic_tutorials/explicit_methods_in_number_theory/nf_galois_groups.rst (marked as random for now):

-sage: K.<a> = NumberField(x^6 + 40*x^3 + 1372)
-sage: G = K.galois_group()
-sage: sorted([G.artin_symbol(Q) for Q in K.primes_above(5)])
-[(1,2)(3,4)(5,6), (1,3)(2,6)(4,5), (1,5)(2,4)(3,6)]
+    sage: P = K.primes_above(2)[0]
+    sage: G.inertia_group(P)
+    Subgroup [(), (1,4,6)(2,5,3), (1,6,4)(2,3,5)] of Galois group of Number Field in alpha with defining polynomial x^6 + 40*x^3 + 1372
+    sage: [G.artin_symbol(Q) for Q in K.primes_above(5)]  # random order, see Trac #18308
+    [(1,3)(2,6)(4,5), (1,2)(3,4)(5,6), (1,5)(2,4)(3,6)]
jdemeyer commented 9 years ago

Description changed:

--- 
+++ 
@@ -14,6 +14,6 @@
     sage: P = K.primes_above(2)[0]
     sage: G.inertia_group(P)
     Subgroup [(), (1,4,6)(2,5,3), (1,6,4)(2,3,5)] of Galois group of Number Field in alpha with defining polynomial x^6 + 40*x^3 + 1372
-    sage: [G.artin_symbol(Q) for Q in K.primes_above(5)]  # random order, see Trac #18308
+    sage: sorted([G.artin_symbol(Q) for Q in K.primes_above(5)])  # random order, see Trac #18308
     [(1,3)(2,6)(4,5), (1,2)(3,4)(5,6), (1,5)(2,4)(3,6)]