linear algebra, principal component analysis and their chemometrics applications
Post on 22-Dec-2015
220 views
TRANSCRIPT
![Page 1: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/1.jpg)
Linear Algebra, Principal Component Analysis and
their Chemometrics Applications
![Page 2: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/2.jpg)
Linear algebra is the language of chemometrics. One can not expect to truly understand most chemometric techniques without a basic understanding of linear algebra
Linear Algebra
![Page 3: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/3.jpg)
Vector
A vector is a mathematical quantity that is completely described by its magnitude and direction
x1
y1
x
y
P
![Page 4: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/4.jpg)
Vector
A vector is a mathematical quantity that is completely described by its magnitude and direction
x1
y1
x
y
P
P =
x1
y1
![Page 5: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/5.jpg)
![Page 6: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/6.jpg)
MATLAB Notation
![Page 7: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/7.jpg)
![Page 8: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/8.jpg)
Length of a Vector
x1
y1
x
y
PP = x1
2 + y12
x = [x1, x2, …, xn]
x M= ( xi2 ) 0.5
i=1
n
Normal Vector
u =xx
u =1
![Page 9: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/9.jpg)
![Page 10: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/10.jpg)
![Page 11: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/11.jpg)
![Page 12: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/12.jpg)
![Page 13: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/13.jpg)
![Page 14: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/14.jpg)
![Page 15: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/15.jpg)
![Page 16: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/16.jpg)
Normalized vector
![Page 17: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/17.jpg)
Mean Centered Vector
x1
x2
xn
…x = mx = M
xi
i=1
n
nmcx =
x1 - mx
…
x2 - mx
xn - mx
0015100
x = mx = 1
-1-1040-1-1
mcx =
0+20+21+25+21+20+20+2
y =
2237322
=mx = 3
![Page 18: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/18.jpg)
0
0.2
0.4
0.6
0.8
1
1.2
400 450 500 550 600Wavelength (nm)
Ab
so
rba
nc
e
00.20.40.60.8
11.21.4
400 450 500 550 600Wavelength (nm)
Ab
so
rba
nc
e
-0.4
-0.2
0
0.2
0.4
0.6
400 450 500 550 600
Wavelength (nm)
Ab
so
rba
nc
e
Mean centeredMean centered
![Page 19: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/19.jpg)
![Page 20: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/20.jpg)
![Page 21: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/21.jpg)
![Page 22: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/22.jpg)
?
The length of a mean centered vector is proportional to the standard deviation of its elements
y1
y2
yn
…y = y* =
y1 - my
…
y2 - my
yn - myy* ≈ syi
![Page 23: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/23.jpg)
A set of p vectors [x1, x2, …, xp] with same dimension n is linearly independent if the expression:
ci xi = 0Mi=1
p
holds only when all p coefficients ci are zero
Linear Independent Vectors
x1
x2
x3c1x1
c2x2
![Page 24: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/24.jpg)
A vector space spanned by a set of p linearly independent vectors (x1, x2, …, xp) with the same dimension n is the set of all vectors that are linear combinations of the p vectors that span the space
Vector Space
Basis setA set of n vectors of dimension n which are linearly independent is called a basis of an n-dimensional vector space. There can be several bases of the same vector space
A coordinate space can be thought of as being constructed from n basis vectors of unit length which originate from a common point and which are mutually perpendicular
Coordinate Space
![Page 25: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/25.jpg)
Q = P = x1
y1
x1
y1
x
y
P
x1
y1
Q
Vector Multiplication by a Scalar
![Page 26: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/26.jpg)
0
0.05
0.1
0.15
0.2
0.25
0.3
0.35
0.4
0.45
400 450 500 550
Wavelength (nm)
Ab
so
rba
nc
e
x = 1.19 y = 2.38
x
y
y = 2 x
![Page 27: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/27.jpg)
Addition of Vectorsx1
x2
xn
…
y1
y2
yn
…x + y = + =
x1 + y1
…
x2 + y2
xn + yn
x + y
x1
x2
y1
y2y
x
x1 + y1
x2 + y2
![Page 28: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/28.jpg)
x1cx
…ax + ay = + =
x2cx
xncx
y1cy
…
y2cy
yncy
x1cx + y1cy
…
x2cx + y2cy
xncx + yncy
Component 1 Component 2 mixture
0
0.05
0.1
0.15
0.2
0.25
0.3
0.35
0.4
400 420 440 460 480 500 520 540 560
Wavelength (nm)
Ab
so
rba
nc
e
axay
ax + ay
![Page 29: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/29.jpg)
Subtraction of Vectorsx1
x2
xn
…
y1
y2
yn
…x - y = - =
x1 - y1
…
x2 - y2
xn - yn
x - y
x1
x2
y1
y2y
x
![Page 30: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/30.jpg)
Inner Product (Dot Product)x1
x2
xn
…x . x = xTx = [x1 x2 … xn] = x12 + x2
2 + … +xn2
= x2
x . y = xTy = x y cos
The cosine of the angle of two vectors is equal to the dot product between the normalized vectors:
x . y
x ycos =
![Page 31: Linear Algebra, Principal Component Analysis and their Chemometrics Applications](https://reader038.vdocuments.us/reader038/viewer/2022103005/56649d815503460f94a65c33/html5/thumbnails/31.jpg)
y
xx . y = x y
y
xx . y = - x y
y
x x . y = 0
Two vectors x and y are orthogonal when their scalar product is zero
x . y = 0 and x y = 1=
Two vectors x and y are orthonormal