# Posts Tagged ‘binary quadratic forms’

## Binary quadratic forms over the rational integers and class numbers of quadratic ﬁelds.

August 23, 2014 by Will Jagy. 3 comments

I wrote an article with Irving Kaplansky on indefinite binary quadratic forms, integral coefficients. At the time, I believe I used high-precision continued fractions or similar. It took me years to realize that the right way to solve Pell’s equation, or find out the “minimum” of an indefinite form (and other small primitively represented values), or the period of its continued fraction, was the method of “reduced” forms in cycles/chains, due to Lagrange, Legendre, Gauss. It is also the cheapest way to find the class number and group multiplication for ideals in real quadratic fields, this probably due to Dirichlet. For imaginary quadratic fields, we have easier “reduced” positive forms.

A binary quadratic form, with integer coefficients, is some $$f(x,y) = A x^2 + B xy + C y^2.$$ The discriminant is $$\Delta = B^2 – 4 A C.$$ We will abbreviate this by $$\langle A,B,C \rangle.$$ It is primitive if $${\gcd(A,B,C)=1. }$$ Standard fact, hard to discover but easy to check: $$(A x^2 + B x y + C D y^2 ) (C z^2 + B z w + A D w^2 ) = A C X^2 + B X Y + D Y^2,$$ where $${ X = x z – D yw, \; Y = A xw + C yz + B yw. }$$ This gives us Dirichlet’s definition of “composition” of quadratic forms of the same discriminant, $$\langle A,B,CD \rangle \circ \langle C,B,AD \rangle = \langle AC,B,D \rangle.$$ In particular, if this $${D=1,}$$ the result represents $${1}$$ and is ($${SL_2 \mathbb Z}$$) equivalent to the “principal” form for this discriminant. Oh, duplication or squaring in the group; if $${\gcd(A,B)=1,}$$ $$\langle A,B,AD \rangle^2 = \langle A^2,B,D \rangle.$$ This comes up with positive forms: $${ \langle A,B,C \rangle \circ \langle A,-B,C \rangle = \langle 1,B,AC \rangle }$$ is principal, the group identity. Probably should display some $${SL_2 \mathbb Z}$$ equivalence rules, these are how we calculate when things are not quite right for Dirichlet’s rule: $$\langle A,B,C \rangle \cong \langle C,-B,A \rangle,$$ $$\langle A,B,C \rangle \cong \langle A, B + 2 A, A + B +C \rangle,$$ $$\langle A,B,C \rangle \cong \langle A, B – 2 A, A – B +C \rangle.$$

more »