Gram-Schmidt Calculator

Enter 2 or 3 vectors to compute an orthogonal and orthonormal basis using the Gram-Schmidt process, with full step-by-step working.

Use the Gram-Schmidt Calculator

Input Vectors

Enter your vectors and click Calculate to see results.

Summary

The Gram-Schmidt process converts a set of linearly independent vectors into an orthogonal (or orthonormal) basis for the same vector space. This calculator supports 2 or 3 vectors in 2D or 3D, computes each orthogonal basis vector by subtracting projections onto previously computed vectors, and then normalizes each result to produce unit vectors. All intermediate steps are shown so you can follow the working exactly.

How it works

  1. Select the dimension (2D or 3D) and the number of vectors (2 or 3).
  2. Enter the components of each input vector.
  3. Click "Calculate" to run the Gram-Schmidt process.
  4. The tool computes each orthogonal vector by subtracting projections of previous basis vectors.
  5. Each orthogonal vector is then divided by its norm to produce an orthonormal unit vector.
  6. Step-by-step working is displayed so you can verify every intermediate value.

Use cases

  • Linear algebra homework and exam preparation.
  • Computing an orthonormal basis for QR decomposition.
  • Verifying manual Gram-Schmidt calculations.
  • Understanding vector projection and orthogonality concepts.
  • Machine learning feature orthogonalization.
  • Physics and engineering problems requiring orthonormal frames.

Frequently Asked Questions

Last updated: 2026-06-04 · Reviewed by Nham Vu