Professional Documents
Culture Documents
Mohammed Nasser
Professor, Dept. of Statistics, RU,Bangladesh
Email: mnasser.ru@gmail.com
----------C.R.Rao
11
Contents
Oblique and Orthogonal Projection in R2
Orthogonal Projection into a Line Rn
Inner product Space
Projection into a Subspace
Gram-Schmidt Orthogonalization
Projection and Matrices
Projection in Infinite-dimensional Space
Projection in Multivariate Methods
22
Mathematical Concepts
Mathematical Concepts
Covariance
Projection
Variance
0
V 1 {l | l R } andV 2 {m
|m R}
1
1
are two one-dimensional subspaces in R2
R2 =V1 +V2
V1 V2 ={0}
R2 =V1 V2
(1,1)
V1
(0,1)
x1
1
0
a1 a2
1
1
x2
x1
a2
x2 x1
a1
x1 1 0 a1
1 0
x
1
1
1
1
a
2
x1 a1
x a
2 2
x1
1
0
x1 ( x2 x1 )
1
1
x2
1
t
1
x1
1
L
x1
1
x2
as
1
The vector is projected on the space generated by
1
V1
(-1,1)
x1
1
1
x a1 1 a2 1
2
a1
2
1
v
1 1
1
10
1
t
1
as
1
x
x1
1 1
x
1
2
1
1
T
11
Projections
(2,2,2)
b = (2,2)
(0,0,1)
(0,1,0)
(1,0,0)
a = (1,0)
2
1 0 0 2
2 0 1 0 2
0
0 0 0 2
2
aT b
c T a
a a
0
12
v s
s
projs v v s s
s s
Example 1.1:
2x.
projs v v s s
s
s s
x
s
s x2 4 x2
2 x
2
1
1 1
8
projs
2 6
5
5
5 2
3
5x
1
2
1
s
5
1
2
13
13
0
e 2 1
x x
proje2 y
y
z
z
0
1
0
0
1
0
0
y 1
0
y
Example 1.3:
Project = Discard orthogonal components
A railroad car left on an east-west track without its brake is pushed by a wind
blowing toward the northeast at fifteen miles per hour; what speed will the car reach?
15
w
2
1
1
15
v proje1 w
2
15
speed v
2
1
0
14
14
A
(a,b)
(c,d)
C
K(c,d)
15
15
Exercises 1
Consider the function mapping a plane to itself that
takes a vector to its
projection into the line y = x.
(a)Produce a matrix that describes the functions action.
(b)Show also that this map can be obtained by first
rotating everything in the plane /4 radians clockwise,
then projecting into the x-axis, and then rotating /4
radians counterclockwise.
1.
2. Show that
18
Example 2.1
Let u = (x1, x2), v = (y1, y2), and w = (z1, z2) be arbitrary vectors in
R2. Prove that u, v , defined as follows, is an inner product
on R2.
u, v = x1y1 + 4x2y2
Determine the inner product of the vectors (2, 5), (3, 1) under
this inner product.
Solution
Axiom 1: u, v = x1y1 + 4x2y2 = y1x1 + 4y2x2 = v, u
Axiom 2: u + v, w = (x1, x2) + (y1, y2) , (z1, z2)
= (x1 + y1, x2 + y2), (z1, z2)
= (x1 + y1) z1 + 4(x2 + y2)z2
= x1z1 + 4x2z2 + y1 z1 + 4 y2z2
= (x1, x2), (z1, z2) + (y1, y2), (z1, z2)19
20
Example 2.2
Consider the vector space M22 of 2 2 matrices. Let u and v
defined as follows be arbitrary 2 2 matrices.
e
f
b
, v
u
g
h
c
d
Prove that the following function is an inner product on M22.
u, v = ae + bf + cg + dh
2
0
3
5
and
1
9
0.
,
(2 5) (3 2) (0 9) (1 0) 4
v
9 0
21
Example 2.3
Consider the vector space Pn of polynomials of degree n. Let f
and g be elements of Pn. Prove that the following function
defines an inner product of Pn1.
f , g f ( x) g ( x)dx
0
22
x 2 x 1, 4 x 1 ( x 2 2 x 1)(4 x 1)dx
2
(4 x 3 9 x 2 2 x 1)dx
0
23
Norm of a Vector
The norm of a vector in Rn can be expressed in terms of the dot
product as follows
( x1 , x2 , , xn ) ( x12 xn2 )
( x1 , x2 , , xn ) ( x1 , x2 , , xn )
Generalize this definition:
The norms in general vector space do not necessary have geometric
interpretations, but are often important in numerical work.
Definition 2.2
Let V be an inner product space. The norm of a vector v is
denoted ||v|| and it defined by
v v, v
24
Example 2.4
Consider the vector space Pn of polynomials with inner product
1
f , g f ( x) g ( x)dx
0
f, f
2
[
f
(
x
)]
dx
2
2
[
5
x
1
]
dx
0
1
4
2
[
25
x
10
x
1]dx
28
3
28
3
25
Example 2.5
Consider the vector space M22 of 2 2 matrices. Let u and v
defined as follows be arbitrary 2 2 matrices.
e
f
b
, v
u
g
h
c
d
It is known that the function u, v = ae + bf + cg + dh is an
inner product on M22 by Example 2.
The norm of the matrix is u
u, u
a2 b2 c2 d 2
26
uv
cos
(??)
u v
Definition 2.3
Let V be an inner product space. The angle between two
nonzero vectors u and v in V is given by
u, v
cos
u v
27
28
Example 2.6
Consider the inner product space Pn of polynomials with inner
1
product
f , g f ( x) g ( x)dx
f,g
f g
f ( x) g ( x)dx
f g
[5 x ] dx 5 and 3x
2 2
Thus
cos
f ( x) g ( x)dx
f g
2
[
3
x
]
dx 3
(5 x 2 )(3x)dx
5 3
15
4
29
Example 2.7
Consider the vector space M22 of 2 2 matrices. Let u and v
defined as follows be arbitrary 2 2 matrices.
e
f
b
, v
u
g
h
c
d
It is known that the function u, v = ae + bf + cg + dh is an
inner product on M22 by Example 2.
The norm of the matrix is u
u, u
a2 b2 c2 d 2
u v
a2 b2 c2 d 2 e2 f 2 g 2 h2
30
Orthogonal Vectors
Def 2.4. Let V be an inner product space. Two nonzero vectors u
and v in V are said to be orthogonal if
u, v 0
Example 2.8
Show that the functions f(x) = 3x 2 and g(x) = x are orthogonal
1
in Pn with inner product
f , g f ( x) g ( x)dx.
0
Solution
1
Distance
As for norm, the concept of distance will not have direct
geometrical interpretation. It is however, useful in numerical
mathematics to be able to discuss how far apart various
functions are.
Definition 2.5
Let V be an inner product space with vector norm defined by
v v, v
The distance between two vectors (points) u and v is defined
d(u,v) and is defined by
d (u , v ) u v ( u v , u v )
32
Example 2.8
Consider the inner product space Pn of polynomials discussed
earlier. Determine which of the functions g(x) = x2 3x + 5 or h(x)
= x2 + 4 is closed to f(x) = x2.
Solution
1
[d ( f , g )] f g , f g 3 x 5, 3 x 5 (3x 5) 2 dx 13
2
[d ( f , h)] f h, f h 4, 4 (4) 2 dx 16
2
Thus d ( f , g ) 13 and d ( f , h) 4.
The distance between f and h is 4, as we might suspect, g is closer
than h to f.
33
3.Gram-Schmidt Orthogonalization
Given a vector s, any vector v in an inner product space V
can be decomposed as
v projs v v projs v v // v
v // v 0
where
Definition 3.1:
Mutually Orthogonal Vectors
Vectors v1, , vk V are mutually orthogonal if vi vj = 0
ij
Theorem 3.1:
A set of mutually orthogonal non-zero vectors is
linearly independent.
Proof
:
v
c
v
c
v
0
j
i
i
j
j
j
c
v
ii
cj = 0 j
34
34
3.Gram-Schmidt Orthogonalization
Corollary .3.1:
A set of k mutually orthogonal nonzero vectors in V k is a basis for
the space.
Definition 3.2: Orthogonal Basis
An orthogonal basis for a vector space is a basis of mutually
orthogonal vectors.
Definition 3.3: Orthonormal Basis
An orthonormal basis for a vector space is a basis of mutually
orthogonal
vectors
of unit length.
Definition 3.4:
Orthogonal
Complement
The orthogonal complement of a subspace M of R3 is M = { v R3 |
v is perpendicular to all vectors in M }
( read M perp ).
35
Lemma 3.1:
Let M be a subspace of Rn.
Hence, v Rn.,
That is,
projM v M
0 A T v Ac
projM v A c
AT A c AT v
c AT A
AT v
36
36
projM vv
1T
M
k
k T
L
1
T
v
1
M
k
vk T
v1
k M
v
k B
L
1
vj j
v j vj
with
j 1
In particular, if = k , then A = AT = I.
In case is not orthonormal, the task is to find C s.t. B = AC and BTB = I.
I AC
Hence
AC
C A AC
T
projM v BBT v
A T A CT C1 CCT
1
AC AC v
T
CCT A T A
ACCT A T v A A T A A T v
1
37
37
Example 3.1:
To orthogonally project
From
into subspace
x, y R
1 0
2 0
1
0
A A
0 1
0 1
0
1
0
1 0
A AT A
1
0
x 0
y
1
1
0
1
v 1
we get
P y
0
1
x z 0
1 0
A 0 1
1 0
AT A
1 0
1 0
1/
2
0
1
0
0 1 1/ 2 0 1/ 2
A T 0 1
0 1 0 1 0
0 1
0
1 0
1 0
1/ 2 0 1/ 2 1
1
projP v 0
1
0
1/ 2 0 1/ 2 1
1/ 2 0
0 1
1/ 2 0 1/ 2
0
1
0
1/ 2 0 1/ 2
38
38
Exercises 3.
1.
2
2 ,
2
1
0
1
0
3
39
39
41
Orthogonal Projection
(1,2)
(2,1)
1
V1=k 2
and V2=k
2
1
1
vectors 2
2
and 1
42
42
Orthogonal Projection
Now, we can find the vector space R2 as V1 V2
x1
Let be any vector of R2 and k1, k2R then we can
x2
write
2
x1
1
=k1 2 +k2 1
x2
Therefore,
x1
x
2
k1
k2
1 2 k
1
2 1 k 2
1 2
= 2 1
x1
x2
k1
k
2
1
2
x1 x 2
3
3
2x 1x
1
2
3
3
43
43
Orthogonal Projection
Now, let P be a projection matrix and x be a vector in R2,
then a projection from R2 to V1 is given by,
Px=k1
1
2
=[-1/3 x1 +2/3 x2 ]
1
2
1
3
2
2
3
4
3
x1
x
2
2
1
, P will be then
44
44
1
2
P
, rank(P ) 1, P P
2 2
x2
1 1
P 2 2
1 1 x1
2 2 x2
(x1 x2)
2
1
3
2
45
1
x 1
3
x2
1
2
1
An vector of the subspace is mapped to the same
vector of the Subspace.,
2
P
2
2
2
46
Px=(x1+x2) 1/ 2
1/ 2
1
2
1
2
1
2
1
2
Px is orthogonal to x-Px
47
1 2
2 1
x y Px, y x P
48
1
1
2
2
1
1
2
2
From a symmetric
matrix we have
always such a P
of its n
independent
eigen vectors
From a symmetric
matrix we have alway
a symmetric
idempotent P of its
r(<n )independent
eigen vectors
49
i) x x=x, Qx=0
Px=0, Qx=x
ii) x T
51
Applications
The common characteristic (structure) among the
following statistical methods?
1. Principal Components Analysis
2. (Ridge ) regression
3. Fisher discriminant analysis
4. Canonical correlation analysis
5.Singular value decomposition
6. Independent component analysis
We consider linear combinations of input vector:
f ( x) wT x
51
reduced data
Linear transformation
G
T
Y d
d p
X p
p d
: X Y G X
T
52
Dimensionality Reduction
One approach to deal with high dimensional data is by
reducing their dimensionality.
Project high dimensional data onto a lower dimensional
sub-space using linear or non-linear transformations.
53
x x
54
min || x x ||
(reconstruction error)
Singular Value
55
56
bi uiT ( x x )
57
58
N
59
e i
i 1
2
i
i k 1
60
Standardization
61
Face Recognition
average face
63
ui
64
65
66
67
68
69
70
71
72
dffs
Face detection, tracking, and recognition
73
Principal Components
Analysis
So, principal components are given by:
b1 = u11x1 + u12x2 + ... + u1NxN
b2 = u21x1 + u22x2 + ... + u2NxN
...
bN= aN1x1 + aN2x2 + ... + aNNxN
xjs are standardized if correlation matrix is used
(mean 0.0, SD 1.0)
74
75
PCA Scores
5
xi2
bi,1
bi,2
2
4.0
4.5
5.0
xi1
5.5
6.0
76
U1
2
4.0
4.5
5.0
5.5
6.0
78
Thank you
79