Problem: Determine if the set
\[
B = \left\{ 1, x^2 - x + 5, 4x^3 - x^2 + 5x, 3x + 2 \right\}
\]
is a basis for the vector space of polynomials in $x$ of degree at most $4$. Is this set a basis for the vector space of polynomials in $x$ of degree $\leq 3$?
The polynomial $x^4$ is not in the spanning set of $B$.
The polynomials $1, x, x^2, x^3$ belong to the spanning set of $B$.
Solution: Let $\mathcal{P}_n$ denotes the vector space of polynomial in $x$ of degree at most $n$. Given that the set
\[
B = \left\{ 1, x^2 - x + 5, 4x^3 - x^2 + 5x, 3x + 2 \right\} ,
\]
we want to determine if $B$ is a basis for $\mathcal{P} _4$. Since the number of elements in $B$ is $4$ and the dimension of $\mathcal{P} _4$ is $5$. Therefore, $B$ can not be a spanning set for $\mathcal{P} _4$. More precisely, $x^4$ does not belong to the spanning set of $B$ and hence it is not a basis for $\mathcal{P} _4$.
Now we need to check if $B$ is a basis for $\mathcal{P} _3$. Since the dimension of $\mathcal{P} _3$ is $4$, which is the number of elements in $B$, so it is enough to check if $B$ is linear independent or $B$ spans $\mathcal{P} _3$. Note that,
\begin{align*}
x & = \frac{1}{3}\cdot (3x+2) - \frac{2}{3}\cdot 1 \implies x \in \operatorname{span}(B) \\[1ex]
x^2 & = (x^2 - x + 5 ) + 1\cdot x - 5 \cdot 1 \implies x^2 \in \operatorname{span}(B) \\[1ex]
x^3 & = \frac{1}{4} \cdot (4x^3 - x^2 + 5x) + + \frac{1}{4}\cdot x^2 - \frac{5}{4}\cdot x \implies x^3 \in \operatorname{span}(B).
\end{align*}
Thus, $1, x, x^2, x^3 \in \operatorname{span}(B)$. Since $\{ 1, x, x^2, x^3 \} $ spans $\mathcal{P} _3$, the set $B$ also spans $\mathcal{P} _3$ and hence $B$ is a basis for $\mathcal{P} _3$.