This is a very basic question about understanding dimension (and codimension).

I was given that the definition for codimension is:
Let $W\subset X$ be a subspace. Then $\operatorname{codim} W=\dim(X\setminus W)$.

But there is a definition on a book saying that:
Given a linear space $X$, a proper linear subspace $M$ is called a linear space of codimension one if for a given $x_{0}\in X\setminus M$, every $x\in X$ can be represented as in the form
$$x=\alpha x_{0}+y$$ where $y$ is a scalar and $y\in M$.
And also, I have seen that many people use this representation (and its uniqueness) to show that the codimension of continuous linear non-zero functional is 1.

But I don't quite understand why this implies $\operatorname{codim}=1$ based on the definition in the very beginning? I think that I need to compute the dimension of the set of $x_{0}$, that is $x_{0}=(x-y)/\alpha$. Then I try to compute the basis for this, but then I get stuck.

Could someone explain this to me or help me understand dimension in a more sensible way?
Thanks a lot!

  • $\begingroup$ $\operatorname{codim}W=\dim (X/W)$ (the quotient space), not $\dim X\setminus W$, which isn't even defined, since $X\setminus W$ isn't a subspace. $\endgroup$
    – Bernard
    Feb 28, 2017 at 12:08

1 Answer 1


If you have a subspace $W\in X$ of co-dimension $1$, the definition of co-dimension as $\dim(X)-\dim(W)$ means that you can write $X=W\oplus Z$, with $Z$ of dimension $1$.

Then every vector $x$ in $X$ can be written as $x=z+y$ for some $z\in Z$, $y\in W$. But since $Z$ has dimension $1$, if you pick an arbitrary non-null $x_0\in Z$, every $z\in Z$ can be written as $a\cdot x_0$ for some scalar $a$, and thus $x$ can be written as $ax_0+y$.

Conversely, if every vector in $x\in X$ can be written as $x=ax_0+y$, with $y\in W$ and $x_0\notin W$, then taking any basis of $W$, and adding $x_0$, yields a set of $\dim(W)+1$ linearly independent vectors (they are linearly independent because you can't obtain $x_0$ as a linear combination of the others!); $W$ must then have dimension equal to $1$ less than the space they generate (i.e. $X$).

  • $\begingroup$ Thanks for your answer! But my question is why x=ax0+y means that Z has dimension 1? I know this may sound stupid..but how can I relate this to the basis since dimension is the number of elements in the basis right? $\endgroup$
    – Lazer
    Feb 28, 2017 at 12:03
  • $\begingroup$ Oh the arbitrary x0 here is the basis which only has dimension 1 right? $\endgroup$
    – Lazer
    Feb 28, 2017 at 12:05
  • $\begingroup$ @J.Y yes, that's right! $\{x_0\}$ is a basis for $Z$. $\endgroup$
    – Anonymous
    Feb 28, 2017 at 12:05

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.