# Trying to find prime factorization of ideals in number fields

Let $L=\mathbb{Q}(\sqrt{-5}, i)$ and $K=\mathbb{Q}(\sqrt{-5})$. Let $O_K$ and $O_L$ be the rings of algebraic integers of $K$ and $L$. It can be checked that

$$2O_K=\langle 2, \sqrt{-5}+1\rangle^2$$

I want to find the factorization of the ideal $\langle 2, \sqrt{-5}+1\rangle O_L$ in $O_L$ ?

The problem I am having is this. I don't know the syntax for the ideal generated by $\langle 2, \sqrt{-5}+1\rangle O_L$.

What to do ?

edit retag close merge delete

Sort by » oldest newest most voted

Is this what you are looking for?

Define the number fields and their rings of integers.

sage: K.<a> = NumberField(x^2+5)
sage: L.<i> = K.extension(x^2+1)
sage: OK = K.ring_of_integers()
sage: OL = L.ring_of_integers()


Define the ideals generated by 2 and by a+1.

sage: J = OL.principal_ideal(2)
sage: JJ = OL.principal_ideal(a + 1)


Take the sum.

sage: H = J + JJ; H
Fractional ideal (-i + 1)


Prime factors.

sage: H.prime_factors()
[Fractional ideal (-i + 1)]

sage: H.is_prime()
True

more