Partitioned inverse, off-diagonal row entries:
ProvedGaussianMatrix.schur_offdiag_invLet , fix a row index , let be the -th row and the matrix of the remaining rows in their original order, and assume is invertible. Let be the least-squares coefficients of on the rows of . Then for every , writing for the index in of the -th row of ,
Together with the diagonal formula (schur_diag_inv), this describes the whole -th row of : it equals (in the ordering first), with the Schur complement. It is the deterministic step that turns off-diagonal entries of an inverse Wishart matrix into a ratio of independent quantities (regression coefficients over a residual).
Formalization Note. The index is i.succAbove a and is G.submatrix i.succAbove id. Lean's matrix inverse is total; the identity holds under the sole hypothesis , including the degenerate case , where is singular and both sides are .
import Definitions.Def_GaussianMatrix_basic open MeasureTheory ProbabilityTheory open scoped Matrix
namespace GaussianMatrix
theorem schur_offdiag_inv {n k : ℕ} (G : Matrix (Fin (n + 1)) (Fin k) ℝ) (i : Fin (n + 1))
(a : Fin n)
(hH : (G.submatrix i.succAbove id * (G.submatrix i.succAbove id)ᵀ).det ≠ 0) :
(G * Gᵀ)⁻¹ i (i.succAbove a) =
-(((G.submatrix i.succAbove id * (G.submatrix i.succAbove id)ᵀ)⁻¹ *ᵥ
(G.submatrix i.succAbove id *ᵥ G i)) a) * (G * Gᵀ)⁻¹ i i := by sorry
end GaussianMatrix