Download Matrix Algebra

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Document related concepts
no text concepts found
Transcript
Matrix Algebra
Matrix Algebra
• Definitions
• Addition and Subtraction
• Multiplication
• Determinant
• Inverse
• System of Linear Equations
• Quadratic Forms
• Partitioning
• Differentiation and Integration
2.1 Definitions
• Scalar (0D matrix)
• Vector ( 1D matrix )
Transpose
• Matrix ( 2D matrix )
Transpose
2.1 Definitions, contd
• Matrix size, [m x n] or [i x j], ( [row x col] )
– Vector, [m x 1]
[m x n] = [4 x 2]
• Square matrix, (m=n) [m x m]
• Symmetric matrix, B=BT
2.1 Definitions, contd
• Diagonal matrix
• Identity matrix, (unit matrix),
• Zero matrix
AI=A
2.2 Addition and Subtraction
• Vector
• Matrix
2.3 Multiplication - scalar
• Scalar – vector multiplication
• Scalar – matrix multiplication
2.3 Multiplication - vector
• Scalar product, (vector – vector multiplication)
[1 x n] [n x 1] = [1 x 1]
• Length of vector (cf. Pythagoras' theorem)
2.3 Multiplication - vector
• Matrix product
 a1 
ab T = a2 [b1 b2
 a3 
 a1b1
b3 ] = a2b1
 a3b1
[m x 1] [1 x n] =
a1b2
a2b2
a3b2
[m x n]
a1b3 
a2b3 
a3b3 
2.3 Multiplication - matrix
• Matrix – vector multiplication
[m x n]
[3 x 2]
[n x 1] =
[2 x 1] =
[m x 1]
[3 x 1]
• Vector – matrix multiplication
[1 x m] [m x n] = [1 x n]
2.3 Multiplication - matrix
• Matrix – matrix multiplication
[m x n] [n x p] = [m x p]
Note!
2.3 Multiplication – matrix, contd
• Product of transposed matrices
• Distribution law
2.4 Determinant
• The determinant may be calculated for any square
matrix, [n x n]
• Cofactor of matrix, A (i=row, k=column)
• Expansion formula
2.4 Determinant, examples
Cofactors
1 2
A=

3
4


c
= (−1) (1+1) 4 = 4
A11
c
A12
= (−1) (1+ 2 ) 2 = −2
Determinant
det A = 1 ⋅ 4 + 2(−4) = −2
1 2 3 
B = 4 5 6
7 8 5
Cofactors
c
= (−1) (1+1) (5 ⋅ 5 − 6 ⋅ 8) = −23
B11
B c21 = (−1) ( 2+1) (2 ⋅ 5 − 3 ⋅ 8) = −14
c
= (−1) (3+1) (2 ⋅ 6 − 3 ⋅ 5) = −3
B 31
Determinant
det B = 1(−23) + 4 ⋅14 + 7(−3) = 12
2.5 Inverse Matrix
• The inverse A-1 of a square matrix A is defined by
• The inverse may be determined by the cofactors, where
is the adjoint of A and
2.4 Inverse, examples
1 2
A=

3
4


 4 − 2
adjA = 

−
3
1


 4 − 2 1
A = adjA / det A = 
 (−2)
−
3
1


−1
1 2 3 
B = 4 5 6
7 8 5
What happens if
det A = 0 ?
− 23 22 − 3
adjB =  − 14 − 16 6 
 − 3
6 − 3
 − 23 14 − 3
1


−1
B = adjB / det B = − 22 − 16 6 
12
 − 3
6 − 3
T
2.6 Systems of Linear Equations
-number of equations is equal to number of unknowns
• Linear equation system
A is a square matrix [n x n],
x and b [n x 1] vector
b = 0 => Homogeneous system
b ≠ 0 => Inhomogeneous system
• Assume that det( A ) ≠ 0
2.6 Linear Equations
-number of equations is equal to number of unknowns
• Homogeneous system b = 0, (trivial solution: x = 0)
Eigenvalue problems
• Inhomogeneous system b ≠ 0
2.8 Quadratic forms and positive
definiteness
• If
• then the matrix A is positive definite
• If A is positive definite, all diagonal elements must
be positive
2.9 Partitioning
The matrix A may be partitioned as
and if
A may be written
2.9 Partitioning, contd
An equation system can be written
with
introduce
The partitioned equation system is written
or
2.10 Differentiation and integration
• A matrix A
• Differentiation
• Integration
Related documents