Lecture 12
Lecture 12
= 1 − b1T b1
∂L
∂λ
= 2b1T S − 2λb1T
∂L
∂ b1
▶ Setting these partial derivatives to zero we get the following
two equations Sb1 = λb1 and b1T b = 1.
▶ Thus we find that the direction b1 we seek is an eigenvector of
the covariance matrix S and λ is its corresponding eigenvalue.
First principal component
Ŝbi =
N
1
(X − Bm−1 X )(X − Bm−1 X )T bi
= (S − SBm−1
T
− Bm−1 XX T + Bm−1 XX T Bm−1
T
)bi
= (S − SBm−1
T
− Bm−1 S + Bm−1 SBm−1
T
)bi
= (S − SBm−1 − Bm−1 S + Bm−1 SBm−1 )bi
▶ Note that in the last line we have used the fact that Bm−1 is
a projection matrix and is therefore symmetric.
Eigenvectors of S and Ŝ
▶ Note that only x˜n is a function of the zin s and the given xn is
a fixed vector independent of the coordinates zin .
▶ We shall now find expressions for each of the partial
derivatives on the right hand side.
Finding optimal coordinates
(x − x̃n )T
∂JM 2
= −
∂ x˜n N
∂ x˜n
M
zmn bm ) = bi
∂ X
= (
∂zin ∂zin
m=1
= − (xn − x̃n )T bi
∂JM 2
∂zin N
M
= − (xn − zmn bm )T bi )
∂JM 2 X
∂zin N
m=1
= − (xnT bi − zin )
∂JM 2
∂zin N
Finding optimal coordinates
N D
(bjT xn )2
1 X X
JM =
N
n=1 j=M+1
N D
=
1 X X
N
bjT xn bjT xn
n=1 j=M+1
N D
=
1 X X
N
bjT xn xnT bj
n=1 j=M+1
D N
bjT ( N1 xn xnT )bj
X X
=
j=M+1 n=1
D
bjT S bj
X
=
j=M+1
Finding a basis of the principal subspace
j=M+1 bj S bj = tr ( j=M+1 bj S bj ) =
▶ We note that JM = D
P T
PD T
j=M+1 S bj bj ) = tr ( j=M+1 bj bj S)
PD T
P D T