Math201 - WK13 - Sec 6.7, 6.8

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 18

 Define length, distance, orthogonality for other vector spaces

 Find the least-squares function approximation

 Obtain Fourier series approximation for a function


6.7 Inner Product Spaces
Inner Product
An inner product on a vector space V is a
function that associates a real number to each
pair of vectors u,v in V satisfying the following
axioms for all u,v in V and scalars c,
1. v,u= u,v
2. u+v,w = u,w+ v,w
3. cu,v = c u,v
4. u,u 0 and u,u=0 if and only if u=0
6.7 Inner Product Spaces
Length
The length (norm) of v in an inner product space
V is:
v = v,v
Distance
The distance between u and v in an inner
product space V is
d (u,v ) = u − v
Orthogonality
u and v in an inner product space V are
orthogonal if
u,v = 0
6.7 Inner Product Spaces
Ex. Show that the standard basis {1, 𝑡, 𝑡2} for
𝑃2 with the inner product 𝑝, 𝑞 = 𝑎0 𝑏0 + 𝑎1 𝑏1 +
𝑎2 𝑏2 , where 𝑝(𝑡) = 𝑎0 + 𝑎1𝑡 + 𝑎2𝑡2 , 𝑞(𝑡) = 𝑏0 +
𝑏1𝑡 + 𝑏2𝑡2, is an orthonormal basis

1, 𝑡 = 1, 𝑡 2 = 𝑡, 𝑡 2 = 0
1 = 𝑡 = 𝑡2 = 1
∴ {1, 𝑡, 𝑡2} is an orthonormal basis for 𝑃2
6.7 Inner Product Spaces
• Gram-Schmidt process

Ex. Let 𝑉 be 𝑃4 with the inner product defined as:

𝑝, 𝑞 = 𝑝 −2 𝑞 −2 + 𝑝 −1 𝑞 −1 + 𝑝 0 𝑞 0 + 𝑝 1 𝑞 1 + 𝑝 2 𝑞 2

Produce an orthogonal basis for the subspace 𝑃2 by applying the

Gram–Schmidt process to the polynomials 1, t , and 𝑡 2 .


1, 𝑡 = 0 𝑡, 𝑡 2 = 0 1, 𝑡 2 = 10 1 𝑡 𝑡2
The complement of orthogonal projection of 𝑡 2
𝑡 2 ,1 𝑡 2 ,𝑡
onto 𝑆𝑝𝑎𝑛 1, 𝑡 = 𝑡 2 − 1,1
1 − 𝑡,𝑡
𝑡 = 𝑡2 − 2 1 −2 4
The orthogonal basis for 𝑃2 are: 1 , t , 𝑡 2 − 2 1 −1 1
1 0 0
1 1 1
1 2 4
6.7 Inner Product Spaces
Ex. Using the inner product defined in the previous example, find
1
the best approximation to 𝑝 𝑡 = 5 − 𝑡 4 by polynomials in 𝑃2
2

𝑝, 1 𝑝, 𝑡 𝑝, 𝑡 2 − 2 2
𝑝Ƹ = 1 + 𝑡 + 2 2
𝑡 −2
1,1 𝑡, 𝑡 𝑡 − 2, 𝑡 − 2

8 31 2
= − 𝑡 −2 1 𝑡 𝑡2 − 2 𝑝
5 14
216 31 2 1 −2 2 −3
= − 𝑡
35 14 1 −1 −1 9/2
1 0 −2 5
1 1 −1 9/2
1 2 2 −3
6.7 Inner Product Spaces
1 4
𝑝 𝑡 =5 − 𝑡
2

8 31
𝑝Ƹ = − 𝑡2 − 2
5 14
6.7 Inner Product Spaces
Inner Product for 𝐶[𝑎, 𝑏]
Let 𝑓 , 𝑔 be two real valued continuous
functions in the vector space 𝐶 [𝑎, 𝑏], show that
𝑏

𝑓, 𝑔 = න 𝑓 𝑥 𝑔 𝑥 𝑑𝑥
𝑎
defines an inner product over 𝐶 [𝑎, 𝑏]
6.7 Inner Product Spaces
𝑏 𝑏

1. 𝑓, 𝑔 = න 𝑓 𝑥 𝑔 𝑥 𝑑𝑥 = න 𝑔 𝑥 𝑓 𝑥 𝑑𝑥 = 𝑔, 𝑓
𝑎 𝑎


