LU Decomposition

Factor a matrix as L U with partial pivoting

Matrix A
Doolittle with partial pivoting: P · A = L · U, det(A) = (−1)^swaps × ∏ diag(U)
Determinant
‎-16
Row swaps
1 · row order: 2 · 1 · 3
Lower-triangular L
1
0
0
0.5
1
0
‎-0.5
1
1
Upper-triangular U
4
‎-6
0
0
4
1
0
0
1
Permutation P
0
1
0
1
0
0
0
0
1

L is unit lower-triangular (1s on the diagonal) and U is upper-triangular. Multiplying L · U reproduces the row-permuted matrix P · A, which confirms the factorization.

P · A = L · UThe row-permuted matrix P·A equals the lower-triangular factor L multiplied by the upper-triangular factor U.4‎-60211‎-272=1000.510‎-0.511·4‎-60041001P·ALU