# Number of bases of an n-dimensional vector space over q-element field.

If I have an n-dimensional vector space over a field with q elements, how can I find the number of bases of this vector space?

There are $q^n-1$ ways of choosing the first element, since we can't choose zero. The subspace generated by this element has $q$ elements, so there are $q^n-q$ ways of choosing the second element. Repeating this process, we have $$(q^n-1)(q^n-q)\cdots(q^n-q^{n-1})$$ for the number of ordered bases. If you want unordered bases, divide this by $n!$.
• @Faz3r: Your observation is correct, but then to compute the number of non-singular matrices, the easiest thing to do is to compute the number of possible first columns, $q^n - 1$, and then given a choice for the first column to compute the number of possible second columns, $q^n - q$, and so on. Since the matrix is invertible, the first $k$ columns must have rank $k$ which is equivalent to saying that the $k$th column must not be in the span of the first $k-1$ columns. Apr 15, 2013 at 12:48