# Prove that $\{ 1 , 1 + x , (1 + x)^2 \}$ is a Basis for the Vector Space of Polynomials of Degree $2$ or Less

## Problem 665

Let $\mathbf{P}_2$ be the vector space of polynomials of degree $2$ or less.

(a) Prove that the set $\{ 1 , 1 + x , (1 + x)^2 \}$ is a basis for $\mathbf{P}_2$.

(b) Write the polynomial $f(x) = 2 + 3x – x^2$ as a linear combination of the basis $\{ 1 , 1+x , (1+x)^2 \}$.

## Proof.

### (a) Prove that the set $\{ 1 , 1 + x , (1 + x)^2 \}$ is a basis for $\mathbf{P}_2$.

Consider the standard basis $\mathfrak{B} = \{ 1 , x , x^2 \}$ of $\mathbf{P}_2$. Using this basis, we can write the elements using coordinate vectors as
$[1]_{\mathfrak{B}} = \begin{bmatrix} 1 \\ 0 \\ 0 \end{bmatrix} \quad [1+x]_{\mathfrak{B}} = \begin{bmatrix} 1 \\ 1 \\ 0 \end{bmatrix} \quad [(1+x)^2]_{\mathfrak{B}} = \begin{bmatrix} 1 \\ 2 \\ 1 \end{bmatrix}.$ We find the coordinate vector by writing an element as a linear combination of the basis elements. For example, $(1+x)^2 = 1 + 2x + 1 x^2$, and so the coefficients $1, 2, 1$ translate into the column vector $\begin{bmatrix} 1 \\ 2 \\ 1 \end{bmatrix}$.

Because $\dim \mathbf{P}_2 = 3$, this set is a basis if and only if these three vectors are linearly independent. To verify this, consider the matrix
$\begin{bmatrix} 1 & 1 & 1 \\ 0 & 1 & 2 \\ 0 & 0 & 1 \end{bmatrix}.$

This matrix is upper-triangular, and the diagonal entries are all non-zero. This implies the matrix is non-singular, and so the columns are linearly independent.

Thus, the set $\{ 1 , 1+x , (1+x)^2 \}$ is a basis of $\mathbf{P}_2$.

### (b) Write the polynomial $f(x) = 2 + 3x – x^2$ as a linear combination of the basis $\{ 1 , 1+x , (1+x)^2 \}$.

First Method: Using the technique of completing the square, we can factor the polynomial $f(x)$ as we like. Specifically,
\begin{align*}
f(x) &= -x^2 + 3x + 2 \\
&= – (x+1)^2 + 5x + 3 \\
&= – (x+1)^2 + 5(x+1) – 2.
\end{align*}

Hence, we have the linear combination
$f(x)= -2\cdot 1 +5(1+x) -(1+x)^2. \tag{*}$

Second Method: We can find this factorization by calculating the Taylor polynomial of $f(x)$ centered at $-1$.

This Taylor polynomial is defined by
$f(x) = f(-1) + f'(-1) (x+1) + \frac{ f”(-1)}{2} (x+1)^2.$ The polynomial in (*) is recovered by finding $f(-1) = -2$, $f'(-1) = 5$, and $f^{\prime \prime}(-1) = -2$.

##### For Fixed Matrices $R, S$, the Matrices $RAS$ form a Subspace
Let $V$ be the vector space of $k \times k$ matrices. Then for fixed matrices $R, S \in V$, define...