How to find an orthonormal basis for $ P_{2}(\mathbb R)$ equipped with the inner product $\langle f,g\rangle =f(-1)g(-1)+f(0)g(0)+f(1)g(1)$?

1.7k Views Asked by At

Given $ P_{2}(\mathbb R)$ the vector space of real polynomials of degree less than or equal to 2 equipped with the inner product $$\langle f,g\rangle=f(-1)g(-1)+f(0)g(0)+f(1)g(1).$$ How would I use the Gram-Schmidt process to find an orthonormal basis ?

2

There are 2 best solutions below

3
On

Take any basis, for instance the canonical basis $(1, X, X^2)$

First normalise $1$ :

We have $\langle 1,1\rangle = 1+1+1 = 3$ so the normalised vector is $e_1 = {1\over \sqrt{3}}$

Now find the part of $X$ orthogonal to $1\over \sqrt{3}$. That's easy since $\langle 1,X \rangle = 0$

And normalise $X$ : $$\langle X,X\rangle = 1+0+1 = 2$$ so the normalised vector is $$e_2={X\over \sqrt 2}$$

Finally find the part of $X^2$ orthogonal to $span(1,X)$, ie : $$\begin{align}X^2 - \langle X^2 ,{X\over \sqrt2}\rangle{X\over \sqrt 2} - \langle X^2, {1\over \sqrt 3}\rangle {1\over \sqrt 3} &= X^2 - {1\over 2}(-1+0+1){X} + {1\over 3}(1+0+1)\\ &= X^2 - {2\over 3}\end{align}$$

Now normalise this vector : $$\langle X^2 - {2\over 3}, X^2 - {2\over 3}\rangle = \langle X^2, X^2\rangle -4\langle X^2, {1\over 3}\rangle + 4\langle {1\over 3}, {1\over 3}\rangle = 2-{8\over 3} + {4\over 3} = {2\over 3}$$

Thus $e_3 = \sqrt {3\over 2}\left(X^2-{2\over 3}\right)$

In conclusion Gram-Schmidt process applied to the canonical basis gives you the orthonormal basis : $$\left({1\over \sqrt 3}, {X\over \sqrt 2}, \sqrt {3\over 2}\left(X^2-{2\over 3}\right)\right)$$

Note : I highly recommend spending some time on it to make sure you understand the idea behind it and are confortable enough about it to do it yourself. One good exercise you can now do is apply the process on the same basis but treating the vectors in a different order (say $X^2$, then $X$ and finally $1$). This will give you a different basis than the one we obtained here.

8
On

Hint I can help you with first part of the problem

( First we may want to convince ourselves that we are actually dealing with an inner product here, but let's assume the question creator is not devious enough to lie about it being one. )

Let us first define projection with the scalar product between two polynomials, $f$, $g$, having coefficients $f_2,f_1,f_0$ and $g_2,g_1,g_0$ respectively:

$$f(x) = f_2 x^2 + f_1 x + f_0 \\g(x) = g_2 x^2 + g_1 x + g_0 $$

$$\langle f,g \rangle = f(-1)g(-1) + f(0)g(0)+f(1)g(1)$$

$$\begin{align*}f(-1)g(-1) &= /\text{convince yourself}/ = (f_2-f_1+f_0)(g_2-g_1+g_0)\\ f(0)g(0) &= /\text{convince yourself}/ = (f_0)(g_0)\\ f(1)g(1) &= /\text{convince yourself}/ = (f_2+f_1+f_0)(g_2+g_1+g_0)\end{align*}$$

Now you can gather all terms up and simplify and you have the first piece of the puzzle done.