FREE ONLINE MATRIX TOOL

Matrix Determinant Calculator

Calculate the determinant of any square matrix from 1×1 to 8×8. Enter your values to get the result and a clear outline of the Gaussian elimination steps.

Calculate a determinant

Choose the matrix size, enter the numbers, and select Calculate Determinant. Use integers, decimals, or negative values.

Maximum matrix size: 8×8. Each entry must be between −1,000,000 and 1,000,000.

What is a matrix determinant?

The determinant is a single number associated with a square matrix. It is commonly written as det(A) or with vertical bars around the matrix. Determinants are used in linear algebra to study matrix inverses, systems of equations, and linear transformations.

Nonzero determinant

A nonzero determinant means the matrix is invertible. Its rows and columns are linearly independent.

Zero determinant

A zero determinant means the matrix is singular. Its rows or columns are linearly dependent, so no inverse exists.

Determinant formulas

1×1 matrix

A = [a]   ⇒   det(A) = a

2×2 matrix

A = [a b; c d]   ⇒   det(A) = ad − bc

Multiply the main diagonal entries and subtract the product of the other diagonal entries.

3×3 matrix

det(A) = a(ei − fh) − b(di − fg) + c(dh − eg)

This formula applies to a matrix with rows [a, b, c], [d, e, f], and [g, h, i]. The signs alternate when expanding along the first row.

Larger square matrices

For larger matrices, the determinant can be calculated by cofactor expansion or by Gaussian elimination. With an upper-triangular matrix, the determinant is the product of its diagonal entries, adjusted for any row swaps made during elimination.

Worked example: a 3×3 determinant

Consider the following matrix:

A = [ 1   2   3 ]
   [ 0   4   5 ]
   [ 1   0   6 ]

Expanding along the first row gives:

det(A) = 1(4×6 − 5×0) − 2(0×6 − 5×1) + 3(0×0 − 4×1)
det(A) = 24 − 2(−5) − 12 = 22

The determinant is 22, which is nonzero. Therefore, this matrix has an inverse. You can enter the example into the calculator above to verify the result.

Frequently asked questions

What is the determinant of a matrix?

The determinant is a single number associated with a square matrix. It provides information about invertibility and the scaling of area or volume under a linear transformation.

Can I calculate the determinant of a non-square matrix?

No. A standard matrix determinant is defined only for square matrices, which have the same number of rows and columns.

What does a determinant of zero mean?

A zero determinant means that the matrix is singular and has no inverse. Its rows or columns are linearly dependent.

How do you calculate a 2×2 determinant?

For a matrix with rows [a, b] and [c, d], calculate det(A) = ad − bc. Multiply the main diagonal entries and subtract the product of the other diagonal.

How is a large matrix determinant calculated?

Gaussian elimination can transform a matrix into upper-triangular form. Account for row swaps, then multiply the diagonal entries to obtain the determinant.

Does the determinant have to be an integer?

No. A determinant can be an integer, a fraction, or another real number. Its value depends on the entries of the matrix.

Explore more matrix calculators

Continue working with matrices using these free online tools.