Gram Schmidt Calculator

Gram-Schmidt Orthonormalization

Turn a set of vectors into an orthonormal basis.

Last updated: June 2026 | By Patchworkr Team

Interactive Calculator

Enter vectors as rows. The calculator produces an orthonormal basis using the classical Gram-Schmidt process.

Vector 1
Vector 2
Vector 3
Orthonormal Basis Output
u1:[0.707107, 0.707107, 0]
u2:[0.408248, -0.408248, 0.816497]
u3:[-0.57735, 0.57735, 0.57735]

What it does

It removes projections onto earlier vectors and then normalizes the result.

Common use

Gram-Schmidt is a building block for QR factorization and orthogonal coordinate systems.

Worked Example

Use the default three vectors.

1. Start with [1, 1, 0]

2. Remove its projection from the next vectors

3. Normalize each orthogonal vector

Final answer: an orthonormal basis

Frequently Asked Questions

How many vectors can I add?

You can add as many as you need for the basis.

What if the vectors are dependent?

A dependent set can produce zero-length output vectors.

Is order important?

Yes. Gram-Schmidt depends on the input order.

Are the outputs normalized?

Yes. The resulting vectors have unit length when possible.

Related Tools