# Vivid examples of vector spaces?

When teaching abstract vector spaces for the first time, it is handy to have some really weird examples at hand, or even some really weird non-examples that may illustrate the concept. For example, a physicist friend of mine uses "color space" as a (non) example, with two different bases given essentially {red, green, blue} and {hue, saturation and brightness} (see http://en.wikipedia.org/wiki/Color_space). I say this is a non-example for a number of reasons, the most obvious being the absence of "negative color".

Anyhow, what are some bizarre and vivid examples of vector spaces you've come across that would be suitable for a first introduction?

-
Seems like a duplicate of math.stackexchange.com/questions/4694/… to me. –  Qiaochu Yuan Sep 22 '10 at 16:40
Oops. Sorry about the duplication. Should I delete this, Qiaochu? –  Jon Bannon Sep 22 '10 at 17:08
If you can reword the question into something sufficiently different it should be fine. –  Qiaochu Yuan Sep 22 '10 at 17:19
Another class of non-examples: (non-identity) cosets of subspaces. So, for example, take a line through the origin $L$. Then $v+L$ is a parallel line. This "looks" like a vector space but does not contain the zero vector (i.e. origin) so it's not. –  Bill Cook Dec 24 '11 at 22:01

The real vector space of all fibonacci sequences (the first two values are arbitrary) is quite instructive. Or the subspace of all smooth functions satisfying the differential equation $f'=f$. It is quite illuminating that elementary linear algebra has a interplay with analysis.

-

I like the example $C([0,1])$ of continuous functions on the interval (or something similar). It is familiar-looking but shows that there is not always a natural choice of basis.

-
I feel like until students have taken an analysis course, they do not really have a good enough mental picture of C([0, 1]). If you want to demonstrate a vector space with no natural choice of basis then just try the space of polynomials. –  Qiaochu Yuan Sep 22 '10 at 19:27
Seems like the space $\mathbb{R}[x]$ of polynomials has a pretty natural choice of basis: the monomials. (Of course there are others too.) The space $\mathbb{R}[[x]]$ of formal power series might blow their minds a bit more, though. –  Nate Eldredge Sep 22 '10 at 20:10
@Nate Eldredge: I disagree. The monomials are only a natural basis if you feel like privileging the origin of R, which, considered as a topological space only, you shouldn't. There are plenty of other interesting bases, such as the Newton basis, that you also miss out on by regarding the monomials as natural. –  Qiaochu Yuan Sep 23 '10 at 0:32
While there may be reasons not to view the monomials as a natural basis, I feel like it would be a (probably pointless) challenge to convince students that this basis is any less natural than the standard basis for $\mathbb{R}^n$. –  Dan Ramras Sep 23 '10 at 4:33
@Dan: Yes, exactly. –  Nate Eldredge Sep 23 '10 at 18:49
1. The positive real numbers, where 1 is the "zero vector," "scalar multiplication" is really numerical exponentiation, and "addition" is really numerical multiplication.

2. Simplicial complexes, as in algebraic topology, are another good example, but perhaps this is even too weird. Still, it might be fun to throw out the idea that mathematicians like to add triangles to each other to get quadrilaterals and negate them to reverse orientation, but they'll probably have to take it on faith that this is actually useful.

-
Could you explain 2.? Are you thinking of something like simplicial complexes embedded in $\mathbb{R}^\infty$ in some way? What is scalar multiplication? –  Dan Ramras Sep 23 '10 at 4:31
Or maybe you were referring to simplicial homology with coefficients in a field? –  Dan Ramras Sep 23 '10 at 5:33
@Dan: yes, but probably without the homology. :-) –  Darsh Ranjan Sep 23 '10 at 5:56
Right, the chain groups alone are a simpler example! –  Dan Ramras Sep 23 '10 at 19:06

I like the color example. It shows how the idea of a basis is useful, even though it's not a vector space.

Barycentric coordinates are another example of something like a vector space but not a vector space.

-
Ooh! Nice idea. –  Jon Bannon Sep 22 '10 at 17:07
Thank you! I was sitting here trying to understand how colors could be "closed under addition" (what is addition? mixing?) and I could not figure it out. But it's not a vector space. ... or could we find some way of formulating it so that it was? hmmm... –  futurebird Oct 23 '10 at 23:01

