The binary quadratic form of a 2 × 2 matrix #
To a matrix M = !![a, b; c, d] we attach the binary quadratic form
Q_M = c x² + (d - a) x y - b y², whose value at v = (x, y) is the determinant of the matrix
with columns v and M v (this is not the Gram form vᵀ M v). Its roots are the fixed points of
M acting by Möbius transformations: for invertible M, Q_M(z, 1) is Mathlib's
Matrix.GeneralLinearGroup.fixpointPolynomial. The discriminant of Q_M is tr(M)² - 4 det M,
Mathlib's Matrix.discr M,
and conjugating M by γ ∈ SL(2, R) acts on Q_M by the action γ • f = f ∘ γ⁻¹ of
TauCeti.BinaryQuadraticForm.Basic.
Over ℤ, M ↦ Q_M is a bijection between the matrices of trace t and determinant n and the
forms of discriminant t² - 4 n: the form determines c, b and d - a, the trace determines
a + d, and (d - a)² + 4 b c = t² - 4 n forces d - a ≡ t (mod 2). This is the correspondence
through which the Eichler–Selberg trace formula counts the elliptic conjugacy classes of matrices
of determinant n by the Hurwitz class numbers H(4 n - t²).
Main definitions #
TauCeti.BinaryQuadraticForm.ofMatrix: the formQ_M = c x² + (d - a) x y - b y².TauCeti.BinaryQuadraticForm.ofMatrixEquiv: fort n : ℤ, the bijectionM ↦ Q_Mfrom the integer matrices of tracetand determinantnto the forms of discriminantt² - 4 n.
Main results #
TauCeti.BinaryQuadraticForm.discrim_ofMatrix: the discriminant ofQ_Mistr(M)² - 4 det M.TauCeti.BinaryQuadraticForm.ofMatrix_conj:Q_{γ M γ⁻¹} = γ • Q_Mforγ ∈ SL(2, R).TauCeti.BinaryQuadraticForm.ofMatrix_inj_of_trace_eq: when2is not a zero divisor, a2 × 2matrix is determined by its trace and its formQ_M.
References #
- A. Popa and D. Zagier, An elementary proof of the Eichler–Selberg trace formula, J. Reine Angew. Math. 762 (2020), 105–122, arXiv:1711.00327, §1.
The binary quadratic form Q_M = c x² + (d - a) x y - b y² of the matrix M = !![a, b; c, d]
(see eval_ofMatrix).
Instances For
For g ∈ GL(2, R), Q_g(z, 1) is Mathlib's fixed-point polynomial of g evaluated at z,
whose roots are the fixed points of g acting by Möbius transformations.
When 2 is not a zero divisor in R, for instance over ℤ, ℤ_p or a field of
characteristic other than two, a 2 × 2 matrix is determined by its trace and its form Q_M.
For t n : ℤ, M ↦ Q_M is a bijection from the integer matrices of trace t and determinant
n to the integral forms of discriminant t² - 4 n. The inverse sends f = ⟨a, b, c⟩ to
!![(t - b) / 2, -c; a, t - (t - b) / 2]; as b² - 4 a c = t² - 4 n forces b ≡ t (mod 2), its
lower right entry is (t + b) / 2.
Instances For
The inverse of ofMatrixEquiv t n sends f = ⟨a, b, c⟩ to
!![(t - b) / 2, -c; a, t - (t - b) / 2].