Sie sind auf Seite 1von 9

Solving SLE using Cramer’s Rule

Let 𝐴𝑥 = 𝐵 be a system of n linear equations in n unkowns with |𝐴| ≠ 0. For 1 ≤ 𝑖 ≤ 𝑛. Let 𝐴𝑖 be


the 𝑛 × 𝑛 matrix obtained from 𝐴 by replacing the 𝑖 𝑡ℎ -column of 𝐴 by the column vector 𝐵.
𝑎11 𝑎12 … 𝑏1 … 𝑎1𝑛
𝑎 𝑎22 … 𝑏2 … 𝑎2𝑛
i.e. 𝐴𝑖 = [ 21 … ]
⋮ ⋮ ⋮ ⋮
𝑎𝑛1 𝑎𝑛2 … 𝑏𝑛 … 𝑎𝑛𝑛
Let 𝐷 = det(𝐴) and let 𝑁𝑖 = det(𝐴𝑖 ) for 𝑖 = 1,2, … , 𝑛
The fundamental relationship between determinant and the solution of the system 𝐴𝑥 = 𝐵
is the following
The system 𝐴𝑥 = 𝐵 has a unique solution iff 𝐷 ≠ 0. In this case the unique solution is given by:
𝑁1 𝑁2 𝑁𝑛
𝑥1 = , 𝑥2 = , … … , 𝑥𝑛 =
𝐷 𝐷 𝐷
Example: Solve the following SLE
2𝑥1 + 𝑥2 − 𝑥3 = 3
𝑥1 + 𝑥2 + 𝑥3 = 1
𝑥1 − 2𝑥2 − 3𝑥3 = 4
This system is equivalent to 𝐴𝑥 = 𝐵, where
2 1 −1 3
𝐴 = (1 1 1), 𝐵 = (1)
1 −2 −3 4
2 1 −1
det 𝐴 = |1 1 1 | = 2(−3 + 2) − 1(−3 − 1) − 1(−2 − 1) = 5 ≠ 0
1 −2 −3
Since 𝐷 ≠ 0, the system has a unique solution
3 1 −1
𝑁1 = |1 1 1 | = 3(−3 + 2) − 1(−3 − 4) − 1(−2 − 4) = 10
4 −2 −3
2 3 −1
𝑁2 = |1 1 1 | = 2(−3 − 4) − 3(−3 − 1) − 1(4 − 1) = −5
1 4 −3
2 1 3
𝑁3 = |1 1 1| = 2(4 + 2) − 1(4 − 1) + 3(−2 − 1) = 0
1 −2 4
Thus, the unique solution is:
𝑁1 𝑁2 𝑁3
𝑥1 = = 2, 𝑥2 = = −1, 𝑥3 = =0
𝐷 𝐷 𝐷
1
Note: If |𝐴| = 0, then Cramer’s rule does not tell whether or not the system has a solution. Thus,
we have to solve by using some other techniques.
Exercise: Solve the following SLE
a) 3𝑥1 + 2𝑥2 + 4𝑥3 = 1
2𝑥1 − 2𝑥2 + 𝑥3 = 0
𝑥1 + 2𝑥2 + 3𝑥3 = 1
b) 𝑥1 + 𝑥2 + 2𝑥3 = 9
2𝑥1 + 4𝑥2 − 3𝑥3 = 1
3𝑥1 + 6𝑥2 − 5𝑥3 = 0