Let $G$ be a finite, simple, undirected graph. A spanning subgraph of $G$ is a subgraph that contains all of the vertices of $G$. The set of spanning subgraphs of $G$ is a vector space over the finite field $\mathbb{F}_2$: given spanning subgraphs $H$ and $H'$, declare a pair of vertices to be adjacent in $H+H'$ if and only if they are adjacent in exactly one of $H$ or $H'$.

An interesting subspace of this vector space is the cycle space $C(G)$, which consists of those spanning subgraphs which are even, in the sense that every vertex has even degree. It is an interesting exercise to show that, as the name indicates, $C(G)$ is spanned by the cycles of $G$.

Indeed, assume that $G$ is connected, and let $T$ be a spanning tree of $G$. Adding any single edge of $G-T$ to $T$ produces a cycle. The cycles constructed in this way are called the fundamental cycles of $T$, and in fact these cycles form a basis for $C(G)$.

One application of this theory is Mac Lane's planarity criterion, which states that a graph is planar if and only if there exists a basis $\beta$ for $C(G)$ such that each edge of $G$ is an edge of at most two elements of $\beta$.

-

The solutions of the differential equation $y''+p y' +q y=0$ on some interval $I\subset{\mathbb R}$ form a vector space $V$ of functions $f:I\to{\mathbb R}$. What is the dimension of this space? Physical intuition or the fundamental existence and uniqueness theorem for differential equations tell you that this dimension is 2: Consider the two initial problems $y(0)=1, y'(0)=0$ and $y(0)=0, y'(0)=1$. The two corresponding solutions $y_1(\cdot)$, $y_2(\cdot)$ form a basis of $V$. Now comes the upshot: You can "guess" explicit solutions of the form $y(t):=e^{\lambda t}$ for suitable $\lambda$'s (apart from special cases), and in this way you obtain a completely different basis of $V$.

Of course this is not "weird", but it is an instance of a finite-dimensional vector space which does not have a "natural" basis to begin with.

-

Vector spaces over $\mathbb{Z}_2$ are quite interesting. Tell them $0=$ false and $1=$ true. Then $0+0=0$, $0+1=1$, $1+0=1$, and $1+1=0$ means "$+$" is "exclusive or". $00=0$, $01=0$, $10=0$, and $11=1$ means "$\times$" is "and".

The $\mathbb{Z}_2$-vector space $(\mathbb{Z}_2)^n$ is the space of codes with $n$-bits.

-

Some examples that come to mind are Fock space, the vector space of all linear combinations of bets on a set of events, the subspace of all coherent combinations of bets (which is the kernel of the linear map from the space of all combinations to their expectation values), and the vector space of all functions specifying air pressure as a function of time, say, on a 5-minute interval, which includes all sorts of speeches and songs as well as all their combinations with people speaking and singing on top of each other with different volumes.

-

The vector space of all order $n$ magic squares ($n\times n$ matrices with real entries and all row and column and diagonal sums equal).

The reals as a vector space over the rationals. ${\bf Q}(\sqrt2)$ as a vector space over the rationals.

-

The space of all lights witch settings in a house is a vector space over the field with 2 elements, and the set of all invertible adjectives in sentences is a vector space over the field with 3 elements.

-
What is an invertible adjective? (Cool answer!) –  Jon Bannon Jun 26 '13 at 19:10
Like cool and uncool. Uncool is -cool; if the sentence doesn't mention coolness, the value is zero. –  Brian Rushton Jun 26 '13 at 20:51

An interesting one I saw in Anton Elementary Linear Algebra (10th ed. ch.4 ex. 8: "An Unusual Vector Space").

The set of positive reals as a vector space over the reals. (I will place a vector over vectors, e.g. $\vec{u}$ and use plain letters for scalars and the values of vectors as reals (so $\vec{u}$ is the vector whose "real number value" is $u$), hopefully this reduces confusion.)

For vectors $\vec{u}$ and $\vec{v}$ and a real number $k$ define:

$\vec{u}+\vec{v} := uv$

$k\cdot\vec{u} := u^k$

We then have:

$\vec{0} = 1$

$-\vec{u} = 1/u$

-
I believe this is the first example Rash Danjan describes here, but yours is a little more explicit. –  Bryan Jun 27 '14 at 2:15
@Bryan that appears to be the case, not sure how I missed that. Should I leave this since it gives more detail or not? –  ballesta25 Jun 27 '14 at 2:22
I'd come up with another interesting example just to avoid being a strict repetition. –  Bryan Jun 27 '14 at 2:27