• Support PF! Buy your school textbooks, materials and every day products Here!

Linear Algebra - Gram-Schmidt Process

  • #1
24
0

Homework Statement


Let R2 have the Euclidean inner product and use the Gram-Schmidt process to transform the basis {u1,u2} into an orthonormal basis.

u1 = (1,-3)
u2 = (2,2)

Homework Equations



Gram-Schmidt process:

[tex]
\\v_1 = u_1
\\v_2= u_2 -

\frac{\left ( \left \langle u_2, v_1\right \rangle \right )}{\left \|
v_1

\right \| ^ 2}


v_1
[/tex]

The Attempt at a Solution



We'll go ahead and find the norm of v first. Then we'll evaluate the second Gram-Schmidt equation.

[tex]
\\\left \| v_1 \right \| = \sqrt{10} \\\\
\left \| v_1 \right \|v_1 = u_1 = (1,-3)
\\\\\left \| v_2 \right \|v_2= \begin{bmatrix}
2\\2

\end{bmatrix} -

\frac{\left ( \left \langle \begin{bmatrix}
2\\2

\end{bmatrix} , \begin{bmatrix}
\frac{1}{\sqrt{10}}\\ \frac{-3}{\sqrt{10}}

\end{bmatrix} \right \rangle \right )}{\left \| \begin{bmatrix}
\frac{1}{\sqrt{10}}\\ \frac{-3}{\sqrt{10}}

\end{bmatrix} \right \| ^ 2}

\begin{bmatrix}
\frac{1}{\sqrt{10}}\\ \frac{-3}{\sqrt{10}}

\end{bmatrix}


\\\\\left \| v_2 \right \|v_2= \begin{bmatrix}
2\\2

\end{bmatrix} - \frac{\left ( \frac{-4}{\sqrt{10}} \right )}{1} \begin{bmatrix} \frac{1}{\sqrt{10}}\\ \frac{-3}{\sqrt{10}} \end{bmatrix}

\\\\

\begin{bmatrix}
2\\2

\end{bmatrix}

- \begin{bmatrix}
\frac{-4}{10}\\\\\frac{12}{10}

\end{bmatrix}

=

\begin{bmatrix}
\frac{24}{10}\\\\\frac{8}{10}

\end{bmatrix}

=

\begin{bmatrix}
\frac{12}{5}\\\\\frac{4}{5}

\end{bmatrix}
[/tex]

I've not been able to get another answer for this step. Even checked in Matlab.

Now, we'll normalize the vector like the problem wants us to:
[tex]
\\\left \| v_2 \right \| = \sqrt{8}
\\
v_2 = \begin{bmatrix}
\frac{\frac{12}{5}}{\sqrt{8}}\\
\frac{\frac{4}{5}}{\sqrt{8}}

\end{bmatrix}

=

\begin{bmatrix}

\frac{\frac{12}{5}}{\sqrt{8}}\\
\frac{\frac{4}{5}}{\sqrt{8}}

\end{bmatrix}

=

\begin{bmatrix}

\frac{12}{10\sqrt{2}}\\\\
\frac{4}{10\sqrt{2}}

\end{bmatrix}

=

\begin{bmatrix}

\frac{6}{5\sqrt{2}}\\\\
\frac{2}{5\sqrt{2}}

\end{bmatrix}

=

\begin{bmatrix}

\frac{6\sqrt{2}}{10}\\\\
\frac{2\sqrt{2}}{10}

\end{bmatrix}

=

\begin{bmatrix}

\frac{3\sqrt{2}}{5}\\\\
\frac{\sqrt{2}}{5}

\end{bmatrix}
[/tex]

This is an odd problem, so I know that the solution should be [itex] v_2 = (\frac{3}{\sqrt{10}} , \frac{1}{\sqrt{10}}) [/itex]. There must be something wrong when I'm finding [itex]||v_2||v_2[/itex] . Is there anything fundamentally wrong with my process?
 
Last edited:

Answers and Replies

  • #2
vela
Staff Emeritus
Science Advisor
Homework Helper
Education Advisor
14,580
1,198

Homework Statement


Let R2 have the Euclidean inner product and use the Gram-Schmidt process to transform the basis {u1,u2} into an orthonormal basis.

u1 = (1,-3)
u2 = (2,2)

Homework Equations



Gram-Schmidt process:

[tex]
\\v_1 = u_1
\\v_2= u_2 -

\frac{\left ( \left \langle u_2, v_1\right \rangle \right )}{\left \|
v_1

\right \| ^ 2}


v_1
[/tex]

The Attempt at a Solution



