# Continuous real valued functions and inner product space?

Let $V$ be the space of all continuous real valued functions on the interval $[1,4]$ with the inner product defined by:

$$\langle f,g\rangle = \int_1^{4} f(t)g(t)\,dt.$$

(i) Find an orthonormal basis of the space $W$ of polynomials of degree less than or equal to $4$.

Here is my attempt:

You should use the [Gram–Schmidt process]: Take any three linearly independent polynomials, for example $1,x,x^2$. Now apply the process to this set. $$\|1\|^2=\langle1,4\rangle=\int_1^4 dt=4-1\quad\Rightarrow\quad p_0(x)=\frac{1}{\|4\|}$$ $$proj_{p_0}(v_1)=\langle v_1,p_0 \rangle p_0=p_0\cdot\langle x,p_0 \rangle=\frac{1}{\|4\|}\int_1^4dt$$ and then $u_1=v_1-proj_{p_0}(v_1)$ and $p_1=\frac{u_1}{\|u_1\|}$ and so on.

(ii) Find the polynomial of degree less than or equal to 4 that is closest to $\log t$.

Can you please help me with this? I saw this in a numerical analysis book and was trying to solve this problem the other day. This is what I tried to do but I know this is probably wrong. I have come to the point of exhaustion trying to teach myself this. I tried following other examples but they are not the same. Sorry for not being able to do much.

First of all, you should know how the Gram-Schmidt proccess works (see Wikipedia, for example).

Let $\left\{p_1,\ldots,p_5\right\}$ be a basis for the set $W$ of polynomials (in $[1,4]$) of degree $\leq 4$. For example, you can take $p_i(x)=x^{i-1}$. Apply the Gram-Schmidt process as explained in Wikipedia. You'll obtain 5 polynomials, say $q_1,\ldots,q_5$ s.t. $<q_i,q_j>=\delta_{ij}=\begin{cases}1&\text{, if }i=j\\ 0&\text{ otherwise}\end{cases}$. Remember that, when applying the Gram-Schmidt process, you'll have to calculate some polynomial integrals, which can take quite some time...

The set $\left\{q_1,\ldots,q_5\right\}$ is an orthonormal basis for $W$.

Now, to find polynomial in $W$ that is closest to $\log$, you should already know that this is given by $$p=\sum_{i=1}^5<q_i,\log>q_i$$ that is, the polynomial $p$ is given by $$p(t)=\sum_{i=1}^5\left(\int_1^4q_i(s)\log(s)ds\right)q_i(t)$$ for every $x\in[1,4]$.

• Thanks for helping. I see how this works now. – user99744 Nov 3 '13 at 22:30

Your description of the Gram-Schmidt method is somewhat wrong. For instance, if $\|1\|^2=3$, then the corresponding unit polynomial must be $1/\|1\|=1/\sqrt{3}$.

Also, the vector space of polynomials of degree at most 4 is a five-dimensional vector space. You won't find a basis for it consisting of only three polynomials.

What are $v_1$? I don't think you are carrying it out correctly. See here, for example.

For part (ii), it's not just any random "closest" polynomial to $\log x$ that you need to find, you should note that it is closest in the sense of the inner product defined in your question. You are looking for a polynomial belonging to the vector space $W\subset V$ that is closest in the given norm to the given element $\log x$ of the space $V$.

So if $q(x) = \sum_{k=0}^{k=4} c_k u_k(x)$ is that polynomial, then you should know already that $$\langle \log x-q(x), p(x)\rangle=0$$ for every polynomial $p\in W$. In particular $$\langle \log x - q(x), u_k\rangle=0,$$ which gives you the five equations you need to solve for $c_k$. All this follows from the properties of orthonormal bases and inner product vector spaces, and is standard fare in textbooks on real analysis.

• +1 Thanks. I had an idea like this but was not sure so I did it this way. Thank you for explaining it to me. – user99744 Nov 3 '13 at 22:31