Sei sulla pagina 1di 1

R.

Mark Prosser CS 370

Example: PA = LU Factorization with Row Pivoting


Find the P A = LU factorization using row pivoting for the matrix

10 7 0
A = 3 2 6 .
5 1 5
The first permutation step is trivial (since the pivot element 10 is already the largest).
The corresponding permutation matrix is the identity, and we need not write it down. The
first elimination step is:
row 2 row 2 3

10
(row 1)
1
row 3 row 3 2 (row 1)

10 7 0 1 0 0 10 7 0
3 3 1
2 6 = 10 1 0 0 10 6
1 5
5 1 5 2
0 1 0 2
5

The second permutation step is:


Swap rows 2 and 3

10 7 0 1 0 0 1 0 0 10 7 0
3 3 5
2 6 = 10 1 0 0 0 1 0 2
5
1 1
5 1 5 2
0 1 0 1 0 0 10 6

The second elimination step is:


row 3 row 3 1

25
(row 2)

10 7 0 1 0 0 1 0 0 1 0 0 10 7 0
3 3 5
2 6 = 10 1 0 0 0 1 0 1 0 0 2
5
1 1 31
5 1 5 2
0 1 0 1 0 0 25
1 0 0 5

The process is complete and the operations can be reorganized as follows:



1 0 0 10 7 0 1 0 0 1 0 0 1 0 0 1 0 0 10 7 0
0 0 1 3 3 5
2 6 = 0 0 1 10 1 0 0 0 1 0 1 0 0 2
5
1 1 31
0 1 0 5 1 5 0 1 0 0 1 0 1 0 0 25 1 0 0
2 5
1 0 0 1 0 0 10 7 0
1 5
=
2
1 0 0 1 0 0 2
5
3 1 31
0 1 0 1 0 0 5
10 25
1 0 0 10 7 0
1 5
=
2
1 0 0 2
5
3 1 31
10 25 1 0 0 5

We have obtained the P A = LU factorization:


P A = L U

1 0 0 10 7 0 1 0 0 10 7 0
0 0 1 3 2 6 = 12 1 0 0 5
2
5
3 1 31
0 1 0 5 1 5 10 25 1 0 0 5

Potrebbero piacerti anche