Excel function

MDETERMfunction

Returns the determinant of a square matrix.

All versions
=MDETERM(A2:B3)
A
B
C
D
E
F
G
H
I
J
K
1
2
3
4

Drag the corner dots to change array. Widen the range to A2:C4 for a 3×3 determinant. A non-square range gives #VALUE!. Try breaking it on purpose to see the errors.

Result

-2

array
A2:B3Drag the corner dots on the table

A square range of numbers (rows = columns).

What is the MDETERM function?

=MDETERM(array)

MDETERM returns the determinant of a square matrix. For a 2×2 matrix {a,b;c,d}, it is a×d−b×c.

If the determinant is 0, the matrix has no inverse (MINVERSE returns #NUM!). A2:C4 is matrix 1, E2:G4 is matrix 2, and the result fills from column I. Drag a range to change the matrix size.

The main use of MDETERM is to check that a system of equations has exactly one solution before solving it. A determinant of 0 means one equation is a multiple or combination of the others, so there is no solution or there are infinitely many. For a 2×2 matrix, the absolute value of the determinant is also the area of the parallelogram formed by its two columns.

Arguments

array
A range of numbers with as many rows as columns.

MDETERM examples

  1. Example 1. 2×2

    =MDETERM(A2:B3)

    1×4−2×3 = -2.

  2. Example 2. 3×3

    =MDETERM(A2:C4)

    The determinant of a 3×3 matrix.

  3. Example 3. 2×2 determinants

    =MDETERM(A2:B3)

    Calculated as a×d − b×c.

    MatrixCalculationResult
    {1,2;3,4}1×4 − 2×3-2
    {2,0;0,3}2×3 − 0×06
    {1,2;2,4}1×4 − 2×20 (no inverse)
  4. Example 4. A 3×3 example

    =MDETERM({1,2,1;3,4,-1;0,2,0})

    8. It is not 0, so MINVERSE can find the inverse.

Common mistakes

FAQ

What is it used for?
To check whether a system of equations has a single solution (determinant ≠ 0).
Inverse?
Use MINVERSE.
How do I solve the equations?
=MMULT(MINVERSE(coefficients), constants).