\documentclass[12pt]{article}
\usepackage[active]{srcltx}
\input{macros}
\hoffset=-0.05\textwidth
\textwidth=1.1\textwidth
\voffset=-0.08\textheight
\textheight=1.16\textheight

\title{Math 129: Algebraic Number Theory\\
{\bf Lecture 3}}
\author{William Stein}
\date{Thursday, February 12, 2004}
\begin{document}
\maketitle

{\tt Announcements:} I will be giving a talk on my research on
computing with modular abelian varieties at 3pm in SC 507 today.  If
you're interested in finding out what my research is about, feel free
to attend.  The first half will be less technical, and you could leave
halfway through.
\begin{verbatim}
---------------------------------------------------------------------
\end{verbatim}

Today we will learn about rings of algebraic integers and discuss some of
their properties.

\section{Rings of Algebraic Integers}
Fix an algebraic closure $\Qbar$ of $\Q$.  For example, $\Qbar$ could
be the subfield of the complex numbers $\C$ generated by all roots in
$\C$ of all polynomials with coefficients in $\Q$.

Much of this course is about algebraic integers.
\begin{definition}[Algebraic Integer]
An element $\alpha\in\Qbar$ is an {\em algebraic integer} if it is a
root of some monic polynomial with coefficients in $\Z$.
\end{definition}

\begin{definition}[Minimal Polynomial]
The {\em minimal polynomial} of $\alpha\in\Q$ is the monic polynomial
$f\in\Q[x]$ of least positive degree such that $f(\alpha)=0$.
\end{definition}
The minimal polynomial of $\alpha$ divides any polynomial~$h$ such
that $h(\alpha)=0$, for the following reason. If $h(\alpha)=0$, use
the division algorithm to write $h=qf + r$, where $0\leq \deg(r) <
\deg(f)$.  We have $r(\alpha) = h(\alpha) - q(\alpha) f(\alpha) = 0$,
so $\alpha$ is a root of~$r$.  However,~$f$ is the polynomial of least
positive degree with root~$\alpha$, so $r=0$.

\begin{lemma}\label{lem:minpolint}
If~$\alpha$ is an algebraic integer, then the minimal polynomial
of~$\alpha$ has coefficients in~$\Z$.
\end{lemma}
\begin{proof}
%(From S-D, page 2.) 
Suppose $f\in\Q[x]$ is the minimal polynomial of $\alpha$ and
$g\in\Z[x]$ is a monic integral polynomial such that $g(\alpha)=0$.
As mentioned after the definition of minimal polynomial, we have
$g=fh$, for some $h\in\Q[x]$.  If $f\not\in\Z[x]$, then some prime~$p$
divides the denominator of some coefficient of $f$.  Let $p^i$ be the
largest power of~$p$ that divides some denominator of some
coefficient~$f$, and likewise let $p^j$ be the largest power of~$p$
that divides some denominator of a coefficient of~$g$.  Then $p^{i+j}g
= (p^if)(p^j g)$, and if we reduce both sides modulo $p$, then the
left hand side is $0$ but the right hand side is a product of two
nonzero polynomials in $\F_p[x]$, hence nonzero, a contradiction.
\end{proof}

\begin{proposition}\label{prop:intfg}
An element $\alpha\in\Qbar$ is integral if and only if $\Z[\alpha]$ is
finitely generated as a $\Z$-module.
\end{proposition}
\begin{proof}
Suppose~$\alpha$ is integral and let $f\in\Z[x]$ be the monic minimal polynomial
of~$\alpha$ (that $f\in\Z[x]$ is Lemma~\ref{lem:minpolint}).  Then $\Z[\alpha]$
is generated by $1,\alpha,\alpha^2,\ldots,\alpha^{d-1}$, where~$d$ is
the degree of~$f$.   Conversely, suppose $\alpha\in\Qbar$ is such that
$\Z[\alpha]$ is finitely generated, say by elements 
$f_1(\alpha), \ldots, f_n(\alpha)$.  Let~$d$ be any integer bigger
than the degree of any~$f_i$.  Then there exist integers $a_i$ such
that $\alpha^d = \sum a_i f_i(\alpha)$, hence~$\alpha$ satisfies
the monic polynomial $x^d - \sum a_i f_i(x) \in \Z[x]$, so~$\alpha$
is integral.
\end{proof}

The rational number $\alpha=1/2$ is not integral.  Note that
$G=\Z[1/2]$ is not a finitely generated $\Z$-module, since $G$ is infinite
and $G/2G=0$.

