# Connection between quadratic forms and ideal class group

I'm studying the classic results on binary (integer) quadratic forms and I'm looking for a reference on the following result (maybe a book that contains a proof):

Let $O_k$ be the ring of algebraic integers of $Q(\sqrt{d})$. In the set of ideals of $O_k$, we define the equivalence relation $I \sim J \Leftrightarrow \exists a,b : (a)I=(b)J$ where $(a)$ is the ideal generated by $a$. Then, the equivalence classes of $\sim$ form a group $G$ with the usual multiplication of ideals. Furthermore, $|G|=h(d)$, where $h(d)$ is the class number.

The definition I've read for $h(d)$ is the number of equivalence classes of quadratic forms with discriminant $d$ for the equivalence relation $f \sim g \Leftrightarrow f(x,y)=g(px+qy,rx+sy)$ with $ps-qr=1$.

If someone could give me a good reference in this nice connection I would be really grateful.

• Does math.stackexchange.com/questions/410184/… answer your question? – S. Carnahan Feb 18 '14 at 0:05
• have you checked Cohen's a course in computational algebraic number theory? – Tom Bachmann Feb 18 '14 at 22:07
• See Theorem 5.30 of Cox's book on Primes of the form $x^2+ny^2$. The book in general discusses lots of things on binary quadratic forms and algebraic number theory. – Lucia Feb 18 '14 at 22:15
• Your definition needs to require $a$ and $b$ nonzero... – Arturo Magidin Feb 18 '14 at 22:16