# Dimension of Basis of Subspace

I was just wondering if there is any "rule" for what the dimension of a basis of a given subspace will be.

For example, a problem I just did involved a vector $v = (1, 2, 3, 4)$ in $\mathbb{R}^4$, and I had to find a basis for the subspace in $\mathbb{R}^4$ consisting of all vectors perpendicular to $v$.

My intuition for this was to note that the subspace of vectors perpendicular to v is the plane with v as its normal vector. Thus, any two vectors in the plane which are linearly independent would be a basis, and the dimension of the basis would be two.

However, the answer the book gave had a dimension of three. They solved it in a way that makes sense to me as well but I'm still confused as to where I went wrong with my logic. I'm sensing the answer lies in the fact that R4 planes don't behave the same way as R3 planes.

Another problem involved finding the basis for the orthogonal complement of a subspace in R4 spanned by two vectors: $W = Span\{(1, 2, 3, 4),(5, 6, 7, 8)\}$, and the answer had a dimension of two (not three).

I guess I'm just confused on where the dimension is coming from. Any help would be great.

Thanks!

• The dimension of a vector space is often defined to be the number of elements in a basis. Does that help? – siegehalver Mar 29 '16 at 1:38
• In $\mathbb{R}^2$, the subspace of all vectors orthogonal to a single vector is a line: it has dimension $1$. In $\mathbb{R}^3$, it has dimension $2$. So then, in $\mathbb{R}^4$, wouldn't you expect it to have dimension $3$? – Alex Provost Mar 29 '16 at 1:39

You were wrong because your intuition misled you. I don't mean to offend; it happens to everyone who studies math. Your intuition told you that the set of vectors perpendicular to $v$ would be a plane. This is because you are used to imagining with vectors in $\mathbb R^3$. In $\mathbb R^3$, we can choose only three independent directions at a time, and all other directions are some combination of those. You have one direction you cannot go, so that leaves two. But in $\mathbb R^4$, you have four directions! You cannot go in the direction of $v$, but you still have three other directions. In general, if you are looking for the orthogonal complement of a $k$ dimensional subspace of $\mathbb R^n$, it will have $n-k$ dimensions.

Well if you were talking about $R^3$ then you would have a plane of perpendicular vectors and that subspace would be two dimensional. The extra dimension comes from the fact that you are dealing with $R^4$.

In $\mathbb{R}^4$, planes are called "hyperplanes", and has dimension $4 - 1 = 3$. To see this, you can define a linear map $$f(u) = u \cdot v$$ where $\cdot$ is the dot product. Clearly $u \perp v \iff f(u) = 0 \iff u \in \ker f$, so the space of all vectors perpendicular to $v$ is $\ker f$. Using the Rank-Nullity Theorem, $$\dim \mathbb{R}^4 = \dim\ker f + \dim\operatorname{im} f = \dim\ker f + 1$$ Hence the hyperplane has dimension $3$.

My intuition for this was to note that the subspace of vectors perpendicular to v is the plane with v as its normal vector. Thus, any two vectors in the plane which are linearly independent would be a basis, and the dimension of the basis would be two.

Unfortunately planes are not always two-dimensional. The correct intuition is that the orthogonal complement of a subspace $U$ has dimension that "complements" the dimension of $U$ (assuming everything is finite-dimensional). So in a 5-dimensional space, the orthogonal complement of a one-dimensional subspace is 4-dimensional, the orthogonal complement of a two-dimensional subspace is 3-dimensional, and so forth.

Until you build a strong geometric intuition for vectors in dimensions higher than 3, I would suggest going with the direct approach of forming a basis and counting the number of elements.

We can see this problem as a direct sum problem in linear algebra. We have $$W^\perp=\{v: v\perp w, for\ any\ w \in W\}$$ and for any sub space $W$ of $\mathbb{R}^4$ it is proved that $\mathbb{R}^4= W\oplus W^\perp$ that is $$dim W^\perp +dimW=dim \mathbb{R}^4=4.$$ So we can deduce that $dim W^\perp=3.$