2
Gauss-Jordan Method
The method is based on the idea of reducing the given system of equations 𝐴𝑥 = 𝐵, to a diagonal
system of equations 𝐼𝑥 = 𝑑, where 𝐼 is the identity matrix, using elementary row operations. We
know that the solution of both the system are identical. This reduced system gives the solution
vector 𝑋.
𝐺𝑎𝑢𝑠𝑠−𝐽𝑜𝑟𝑑𝑎𝑛 𝑀𝑒𝑡ℎ𝑜𝑑
(𝐴|𝑏) → (𝐼|𝑋)
Example: Solve
𝑥 + 𝑦 − 2𝑧 = −2
𝑦+𝑧 =7
𝑥 − 𝑧 = −1
Sol: The augmented matrix is given by
1 1 −2 −2
(0 1 3|7)
1 0 −1 −1
We apply elementary transformations:
1 1 −2 −2 𝑅3=−𝑅1+𝑅3 1 1 −2 −2 𝑅3=𝑅2 +𝑅3 1 1 −2 −2 𝑅3 =1⁄ 𝑅3
4
(0 1 3 | 7 )→ (0 1 3 | 7 )→ (0 1 3 | 7 )→
1 0 −1 −1 0 −1 1 1 0 0 4 8
1 1 −2 −2 𝑅1=𝑅1 −𝑅2 1 1 −5 −9 𝑅 = 𝑅 + 5𝑅 1 0 01
1 1 3
(0 1 3 | 7 )→ (0 1 3 | 7 ) (0 1 0|1)
𝑅2 = 𝑅2 − 3𝑅3
0 0 1 2 0 0 1 2 0 0 12
Therefore, the solution of the system is
𝑥 = 1, 𝑦 = 1, 𝑧 = 2.
Exercise: Solve
𝑥+𝑦+𝑧=1
4𝑥 + 3𝑦 − 𝑧 = 6
3𝑥 + 5𝑦 + 3𝑧 = 4
Matrix Inversion Method
Consider a set of three simultaneous linear algebraic equations
𝑎11 𝑥1 + 𝑎12 𝑥2 + 𝑎13 𝑥3 = 𝑏1
𝑎21 𝑥1 + 𝑎22 𝑥2 + 𝑎23 𝑥3 = 𝑏2 (*)
𝑎31 𝑥1 + 𝑎32 𝑥2 + 𝑎33 𝑥3 = 𝑏3
Equation (*) can be expressed in the matrix form

3
𝐴𝑥 = 𝑏
Premultiplying by the inverse 𝐴−1 , we obtain the solution of 𝒙 as
𝑥 = 𝐴−1 𝑏 (**)
If the matrix 𝐴 is non-singular, that is, if |𝐴| ≠ 0, then Eq. (**) has a unique solution.The solution
for 𝑥1 is
𝑏 𝑎12 𝑎13
1 1 1 𝑎22 𝑎23 𝑎12 𝑎13 𝑎12 𝑎13
𝑥1 = |𝑏 𝑎22 𝑎23 | = {𝑏1 |𝑎 | + 𝑏 | | + 𝑏 | 𝑎23 |}
|𝐴| 2 |𝐴| 32 𝑎33 2 𝑎32 𝑎33 3 𝑎22
𝑏3 𝑎32 𝑎33
1
= {𝑏 𝐶 + 𝑏2 𝐶21 + 𝑏3 𝐶31 }
|𝐴| 1 11
where 𝐴 is the determinant of the coefficient matrix 𝐴, and 𝐶11 , 𝐶21 and 𝐶31 are the cofactors of
𝐴 corresponding to element 11, 21 and 31. We can also write similar expressions for 𝑥2 and 𝑥3
by replacing thesecond and third columns by the 𝑦 column respectively. Hence, the complete
solution can be written inmatrix form as follows:

𝑥1
1 𝐶11 𝐶21 𝐶31 𝑏1
{𝑥2 } = [𝐶 𝐶22 𝐶32 ] {𝑏2 }
𝑥3 |𝐴| 12
𝐶13 𝐶23 𝐶33 𝑏3
1 1
Or {𝑥} = |𝐴| [𝐶𝑖𝑗 ]{𝑏} = |𝐴| [𝑎𝑑𝑗 A]{𝑏}
1
Hence 𝐴−1 = |𝐴| 𝑎𝑑𝑗 A and 𝑎𝑑𝑗 A = 𝐴−1 𝑎𝑏𝑠 [𝐴]

