Worked example
a: 1 2 3 4
→ −2
Method and scope
Square matrices only. Gaussian elimination with partial pivoting uses cubic work rather than cofactor expansion. Every row swap flips the determinant sign. Floating-point cancellation near singularity can affect the answer.
det(A) = det(P) × ∏ Uᵢᵢ; det(P) ∈ {−1,+1}
Precision and limits
≈ marks an approximation. Display rounding does not change the internal calculation.