Home · Everyday · Matrices · Gram-Schmidt Calculator
Gram-Schmidt Calculator
Gram–Schmidt orthonormalization — turn a set of independent vectors into an orthonormal basis for the same space.
What this calculator does
Gram–Schmidt orthonormalization — turn a set of independent vectors into an orthonormal basis for the same space. Where a measure is involved, US and metric units are both accepted — flip the unit toggle and the figures convert with the same definitions the formula uses. Every result on this page is computed from the formula stated below, with no hidden rounding steps.
The formula and method
Vectors are read as the rows of the matrix you enter.
Gram–Schmidt subtracts each vector's projections on the orthonormal vectors built so far, then normalises.
A zero residual means the vector was dependent on the earlier ones; rank counts the independent set.
Worked example
With the example inputs this page opens with, the result is (0.7071, 0.7071, 0) (0.4082, -0.4082, 0.8165) — orthonormal basis. Gram–Schmidt subtracts from each vector its projections onto the previous ones, then normalizes. The headline figure is the first component of the first basis vector.
Quick reference
| Figure | Value |
|---|---|
| Orthonormal basis | (0.7071, 0.7071, 0) (0.4082, -0.4082, 0.8165) |
| q1 | (0.7071, 0.7071, 0) |
| q2 | (0.4082, -0.4082, 0.8165) |
Computed with the same formulas as the calculator above — enter any values there for figures beyond this table.
Common questions
How does the Gram-Schmidt Calculator work?
Gram–Schmidt orthonormalization — turn a set of independent vectors into an orthonormal basis for the same space. Vectors (as matrix columns) → Orthonormal basis. The result updates as you type, and the formula and method on this page state the exact definitions used, so you can reproduce the calculation by hand.
What inputs does the Gram-Schmidt Calculator need?
Vectors (as matrix columns) → Orthonormal basis. Invalid entries — such as a zero denominator, an out-of-range value or a malformed list — produce a plain-language message instead of a misleading number.
Is the Gram-Schmidt Calculator free to use?
Yes. It runs entirely in your browser with no sign-up, and the same calculator is available as an embeddable widget via the Embed button, so it can be placed on another site with its calculation intact.