NLA-lib Explorer

Matrix.PosSemidef.sum_mul_re_trace_eliminationStep

Library · theorem

The expected trace after a step of randomly pivoted Cholesky: for positive semidefinite \mathbf{A} with \operatorname{tr} \mathbf{A} \ne 0, choosing the pivot i with probability \mathbf{A}_{i,i} / \operatorname{tr} \mathbf{A} leaves, on average, the trace \operatorname{tr} \mathbf{A} - \operatorname{tr}(\mathbf{A}^2) / \operatorname{tr} \mathbf{A}. [ChenEtAl2025, §5].

Matrix.PosSemidef.sum_mul_re_trace_eliminationStep.{u_1, u_2} {𝕜 : Type u_1} [RCLike 𝕜]
  {n : Type u_2} [Fintype n] {A : Matrix n n 𝕜} (hA : A.PosSemidef) (ht : RCLike.re A.trace ≠ 0) :
  ∑ i, RCLike.re (A i i) / RCLike.re A.trace * RCLike.re (eliminationStep A i).trace =
    RCLike.re A.trace - RCLike.re (A * A).trace / RCLike.re A.trace

Full source on GitHub

Import NLAlib.Matrix.Factorizations.Nystrom.