I have a (potentially silly) question about a problem I've been having with SAGEMath.
Let $K$ be the maximal totally real subfield of the cyclotomic field of conductor $24$, i.e. the number field with defining polynomial $x^4-4x^2+1$. I have defined this as such in SAGE:
K.<f>=NumberField(x^4-4*x^2+1)
I then go on to define the Galois group of $K$:
G=K.galois_group()
This group has order $4$. If we check the generators of this group by writing G.gens(), we get
[(1,2)(3,4), (1,4)(2,3)]
If I understand this correctly, this means there are two generators of the group $G$. However, if I write
G.<g,h>=K.galois_group()
I receive an error saying that the number of names needs to match the number of generators of $G$. Writing G.<g>=K.galois_group() works, but g here has order $2$. Why is it that I can't define $G$ in terms of two generators in SAGE?
In Sagemath, the syntax
OBJECT.<a,b,c,...> = ...works if the right side of the equation is properly set up for this; among other things, I believe it looks for an argument callednamesand tries to usea,b,c,...for that argument. In the case ofgalois_group, one of the arguments isnames:So in this case,
G.<a,b,c, ...> = K.galois_group()is not trying to define generators of the group, but instead a single generator for the Galois closure ofK.To actually get the group generators, you can instead define
G = K.galois_group()and then dog, h = G.gens().Edit: I hadn't read the newest comments before posting this, and I now see that this is repeating some of the same information given by @durianice. I've converted this answer to "Community wiki."