Certainly! The Gram-Schmidt process is a method for orthonormalizing a set of vectors in an inner product space, typically (\mathbb{R}^n). Given a set of linearly independent vectors, it produces an orthonormal set of vectors that span the same subspace.
Example
Let's apply the Gram-Schmidt process to the following set of vectors in (\mathbb{R}^3):
[
\mathbf{v}_1 = \begin{bmatrix}1 \ 1 \ 0\end{bmatrix}, \quad
\mathbf{v}_2 = \begin{bmatrix}1 \ 0 \ 1\end{bmatrix}
]
Step 1: Define (\mathbf{u}_1)
[
\mathbf{u}_1 = \mathbf{v}_1 = \begin{bmatrix}1 \ 1 \ 0\end{bmatrix}
]
Normalize (\mathbf{u}_1) to get (\mathbf{e}_1):
[
|\mathbf{u}_1| = \sqrt{1^2 + 1^2 + 0^2} = \sqrt{2}
]
[
\mathbf{e}_1 = \frac{\mathbf{u}_1}{|\mathbf{u}_1|} = \frac{1}{\sqrt{2}}\begin{bmatrix}1 \ 1 \ 0\end{bmatrix}
]
Step 2: Define (\mathbf{u}_2)
Project (\mathbf{v}_2) onto (\mathbf{e}_1):
[
\text{proj}_{\mathbf{e}_1} \mathbf{v}_2 = \left(\mathbf{v}_2 \cdot \mathbf{e}_1\right) \mathbf{e}_1
]
Calculate the dot product:
[
\mathbf{v}_2 \cdot \mathbf{e}_1 = \begin{bmatrix}1 & 0 & 1\end{bmatrix} \cdot \frac{1}{\sqrt{2}}\begin{bmatrix}1 \ 1 \ 0\end{bmatrix} = \frac{1 \times 1 + 0 \times 1 + 1 \times 0}{\sqrt{2}} = \frac{1}{\sqrt{2}}
]
Therefore,
[
\text{proj}_{\mathbf{e}_1} \mathbf{v}_2 = \frac{1}{\sqrt{2}} \mathbf{e}_1 = \frac{1}{\sqrt{2}} \times \frac{1}{\sqrt{2}} \begin{bmatrix}1 \ 1 \ 0\end{bmatrix} = \frac{1}{2} \begin{bmatrix}1 \ 1 \ 0\end{bmatrix}
]
Now,
[
\mathbf{u}_2 = \mathbf{v}2 - \text{proj}{\mathbf{e}_1} \mathbf{v}_2 = \begin{bmatrix}1 \ 0 \ 1\end{bmatrix} - \frac{1}{2} \begin{bmatrix}1 \ 1 \ 0\end{bmatrix} = \begin{bmatrix}1 - \frac{1}{2} \ 0 - \frac{1}{2} \ 1 - 0\end{bmatrix} = \begin{bmatrix}\frac{1}{2} \ -\frac{1}{2} \ 1\end{bmatrix}
]
Normalize (\mathbf{u}_2):
[
|\mathbf{u}_2| = \sqrt{\left(\frac{1}{2}\right)^2 + \left(-\frac{1}{2}\right)^2 + 1^2} = \sqrt{\frac{1}{4} + \frac{1}{4} + 1} = \sqrt{1.5} = \sqrt{\frac{3}{2}} = \frac{\sqrt{6}}{2}
]
[
\mathbf{e}_2 = \frac{\mathbf{u}_2}{|\mathbf{u}_2|} = \frac{1}{\frac{\sqrt{6}}{2}} \begin{bmatrix} \frac{1}{2} \ -\frac{1}{2} \ 1 \end{bmatrix} = \frac{2}{\sqrt{6}} \begin{bmatrix} \frac{1}{2} \ -\frac{1}{2} \ 1 \end{bmatrix} = \begin{bmatrix} \frac{1}{\sqrt{6}} \ -\frac{1}{\sqrt{6}} \ \frac{2}{\sqrt{6}} \end{bmatrix}
]
Final orthonormal basis vectors:
[
\mathbf{e}_1 = \frac{1}{\sqrt{2}} \begin{bmatrix}1 \ 1 \ 0\end{bmatrix}, \quad
\mathbf{e}_2 = \begin{bmatrix} \frac{1}{\sqrt{6}} \ -\frac{1}{\sqrt{6}} \ \frac{2}{\sqrt{6}} \end{bmatrix}
]
Summary
- The original vectors (\mathbf{v}_1) and (\mathbf{v}_2) are linearly independent but not orthogonal.
- The Gram-Schmidt process creates an orthonormal set ({\mathbf{e}_1, \mathbf{e}_2}) spanning the same subspace.
- You can verify that (\mathbf{e}_1 \cdot \mathbf{e}_2 = 0) and (|\mathbf{e}_1| = |\mathbf{e}_2| = 1).
If you'd like, I can also demonstrate the process on three vectors or in symbolic form. Just let me know!