0% found this document useful (0 votes)
43 views5 pages

Cramer's Rule, Adjoint, LU Factorization

This document discusses solving systems of linear equations using determinants and Cramer's rule, LU factorization/decomposition, and other matrix methods. It provides 4 examples of using Cramer's rule to solve systems of 2 and 3 equations with 2 and 3 unknowns. It also gives an overview of using the adjoint matrix and inverse to solve systems, and provides one example. Finally, it introduces LU factorization/decomposition and Doolittle's method for solving systems, giving one example.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
43 views5 pages

Cramer's Rule, Adjoint, LU Factorization

This document discusses solving systems of linear equations using determinants and Cramer's rule, LU factorization/decomposition, and other matrix methods. It provides 4 examples of using Cramer's rule to solve systems of 2 and 3 equations with 2 and 3 unknowns. It also gives an overview of using the adjoint matrix and inverse to solve systems, and provides one example. Finally, it introduces LU factorization/decomposition and Doolittle's method for solving systems, giving one example.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

c.

By Determinants

Solve by,

• Cramer’s Rule
Applicable only to linear system with “n” equations and “n” unknowns.
Applicable only to non-singular matrices.
|𝐴𝑛 |
𝑥𝑛 =
𝐴
Example 1:

x1 – 3x2 = -7 2x1 + x2 = 7

|𝐴| = |1 −3| = (1)(1) − (−3)(1) = 𝟕


2 1
|𝐴1 | = | −7 −3
| = (−7)(1) − (−3)(7) = 𝟏𝟒
7 1
14
𝑥1 = =𝟐
7
|𝐴2 | = |1 −7| = (1)(7) − (−7)(2) = 𝟐𝟏
2 7
21
𝑥2 = =𝟑
7

Example 2:

x1 + 2x2 – x3 = 4 2x1 + x2 + x3 = 5 3x1 - x2 + 2x3 = 3


