LU Decomposition Calculator
Decompose square matrices into lower and upper triangular matrices using Doolittle's method
Matrix Input
Enter the elements of your square matrix A
LU Decomposition Results
L (Lower Triangular) Matrix
U (Upper Triangular) Matrix
Verification: L × U
Step-by-Step Solution
Example Calculation
2×2 Matrix Example
Matrix A:
[6 3]
LU Decomposition Result
L Matrix:
[1.5 1 ]
U Matrix:
[0 -1.5]
Determinant: 4 × (-1.5) = -6
LU Decomposition Properties
Lower Triangular
All elements above diagonal are zero
Diagonal elements are 1 (unit triangular)
Upper Triangular
All elements below diagonal are zero
Contains the pivot elements
Original Matrix
A = L × U decomposition
Must be square and non-singular
Applications
Solving systems of linear equations
Computing matrix determinants
Finding matrix inverses
Numerical analysis computations
Computer graphics transformations
Understanding LU Decomposition
What is LU Decomposition?
LU decomposition factors a square matrix A into the product of two matrices: a lower triangular matrix L and an upper triangular matrix U, such that A = LU.
Doolittle's Method
- •Sets diagonal elements of L to 1 (unit triangular)
- •Calculates U matrix row by row
- •Calculates L matrix column by column
- •Uses forward and backward substitution
Mathematical Formulas
Upper triangular U:
U[i][j] = A[i][j] - Σ(L[i][k] × U[k][j])
Lower triangular L:
L[i][j] = (A[i][j] - Σ(L[i][k] × U[k][j])) / U[j][j]
Determinant:
det(A) = Π(U[i][i]) for i = 0 to n-1
Note: LU decomposition fails if any pivot element is zero. In such cases, partial pivoting (row permutation) is needed.