Gram–Schmidt and QR Factorization — Cheat sheet
On this page
Core rule
Subtract earlier projections, then normalize. For full column rank, with and upper triangular invertible .
Watch for
Zero residuals indicate dependence. Rectangular does not satisfy on the entire output space.