Basis of a matrix with zero rows

187 Views Asked by At

I'm trying to check whether B is a basis for $\mathbb{R}^m$. If B is not a basis, I want to use the matrix eye(m) from matlab to create a basis for $\mathbb{R}^m$ that will contain all vectors from B and some vectors from the matrix eye(m). I don't have issue with the matlab function coding, I have issue with what the right answer should be. For example: The matrix $\begin{bmatrix}1& 0\\ 0 &0\\ 0 & 0\\ 0 &1\end{bmatrix}$ turns into what? Does it turn into this: $$\begin{bmatrix}1 &0 &0 &0\\0 &0 &1 &0\\0 &0& 0 &1 \\ 0 & 1 & 0 & 0\end{bmatrix}$$ or this: $\begin{bmatrix}1 &0\\ 0 &1\end{bmatrix}$?

1

There are 1 best solutions below

4
On

A rectangular matrix has a left and a right basis. Both can be completed to an orthogonal set (gram-schmidt or something similar).

If you want to understand this better, take a look at the SVD decomposition. It does precisely that (and more): it presents a rectangular matrix as a succession of three transformations: decomposition in the right basis, scale in this basis, and mapping to the vectors of the left basis:

$$A=U\Sigma V^T$$

where $U$ and $T$ are orthonormal.