Find a basis of $F = \langle 2x^3+2x^2-2x,x^3+2x^2-x-1,x^3+x+5,x^3+3,2x^3+2x^2-x+2\rangle$ (and define it) $F = \langle 2x^3+2x^2-2x,x^3+2x^2-x-1,x^3+x+5,x^3+3,2x^3+2x^2-x+2\rangle$
First I tried to write this as a linear combination (I added an arbitrary vector at the end so I could define the subspace later without having to do everything all over again):






$$F = \{ (ax^3+bx^2+cx+d+e) \in \mathbb{R}^3[x]: d=\frac{a-b+c}{2},e=d\} \\
ax^3+bx^2+cx+d+e = ax^3+bx^2+cx + (a-b+c) = a(x^3+1)+b(x^2-1)+c(x+1)$$
A basis of F would then be $(x^3+1,x^2-1,x+1)$.
I this correct? My book says a solution is $(x^3+x^2-x,x^2-1,x+2)$. Is mine correct and if not, how do I get this one?
 A: You can check your work by adjoining the basis vectors that you found to the matrix that you constructed and row-reducing again. The resulting matrix should still have rank $3$, i.e., have three pivots. That turns out not to be the case, so at least one of the vectors in the basis that you computed isn’t even an element of $F$. Following your method the equations that I end up with are $d=\frac12(a-b+c)$ and $e=\frac12(a+b+c)$, so you’ve likely made a sign error somewhere along the way. Your handwriting is very hard for me to decipher, though, so I’ll leave finding it to you.  
That aside, this seems a rather roundabout way to compute a basis for the span of a set of vectors. There’s really no need to fiddle with additional equations. Elementary row operations preserve linear dependency relations among the columns of a matrix, so examine the matrix that you got after the row-reduction that you performed: the first three columns are obviously linearly independent, while the last two are linear combinations of those three. Therefore, the first three vectors that you started with are also linearly independent and you can take them as a basis of $F$. Or, looking at it a bit differently, you can delete the last two vectors since they’re linearly dependent on the others without changing their span. What remains is then a basis for $F$.  
That doesn’t appear to be what was done to obtain the book solution, though. Elementary row operations preserve the row space of a matrix, so if you assemble the coordinate vectors into a matrix as rows instead of columns, after reducing the resulting matrix to echelon form the nonzero rows are linearly independent and by definition span the row space, therefore they are a basis for it. Applying this to your problem, we start with the transpose of your matrix, $$\begin{bmatrix}2&2&-2&0\\1&2&-1&-1\\1&0&1&5\\1&0&0&3\\2&2&-1&2\end{bmatrix}$$ and compute the echelon form $$\begin{bmatrix}1&1&-1&0\\0&1&0&-1\\0&0&1&2\\0&0&0&0\\0&0&0&0\end{bmatrix}.$$ From this we see that a basis for $F$ consists of $x^3+x^2-x$, $x^2-1$ and $x+2$, which is exactly the given solution. I might’ve continued the process even further and found the RREF of the matrix, which produces the basis $x^3+3$, $x^2-1$, $x+2$.