\begin{proposition}
The set $\Zbar$ of all algebraic integers is a ring, i.e., the sum and
product of two algebraic integers is again an algebraic integer.
\end{proposition}
\begin{proof}
Suppose $\alpha, \beta\in \Z$, and let $m, n$ be the degrees of the
minimal polynomials of $\alpha, \beta$, respectively.  Then
$1,\alpha,\ldots,\alpha^{m-1}$ span $\Z[\alpha]$ and
$1,\beta,\ldots,\beta^{n-1}$ span $\Z[\beta]$ as $\Z$-module.  Thus
the elements $\alpha^i\beta^j$ for $i \leq m, j\leq n$ span
$\Z[\alpha, \beta]$.  Since $\Z[\alpha + \beta]$ is a submodule of the
finitely-generated module $\Z[\alpha, \beta]$, it is finitely
generated, so $\alpha+\beta$ is integral.  Likewise, $\Z[\alpha\beta]$
is a submodule of $\Z[\alpha, \beta]$, so it is also finitely
generated and $\alpha\beta$ is integral.
\end{proof}

Recall that a {\em number field} is a subfield~$K$ of $\Qbar$ such
that the degree $[K:\Q] := \dim_\Q(K)$ is finite.
\begin{definition}[Ring of Integers]
The {\em ring of integers} of a number field~$K$ is the ring 
$$
  \O_K = K \cap \Zbar = \{x \in K : \text{ $x$ is an algebraic integer}\}.
$$
\end{definition}


The field $\Q$ of rational numbers is a number field of degree $1$,
and the ring of integers of $\Q$ is $\Z$.  The field $K=\Q(i)$ of
Gaussian integers has degree $2$ and $\O_K = \Z[i]$.  The field
$K=\Q(\sqrt{5})$ has ring of integers $\O_K = \Z[(1+\sqrt{5})/2]$.
Note that the Golden ratio $(1+\sqrt{5})/2$ satisfies $x^2-x-1$.
According to MAGMA, the ring of integers of $K=\Q(\sqrt[3]{9})$ is
$\Z[\sqrt[3]{3}]$, where $\sqrt[3]{3}=\frac{1}{3}(\sqrt[3]{9})^2$.

\begin{definition}[Order]
An {\em order} in $\O_K$ is any subring $R$ of $\O_K$ such that the
quotient $\O_K/R$ of abelian groups is finite.  
(Note that $R$ must contain $1$ because it is a ring, and for us
every ring has a $1$.)
\end{definition}
As noted above, $\Z[i]$ is the ring of integers of $\Q(i)$.  For every
nonzero integer $n$, the subring $\Z+ni\Z$ of $\Z[i]$ is an order.
The subring $\Z$ of $\Z[i]$ is not an order, because $\Z$ does not
have finite index in $\Z[i]$.  Also the subgroup $2\Z + i\Z$ of
$\Z[i]$ is not an order because it is not a ring.  

We will frequently consider orders in practice because they are often
much easier to write down explicitly than $\O_K$.  For example, if
$K=\Q(\alpha)$ and $\alpha$ is an algebraic integer, then $\Z[\alpha]$
is an order in $\O_K$, but frequently $\Z[\alpha]\neq \O_K$.  

\begin{lemma}\label{lem:intq}
Let $\O_K$ be the ring of integers of a number field.  Then 
$\O_K\cap \Q = \Z$ and $\Q\O_K = K$.
\end{lemma}
\begin{proof}
Suppose $\alpha\in \O_K\cap\Q$ with $\alpha=a/b$ in lowest terms and
$b>0$.  The monic minimal polynomial of $\alpha$ is $bx-a\in\Z[x]$, so
if $b\neq 1$ then Lemma~\ref{lem:minpolint} implies that $\alpha$ is
not an algebraic integer, a contradiction.

To prove that $\Q\O_K=K$, suppose $\alpha\in K$, and let
$f(x)\in\Q[x]$ be the minimal monic polynomial of~$\alpha$.  For any
positive integer~$d$, the minimal monic polynomial of $d\alpha$ is
$d^{\deg(f)}f(x/d)$, i.e., the polynomial obtained from $f(x)$ by
multiplying the coefficient of $x^{\deg(f)}$ by~$1$, multiplying the
coefficient of $x^{\deg(f)-1}$ by~$d$, multiplying the coefficient of
$x^{\deg(f)-2}$ by $d^2$, etc.  If~$d$ is the least common multiple of
the denominators of the coefficients of~$f$, then the minimal monic
polynomial of $d\alpha$ has integer coefficients, so $d\alpha$ is
integral and $d\alpha\in \O_K$.  This proves that $\Q\O_K = K$.
\end{proof}

