This is my first time using sage so this might be a stupid question:
I want to construct the field $K=\mathbb{Q}(\sqrt{2}, \frac{-1+\sqrt{3}i}{2})=\mathbb{Q}(\alpha)$, where $\alpha$ is a primitive element. Denoting its ring of algebraic integers $\mathcal{O}_K$, I want to compute the quotient ring $\mathcal{O}_K/\mathbb{Z}[\alpha]$.
My code is like:
K.<d> = QQ.extension(x^2-2)
L.<w> = K.extension(x^2+x+1)
a = L.primitive_element()
O = L.ring_of_integers()
za = ZZ[a]
print O.quotient(za)
But I always get an error: TypeError: unable to convert Relative Order in Number Field in w0 with defining polynomial x^2 + (2d + 1)x + d + 3 over its base field to Number Field in w with defining polynomial x^2 + x + 1 over its base field
Any help is appreciated. Thanks.