Fit a cubic trend function to the data (-2,7), (-1,9), (0,9), (1,8), (2,7). Let $p_0(t) = 1$, $p_1(t) = t$ and $p_2(t) = t^2 - 2$. The orthogonal cubic polynomial is $p_3(t) = \frac{5}{6}t^3 - \frac{17}{6}t$. The vectors for $p_0$, $p_1$, and $p_2$ are $\begin{bmatrix} 1\\1\\1\\1\\1 \end{bmatrix}$, $\begin{bmatrix} -2\\-1\\0\\1\\2 \end{bmatrix}$ and $\begin{bmatrix} 2\\-1\\-2\\-1\\2 \end{bmatrix}$, respectively.
$\hat{p}(t) = $