Skip to content
uencoder

QR Decomposition

QR decomposition factors a matrix A into the product of an orthogonal matrix Q and an upper-triangular matrix R, A=QR, used for least squares and eigenvalues.

Purpose

To solve least-squares problems and compute eigenvalues with the QR algorithm.

Mechanism

Implemented via Gram-Schmidt, Householder reflections, or Givens rotations. Least squares Ax≈b becomes Rx=Q^T b (an upper-triangular system). Householder is the most numerically stable.

Use cases

  • Least squares
  • Eigenvalue computation
  • Numerical linear algebra

Related tools

References