NLA-lib Explorer

Matrix.IsHermitian.norm_mulVec_sub_smul_sq

Library · theorem

Pythagoras for residuals. For Hermitian \mathbf{A}, any vector \mathbf{x} and real \mu, \|\mathbf{A}\mathbf{x} - \mu\mathbf{x}\|^2 = \|\mathbf{A}\mathbf{x} - \rho\mathbf{x}\|^2 + (\mu - \rho)^2 \|\mathbf{x}\|^2, with \rho the Rayleigh quotient of \mathbf{x}. [Parlett1998, §4.6] (locator to check).

Matrix.IsHermitian.norm_mulVec_sub_smul_sq.{u_1, u_2} {𝕜 : Type u_1} [RCLike 𝕜] {n : Type u_2}
  [Fintype n] {A : Matrix n n 𝕜} (hA : A.IsHermitian) (x : n → 𝕜) (μ : ℝ) :
  ‖WithLp.toLp 2 (A *ᵥ x - μ • x)‖ ^ 2 =
    ‖WithLp.toLp 2 (A *ᵥ x - rayleighQuotient A x • x)‖ ^ 2 +
      (μ - rayleighQuotient A x) ^ 2 * ‖WithLp.toLp 2 x‖ ^ 2

Full source on GitHub

Import NLAlib.Matrix.Perturbation.Residual.