Before we state the problem, consider
, the vector space of
all real-valued continuous functions on the interval
. Define
the inner product
as
.
.
.
The Problem: Suppose we want to find
a
degree polynomial approximation for
the function
on the interval
. That is, we want
to find a quintic polynomial such that for every value
,
In calculus we learned how to build a
degree Taylor
polynomial approximation, centered at
, for the function
as
Unfortunately, when we look at the following graphs of this Taylor
polynomial and
we see that the approximation is very poor near the
endpoints of the interval.
.
Can we find a better approximation for
on this interval
without increasing the degree of the polynomial?
To answer this question we now consider
the inner-product space
, with inner product defined as
above, and observe that
is a subspace
of
. Furthermore, every polynomial with degree
is in
, and so we ask which polynomial in
is ``closest'' to
, relative to the inner-product and norms defined for
. Finding this polynomial is equivalent to finding the
orthogonal projection of
onto the subspace
. The
following diagram might help in understanding this idea.
Before we state the necessary theorems to construct orthogonal projections, we
note that given a vector space
equipped with any inner
product, then if
is a vector not in a subspace
, the
closest point to
in
, with respect the inner product defined,
is always the orthogonal projection of
onto
.
So before we find an orthogonal projection onto
, we need to find an
orthogonal basis for
. This can be found using the Gram-Schmidt
process, which is stated in the following theorem.
![]() |
|||
![]() |
|||
![]() |
Then
is an orthogonal basis for
relative to the given inner product.
For our problem, we use the Gram-Schmidt process on the basis
with the inner product
The process goes as follows:
![]() |
![]() |
|||
![]() |
|||
| 0 | |||
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
Computing the inner products we get
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
|||
| 0 | |||
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
Next we compute
.
Now computing inner products we get
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
|||
| 0 | |||
![]() |
|||
![]() |
|||
| 0 | |||
![]() |
|||
So we get
![]() |
|||
![]() |
|||
![]() |
We now have
![]() |
|||
![]() |
Now we compute
.
![]() |
|||
![]() |
Computing inner products we get
![]() |
|||
![]() |
|||
| 0 |
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
|||
| 0 | |||
![]() |
|||
So we get
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
We now have
![]() |
|||
![]() |
|||
![]() |
We now compute
.
![]() |
|||
![]() |
|||
![]() |
Computing inner products we get
![]() |
|||
![]() |
|||
| 0 | |||
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
|||
| 0 | |||
![]() |
|||
![]() |
|||
![]() |
|||
| 0 |
![]() |
|||
![]() |
So we get
![]() |
|||
![]() |
Simplifying we now have the following orthogonal basis for
.
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
It is now time to project
onto the subspace
.
Using Theorem 1 we get
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
We compute the following inner products.
![]() |
|||
![]() |
|||
| 0 | |||
![]() |
|||
![]() |
|||
| 0 | |||
![]() |
|||
![]() |
![]() |
|||
| 0 | |||
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
So now we have
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
|||
![]() |
Using a calculator to simplify this we get
If we now look at the graph of this orthogonal projection compared to
we see that our approximation is very good on the entire
interval.
In fact, relative to this inner product we can do no better. In other
words, this is the best
degree polynomial approximation of
on the interval
. If we want to improve our
approximation we would have to raise the degree of the approximating
polynomial.
Fortunately, many mathematics computer programs, such as Mathematica, have
built in functions that perform the Gram-Schmidt process and the
orthogonal projections. Once we have removed the tedious hand
computations from the process, we have found a superior method to
approximate continuous functions with polynomials.