In the next two sections we will develop some basic properties of
norms and traces, and deduce further properties of rings of integers.

\section{Norms and Traces}
Before discussing norms and traces we introduce some notation for
field extensions.  If $K\subset L$ are number fields, we let $[L:K]$
denote the dimension of~$L$ viewed as a $K$-vector space.  If~$K$ is a
number field and $a\in \Qbar$, let $K(a)$ be the number field
generated by~$a$, which is the smallest number field that
contains~$a$.  If $a\in\Qbar$ then~$a$ has a minimal polynomial
$f(x)\in\Q[x]$, and the {\em Galois conjugates} of~$a$ are the roots
of~$f$.  For example the element $\sqrt{2}$ has minimal polynomial
$x^2-2$ and the Galois conjugates of $\sqrt{2}$ are $\pm \sqrt{2}$.

Suppose $K\subset L$ is an inclusion of number fields and let $a\in
L$.  Then left multiplication by~$a$ defines a $K$-linear
transformation $\ell_a:L\to L$.  (The transformation $\ell_a$ is
$K$-linear because $L$ is commutative.)

\begin{definition}[Norm and Trace]
The {\em norm} and {\em trace} of~$a$ from~$L$ to~$K$ are
$$\norm_{L/K}(a)=\det(\ell_a) \quad\text{ and }\quad
 \tr_{L/K}(a)=\tr(\ell_a).$$
\end{definition}
It is standard from linear algebra that 
determinants are multiplicative
and traces are additive, so for $a,b\in L$ we have
$$\norm_{L/K}(ab) = \norm_{L/K}(a)\cdot \norm_{L/K}(b)$$
and
$$\tr_{L/K}(a+b) = \tr_{L/K}(a) + \tr_{L/K}(b).$$

Note that if $f\in\Q[x]$ is the characteristic polynomial of~$\ell_a$,
then the constant term of $f$ is $(-1)^{\deg(f)}\det(\ell_a)$, and the
coefficient of $x^{\deg(f)-1}$ is $-\tr(\ell_a)$.

\begin{proposition}\label{prop:normtracesigma}
Let $a\in L$ and let $\sigma_1,\ldots, \sigma_d$, where $d=[L:K]$, be
the distinct field embeddings $L\hra \Qbar$ that fix every element
of~$K$.  Then
$$
\norm_{L/K}(a) = \prod_{i=1}^d \sigma_i(a)
\quad\text{ and }\quad
\tr_{L/K}(a) = \sum_{i=1}^d \sigma_i(a).
$$
\end{proposition}
\begin{proof}
We prove the proposition by computing the characteristic
polynomial~$F$ of~$a$.  Let $f\in K[x]$ be the minimal polynomial
of~$a$ over~$K$, and note that~$f$ has distinct roots (since it is the
polynomial in $K[x]$ of least degree that is satisfied by~$a$).
Since~$f$ is irreducible, $[K(a):K]=\deg(f)$, and~$a$ satisfies a
polynomial if and only if~$\ell_a$ does, the characteristic polynomial
of $\ell_a$ acting on $K(a)$ is~$f$.  Let $b_1,\ldots,b_n$ be a basis
for $L$ over $K(a)$ and note that $1,\ldots, a^m$ is a basis for
$K(a)/K$, where $m=\deg(f)-1$.  Then $a^i b_j$ is a basis for $L$ over
$K$, and left multiplication by $a$ acts the same way on the span of
$b_j, a b_j, \ldots, a^m b_j$ as on the span of $b_k, a b_k, \ldots,
a^m b_k$, for any pair $j, k\leq n$.  Thus the matrix of $\ell_a$ on
$L$ is a block direct sum of copies of the matrix of $\ell_a$ acting
on $K(a)$, so the characteristic polynomial of $\ell_a$ on~$L$ is
$f^{[L:K(a)]}$.  The proposition follows because the roots of
$f^{[L:K(a)]}$ are exactly the images $\sigma_i(a)$, with multiplicity
$[L:K(a)]$ (since each embedding of $K(a)$ into $\Qbar$ extends in
exactly $[L:K(a)]$ ways to $L$ by Exercise ??).
\end{proof}