1 2 −1
𝐵 = |2 1 1|
3 −1 2
= [(1)(1)(2) + (2)(1)(3) + (−1)(2)(−1)] − [(−1)(1)(3) + (2)(2)(2)
+ (1)(1)(−1) = 𝟔
4 2 −1
𝐵1 = |5 1 1|
3 −1 2
= [(4)(1)(2) + (2)(1)(3) + (−1)(5)(−1)]
− [(−1)(1)(3) + (2)(5)(2) + (4)(1)(−1)] = 𝟔
6
𝑥1 = = 𝟏
6
1 4 −1
𝐵2 = |2 5 1 |
3 3 2
= [(1)(5)(2) + (4)(1)(3) + (−1)(2)(3)]
− [(−1)(5)(3) + (4)(2)(2) + (1)(1)(3_] = 𝟏𝟐
12
𝑥2 = =𝟐
6
1 2 4
𝐵3 = |2 1 5|
3 −1 3
= [(1)(1)(3) + (2)(5)(3) + (4)(2)(−1)]
− [(4)(1)(3) + (2)(2)(3) + (1)(5)(−1)] = 𝟔
6
𝑥3 = = 𝟏
6
Example 3:
1 1 1 13
2 −2 −1 2 0
𝐶=[ | ]
3 −1 2 2 2
1 −1 −2 1 0
𝐶=6
3 𝟏
𝑥1 = =
6 𝟐
9 𝟑
𝑥2 = =
6 𝟐
0
𝑥3 = =𝟎
6
6
𝑥1 = =𝟏
6

Example 4:

3x + 2y + z= 2 4x + 2y + 2z= 8 x – y + z= 4
3 2 12
[4 2 2|8]
1 −1 1 4
𝐷=2
8
𝑥 = − = −𝟒
2
4
𝑦= = 𝟐
2
20
𝑧= = 𝟏𝟎
2
• Using Adjoint of a Matrix

Get the adjoint.

Get the inverse using adjoint.

Solutions are obtained by,

𝑥 = 𝐴−1 𝑏
Example 1:

x1 – 3x2 = -7 2x1 + x2 = 7

|𝐴| = |1 −3| 𝐴=7


2 1
3 −2 1 3
𝐴𝑐𝑜 = | | 𝐴𝑎𝑑𝑗 = | |
3 1 −2 1
1 3
7 7
𝐴−1 = | 2 1|

7 7

𝑈𝑠𝑒 𝑥 = 𝐴−1 𝑏
1 3
𝑥1 = ( ) (−7) + ( ) (7) = 𝟐
7 7
2 1
𝑥2 = (− ) (−7) + ( ) (7) = 𝟑
7 7
Example 2:

x1 + 2x2 – x3 = 4 2x1 + x2 + x3 = 5 3x1 - x2 + 2x3 = 3


1 2 −1
𝐵 = |2 1 1| 𝐵=6
3 −1 2

3 −1 −5 3 −3 3
𝐵𝑐𝑜 = |−3 5 7| 𝐵𝑎𝑑𝑗 = |−1 5 −3|
3 −3 −3 −5 7 −3

3 3 3

6 6 6
1 5 3
𝐵−1 = ||− 6 6
− 6||
5 7 3
− −
6 6 6

3 3 3
𝑥1 = ( ) (4) + (− ) (5) + ( )(3) = 𝟏
6 6 6
1 5 3
𝑥2 = (− ) (4) + ( ) (5) + (− )(3) = 𝟐
6 6 6
5 7 3
𝑥3 = ( ) (4) + ( ) (5) + (− )(3) = 𝟏
6 6 6

d. LU Factorization/ Decomposition

A non-singular matrix A ha an LU factorization if it can be written as a product of a


matrix L (lower triangular form) and a matrix U (upper triangular form).

𝐴 = 𝐿𝑈 𝐿𝑈𝑥 = 𝑏 𝐿𝑦 = 𝑏 𝑦 = 𝑈𝑥
Solve by,

• Doolittle’s Method

Example 1:

x1 – 3x2 = -7 2x1 + x2 = 7

|𝐴| = |1 −3|
2 1
(-2)r1 + r2
1 −3
𝑈= | |
0 7

𝐴 = 𝐿𝑈
1 −3 1 0 1 −3
| |=| || |
2 1 𝐿 1 0 7
2 = 𝐿(1) + 1(0)
𝐿=2

𝐿𝑦 = 𝑏
1 0 𝑦1 −7
| || | = | |
2 1 𝑦2 7
1(𝑦1 ) = −7 𝑦1 = 7
2(𝑦1 ) + 1(𝑦2 ) = 7 𝑦2 = 21

𝑦 = 𝑈𝑥
−7 1 −3 𝑥1
| |=| || |
21 0 7 𝑥2
21 = 0(𝑥1 ) + 7(𝑥2 ) 𝑥2 = 𝟑
−7 = 1(𝑥1 ) + (−3)(𝑥2 ) 𝑥1 = 𝟐

• Crout’s Method

Example 1:

x1 – 3x2 = -7 2x1 + x2 = 7

|𝐴| = |1 −3
|
2 1
𝐴 = 𝐿𝑈
1 −3 𝐿 0 1 𝑈
[ ]=[ 1 ][ ]
2 1 𝐿2 𝐿3 0 1

1 = 𝐿1 (1) + 0 𝐿1 = 1
−3 = 𝐿1 (𝑈) + 0 𝑈 = −3
2 = 𝐿2 (1) + 0 𝐿2 = 2
1 = 𝐿2 (𝑈) + 𝐿3 𝐿3 = 7

𝐿𝑦 = 𝑏
1 0 𝑦1 −7
[ ][ ] = [ ]
2 7 𝑦2 7
1(𝑦1 ) = −7 𝑦1 = −7
2(𝑦1 ) + 7(𝑦2 ) = 7 𝑦2 = 3

𝑦 = 𝑈𝑥
−7 1 −3 𝑥1
[ ]=[ ][ ]
3 0 1 𝑥2
3 = 𝑥1 (0) + 1(𝑥2 ) 𝑥2 = 𝟑
−7 = 1(𝑥1 ) − 3(𝑥2 ) 𝑥1 = 𝟐

You might also like