Although this method is quite general but it is not quite suitable for large systems because
evaluation of 𝐴−1 by co-factors becomes very cumbersome.
Example: Solve
𝑥 − 𝑦 + 3𝑧 = 5
4𝑥 + 2𝑦 − 𝑧 = 0
𝑥 + 3𝑦 + 𝑧 = 5
1 −1 3
Sol: |𝐴| = |4 2 −1| = 40
1 3 1
The matrix of cofactors is given by
5 −5 10
𝐶 = [ 10 −2 −4]
−5 13 6
The transpose of 𝐶 is the adjoint of 𝐴 or

4
5 10 −5
𝐴𝑑𝑗 A = 𝐶 𝑇 = [−5 −2 13 ]
10 −4 6

−1
1 1 5 10 −5
𝐴 = 𝐴𝑑𝑗 A = [−5 −2 13 ]
|𝐴| 40
10 −4 6
Therefore

1 5 10 −5 5 1 0 0
𝑋 = 𝐴−1 𝑏 = [−5 −2 13 ] [0] = [40] = [1]
40 40
10 −4 6 5 80 2
Or 𝑥 = 0, 𝑦 = 1, 𝑧 = 2.
Eigenvalues and Eigenvectors of a Matrix
Defn:Let 𝐴 be an 𝑛 × 𝑛 matrix. A real number 𝜆 is an Eigen value of 𝐴 iff there is a non-zero
vector 𝑋 such that 𝐴𝑥 = 𝜆𝑥. Also, any nonzero vector X for which 𝐴𝑥 = 𝜆𝑥 is an Eigen
vector corresponding to the Eigen value 𝜆.
Theorem:Let𝐴 be an 𝑛 × 𝑛 matrix and 𝜆 be a real number. Then
a) 𝜆 is an Eigen vale of 𝐴 iff |𝐴 − 𝜆𝐼𝑛 | = 0
b) The Eigen vectors corresponding to 𝜆 are the nontrivial solution of the homogenous system
(𝐴 − 𝜆𝐼𝑛 )𝑋 = 0
Example: Find the Eigen value and Eigen vectors of the following matrix
3 2
a) 𝐴 = ( )
−1 0
Sol: Let 𝜆 be an Eigen value of 𝐴
3−𝜆 2
det(𝐴 − 𝜆𝐼) = | | ⇒ (3 − 𝜆)(−𝜆) + 2 = 0
−1 −𝜆
⇒𝜆2 − 3𝜆 + 2 = 0
⇒(𝜆 − 2)(𝜆 − 1) = 0
⇒𝜆1 = 1 or𝜆2 = 2
The Eigen values are 𝜆1 = 1 and𝜆2 = 2
To find the corresponding Eigenvectors
3 2 1 0 𝑥1
For 𝜆 = 1,we have (𝐴 − 𝜆𝐼)𝑥 = 0⇒[( ) − 1( )] (𝑥 ) = 0
−1 0 0 1 2
2 2 𝑥1
⇒( ) (𝑥 ) = 0
−1 −1 2

5
𝑥1
⇒ 2𝑥1 + 2𝑥2 = 0 , where 𝑥 = (𝑥 )
2

−𝑥1 − 𝑥2 = 0
A non-trivial solution to this set of equation is 𝑥2 = −𝑥1
Hence the Eigenvector is
𝑥1 𝑥1 1
𝑥 = (𝑥 ) = (−𝑥 ) = 𝑥1 ( ) , 𝑥1 ≠ 0
2 1 −1
Therefore; 𝑥: (1, −1)𝑡 is an Eigen vector corresponding to 𝜆1 = 1
3 2 1 0 𝑥1
For 𝜆2 = 2, we’ve (𝐴 − 𝜆𝐼)𝑥 = 0⇒[( ) − 2( )] (𝑥 ) = 0
−1 0 0 1 2

1 2 𝑥1
⇒( ) (𝑥 ) = 0
−1 −2 2

