Modified Gram-Schmidt Algorithm

Definition

The Modified Gram-Schmidt (MGS) algorithm is a numerically stable variant of the Gram-Schmidt Orthogonalization used to compute an orthonormal basis for a set of vectors. It iteratively orthogonalizes each vector against previously orthogonalized vectors, reducing the numerical errors common in the classical Gram-Schmidt process.

Problem Setup

Given a set of linearly independent vectors in , the goal is to compute an orthonormal set such that:

Modified Gram-Schmidt Algorithm

Input:

  1. A matrix with columns .
  2. Linearly independent vectors in .

Output:

  1. Orthonormal matrix with columns .
  2. Upper triangular matrix such that .

Steps:

  1. Initialize: Set and .

  2. For each column :

    1. Compute : For :
    2. Orthogonalize :
    3. Normalize to get :
  3. Return and .


Comparison with Classical Gram-Schmidt

  1. Numerical Stability:

    • The MGS algorithm reduces loss of orthogonality that arises due to floating-point round-off errors in the classical Gram-Schmidt process.
  2. Re-orthogonalization:

    • MGS orthogonalizes one vector against all previous orthonormal vectors in a structured way, minimizing accumulated numerical errors.
  3. Efficiency:

    • MGS and classical Gram-Schmidt have the same computational complexity, , but MGS is more reliable for numerical computations.