The following corollary asserts that the norm and trace behave well in
towers.
\begin{corollary}
Suppose $K\subset L \subset M$ is a tower of number fields, and
let $a\in M$.  Then 
$$
\norm_{M/K}(a) = \norm_{L/K}(\norm_{M/L}(a))
\quad\text{ and }\quad
\tr_{M/K}(a) = \tr_{L/K}(\tr_{M/L}(a)).
$$
\end{corollary}
\begin{proof}
For the first equation, both sides are the product of $\sigma_i(a)$,
where $\sigma_i$ runs through the embeddings of~$M$ into $K$.  To see
this, suppose $\sigma:L\to \Qbar$ fixes $K$. If $\sigma'$ is an
extension of $\sigma$ to $M$, and $\tau_1,\ldots, \tau_d$ are the
embeddings of $M$ into $\Qbar$ that fix $L$, then
$\tau_1\sigma',\ldots,\tau_d\sigma'$ are exactly the extensions of
$\sigma$ to~$M$.  For the second statement, both sides are the sum of
the $\sigma_i(a)$.
\end{proof}

The norm and trace down to~$\Q$ of an algebraic integer~$a$ is an
element of~$\Z$, because the minimal polynomial of~$a$ has integer
coefficients, and the characteristic polynomial of~$a$ is a power of the
minimal polynomial, as we saw in the proof of
Proposition~\ref{prop:normtracesigma}.

\begin{proposition}\label{prop:ok_lattice}
Let~$K$ be a number field.  The ring of integers $\O_K$ is a lattice
in~$K$, i.e., $\Q\O_K=K$ and $\O_K$ is an abelian group of rank $[K:\Q]$.
\end{proposition}
\begin{proof}
We saw in Lemma~\ref{lem:intq} that $\Q\O_K=K$.  Thus there exists a
basis $a_1,\ldots, a_n$ for~$K$, where each~$a_i$ is in $\O_K$.
Suppose that as $x=\sum c_i a_i\in \O_K$ varies over all elements of
$\O_K$ the denominators of the coefficients $c_i$ are arbitrarily
large.  Then subtracting off integer multiples of the $a_i$, we see
that as $x=\sum c_i a_i\in \O_K$ varies over elements of $\O_K$ with
$c_i$ between $0$ and $1$, the denominators of the $c_i$ are also
arbitrarily large.  This implies that there are infinitely many elements
of $\O_K$ in the bounded subset
$$S = \left\{c_1 a_1 +\cdots + c_n a_n : c_i \in \Q,\, 0\leq c_i \leq 1\right\}\subset K.$$
Thus for any $\eps>0$, there are elements $a,b\in \O_K$ such that the
coefficients of $a-b$ are all less than $\eps$ (otherwise the elements
of $\O_K$ would all be a ``distance'' of least $\eps$ from each other, so only finitely
many of them would fit in $S$).

As mentioned above, the norms of elements of $\O_K$ are integers.
Since the norm of an element is the determinant of left multiplication
by that element, the norm is a homogenous polynomial of degree $n$ in
the indeterminate coefficients $c_i$.  If the $c_i$ get arbitrarily
small for elements of $\O_K$, then the values of the norm polynomial
get arbitrarily small, which would imply that there are elements of
$\O_K$ with positive norm too small to be in $\Z$, a contradiction.
So the set $S$ contains only finitely many elements of $\O_K$.  Thus
the denominators of the $c_i$ are bounded, so for some $d$, we have
that $\O_K$ has finite index in $A=\frac{1}{d}\Z a_1 + \cdots +
\frac{1}{d}\Z a_n$.  Since $A$ is isomorphic to $\Z^n$, it follows
from the structure theorem for finitely generated abelian groups that
$\O_K$ is isomorphic as a $\Z$-module to $\Z^n$, as claimed.
\end{proof}

\begin{corollary}\label{prop:intnoetherian}
The ring of integers $\O_K$ of a number field is Noetherian.
\end{corollary}
\begin{proof}
By Proposition~\ref{prop:ok_lattice}, the ring $\O_K$ is
finitely generated as a module over $\Z$, so it is certainly
finitely generated as a ring over $\Z$.  By the Hilbert
Basis Theorem, $\O_K$ is Noetherian.
\end{proof}

\begin{definition}[Integrally Closed]
An integral domain $R$ is {\em integrally closed} if whenever $\alpha$
is in the field of fractions of $R$ and $\alpha$ satisfies a monic
polynomial $f\in R[x]$, then $\alpha \in R$.
\end{definition}

\begin{proposition}\label{prop:integrallyclosed}
If $K$ is any number field, then $\O_K$ is integrally closed.  Also,
$\Zbar$ is integrally closed.
\end{proposition}
\begin{proof}
It suffices to prove that $\Zbar$ is integrally closed, since if $c\in
K$ is integral over $\O_K$, then~$c$ would be an element of $\Zbar$,
so $c\in K \cap \Zbar=\O_K$, as required.  