⇒ 𝑥1 + 2𝑥2 = 0
−𝑥1 − 2𝑥2 = 0
⇒ 𝑥1 = −2𝑥2
Hence the Eigen vector is
𝑥1 −2𝑥1 −2
𝑥 = (𝑥 ) = ( ) = 𝑥2 ( )
2 𝑥2 1
Therefore; 𝑥: (−2,1)𝑡 is an Eigen vector corresponding to 𝜆2 = 2.
2 1 −1
b) 𝐴 = (3 2 −3)
3 1 −2
Soln: Let 𝜆 be an Eigen values of 𝐴
2 1 −1 1 0 0
Since 𝐴 − 𝜆𝐼 = (3 2 −3) − 𝜆 (0 1 0)
3 1 −2 0 0 1
2−𝜆 1 −1
=( 3 2−𝜆 −3 )
3 1 −2 − 𝜆
2−𝜆 1 −1
Det(𝐴 − 𝜆𝐼) = | 3 2−𝜆 −3 |
3 1 −2 − 𝜆
⇒ (2 − 𝜆)[(2 − 𝜆)(−2 − 𝜆) + 3] − 1[3(−2 − 𝜆) + 9] − [3 − 3(2 − 𝜆)]
⇒ (2 − 𝜆)(𝜆2 − 1) − 1(−3𝜆 + 3) − 1(−3 + 3𝜆)
⇒ (2 − 𝜆)(𝜆 − 1)(𝜆 + 1) + 3𝜆 − 3 + 3 − 3𝜆
⇒ 𝜆1 = 2, 𝜆2 = 1, and𝜆3 = −1
To find the corresponding Eigen vectors
6
For 𝜆1 = 2, we’ve(𝐴 − 𝜆𝐼)𝑥 = 0⇒(𝐴 − 2𝐼)𝑥 = 0
0 1 −1 𝑥1 0 𝑥1
𝑥 𝑥
⇒ [3 0 −3] [ 2 ] = [0]Where 𝑥 = [ 2 ]
3 1 −4 𝑥3 0 𝑥3
⇒𝑥2 − 𝑥3 = 0 ⇒ 𝑥2 = 𝑥3
3𝑥1 − 3𝑥3 = 0 ⇒𝑥1 = 𝑥3
3𝑥1 + 𝑥2 − 4𝑥3 = 0 ⇒ 𝑥1 = 𝑥2 = 𝑥3
𝑥1 𝑥3 1
𝑥 𝑥
Thus, 𝑥 = [ 2 ] = [ 3 ] = 𝑥3 [1] , 𝑥3 ≠ 0
𝑥3 𝑥3 1
Therefore; the Eigen vectors corresponding to the Eigen value 𝜆1 = 2 is
1
𝐸 = {𝛼 [1] : 𝛼 ∈ 𝑅/{0}}
1
For 𝜆2 = 1, we’ve (𝐴 − 𝜆𝐼)𝑥 = 0
⇒ (𝐴 − 𝐼)𝑥 = 0
1 1 −1 𝑥1 0 𝑥1
⇒ [3 1 −3] [𝑥2 ] = [0] ,Where 𝑥 = [𝑥2 ]
3 1 −3 𝑥3 0 𝑥3
⇒𝑥1 + 𝑥2 − 𝑥3 = 0The second and the third equation are identical.
3𝑥1 + 𝑥2 − 3𝑥3 = 0Set 𝑥2 = 0 and𝑥3 = 𝑥1
3𝑥1 + 𝑥2 − 3𝑥3 = 0
𝑥1 𝑥1 1
Thus, 𝑥 = [𝑥2 ] = [ 0 ] = 𝑥1 [0] , 𝑥1 ≠ 0
𝑥3 𝑥1 1
Therefore; the Eigen vectors corresponding to the Eigen value 𝜆2 = 1 is
1
𝐸 = {𝛼 [0] : 𝛼 ∈ 𝑅/{0}}
1
For 𝜆3 = −1, we’ve (𝐴 − 𝜆𝐼)𝑥 = 0
⇒ (𝐴 − (−𝐼))𝑥 = 0
3 1 −1 𝑥1 0 𝑥1
𝑥 𝑥
⇒ [3 3 −3] [ 2 ] = [0] ,Where 𝑥 = [ 2 ]
3 1 −3 𝑥3 0 𝑥3
⇒3𝑥1 + 𝑥2 − 𝑥3 = 0Thefirst and the last equation are identical.
3𝑥1 + 3𝑥2 − 3𝑥3 = 0Set 𝑥1 = 0 and𝑥2 = 𝑥3
3𝑥1 + 𝑥2 − 𝑥3 = 0
7
𝑥1 0 0
𝑥 𝑥
Thus, 𝑥 = [ 2 ] = [ 2 ] = 𝑥2 [1] , 𝑥2 ≠ 0
𝑥3 𝑥2 1
Therefore; the Eigen vectors corresponding to the Eigen value 𝜆2 = −1 is
0
𝐸 = {𝛼 [1] : 𝛼 ∈ 𝑅/{0}}
1

