Properties of Determinants
The determinant is multiplicative, , and unchanged by transposition. These two facts, together with the row-operation rules, give a toolbox of identities for inverses, powers and similar matrices, and they all have a clear geometric meaning: determinants are volume scale factors, and scale factors multiply.
The list
For matrices and and a scalar :
| Property | Note |
|---|---|
| the key property | |
| so column rules = row rules | |
| from | |
| , and all integers if is invertible | |
| rows are each scaled by | |
| similar matrices have the same determinant | |
| in general: the determinant is not additive | |
| orthogonal () | rotations +1, reflections −1 |
| linear in each row separately | with the other rows fixed |
Proof of the inverse rule: . Proof of the similarity rule: . For orthogonal : .
from sympy import Matrix, Rational
A = Matrix([[2, 1, 0], [1, 3, -1], [0, 2, 4]])
B = Matrix([[1, -2, 1], [0, 1, 3], [2, 0, 1]])
P = Matrix([[1, 1, 0], [0, 1, 1], [1, 0, 2]])
print("det A, det B:", A.det(), B.det())
print("det(AB) == det A det B:", (A * B).det() == A.det() * B.det())
print("det(A^T) == det A:", A.T.det() == A.det())
print("det(A^-1) =", A.inv().det(), " 1/det A =", Rational(1, A.det()))
print("det(A^3) == det(A)^3:", (A**3).det() == A.det()**3)
print("det(P^-1 A P) == det A:", (P.inv() * A * P).det() == A.det())
print("det(A+B) =", (A + B).det(), " but det A + det B =", A.det() + B.det())det A, det B: 24 -13
det(AB) == det A det B: True
det(A^T) == det A: True
det(A^-1) = 1/24 1/det A = 1/24
det(A^3) == det(A)^3: True
det(P^-1 A P) == det A: True
det(A+B) = 43 but det A + det B = 11
Why
Geometric reason. The map applies first, scaling volumes by , then , scaling by . Orientation flips also combine: two flips cancel. So the total signed scale factor is .
Algebraic proof sketch. For an elementary matrix , is exactly the row-operation rules of Determinants and Row Operations ( is , or 1). If is invertible it is a product of elementary matrices (Elementary Matrices), and applying the rule times gives . If is singular, so is (its columns lie in , which is not all of ), and both sides are 0.
: if , then , and each is an elementary matrix of the same kind with the same determinant. Singular has singular (same rank).
Linearity in one row
Fix all rows except row . Then det is a linear function of row :
This is easy to see from cofactor expansion along row : , and the cofactors do not involve row at all. It does not make det linear in the whole matrix; that is why .
In software
- Jacobian determinants. For a non-linear map, the local area/volume scale factor is the determinant of its Jacobian matrix. It is the factor in the change-of-variables formula for integrals (Jacobian and Hessian), it tells a texture sampler how much a pixel's footprint is stretched, and in normalizing flows the multiplicativity turns the log-density of a stack of layers into a sum of per-layer log-determinants.
- Physics simulation. In finite-element and cloth/soft-body solvers, each element has a deformation gradient ; is its volume ratio. means incompressible (rubber, flesh), and means the element has been turned inside out, a numerical failure that robust solvers detect and repair.
- Transform chains in games. The determinant of a model matrix is the product of those of its parts. One negative scale anywhere in a hierarchy makes the final determinant negative, and the renderer must flip triangle winding (Transform Hierarchies).
import numpy as np
def rot(deg):
t = np.radians(deg)
return np.array([[np.cos(t), -np.sin(t)], [np.sin(t), np.cos(t)]])
parent = np.diag([2.0, 2.0]) # scale x2: area x4
child = np.diag([-1.0, 1.0]) @ rot(30) # mirrored and rotated: det -1
world = parent @ child
print("det parent, child:", round(float(np.linalg.det(parent)), 6), round(float(np.linalg.det(child)), 6))
print("det world:", round(float(np.linalg.det(world)), 6), "-> negative: flip the culling mode")det parent, child: 4.0 -1.0
det world: -4.0 -> negative: flip the culling mode
Exercises
Exercise 1: Use the rules
and are with and . Find , , , and .
Answer
−10, , 2, −135, 2.
Solution
Exercise 2: No square roots of
Show there is no real matrix with .
Answer
but .
Solution
. If then , impossible for a real number . (In , , and indeed the rotation satisfies .)
Exercise 3: Linearity in a row
Given and , find without expanding.
Answer
−11.
Solution
The second row , and row 1 is the same in all three matrices, so by linearity in row 2: . Check: ✓.
Exercise 4: Orthogonal matrices
Generate a random orthogonal matrix in NumPy with a QR factorisation of a seeded random matrix and check that .
Answer
up to rounding.
Solution
QR factorisation writes any matrix as with orthogonal, and orthogonal matrices satisfy .
import numpy as np
rng = np.random.default_rng(4)
Q, _ = np.linalg.qr(rng.normal(size=(4, 4)))
print(np.allclose(Q.T @ Q, np.eye(4)), round(abs(float(np.linalg.det(Q))), 10))True 1.0
Test yourself
and (both ). What is ?
- 2
- 4.5
- 8
Which identity is FALSE in general?
In a soft-body simulation, an element's deformation gradient has . What happened?
- It shrank to 30% volume
- It was turned inside out
- It is perfectly incompressible
- Nothing unusual