NLA-lib Explorer

Matrix.IsHermitian.trace_eq_sum_range_eigenvalue

Library ยท theorem

The trace of a Hermitian matrix is the sum of its eigenvalues: \operatorname{tr} \mathbf{A} = \sum_{k < \lvert n \rvert} \lambda_k(\mathbf{A}). Mathlib's Matrix.IsHermitian.trace_eq_sum_eigenvalues is the same fact for the unsorted hA.eigenvalues. [HornJohnson2013, Theorem 1.2.16].

Matrix.IsHermitian.trace_eq_sum_range_eigenvalue.{u_1, u_2} {๐•œ : Type u_1} [RCLike ๐•œ] {n : Type u_2}
  [Fintype n] {A : Matrix n n ๐•œ} (hA : A.IsHermitian) :
  A.trace = โ†‘(โˆ‘ k โˆˆ Finset.range (Fintype.card n), eigenvalue A k)

Full source on GitHub

Import NLAlib.Matrix.Spectral.EigenvalueTransform.