𝑏 𝑏
2 2
4. 𝑓, 𝑓 = න 𝑓 𝑥 𝑑𝑥 ≥ 0 𝑎𝑛𝑑 න 𝑓 𝑥 𝑑𝑥 = 0
𝑎 𝑎
if and only if 𝑓 = 0
6.8 Applications of inner product spaces.
Fourier Series
Ex. Let 𝑓 = sin(𝑚𝑥) , 𝑔 = sin(𝑛𝑥) where 𝑚, 𝑛 are +ve integer
and 𝑚 𝑛 and using the inner product:
2𝜋

𝑓, 𝑔 = න 𝑓 𝑥 𝑔 𝑥 𝑑𝑥
0
defined over 𝐶 0,2𝜋 , show that 𝑓 and 𝑔 are orthogonal

French Scientist
Jean-Baptiste
Joseph Fourier
1768 - 1830
6.8 Applications of inner product spaces.
2
f, g =  sin (mx ) sin (nx ) dx
0
2
= 12  cos (m − n ) x  − cos (m + n ) x  dx
0
2
 sin (m − n) x  sin (m + n ) x  
= 12  −  =0
 m −n m+n  0
2 2
f, f =  sin (mx ) dx = 12  1 − cos ( 2mx ) dx = 
2

0 0
6.8 Applications of inner product spaces.
Ex. Let 𝑓 = 𝑐𝑜𝑠(𝑚𝑥) , 𝑔 = 𝑐𝑜𝑠(𝑛𝑥) where 𝑚, 𝑛 are +ve integer
and 𝑚 𝑛 and using the inner product:
2𝜋

𝑓, 𝑔 = න 𝑓 𝑥 𝑔 𝑥 𝑑𝑥
0
defined over 𝐶 0,2𝜋 , show that 𝑓 and 𝑔 are orthogonal
6.8 Applications of inner product spaces.
2
f, g =  cos (mx ) cos (nx ) dx
0
2
= 12  cos (m − n ) x  + cos (m + n ) x  dx
0
2
 sin (m − n) x  sin (m + n ) x  
= 
1
+  =0
2
 m −n m+n  0
6.8 Applications of inner product spaces.
2
f, f =  cos (mx ) dx
2

0
2
= 12  1 + cos ( 2mx ) dx = 
0

2
1,1 =  dx = 2
0
6.8 Applications of inner product spaces.
Fourier Approximation on 0,2𝜋
On the interval 0,2𝜋 , the least squares
approximation theorem of a continuous function 𝑓
with respect to the vector space spanned by:
{1, cos(𝑥), cos(2𝑥), … , sin(𝑥), sin(2𝑥), … } is given by:
a0
f(x) = + a1 cos(x) + a2 cos(2x) + + b1 sin(x) + b2 sin(2x) +
2
2 2
1 1
a0 =  f(x)dx an =  f(x)cos(nx)dx
0 0
2
1
bn =  f(x)sin(nx)dx
0
6.8 Applications of inner product spaces.
Ex. Find Fourier series approximation for the
function f(x)=x on the interval [0,2𝜋]
2
1
a0 =  xdx = 2
0
2
1
an =  xcos(nx)dx = 0
0
2 2
1 11 1  −2
bn =  xsin(nx)dx =  2 sin(nx) − cos(nx)  =
0  n n 0 n

−2
f(x) = x   +  sin(nx) ,x  ( 0,2 )
n=1 n
6.8 Applications of inner product spaces.

General Fourier Approximation


On the interval [0, 2L ], the least squares
approximation theorem of a continuous function
𝑓 with respect to the vector space spanned by:
𝑥 2𝑥 𝑥 2𝑥
1, cos , cos , … , sin , sin ,…
𝐿 𝐿 𝐿 𝐿
is given by: a0    nx   nx  
f(x) = +  an cos   + bn sin  
1
2L 2 n=1   L   L 
a0 =  f(x)dx 2L 2L
L0 1 1
an =  f(x)cos(nx / L)dx bn =  f(x)sin(nx / L)dx
L0 L0
6.8 Applications of inner product spaces.
Periodic Extension of Fourier Approximation
On the interval [0,2L],
a0    nx   nx  
f(x) = +  an cos   + bn sin  
2 n=1   L   L 
If f(x+2L)=f(x) over R and since:
 n ( x + 2L )   nx   n ( x + 2L )   nx 
cos   = cos   sin   = sin  
 L   L   L   L 
Then, the above expansion approximates the
periodic function over R

You might also like