I have a function space $\mathcal {F}([-1,1],\mathbb R)$ and the subspace $\mathcal{P_2}:=$ $(x\mapsto a_o+a_1x+a_2x^2| a_0,a_1,a_2 \in \mathbb R )$ for all polynomials with degree $\le2$. In this subspace the dot product and norm are defined as follows:
$<p,q>=\int_{-1}^{1}p(x)q(x)dx$
$||p||=\sqrt{<p,p>}$
I have four polynomials $p_1,...,p_4$
$p_1(x)=4x+3$
$p_2(x)=x^2+2x-1$
$p_3(x)=x^2-1$
$p_4(x)=11x^2+2$
I have to show that $p_1,p_2,p_3$ are linearly independant and I have to create an Orthonormal basis $q_1,q_2,q_3$
1) The first step is "trivial". They are linearly independant.
2) I want to use Gram-Schmidt to create an orthonormal basis.
$q_1=\frac{p_1}{||p_1||};$
$q_2'=p_2-<q_1,p_2> \cdot q_1 \Rightarrow q_2=\frac{q_2'}{||q_2'||}$
$q_3'=p_3-<q_1,p_3>\cdot q_1-<q_2,p_3>\cdot q_2 \Rightarrow q_3=\frac{q_3'}{||q_3'||}$
$\vec{p_1}=\begin{pmatrix}0\\4\\3\end{pmatrix}; ||\vec{p_1}||=\sqrt{0^2+4^2+3^2}=5 \Rightarrow \color{red}{\vec{q_1}=\frac{1}{5}\begin{pmatrix}0\\4\\3\end{pmatrix}}$
$\vec{q_2'}=\begin{pmatrix}1\\2\\-1\end{pmatrix}-(\int_{-1}^{1}(\frac{4}{5}x+\frac{3}{5})(x^2+2x-1)dx)\begin{pmatrix}0\\\frac{4}{5}\\\frac{3}{5}\end{pmatrix}=\begin{pmatrix}1\\2\\-1\end{pmatrix}-(\frac{4}{15})\begin{pmatrix}0\\\frac{4}{5}\\\frac{3}{5}\end{pmatrix}=\begin{pmatrix}1\\\frac{134}{75}\\\frac{-29}{25}\end{pmatrix}$
As you can see, the numbers are getting extremely ugly. The next step is even worse. Am I doing something wrong?
I would be grateful for any help you can give me.
Thanks