Determinant Calculator
Free determinant calculator for any square matrix up to 8x8. Get det(A) exactly, the cofactor expansion written out, and a row-reduction cross-check.
Determinant Calculator
Background.
The determinant is a single number squeezed out of a square matrix, and it carries a surprising amount of information about what that matrix does. This calculator takes any square matrix from 1x1 up to 8x8, returns det(A), and shows you the cofactor expansion that produced it — then quietly recomputes the same number by a completely different algorithm and tells you whether the two agree.
Type or paste your matrix with one row per line. Entries can be separated by commas or by spaces, rows can be separated by line breaks or semicolons, and the bracketed form you get from copying out of most software — [[1,2],[3,4]] — is accepted too. Negative numbers, decimals and scientific notation all work.
What the answer means depends on which reading you want. Algebraically, the determinant is the invertibility test: a square matrix over a field has an inverse if and only if its determinant is not zero. That single fact is why the determinant turns up as a precondition in so many other procedures — Cramer's rule refuses to run when it is zero, the adjugate formula for the inverse divides by it, and a system of n equations in n unknowns has exactly one solution precisely when it is non-zero. Geometrically, the absolute value of the determinant is a volume: the parallelepiped spanned by the rows of A has volume |det(A)|, so a determinant of zero means those rows have collapsed into a lower-dimensional space and the matrix squashes volume down to nothing. The sign tells you whether the transformation preserves orientation or flips it, the way a mirror does.
The headline number here is computed without a single division. A naive recursive cofactor expansion costs O(n!) operations, which is why textbooks stop at 3x3; this calculator evaluates the same Laplace expansion by dynamic programming over subsets of columns, which costs O(2^n x n) instead — about two thousand operations at 8x8. Because that route uses only addition and multiplication, an integer matrix produces an exact integer answer no matter how badly conditioned it is. Every intermediate value is carried in 80 significant digits and rounded exactly once, at the end, to 10 decimal places.
That exactness matters more than it sounds. The usual fast way to get a determinant is Gaussian elimination — reduce the matrix to triangular form and multiply the pivots, adjusting the sign for each row swap. It is the right algorithm for large matrices, but it divides, and division is where floating-point error creeps in and where a determinant that should be exactly zero comes out as something like 1e-16 instead. Rather than pick one method and hope, this page runs both and prints the elimination result beside the exact one, along with the number of row interchanges it needed. If they ever disagree you will see it, which is the point.
One scope note that belongs next to the number rather than buried in an FAQ: the singular / non-singular verdict is decided on the determinant as displayed, after rounding to 10 decimal places. A determinant of 4e-11 is reported as singular; 6e-11 is reported as non-singular. Classifying the unrounded value instead would let the page print a hero result of 0 next to the words 'non-singular', which is worse than a boundary you can read. If your matrix genuinely lives at that scale, rescale it before trusting the label.
The calculator handles square matrices only — a determinant simply is not defined for a rectangular one, and the page will tell you so rather than inventing an answer. If your matrix is not square and you want to know how many independent rows it has, that question is answered by rank, not by a determinant. Complex entries and symbolic entries are out of scope.
What is determinant calculator?
The determinant of an n x n matrix A, written det(A) or |A|, is the signed sum over all n! permutations of products of entries, one from each row and column, with the sign of each term given by the parity of the permutation. In practice nobody evaluates it that way. The working definition is the Laplace (cofactor) expansion: pick any row i, and det(A) = sum over j of a_ij times C_ij, where the cofactor C_ij equals (-1)^(i+j) times M_ij, and the minor M_ij is the determinant of the smaller matrix you get by deleting row i and column j. Expanding along any row or any column gives the same answer, which is itself a non-obvious theorem. The determinant is the invertibility test for square matrices: A has an inverse if and only if det(A) is not zero, and det(A) = 0 exactly when the rows (equivalently the columns) are linearly dependent. Its absolute value is the volume scaling factor of the linear map A represents, and its sign records whether that map preserves or reverses orientation. Useful properties: det(A^T) = det(A); swapping two rows negates it; multiplying one row by a scalar k multiplies it by k; adding a multiple of one row to another leaves it unchanged; det(AB) = det(A)det(B); and for a triangular matrix it is simply the product of the diagonal entries.
How to use this calculator.
- Type your square matrix into the box, one row per line, with entries separated by commas or spaces.
- You can also paste the bracketed form [[1,2,3],[4,5,6],[7,8,10]] or use semicolons as row separators — both are parsed.
- The matrix must be square. If it is not, the calculator says so instead of returning a number, because a determinant is undefined for a rectangular matrix.
- Read the headline number: that is det(A), computed without any division and therefore exact for integer input.
- Check the singular / non-singular verdict. Non-singular means the matrix is invertible and its rows are linearly independent; singular means it is not invertible and the rows are dependent.
- Read the cofactor expansion line to see the working: each first-row entry multiplied by its own cofactor, summed.
- Read the row-reduction line for an independent confirmation by Gaussian elimination, including how many row interchanges it needed and whether the two methods agree.
- Matrices larger than 8 x 8 are out of scope — for those, use a numerical library where an LU factorisation is the right tool.
The formula.
The Laplace expansion says that for any fixed row i, det(A) = Σⱼ aᵢⱼ·Cᵢⱼ, where Cᵢⱼ = (−1)^(i+j)·Mᵢⱼ and Mᵢⱼ is the minor: the determinant of the (n−1)x(n−1) matrix left after deleting row i and column j. The (−1)^(i+j) factor is the familiar checkerboard of plus and minus signs starting with + in the top-left corner. Expanding along row 1 of the worked example A = [[1,2,3],[4,5,6],[7,8,10]] gives minors M11 = 5·10 − 6·8 = 2, M12 = 4·10 − 6·7 = −2 and M13 = 4·8 − 5·7 = −3; attaching the signs turns those into cofactors C11 = +2, C12 = +2 and C13 = −3, so det(A) = 1·2 + 2·2 + 3·(−3) = 2 + 4 − 9 = −3. Evaluating that recursion naively costs O(n!) operations, so this calculator computes the same expansion by dynamic programming over subsets of columns instead: f[S] is the determinant of the submatrix built from the first |S| rows and the columns in S, expanded along its own last row, which brings the cost down to O(2ⁿ·n) — roughly two thousand operations at 8x8. Crucially that route uses only addition and multiplication, never division, so for an integer matrix the result is exact. Rounding happens once and only once, at the very end, to 10 decimal places; every intermediate value is carried at 80 significant digits. The second, independent route is Gaussian elimination with partial pivoting: reduce A to upper-triangular form, multiply the pivots, and multiply by (−1)^s where s is the number of row interchanges. On the worked example pivoting picks 7 first, so the rows are swapped twice, the pivots come out as 7, 6/7 and −1/2, and their product 7 · 6/7 · (−1/2) = −3 with an even number of swaps confirms det(A) = −3. Both results are shown on the page.
A worked example.
Take A = [[1, 2, 3], [4, 5, 6], [7, 8, 10]]. Expanding along the first row needs the three first-row minors: M11 is the determinant of [[5,6],[8,10]] = 50 − 48 = 2; M12 is the determinant of [[4,6],[7,10]] = 40 − 42 = −2; and M13 is the determinant of [[4,5],[7,8]] = 32 − 35 = −3. The checkerboard signs turn these into cofactors C11 = +2, C12 = −(−2) = +2 and C13 = +(−3) = −3, so the calculator prints the expansion as det = 1 x 2 + 2 x 2 + 3 x (-3), which sums to 2 + 4 − 9 = −3. The determinant output is therefore −3, its absolute value is 3, and the matrix size is 3. Because −3 is not zero the verdict is non-singular: A is invertible and its three rows are linearly independent. Geometrically, |det(A)| = 3 says the parallelepiped spanned by the rows (1,2,3), (4,5,6) and (7,8,10) has volume 3 — a thin sliver, because those three vectors are close to lying in a common plane, which is exactly what a small determinant relative to the size of the entries indicates. The independent check confirms it: Gaussian elimination with partial pivoting moves the 7 to the top, performs two row interchanges in total, produces pivots 7, 6/7 and −1/2 whose product is −3, and since two swaps is an even number the sign is unchanged. Both methods return −3, so the page reports that row reduction agrees with the cofactor expansion.
Frequently asked questions.
How do you find the determinant of a 3x3 matrix by hand?
What does it mean when the determinant is zero?
Can a non-square matrix have a determinant?
Why does this calculator show two different methods?
What is the largest matrix this handles?
Does the order of the rows change the determinant?
How is the determinant related to the inverse of a matrix?
Is the determinant the same as the trace or the rank?
Does rounding affect the singular / non-singular verdict?
References& sources.
- [1]Encyclopedia of Mathematics (EMS Press), 'Determinant'. Gives the permutation definition, the Laplace expansion identity sum_j a_ij A_kj = delta_ik det A, and the criterion that a square matrix over a field is invertible if and only if its determinant is not zero. Retrieved 2026-07-29.
- [2]MIT OpenCourseWare 18.06 Linear Algebra (Spring 2010), Prof. Gilbert Strang — course syllabus. States the determinants goal as 'properties of determinants (leading to the cofactor formula and the sum over all n! permutations, applications to inv(A) and volume)'. Retrieved 2026-07-29.
- [3]MIT OpenCourseWare 18.06, Lecture 20 — 'Cramer's rule, inverse matrix, and volume'. Source for A^-1 = (1/det A) C^T and for the statement that the absolute value of the determinant gives the volume of a box. Retrieved 2026-07-29.
- [4]Golub, G. H. & Van Loan, C. F. (2013). Matrix Computations, 4th ed., Johns Hopkins University Press, section 3.2 — Gaussian elimination with partial pivoting and det(A) = (-1)^s times the product of the pivots. Print reference; publisher page linked.
- [5]Encyclopedia of Mathematics (EMS Press), 'Rank'. States that the rank equals the maximal order of a non-zero minor, which is the link between a zero determinant and rank deficiency. Retrieved 2026-07-29.
In this category
Embed
Quanta Pro
Paid features are coming later.
- All 977 calculators remain free
- No billing is enabled