1
$\begingroup$

So I am trying to find an orthonormal basis of a subspace, defined as

$U := \{x \in \mathbb{R}^4 | x_1 + 2x_2 - x_4 = 0 \} \subset \mathbb{R}^4 $

I choose $w_1=\pmatrix{0\\0\\1\\0},w_2=\pmatrix{1\\0\\0\\1},w_3=\pmatrix{1\\0\\1\\1} $

The Gram-Schmidt procedure lead to the following vectors $v_1=\pmatrix{0\\0\\1\\0},v_2=\pmatrix{1\\0\\0\\1},v_3=\pmatrix{0\\0\\0\\0} $

But I suspect $v_3$ not to be a valid solution. So what did I wrong here? (Is $w_1$ not allowed?)

Additionally, how do I check vectors to be a basis of a linear subspace?

$\endgroup$
  • 3
    $\begingroup$ You need to initialize Gram-Schmidt with a basis, but your $\{w_1,w_2,w_3\}$ is dependent. $\endgroup$ – vadim123 May 3 '13 at 20:37
  • 2
    $\begingroup$ $w_1 = w_3 - w_2$. The starting set of vectors needs to be linearly independent. $\endgroup$ – Ayman Hourieh May 3 '13 at 20:37
  • $\begingroup$ thanks to you two. So I have to choose a different starting set. But how can I check afterwards whether my solution is correct? $\endgroup$ – Angelo.Hannes May 3 '13 at 20:40
  • $\begingroup$ Verify that the resulting set is orthonormal and spans the original space. Write each one of the original vectors as a linear combination of the resulting vectors. $\endgroup$ – Ayman Hourieh May 3 '13 at 20:46
  • $\begingroup$ @Angelo.Hannes : You are trying to find an orthonormal basis, not "the basis". Your first sentence is incorrect because (a) there are infinitely many bases, and (b) you are trying to find an orthonormal basis, not just any basis. Eventually you say what you mean, but you should make a habit of being precise because being imprecise sometimes causes confusion. Also, I am not sure if the term "linear subspace" is correct. I honestly don't know. I've never heard it, and I don't think there is any other kind of subspace. Almost anyone would just say "subspace". $\endgroup$ – Stefan Smith May 4 '13 at 1:40
1
$\begingroup$

Recall the definition of a basis:

Let $V$ be a vector space. Then a set of vectors $B$ is said to be a basis of $V$ if $lin(B) = V$ and is linearly independent.

The vectors you chose do not fit the linear independence definition as $w_1=w_3-w_2$. For that reason, the subspace spanned by your vectors actually only describe a two-dimensional object in $\mathbb{R}^4$

We can see that U is a three-dimensional object in $\mathbb{R}^4$.

An example of three linearly independent vectors in $U$ is $w_1=\pmatrix{0\\0\\1\\0},w_1=\pmatrix{2\\-1\\0\\0},w_1=\pmatrix{1\\0\\0\\1}$.

We check for linear independence:

If $\alpha\pmatrix{0\\0\\1\\0}+\beta\pmatrix{2\\-1\\0\\0}+\gamma\pmatrix{1\\0\\0\\1}=\pmatrix{0\\0\\0\\0}$, then clearly $\alpha=\beta=\gamma=0$.

From there you can carry on the Gram-Schmidt procedure, and you should get your desired result.

$\endgroup$
  • $\begingroup$ This check must also hold true for my resulting vectors, right? $\endgroup$ – Angelo.Hannes May 4 '13 at 7:13
  • $\begingroup$ The Gram–Schmidt process takes a finite, linearly independent set of vectors (here w1, w2, w3) and generates an orthogonal set of vectors that spans the same subspace. So, if the vectors you initially chose are linearly independent, it has to be that your resulting vectors are linearly independent too. $\endgroup$ – Yuee Sun May 4 '13 at 17:44
2
$\begingroup$

Your original vector $w_3$ is a linear combination of the previous two; in fact, $w_3 = w_1 + w_2$. Whenever that happens, the Gram-Schmidt process will spit out the zero vector. (Because $v_3$ will be forced to be in the span of $w_1$ and $w_2$, but also orthogonal to $w_1$ and $w_2$, the only possibility for $v_3$ is $0$.)

Go back and produce a basis for your subspace, then apply the Gram-Schmidt process and you'll have an orthogonal basis as desired.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.