If I set
B:=[1,2^(1/3),2^(2/3),I*sqrt(3),I*sqrt(3)*2^(1/3),I*sqrt(3)*2^(2/3)];
and then let
g:=B[2]+B[4];
I would like to be able to solve for g^2 in terms of the (basis) B, i.e.
solve(expand(g^2)=c[1]*B[1]+c[2]*B[2]+c[3]*B[3]+c[4]*B[4]+c[5]*B[5]+c[6]*B[6],{c[1],c[2],c[3],c[4],c[5],c[6]});
However, Maple does not seem to be able to recognize g^2 as a linear combination of the elements in the set B, in particular that g^2 = -3*B[1] + B[3] + 2*B[5]
A parallel question would be whether one could, for example, do something like this:
coeff(expand(g^2),2^(2/3))
but Maple does not compute coeffiencts except with respect to indeterminates.
Does anyone have an idea how to do such a computation? Thanks.
(The set B is a basis of the field extension of Q given by adjoining 2^(1/3) and sqrt(-3) and I'm trying to find a so-called 'primitive element' for this field extension.)