Gaussian Elimination with scaled partial pivoting

(in place)


æ
ç
ç
ç
ç
è
   3
1
2
9
|  
5
   2
1
2
1
|
-2
   6
1
1
8
|  
2
-3
0
2
1
|  
2
ö
÷
÷
÷
÷
ø
   row scales    æ
ç
ç
ç
ç
è
9
2
8
3
ö
÷
÷
÷
÷
ø
   pivot order æ
ç
ç
ç
ç
è
1
2
3
4
ö
÷
÷
÷
÷
ø
Determine the pivot row by taking the row corresponding to the largest of [3/9, 2/2, 6/8, 3/3]. Row 2 is the pivot row that will be used to eliminate the first variable from equations 1,3, and 4. The multipliers are: [-3/2,X,-6/2,3/2] and the result of the elimination is:


æ
ç
ç
ç
ç
è
0
-1/2
-1
15/2
|   
8
2
1   
2
1
|
-2
0
-2
-5
5
|   
8
0
3/2   
5
5/2
|
-1
ö
÷
÷
÷
÷
ø
   pivot order æ
ç
ç
ç
ç
è
2
1
3
4
ö
÷
÷
÷
÷
ø
Determine the next pivot by taking the row corresponding to the largest of [[(1/2)/9], X,2/8,[( 3/2)/4]] = [1/18, X, 1/4, 3/8]. Row 4 is the pivot row that will be used to eliminate the second variable from equations 1 and 3. The multipliers are: [1/3,X,4/3,X] and the result of the elimination is:


æ
ç
ç
ç
ç
è
0
0
2/3
25/3
|
23/3
2
1
2
1
|
-2
0
0
5/3
25/3
|
20/3
0
3/2
5
5/2
|
-1
ö
÷
÷
÷
÷
ø
   pivot order æ
ç
ç
ç
ç
è
2
4
3
1
ö
÷
÷
÷
÷
ø

Determine the next pivot as the row corresponding to the largest of [2/27, X, 5/24, X]. Row 3 is the pivot row that will be used to eliminate the third variable from equation 1. The multiplier is: [-2/5,X,X,X] and the result of the elimination is:


æ
ç
ç
ç
ç
è
0
0
0
5
|
5
2
1
2
1
|
-2
0
0
5/3
25/3
|
20/3
0
3/2
5
5/2
|
-1
ö
÷
÷
÷
÷
ø
   pivot order æ
ç
ç
ç
ç
è
2
4
3
1
ö
÷
÷
÷
÷
ø

Back Substitution



æ
ç
ç
ç
ç
è
0
0
0
5
|
5
2
1
2
1
|
-2
0
0
5/3
25/3
|
20/3
0
3/2
5
5/2
|
-1
ö
÷
÷
÷
÷
ø
   pivot order æ
ç
ç
ç
ç
è
2
4
3
1
ö
÷
÷
÷
÷
ø
The pivot order determines the order in which equations will be solved. The equations are taken in the reverse of the pivot order.



5z = 5
Þ z=1
(1)
5
3
y + 25
3
z = 20/3
Þ y = (20/3-25/3)/(5/3)=-1
(3)
3
2
x + 5 y + 5
2
z = -1
Þ x=( -1 +5 -5/2)/(3/2)=1
(4)
2 w + x + 2 y +z = -2
Þ w=( -2 -1 +2 -1 )/2=-1
(2)


The determinant


There were no row interchanges so the determinant of the above matrix is the same as that of the original matrix.



5 (-1)1+4 (5/3) (-1)2+3 (3/2) (-1)2+2 2 =25

We could also note that the pivot order is 2,4,3,1 and the number of interchanges required to restore the natural order is 4.
(5)(5/3)(3/2)(2) =25




File translated from TEX by TTH, version 2.84.
On 24 Nov 2001, 11:06.