Diagonalization of Matrices
Let the 𝑛 × 𝑛 matrix 𝐴 have 𝑛 Eigen values 𝜆1 , 𝜆2 , … , 𝜆𝑛 , not all of which need be distinct, and let
there be 𝑛 corresponding distinct Eigen vectors 𝑥1 , 𝑥2 , … , 𝑥𝑛 , so that
𝐴𝑥𝑖 = 𝜆𝑖 𝑥𝑖 𝑖 = 1,2, … , 𝑛
Define the matrix 𝑃 to be the 𝑛 × 𝑛 matrix in which the 𝑖 𝑡ℎ column is the Eigen vector 𝑥𝑖 , with
𝑖 = 1,2, … , 𝑛, 𝑃 = [𝑥1 , 𝑥2 , … , 𝑥𝑛 ] and let 𝐷 be the diagonal matrix
𝜆1 0 0 ⋯ 0
𝐷 = [0 𝜆1 0 ⋯ 0]
⋮ ⋮ ⋮ ⋱ ⋮
0 0 0 ⋯ 0
Where the Eigen value 𝜆𝑖 is in the 𝑖 𝑡ℎ positionin the 𝑖 𝑡ℎ row. Then
𝑃−1 𝐴𝑃 = 𝐷
Remark:i) An 𝑛 × 𝑛 matrix can be diagonalized provided it possesses𝑛 linearly independentEigen vectors.
ii) A symmetric matrix can always be diagonalized.
iii) A diagonalizing matrix is not unique, because its form depends on the order in which the Eigen
vector of 𝐴 are used to form its columns.
An 𝑛 × 𝑛 matrix can be raised to a power when it is diagonalizable,
𝐴 = 𝑃𝐷𝑃−1
𝐴2 = (𝑃𝐷𝑃−1 )(𝑃𝐷𝑃−1 ) = 𝑃𝐷𝑃−1 𝑃𝐷𝑃−1 = 𝑃𝐷𝐷𝑃 −1 = 𝑃𝐷2 𝑃−1 ,
So that, in general,
𝐴𝑚 = 𝑃𝐷𝑚 𝑃 −1 , for 𝑚 = 1,2, …
Example: Diagonalize the matrix
2 1 −1
𝐴 = [3 2 −3],And use the result to find 𝐴5 .
3 1 −2

8
Soln: The Eigen values are 𝜆1 = 2, 𝜆2 = 1, and𝜆3 = −1, and the corresponding Eigen vector
1 1 0
𝑥1 = [1] , 𝑥2 = [0], and𝑥3 = [1]
1 1 1
1 1 0 1 1 −1
−1
𝑃 = [1 0 1]and𝑃 = [ 0 −1 1 ]
1 1 1 −1 0 1
2 0 0
𝐷 = 𝑃−1 𝐴𝑃 = [0 1 0]
0 0 −1
The Eigen values appearing in the diagonal matrix D
𝐴5 = 𝑃𝐷5 𝑃−1
1 1 0 32 0 0 1 1 −1 32 31 −31
= [1 0 1 ] [ 0 1 0 ] [ 0 −1 1 ] = [33 32 −33]
1 1 1 0 0 −1 −1 0 1 33 31 −32
1 −3 3
2) Find a matrix P that diagonalizes 𝐴 = (3 −5 3)
6 −6 4

Das könnte Ihnen auch gefallen