Now suppose $c\in\Qbar$ is integral over $\Zbar$, so there is a monic
polynomial $f(x)=x^n + a_{n-1}x^{n-1} + \cdots + a_1 x + a_0$ with
$a_i\in\Zbar$ and $f(c)=0$.  The $a_i$ all lie in the ring of integers
$\O_K$ of the number field $K=\Q(a_0,a_1,\ldots a_{n-1})$, and $\O_K$
is finitely generated as a $\Z$-module by
Proposition~\ref{prop:ok_lattice}, so $\Z[a_0,\ldots, a_{n-1}]$ is
finitely generated as a $\Z$-module.  Since $f(c)=0$, we can write
$c^n$ as a $\Z[a_0,\ldots, a_{n-1}]$-linear combination of $c^i$ for
$i<n$, so the ring $\Z[a_0,\ldots, a_{n-1},c]$ is also finitely
generated as a $\Z$-module.  Then $\Z[c]$ is finitely generated as
$\Z$-module because it is a submodule of a finitely generated
$\Z$-module, which implies that~$c$ is integral over~$\Z$.
\end{proof}

\comment{\section{Discriminants}
Define absolute discriminant and mention properties.

\begin{proposition}
If $R$ is an order in the ring of integers $\O_K$ of
a number field, then $\disc(R) = \disc(\O_K)\cdot[\O_K:R]^2$.
\end{proposition}
}

\section{Dedekind Domains}
\begin{definition}[Dedekind Domain]
A ring $R$ is a {\em Dedekind domain} if it is 
Noetherian, integrally closed, and every nonzero
prime ideal of $R$ is maximal.
\end{definition}

\begin{proposition}
The ring of integers $\O_K$ of a number field is a Dedekind domain.
\end{proposition}
\begin{proof}
By Proposition~\ref{prop:integrallyclosed}, the ring $\O_K$ is
integrally closed, and by Proposition~\ref{prop:intnoetherian} it is
Noetherian.  Suppose that~$\p$ is a nonzero prime ideal of $\O_K$.
Let $\alpha\in \p$ be a nonzero element, and let $f(x)\in\Z[x]$ be the
minimal polynomial of~$\alpha$.  Then
$$f(\alpha)=\alpha^n+a_{n-1}\alpha^{n-1}+\cdots+a_1\alpha+a_0=0,$$ so
$a_0 = -(\alpha^n+a_{n-1}\alpha^{n-1}+\cdots+a_1\alpha)\in \p$.  Since
$f$ is irreducible, $a_0$ is a nonzero element of $\Z$ that lies
in~$\p$.  Every element of the finitely generated abelian group
$\O_K/\p$ is killed by~$a_0$, so $\O_K/\p$ is a finite set.
Since~$\p$ is prime, $\O_K/\p$ is an integral domain.  Every finite
integral domain is a field (see Exercise~?), so $\p$ is maximal, which
completes the proof.
\end{proof}

If $I$ and $J$ are ideals in a ring $R$, the product $IJ$
is the ideal generated by all products of elements in $I$ with elements in $J$:
$$
  IJ = (ab : a\in I, b\in J)R.
$$
Note that the set of all products $ab$, with $a\in I$ and $b\in J$,
need not be an ideal, so it is important to take the ideal generated
by that set.  

Next Tuesday we will start by proving the crucial
Theorem~\ref{thm:div} below, which will allow us to show that any
nonzero ideal of a Dedekind domain can be expressed uniquely as a
product of primes (up to order).  Thus unique factorization holds for
ideals in a Dedekind domain, and it is this unique factorization that
initially motivated the introduction of rings of integers of number
fields over a century ago.

\begin{definition}[Fractional Ideal]
A {\em fractional ideal} is an $\O_K$-submodule of $K$ that is
finitely generated.  Every fractional ideal is of the form $a I = \{a
b : b \in I\}$ for some $a\in K$ and ideal $I\subset \O_K$.  For
emphasis, we will sometimes call a genuine ideal $I\subset \O_K$ an
{\em integral ideal}.
\end{definition}
For example, the set $\frac{1}{2}\Z$ of rational numbers with
denominator $1$ or $2$ is a fractional ideal of $\Z$.

\begin{theorem}\label{thm:div}
The set of nonzero fractional ideals of a Dedekind domain~$R$ is an
abelian group under ideal multiplication.
\end{theorem}




\end{document}