We'll go ahead and find the norm of v first. Then we'll evaluate the second Gram-Schmidt equation.

[tex]
\\\left \| v_1 \right \| = \sqrt{10} \\\\
\left \| v_1 \right \|v_1 = u_1 = (1,-3)
\\\\\left \| v_2 \right \|v_2= \begin{bmatrix}
2\\2

\end{bmatrix} -

\frac{\left ( \left \langle \begin{bmatrix}
2\\2

\end{bmatrix} , \begin{bmatrix}
\frac{1}{\sqrt{10}}\\ \frac{-3}{\sqrt{10}}

\end{bmatrix} \right \rangle \right )}{\left \| \begin{bmatrix}
\frac{1}{\sqrt{10}}\\ \frac{-3}{\sqrt{10}}

\end{bmatrix} \right \| ^ 2}

\begin{bmatrix}
\frac{1}{\sqrt{10}}\\ \frac{-3}{\sqrt{10}}

\end{bmatrix}


\\\\\left \| v_2 \right \|v_2= \begin{bmatrix}
2\\2

\end{bmatrix} - \frac{\left ( \frac{-4}{\sqrt{10}} \right )}{1} \begin{bmatrix} \frac{1}{\sqrt{10}}\\ \frac{-3}{\sqrt{10}} \end{bmatrix}

\\\\

\begin{bmatrix}
2\\2

\end{bmatrix}

- \begin{bmatrix}
\frac{-4}{10}\\\\\frac{12}{10}

\end{bmatrix}

=

\begin{bmatrix}
\frac{24}{10}\\\\\frac{8}{10}

\end{bmatrix}

=

\begin{bmatrix}
\frac{12}{5}\\\\\frac{4}{5}

\end{bmatrix}
[/tex]

I've not been able to get another answer for this step. Even checked in Matlab.
If you get rid of a common factor of 4/5, you have ##\vec{v}_2 = \begin{bmatrix} 3 \\ 1 \end{bmatrix}##.

Now, we'll normalize the vector like the problem wants us to:
[tex]
\\\left \| v_2 \right \| = \sqrt{8}
\\
v_2 = \begin{bmatrix}
\frac{\frac{12}{5}}{\sqrt{8}}\\
\frac{\frac{4}{5}}{\sqrt{8}}

\end{bmatrix}

=

\begin{bmatrix}

\frac{\frac{12}{5}}{\sqrt{8}}\\
\frac{\frac{4}{5}}{\sqrt{8}}

\end{bmatrix}

=

\begin{bmatrix}

\frac{12}{10\sqrt{2}}\\\\
\frac{4}{10\sqrt{2}}

\end{bmatrix}

=

\begin{bmatrix}

\frac{6}{5\sqrt{2}}\\\\
\frac{2}{5\sqrt{2}}

\end{bmatrix}

=

\begin{bmatrix}

\frac{6\sqrt{2}}{10}\\\\
\frac{2\sqrt{2}}{10}

\end{bmatrix}

=

\begin{bmatrix}

\frac{3\sqrt{2}}{5}\\\\
\frac{\sqrt{2}}{5}

\end{bmatrix}
[/tex]

This is an odd problem, so I know that the solution should be [itex] v_2 = (\frac{3}{\sqrt{10}} , \frac{1}{\sqrt{10}}) [/itex]. There must be something wrong when I'm finding [itex]||v_2||v_2[/itex] . Is there anything fundamentally wrong with my process?
 
  • #3
24
0
Ok. So I gather that my answer is not technically wrong? How can I verify that my original answer is in fact an orthonormal basis spanning the same subspace?

I guess if I make computational errors, it will be unlikely that all the dot products in some generated set of vectors is zero. Right?
 
Last edited:
  • #4
vela
Staff Emeritus
Science Advisor
Homework Helper
Education Advisor
14,580
1,198
Your answer is wrong. You didn't normalize the vector correctly.
 
  • #5
24
0
Ah, I see that I accidentally used the norm of u2 instead of v2 to normalize v2. The book confused me by switching up u's and v's.

Checking to see if the norm of the final vectors is one would also be a useful trick.
 

Related Threads on Linear Algebra - Gram-Schmidt Process

  • Last Post
Replies
1
Views
1K
Replies
1
Views
1K
Replies
1
Views
392
  • Last Post
Replies
10
Views
2K
  • Last Post
Replies
2
Views
4K
  • Last Post
Replies
2
Views
1K
  • Last Post
Replies
1
Views
9K
  • Last Post
Replies
4
Views
6K
Replies
2
Views
530
Replies
1
Views
1K
Top