# Orthogonal basis in R3 containing a given set

I need guidance in solving this problem: Find an orthogonal basis for $$\mathbb{R}^3$$ containing the set $$S = \{v_1, v_2\}$$ where $$v_1 = \begin{bmatrix} -4 \\ 1 \\ 2 \end{bmatrix}$$ and $$v_2 = \begin{bmatrix} 0 \\ -1 \\ 2 \end{bmatrix}, \langle v_1, v_2\rangle := a_1b_1 + 4a_2b_2 + a_3b_3$$

My approach: Applying the Gram-Schmidt Method, \begin{align*} x_1 &= v_1\\ x_2 &= v_2 - \dfrac{{v_2}^Tx_1}{{x_1}^Tx_1}x_1 = \begin{bmatrix} 0 \\ -1 \\ 2 \end{bmatrix} - \dfrac{\begin{bmatrix} 0 & -1 & 2 \end{bmatrix}\begin{bmatrix} -4 \\ 1 \\ 2 \end{bmatrix}}{\begin{bmatrix} -4 & 1 & 2 \end{bmatrix}\begin{bmatrix} -4 \\ 1 \\ 2 \end{bmatrix}}\begin{bmatrix} -4 \\ 1 \\ 2 \end{bmatrix}\\ &= \begin{bmatrix} 0 \\ -1 \\ 2 \end{bmatrix} - \dfrac{3}{21}\begin{bmatrix} -4 \\ 1 \\ 2 \end{bmatrix}\\ &= \begin{bmatrix} 0 \\ -1 \\ 2 \end{bmatrix} - \begin{bmatrix} -4/7 \\ 1/7 \\ 2/7 \end{bmatrix} = \begin{bmatrix} 4/7 \\ -8/7 \\ 12/7 \end{bmatrix}\\\\ \text{Orthogonal basis } &= \text{ span}\left\{x_1, x_2\right\}\\ &= \text{ span}\left\{\begin{bmatrix} -4 \\ 1 \\ 2 \end{bmatrix}, \begin{bmatrix} 4/7 \\ -8/7 \\ 12/7 \end{bmatrix}\right\} \end{align*} Is my solution and conclusion correct?

• can 2 vectors span $\mathbb{R}^3$? May 19, 2021 at 16:55
• This was given as a seatwork for us which makes me wonder, could this possibly be a trick question?
– muw
May 19, 2021 at 16:59
• Are you sure there is no accidental swapping of $y$ and $z$ coordinate for one of the two given vectors? May 19, 2021 at 17:01
• Do you know what the cross product (or: vector product) of vectors is ? May 19, 2021 at 17:03
• @HagenvonEitzen those were the given. There was also an inner product endowed but I am not exactly sure where to use it. Updated my post.
– muw
May 19, 2021 at 17:07

With respect to the given inner product, you have $$\langle v_1,v_2\rangle=0$$; in other words, they're orthogonal.
So, find a vector$$u=\begin{bmatrix}a\\b\\c\end{bmatrix}$$which is orthogonal to both and which os not the null vector. That is, solve the system$$\left\{\begin{array}{l}\langle v_1,u\rangle=0\\\langle v_2,u\rangle=0.\end{array}\right.$$Every solution is of the form$$u=\begin{bmatrix}2c\\c\\2c\end{bmatrix}$$and you can take, say,$$u=\begin{bmatrix}2\\1\\2\end{bmatrix}.$$