In the history of linear algebra, one fact looks anomalous: the early study of determinants came before the systematic development of matrix algebra in the mid-nineteenth century.
Determinants were at first closely tied to elimination and to simultaneous equations. Mathematicians studied how the coefficients combine and permute, and gradually turned an operation that originally served equation solving into an algebraic object in its own right.
At the end of the seventeenth century, Seki Takakazu and Leibniz each studied early forms of the determinant in problems of elimination and of equations. Their work was not yet the complete theory of determinants of arbitrary order that we have today, but it shows a similar motivation: how can the structure of a system of equations be read off from combinations of its coefficients?
In the eighteenth century, the work of Maclaurin, Cramer, and others further connected determinants of the coefficients with the solutions of linear equations. Today’s Cramer’s rule states this relationship with particular clarity: when the coefficient matrix is invertible, each unknown can be expressed as a ratio of determinants.
In the nineteenth century, the determinant gradually became a systematic algebraic theory. The work of Cauchy and others established and developed basic tools such as the multiplicative property ; the connections among multilinearity, the sign change when two rows are exchanged, and the sign of a permutation also gave a unified structure to expansions that look intricate.
This winding history tells us that the most central modern geometric meaning of the determinant—the signed factor by which a linear transformation scales higher-dimensional volume—was not its historical starting point; it is a deeper essence that later generations recognized only through a long look back. Chapter 3 already introduced the effect of the determinant on area and volume intuitively in two and three dimensions (Definition 10).
The task of this chapter is to raise this geometric intuition to a rigorous axiomatic theory: starting from multilinearity and the alternating property, we extend the determinant to arbitrary -dimensional spaces, derive its Laplace expansion, the adjugate matrix, and its characteristic rules of computation, and forge the heavy algebraic machinery that is indispensable for the theory of eigenvalues and eigenvectors in Chapter 8.
Chapter Structure and Learning Objectives¶
The determinant can be defined from two entirely different angles, and the two eventually shake hands on the same formula—this tension is the core of §7.1. The permutation definition starts from the Leibniz formula and gives an explicit computational formula; the axiomatic definition goes the other way, starting from three geometric properties (multilinearity, the alternating property, normalization) and deriving the uniqueness of this formula. Each definition has its strengths: the former is convenient for computation, while the latter reveals the essence. Understanding the relationship between the two is the first step toward mastering the theory of determinants.
With the definitions in place, §7.2 builds the tools for computing determinants. Cofactor expansion (Laplace expansion) reduces a determinant of order recursively to smaller determinants and is a powerful tool for theoretical derivations; Gaussian elimination offers a far more efficient path in actual computation; and the Vandermonde determinant, with its elegant formula as “the product of all the differences,” serves as the theoretical high point of the section.
§7.3 turns to applications. Cramer’s rule, the protagonist of §7.3.1, shows how determinants solve systems of equations elegantly—although it is not the best choice for numerical computation, it is indispensable in theoretical analysis. §7.3.2 and §7.3.3 return to geometry and formally establish the determinant’s identity as the “volume scale factor”: the determinant is the signed volume scale factor, and its absolute value is the ordinary volume scale factor; in the nondegenerate case its sign records whether orientation is reversed. This viewpoint not only deepens geometric intuition but also prepares for understanding the geometric meaning of eigenvalues in Chapter 8. §7.4 closes the chapter with a Python implementation, using NumPy and a cofactor expansion function of our own to translate the theory of this chapter into code that can be executed and verified. Chapter 8 will use the characteristic polynomial as the junction (see Definition 2), formally connecting the theory of determinants in this chapter to the theory of eigenvalues.
After reading this chapter, you will see how a number born from the leftover scraps of equation solving became, after two centuries of refinement, one of the most central tools of linear algebra.
7.1 Definition and Properties of the Determinant¶
This section discusses two different definitions of the determinant, together with some commonly used important properties.
7.1.1 The Permutation Definition of the Determinant¶
In Definition Definition 2 we defined the sign . But in building the foundations of linear algebra and group theory there is a deep question: when a permutation is written as a product of transpositions, is the parity of the number of transpositions well-defined?
If we decompose a permutation into a number of basic transpositions (each exchanging two elements), the decomposition is clearly not unique. Yet however it is decomposed, the parity of the number of transpositions never changes—that is, a permutation can never be generated both by an even number of transpositions and by an odd number of transpositions. This guarantees that the sign of a permutation does not depend on any particular sequence of operations.
Mathematically, the most elegant and powerful way to prove this well-definedness is to construct a group homomorphism by means of the Vandermonde difference-product polynomial.
Click to expand: complete proof of the sign homomorphism and the parity theorem (Vandermonde difference-product method)
Consider the difference-product polynomial in variables (this structure will reappear in the Vandermonde determinant theorem Theorem 16):
1. Action of a permutation on the polynomial. For any permutation , define its action on the subscripts of the variables:
Since is a bijection from to itself, the unordered index pairs run through all two-element subsets exactly once. Hence the set of factors in the numerator is the same as that of , except that some factors may change sign because . It follows that:
Moreover, the number of factors in the product with (that is, the factors that change sign) is exactly the number of inversions , so follows directly.
2. The homomorphism property (purely algebraic cancellation). For any two permutations , the action of the composite permutation on the polynomial satisfies . Therefore:
These two lines of algebraic cancellation directly prove that is a genuine group homomorphism.
3. A transposition always changes the sign. Consider the simplest adjacent transposition . In the difference product , only the factor becomes ; all the other factors involving or can be paired off, and their signs are unchanged. Therefore:
Since any transposition can be written as a composition of an odd number of adjacent transpositions (specifically of them), the homomorphism property gives for every transposition .
Conclusion. If a permutation can be decomposed as a product of transpositions , then:
Since the value of the sign on the left is uniquely determined by , the parity of the number of factors is absolutely unique modulo 2: the permutation cannot be expressed both as a product of an odd number of transpositions and as a product of an even number of transpositions.
With a consistent, well-defined sign , we can use the Leibniz formula with confidence, and be sure that when determinants are later computed by elementary column/row exchanges, the result does not depend on the reduction path.
Compute the number of inversions and the sign of the permutation with (that is, ).
Step 1. Run through all index pairs with . For there are pairs:
: ✓ (an inversion)
: ✓ (an inversion)
: ✗ (in the correct order)
Step 2. Count the inversions and determine the sign: The number of inversions is . Since 2 is even, is an even permutation, and its sign is:
import itertools
def count_inversions(sigma):
"""Compute the number of inversions, the sign, and the inversion pairs of the permutation sigma"""
n = len(sigma)
inv = 0
pairs = []
for i in range(n):
for j in range(i + 1, n):
if sigma[i] > sigma[j]:
inv += 1
pairs.append((i, j))
sgn = (-1) ** inv
return inv, sgn, pairs
# Check the permutation sigma = (2, 0, 1) from the example
sigma = (2, 0, 1)
inv, sgn, pairs = count_inversions(sigma)
print(f"Permutation sigma = {sigma}:")
print(f" inversion pairs: {pairs}")
print(f" number of inversions inv(sigma) = {inv}")
print(f" sign sgn(sigma) = {sgn} ({'even permutation' if sgn == 1 else 'odd permutation'})")
print("\nAll 6 permutations in S_3 and their signs (corresponding to the 6 terms of the rule of Sarrus):")
for p in itertools.permutations(range(3)):
inv_p, sgn_p, _ = count_inversions(p)
parity_str = "+1 (even, main-diagonal direction)" if sgn_p == 1 else "-1 (odd, antidiagonal direction)"
print(f" permutation {p} -> inv={inv_p}, sgn = {parity_str}")
The square-matrix function defined by the Leibniz formula satisfies the following three core algebraic properties:
Normalization at the identity: the determinant of the identity matrix is 1, that is, .
Alternating in the rows: exchanging any two rows of a matrix changes the sign of the determinant. That is, if the matrix is obtained from the matrix by exchanging row and row (), then .
Multilinear in the rows: the determinant is a linear function of each row of the matrix. That is, if the other rows are held fixed and only row is taken to be a linear combination of vectors , then the determinant expands linearly in the same way:
Normalization at the identity. For the identity matrix , the entries are (1 when and 0 otherwise). For the product term to be nonzero, we must have for every . Hence, among all permutations, only the identity permutation makes a nonzero contribution, and . Therefore:
Alternating in the rows. Let the matrix be obtained from by exchanging row and row . This means that , where is the transposition that exchanges the indices and .
For each permutation , consider the product term .
Since multiplication of real numbers is commutative, the factors of the product can be reordered arbitrarily. Let the new index be (since is a bijection, also runs through all of 0 to ), so that ; hence:
Define the new permutation . By the homomorphism property of the sign of a permutation and the fact that a transposition changes the sign, , that is, .
As runs through , also runs through the entire symmetric group , each element exactly once. Therefore:
Multilinear in the rows. Suppose row of the matrix is a linear combination of two vectors, with entries , and its other rows () are exactly the same as those of and . In each product term of the Leibniz formula, the row- entry appears exactly once:
Substituting this into the sum and splitting the terms, we immediately obtain:
7.1.2 The Axiomatic Definition of the Determinant¶
In §7.1.1 we started from the Leibniz formula of the permutation definition and verified that it satisfies three properties: normalization at the identity, the row-alternating property, and multilinearity in the rows. Mathematicians later discovered a deeper viewpoint: these three properties are not merely consequences of the Leibniz formula; conversely, they can even serve as “axioms”—among all functions, the determinant is the only one that satisfies all three requirements at once!
This is the axiomatic definition of the determinant (also called the Weierstrass axioms). The axiomatic method frees the determinant from tedious combinatorial computation with terms and lets us focus on its geometric and algebraic essence.
The determinant is the square-matrix function satisfying the following three basic properties/axioms; we also say that the determinant is an alternating multilinear function:
Identity property: the determinant of the identity matrix is 1, that is,
Row-alternating property: exchanging two rows of a matrix changes the sign of the determinant; that is, if the matrix is obtained from the matrix by exchanging two rows, then
Multilinear property: the determinant is a linear function of any one row of the matrix, that is:
Additivity: if are identical except in row , and , then
Homogeneity under scalar multiplication: if the matrix is obtained by multiplying row of the matrix by a scalar , then
These three axioms completely determine the determinant function. Axiom 1 “anchors” the determinant at the identity matrix, while Axioms 2 and 3 describe how the determinant changes as the matrix changes. Starting from these three axioms, all other properties of the determinant can be derived, including the familiar formulas for computing determinants. This axiomatic approach is elegant and powerful: it lets us concentrate on the essential features of the determinant rather than on computational details. On this foundation, we can understand more deeply how the determinant is related to linear transformations, changes in volume, and the invertibility of matrices.
7.1.3 Basic Properties Derived from the Axioms¶
From a few basic principles, many important properties of the determinant can be derived.
If a matrix has a row consisting entirely of zeros, then .
Suppose row of the matrix is the zero vector. Consider multiplying row of by an arbitrary scalar ; by the homogeneity of the determinant under scalar multiplication, .
But since row is entirely zero, it is still zero after multiplication by any scalar , that is, , so .
Combining the two equalities above, we have for every ; the only way this can hold is .
The zero-row property is closely related to the rank of a square matrix: a matrix with a zero row is necessarily not of full rank, and its determinant is zero.
If a matrix has two identical rows, then .
Suppose row and row of the matrix are identical (). Exchanging these two rows gives a matrix . By the row-alternating property, .
But since row and row are identical, the matrix does not actually change after the exchange, that is, ; therefore .
The only way this equality can hold is .
We may use the identical-rows property in place of the row-alternating property as one of the initial basic properties. The elementary row operation properties below embody the alternating nature of the determinant and are also directly linked to linear dependence: a matrix with linearly dependent rows has determinant zero.
If “a matrix with two identical rows has determinant zero” is taken as a basic property (axiom), then together with the multilinear property it implies that exchanging two rows of a matrix changes the sign of the determinant.
Let row of the matrix be the vector and row be the vector , with the remaining rows fixed. Exchanging rows and gives a matrix , that is, , .
For convenience of writing, we introduce the following notation: let denote “the matrix that is identical to except in rows and , with row equal to and row equal to .” Then:
Construct the matrix , whose rows and are both , with the other rows unchanged. By the identical-rows property, this matrix has two identical rows, so:
Decompose row of the expression above additively (multilinear property):
Then decompose row of each term additively (multilinear property):
Note that and each have identical rows and , so by the identical-rows property:
Substituting all of the above into the equality of step 1, we obtain:
Therefore , that is, exchanging rows and changes the sign of the determinant.
The determinant behaves as follows under elementary row operations:
Exchanging two rows: the determinant changes sign
Multiplying a row by a nonzero constant : the determinant is multiplied by
Adding a constant multiple of one row to another row: the determinant is unchanged
The first two are direct applications of the axioms. For the third, let the matrix be obtained from the matrix by adding times row to row . Let denote row of ; then row of is .
By linearity in the rows:
Here is the matrix obtained from by replacing row with row . This matrix has two identical rows (row and row ), so by Theorem Theorem 3, .
Therefore , that is, under this kind of row operation the determinant .
This theorem is crucial for understanding and computing determinants; it is also the theoretical basis for computing determinants by Gaussian elimination.
The determinant of a permutation matrix is . Moreover, for any square matrix of the same size,
A permutation matrix is a square matrix in which every row and every column contains exactly one 1 (a one-to-one correspondence between rows and columns), and all other entries are 0. A permutation matrix can be obtained from the identity matrix by a sequence of row exchanges.
Decomposition of a permutation matrix. Any permutation matrix can be obtained from the identity matrix by a sequence of row exchanges. Let the number of these row exchanges be , that is, , where each is the elementary matrix corresponding to one row exchange.
Consider the permutation matrix acting on the identity matrix: we have
By the assumption that a row exchange changes the sign, the determinant of the final result of applying a sequence of row exchanges to the identity matrix is , so . (Note: the well-definedness of —that the parity of the number of exchanges does not depend on the decomposition—is precisely the parity theorem proved in §7.1.1 (Well-Definedness of Permutation Parity: An Algebraic Approach); the axiomatic derivation here relies on that fact.)
For the second conclusion, note that amounts to performing a sequence of row exchanges on , so .
A square matrix that is not of full rank has determinant zero.
Since the square matrix is not of full rank, Gaussian elimination (Theorem 5), which changes the determinant by at most a sign (elimination leaves it unchanged, a row exchange changes its sign), yields a matrix whose last row is entirely zero. By Theorem 2, that matrix has determinant zero, so the original square matrix .
If Gaussian elimination gives a square matrix the decomposition , then
First, since , we have .
Since is a combination of multiple row eliminations, , and hence .
The determinant of an upper triangular square matrix is the product of its diagonal entries. Similarly, the determinant of a lower triangular square matrix is also the product of its diagonal entries.
Suppose all diagonal entries of the upper triangular matrix are nonzero. Using Gaussian elimination (Theorem 5)—row eliminations do not change the determinant—we obtain a diagonal matrix with the same determinant, which has the same diagonal entries as the original matrix and zeros everywhere else.
Then, by Axiom Axiom 1, the determinant of that matrix is .
If the upper triangular matrix has a zero diagonal entry, then by the discussion at the end of Chapter 5 the matrix is not invertible, and by the discussion of Gaussian elimination and echelon matrices in Chapter 6 it is not of full rank, so .
By the same reasoning, together with Theorem 9, we see that a square matrix of full rank .
Under the axiomatic system, the definition of the determinant is unique. The axiomatic definition and the permutation definition are exactly the same.
Every square matrix has a decomposition. By Theorem 9 and Theorem 8, we can compute under the three axioms, and .
The question is whether some other
PLUdecomposition could give a different . We now consider the determinant given by the permutation definition. This definition is clearly global and unique, and it is easy to check from the permutation definition that .By Theorem 1 and Definition 2, we conclude: .
The determinant of a product of square matrices is the product of their determinants:
If or is not of full rank, then is not of full rank either, so both sides are zero and the equality holds. From now on, assume that and both have full rank.
First proof (PLU decomposition)
Let , where is a permutation matrix, is a unit lower triangular matrix, and is an upper triangular matrix.
Further decompose as a composition of row scalings and row eliminations; the effect of each operation on the determinant is listed in Theorem 5.
Therefore:
.
Second proof (uniqueness of the determinant)
Fix a full-rank matrix and define the function ; we verify the three axioms of the determinant for it:
Identity. .
Identical-rows property. If has two identical rows, then the corresponding two rows of are also identical, so and hence . By Theorem 4, the identical-rows property together with multilinearity already implies the row-alternating property, so satisfies the alternating condition required by the three axioms.
Multilinearity. Suppose differs from only in row , with . Then , and the multilinearity of the determinant gives , where is the matrix obtained from by replacing row with .
By Theorem 10, the function satisfying these three axioms is unique, so .
.
Basic problem
If is an block upper triangular matrix:
where is a matrix and is an matrix, use the PLU decomposition to prove that
Extension: a second proof of the multiplicative property using block matrices
Let both be matrices of full rank, and consider the block matrix:
Using the result of the basic problem, compute in terms of and .
Multiply on the left by the block lower triangular matrix , compute the product, and explain why this operation does not change the value of the determinant.
Perform row exchanges on the resulting product (exchanging row with row in turn, ) to bring it to the form
Explain why each row exchange changes the sign of the determinant and how the sign changes after exchanges, and use this to compute the determinant of this matrix.
Combining the steps above, derive .
Solution to Exercise 1
Basic problem
Following the convention of Chapter 6, let (). Then:
Since , the determinant can be computed with the rules for permutations, row additions, and triangular matrices. The three factors are a block permutation matrix, a block unit lower triangular matrix, and a block upper triangular matrix, with determinants , 1, and respectively, so:
Extension
Step 1. By the basic problem, .
Step 2.
This left multiplication amounts to adding linear combinations of the rows of the upper half to the corresponding rows of the lower half; it uses only row additions, which do not change the determinant, so there is no need to use in advance the multiplicative property that is to be proved. The resulting determinant is still .
Step 3. In , exchange row with row in turn (). These are exchanges of nonadjacent rows, each changing the sign once, so the whole is multiplied by , giving:
Then, by the basic problem: .
Step 4. Combining the above,
Hence .
The product formula for block upper triangular determinants proved in the basic problem also makes good on the unproved assertion in the property box of Chapter 5. It is only one block elimination away from proving the Schur complement determinant formula stated at the beginning of Chapter 5:
Let the block matrix have invertible. Then
where is precisely the Schur complement introduced in §5.3.2 of Chapter 5.
Multiply on the left by a block unit lower triangular matrix to perform block elimination:
The first factor on the left is a block unit lower triangular matrix. Applying the basic problem of Exercise 1 to its transpose (or repeating the same argument for the lower triangular case), its determinant is ; by the product theorem Theorem 11, multiplying on the left by it does not change the determinant.
Applying the basic problem of Exercise 1 once more to the block upper triangular matrix on the right, we obtain
If the matrix is invertible, then:
Consider the composition of a rotation matrix and a scaling matrix:
Compute their determinants: (rotation preserves area) (scaling multiplies area by )
Compute the determinant of the composite transformation:
This shows that the composite transformation that first scales and then rotates multiplies area by , the same effect as the scaling alone, because rotation does not change area.
The determinant has an important symmetry property: a matrix and its transpose have equal determinants. Transpose invariance lets us choose freely whether to compute and analyze determinants by rows or by columns; choosing the direction with more zero entries simplifies the computation.
For a square matrix , .
Consider the PLU decomposition . Then and . Since and , and are still triangular matrices, we have
This property shows that every property of the determinant concerning rows applies equally to columns. For example:
Exchanging two columns changes the sign of the determinant.
Multiplying a column by a nonzero constant multiplies the determinant by that constant.
Adding a constant multiple of one column to another column leaves the determinant unchanged.
A matrix with a zero column or with linearly dependent columns has determinant zero.
§7.1 answers the fundamental question of what the determinant “is,” and gives one and the same answer in two strikingly different languages. The permutation definition starts from the Leibniz formula and defines explicitly as the sum of the sign-weighted products over all permutations; the axiomatic definition instead constrains a square-matrix function by three geometric properties (normalization, the row-alternating property, multilinearity) and then derives its form. The equivalence and uniqueness of the two definitions (Theorem Theorem 10) is the deepest conclusion of this section: the determinant is both a rule of computation and a logical necessity of geometric properties—two different roads that lead to the same destination.
With the axioms as tools, §7.1.3 systematically derives a chain of basic properties—the zero-row and identical-rows properties, the rules for elementary row operations, the determinant of a permutation matrix, and finally two proofs of the product theorem. The second proof of the product theorem is especially elegant: it constructs a new function , verifies that it satisfies the three axioms, and then invokes the uniqueness theorem directly to conclude that , displaying the self-consistent power of the axiomatic method. Transpose invariance further breaks down the barrier between row operations and column operations, so that every row property holds for columns as well. These properties will become the theoretical basis for computing determinants in §7.2.
7.2 Methods for Computing Determinants¶
This section introduces several commonly used methods for computing determinants.
Let be an matrix:
Minor: is the determinant of the matrix obtained by deleting row and column
Cofactor:
The signs of the cofactors form a checkerboard pattern:
The sign is positive when is even and negative when is odd.
We prove the case of expansion along row . The case of expansion along a column can be proved by using and applying the row expansion.
Using the multilinearity of the determinant
Select row of the matrix and express it as a linear combination of standard basis vectors:
where is the row vector with 1 in position (counting from 0) and 0 in all other positions.
By the multilinear property of the determinant, we have:
where is the matrix obtained by replacing row of with .
Analyzing
The distinctive feature of is that every entry of row is 0 except the entry in column , which is 1. This allows us to simplify it by a sequence of elementary row operations.
For every with , we can subtract times row from row , so that every entry of column other than the one in row becomes 0. These row operations do not change the value of the determinant.
Computing with the properties of the determinant
After these operations, the rows and columns of can be rearranged so that row and column move to the first position. This involves row exchanges and column exchanges, exchanges in all, which introduces the factor .
After the rearrangement, the matrix has the following form:
where is the submatrix obtained by deleting row and column of the original matrix .
By the properties of the determinant, the determinant of the matrix above equals .
Taking into account the sign factor introduced by the operations and the rearrangement, we have:
Conclusion
Substituting the result of the third step into the expression from the first step:
This is the cofactor expression for the expansion along row . The case of expansion along column is proved in the same way.
Cofactor expansion gives us a recursive method for computing determinants that is especially suitable for sparse matrices with many zero entries. When computing the determinant of a large matrix, choosing the row or column with the most zero entries for the expansion can reduce the amount of computation significantly. For dense matrices, however, cofactor expansion has computational complexity and is not efficient in practice.
In practice, determinants are usually computed via the PLU decomposition (see §6.3.4 and Theorem 4; for the determinant formula see Theorem 8): decompose the square matrix as ; then
where ( is the number of row exchanges) and is the product of the diagonal entries of the upper triangular matrix; the overall complexity is only . NumPy’s np.linalg.det uses exactly this method.
Compute the determinant of the matrix .
Expand along row 1 (counting from 0; it contains a 0 entry):
Therefore .
Consider the entry of the product :
When , this is precisely the Laplace expansion along row :
When , construct the matrix by replacing row of with row , leaving the other rows unchanged. Then has two identical rows, so by the identical-rows property. On the other hand, in the Laplace expansion of along row , the cofactors are exactly the same as the row- cofactors of (the two matrices agree everywhere outside row ), so:
Combining the two cases, . A similar argument by columns for (or applying the same conclusion to and then transposing) gives the other equality.
When , dividing both sides by gives .
Cofactor expansion is not only a practical method for computing determinants; it also connects the determinant with concepts such as the inverse matrix and the solutions of systems of linear equations, revealing the deep unity of the internal structure of linear algebra.
By Theorem Theorem 5, we can reduce a matrix to a triangular matrix by elementary row operations and then compute the determinant as the product of its diagonal entries.
Compute the determinant of the matrix .
Solution. Use row operations, keeping track of their effect on the determinant:
Step 1. Eliminate the entries below the pivot in column 0 (with as the pivot)
Subtract times row 0 from row 1 (determinant unchanged)
Subtract times row 0 from row 2 (determinant unchanged)
Step 2. Eliminate the entry below the pivot in column 1 (with as the pivot)
Subtract times row 1 from row 2 (determinant unchanged)
Check. ✓
Step 3. Read off the product of the diagonal entries
The matrix is now upper triangular, so the determinant equals the product of the entries on the main diagonal:
Therefore .
Remark. Verification by Laplace expansion (along row 0):
The Vandermonde matrix is extremely important in modern mathematics and its applications: it appears in polynomial interpolation, the fast Fourier transform (the DFT matrix is a special Vandermonde matrix), the physical theory of the quantum Hall effect, and the theory of BCH codes and Reed–Solomon error-correcting codes. Here we prove this important mathematical property directly by fairly elementary mathematical induction; another common proof uses the factorization of polynomials from abstract algebra.
We prove this theorem by mathematical induction.
Base case.
When :
The product on the right has no index pairs satisfying , so it is an empty product, whose value is defined to be 1. Hence the equality holds.
When :
The right-hand side is:
The equality holds.
Induction hypothesis.
Suppose the theorem holds for the Vandermonde determinant of order , that is:
Inductive step.
Consider the Vandermonde determinant of order :
Perform column operations on the matrix. For (from right to left), subtract times column from column :
For row (), the entry in column becomes:
The transformed matrix is:
Use row 0 (that is, ) to perform row elimination on rows (subtracting row 0 from each of them), which clears the remaining entries of column 0 to zero; by Theorem 5, the determinant is unchanged.
Then, by the multilinear property, factor out the common factor from row ():
Expanding by cofactors along row 0:
The determinant on the right is exactly . By the induction hypothesis:
Therefore:
By mathematical induction, the theorem is proved.
We close this section with three computational exercises covering cofactor expansion, reduction to triangular form by elementary operations, and a numerical check of the Vandermonde formula. When Chapter 8 expands the characteristic polynomial , these hand-computation skills will come into play directly.
Compute the determinant of the matrix :
by expansion along row 0;
by expansion along column 1;
and verify that the two results agree. (Hint: pay attention to the checkerboard of signs .)
Solution to Exercise 2
Use elementary row operations to reduce the matrix to upper triangular form, and compute
Solution to Exercise 3
Step 1. With as the pivot, eliminate the other entries of column 0 (elimination does not change the determinant): , , giving
Step 2. With as the pivot: , , giving
Step 3. With as the pivot: , giving an upper triangular matrix with diagonal entries .
Check. ✓
Step 4. By Theorem 9, the determinant is the product of the diagonal entries:
Take the nodes :
compute the product formula by hand;
build the Vandermonde matrix with
np.vander(x, increasing=True)and verify the result withnp.linalg.det.
Solution to Exercise 4
By hand. The product of the six differences is
Numerical verification.
import numpy as np
x = np.array([1., 2., 4., 7.])
V = np.vander(x, increasing=True)
print(np.linalg.det(V)) # 540.0000000000002The floating-point result 540.0000000000002 agrees with the formula value 540; the tiny discrepancy comes from rounding error (see §7.4.1).
§7.2 answers the question of “how to compute” the determinant, offering three computational paths, each with its own emphasis. The Laplace expansion (Theorem Theorem 14) reveals the recursive structure of the determinant: a determinant of order can be expanded as a weighted sum of determinants of order , and choosing the row or column with the most zero entries greatly reduces the amount of computation; the adjugate matrix also emerges naturally in this framework, as a closed-form theoretical expression for the inverse matrix. The elementary row operation method is the workhorse of actual computation: using the elementary operation properties of §7.1.3, one reduces the matrix to upper triangular form and then only needs to multiply the diagonal entries, which lowers the complexity from to .
The Vandermonde determinant (Theorem Theorem 16) serves as the theoretical high point of this section: its value equals the product of all the differences , and the proof by mathematical induction is both rigorous and beautiful. This result has direct applications in polynomial interpolation, the fast Fourier transform (the DFT matrix is a special Vandermonde matrix), and Reed–Solomon error-correcting codes, and it foreshadows a deeper connection between determinants and the theory of polynomials. The core difference among the three methods lies not in correctness but in efficiency and range of application; understanding their division of labor is a prerequisite for §7.3, which applies determinants to geometric problems and to systems of equations.
7.3 Applications of the Determinant¶
7.3.1 Solving Systems of Equations¶
Consider the system of linear equations , where is an invertible matrix. Let be the matrix obtained by replacing column of with . Then the solution is:
Elegant as Cramer’s rule is in theory, it is very inefficient in actual computation. For an system, determinants must be computed; if each is computed by cofactor expansion, the computational complexity is , and even if these determinants are computed separately with PLU, a direct implementation still needs . By comparison, Gaussian elimination has complexity of only . Cramer’s rule is therefore used mainly for theoretical derivations and small problems.
Solve the system of linear equations by Cramer’s rule:
Solution to Exercise 5
7.3.2 Geometric Applications of the Determinant¶
The determinant has rich applications in geometry, especially in computing areas and volumes.
We first prove that the determinant is invariant under a change of basis. In §4.2 (Definition 11) we discussed the following: suppose the matrix representations of a linear transformation with respect to two different bases are and . By the theory of change of basis, there exists an invertible matrix (the change-of-basis matrix) such that , and by the multiplicative property of the determinant, clearly . This shows that the geometric quantities we discuss next are all independent of the choice of basis.
Let be an matrix whose column vectors span an -dimensional parallelepiped in . Then the (-dimensional) volume of this parallelepiped is . Equivalently, the linear mapping maps the unit hypercube onto this parallelepiped, and its volume scale factor is exactly .
Let be the signed volume of the parallelepiped spanned by the edge vectors (in two and three dimensions, this is the signed area/volume introduced in Chapter 3, Definition 10; in general dimension the notion of volume is accepted here as a geometric postulate, since a rigorous construction requires measure theory). Geometrically, signed volume satisfies the three axioms of the determinant: the unit hypercube has volume 1; exchanging two edge vectors reverses orientation and therefore changes the sign; and, with the other edge vectors held fixed, the volume is linear in each edge vector (scaling one edge scales the volume, and additive decomposition corresponds to shearing and reassembling with “the same base and heights that add”).
By Theorem 10, the function satisfying the three axioms is unique (the three axioms were originally stated for rows, but by transpose invariance Theorem 13 they hold equally for columns), so , and taking absolute values gives the volume.
In particular, for we return to the following formulas, already seen with the cross product in Chapter 2 (Theorem 2) and in the geometric introduction of Chapter 3; they are low-dimensional special cases of the theorem above.
In , the area of the parallelogram spanned by the vectors and is:
In , the volume of the parallelepiped spanned by the vectors is:
Given three points in the plane , , , the area of triangle is:
This formula can be understood by viewing the triangle as half of the parallelogram spanned by the two vectors and drawn from the vertex .
7.3.3 Applications of the Determinant in Calculus¶
Let be a one-to-one mapping on an open set whose Jacobian determinant (with defined below) is nonzero everywhere on . Let be a measurable region of integration, let , and let be integrable on . Consider the change of variables from to :
The Jacobian matrix is defined as:
The full change-of-variables identity is . Correspondingly, the volume element is written as:
The geometric meaning of Theorem Theorem 21 extends directly from the understanding of volume scaling in §7.3.2.
Under the linear mapping , Theorem Theorem 18 has already shown that a unit parallelepiped with edges has its volume scaled by a factor of exactly under the action of .
For a nonlinear mapping , take the first-order approximation near the point :
Locally, the mapping behaves like the linear mapping . Hence the volume of the image of a tiny volume element under the mapping is determined by the scale factor of the local linear approximation.
This is precisely the geometric foundation of the change-of-variables formula for multiple integrals: a change of variables in an integral is not a game played with algebraic symbols; it makes a local linear approximation on every tiny volume element and then uses the determinant to record this local scaling.
A rigorous proof involves details of multivariable integration and analysis that are beyond the scope of this book; a more general version can be handled with measure theory. Interested readers may consult a multivariable calculus text (such as Spivak, Calculus on Manifolds).
The transformation from polar coordinates to Cartesian coordinates :
In this example we take and let the angle range over an open interval of length , so that no point is covered twice; the origin and the seam in the angle can be treated as a boundary of measure zero.
Jacobian matrix:
Jacobian determinant:
Therefore:
This is the area element in polar coordinates that we use in calculus.
§7.3 answers the question of what the determinant “can do,” turning from algebraic tool to geometric language. Cramer’s rule (Theorem Theorem 17) expresses the solution of a system of linear equations in closed form: each unknown equals a ratio of two determinants, whose numerator is the determinant of the matrix obtained by inserting into column of . This formula is irreplaceable in theoretical analysis, but it is extremely inefficient for large systems (computing each determinant by cofactor expansion takes ; computing them separately with PLU takes ); its value lies in revealing, through a symbolic expression, how the solution depends on the coefficients, not in numerical computation.
On the geometric side, the determinant describes the signed volume scale factor, and its absolute value describes the ordinary area or volume scale factor; in the nondegenerate case its sign records whether orientation is reversed. A change of basis does not change the determinant (§7.3.2), which shows that this scale factor is an intrinsic invariant of the linear transformation, independent of the choice of coordinates. The Jacobian determinant (Theorem Theorem 21) extends the idea of scaling to the local linearization of nonlinear mappings: the ratio of volume elements is given exactly by the determinant of the Jacobian matrix, and this is the geometric foundation of the change-of-variables formula for multiple integrals. Together, the three applications establish the geometric identity of the determinant as a “volume scale factor” and lay the groundwork for the geometric meaning of eigenvalues in Chapter 8.
7.4 Computing Determinants in Python¶
In Python, determinants can be computed efficiently with the NumPy library.
7.4.1 Computing Determinants with NumPy¶
import numpy as np
# Define a matrix
A = np.array([[1, 2, 3],
[4, 5, 6],
[7, 8, 9]])
# Compute the determinant
det_A = np.linalg.det(A)
print(f"Determinant: {det_A}")
# Check whether the determinant is close to zero at a given absolute threshold; this is not an exact test of singularity
print(f"Close to zero at absolute threshold 1e-10: {np.abs(det_A) < 1e-10}")
# Create a nonsingular matrix
B = np.array([[2, 1, 3],
[1, 2, 1],
[3, 1, 4]])
# Compute the determinant
det_B = np.linalg.det(B)
print(f"Determinant: {det_B}")This example shows that the matrix A is singular (in fact because its row vectors are linearly dependent: row 2 = 2 × row 1 − row 0), while the matrix B is not singular.
When determinants are computed numerically, rounding errors may cause some determinants that are theoretically zero to come out as very small nonzero values. A fixed absolute threshold can only indicate that a determinant is close to zero at that scale; it cannot decide exact singularity. For example, the invertible matrix has determinant 10-12. To estimate the numerical rank, use the SVD-based np.linalg.matrix_rank and state the tolerance relative to the largest singular value and the size of the matrix; exact singularity must be decided by exact algebraic relations.
7.4.2 Implementing the Cofactor Expansion Algorithm¶
Below we implement our own function that computes the determinant by cofactor expansion:
import numpy as np
def determinant_cofactor(A):
"""
Compute the determinant by cofactor expansion
Parameters:
A -- NumPy array representing a square matrix
Returns:
the determinant of the matrix A
"""
A = np.asarray(A)
if A.ndim != 2 or A.shape[0] != A.shape[1]:
raise ValueError("A must be a square matrix")
n = A.shape[0]
if n == 0:
return 1
# Base case: 1x1 matrix
if n == 1:
return A[0, 0]
# Base case: 2x2 matrix
if n == 2:
return A[0, 0] * A[1, 1] - A[0, 1] * A[1, 0]
# Expand along row 0 (0-based indexing)
det = 0
for j in range(n):
# Compute the minor matrix (delete row 0 and column j)
minor = np.delete(np.delete(A, 0, axis=0), j, axis=1)
# Compute the cofactor and accumulate
cofactor = (-1) ** (0 + j) * determinant_cofactor(minor)
det += A[0, j] * cofactor
return det
# Test
A = np.array([[2, 1, 3],
[1, 2, 1],
[3, 1, 4]])
print(f"Determinant by cofactor expansion: {determinant_cofactor(A)}")
print(f"Determinant by NumPy: {np.linalg.det(A)}")
# Term-by-term comparison: the cofactor and the contribution of each j in the expansion along row 0
print("\nTerm-by-term breakdown of the expansion along row 0:")
for j in range(A.shape[1]):
minor = np.delete(np.delete(A, 0, axis=0), j, axis=1)
cofactor = (-1) ** (0 + j) * determinant_cofactor(minor)
print(f" j={j}: a_0{j} = {A[0, j]:.0f}, C_0{j} = {cofactor:+.0f}, contribution = {A[0, j] * cofactor:+.0f}")Our implementation agrees with NumPy’s result, but for large matrices the recursive cofactor expansion is inefficient.
NumPy’s linalg.det function uses an algorithm based on the LU decomposition, which is more efficient than cofactor expansion, especially for large matrices. For teaching purposes, understanding cofactor expansion is valuable, but in practical applications one should use optimized libraries such as NumPy.
7.4.3 A Practical Example of Using Determinants¶
Below is an example that uses a determinant to compute the area of a triangle:
import numpy as np
def triangle_area(A, B, C):
"""
Compute the area of triangle ABC
Parameters:
A, B, C -- points in the plane, each an (x, y) coordinate tuple
Returns:
the area of the triangle
"""
# Build the matrix
matrix = np.array([
[A[0], A[1], 1],
[B[0], B[1], 1],
[C[0], C[1], 1]
])
# Compute the determinant and take its absolute value
return 0.5 * abs(np.linalg.det(matrix))
# Test
A = (0, 0)
B = (1, 0)
C = (0, 1)
print(f"Triangle area: {triangle_area(A, B, C)}")
7.4.4 Supplementary Checks: The PLU Decomposition and the Vandermonde Formula¶
We close with two short checks: the first obtains the PLU decomposition with scipy.linalg.lu and verifies (Theorem Theorem 8); the second builds a Vandermonde matrix with np.vander and compares it with the product formula of Theorem Theorem 16.
import numpy as np
from scipy.linalg import lu
np.set_printoptions(precision=4, suppress=True, linewidth=100)
# ── Check 1: the determinant via the PLU decomposition (Theorem thm-det-PLU) ──
A = np.array([[2., 1., 3.],
[1., 2., 1.],
[3., 1., 4.]])
P, L, U = lu(A) # A = P @ L @ U
det_P = np.linalg.det(P) # determinant of a permutation matrix = ±1
det_U = np.prod(np.diag(U)) # upper triangular: product of the diagonal entries
print("Check 1: det(A) = det(P)·det(U)")
print(f" det(P)·det(U) = {det_P * det_U:.6f}")
print(f" np.linalg.det(A) = {np.linalg.det(A):.6f}")
# ── Check 2: Vandermonde determinant = product of all the differences ──
x = np.array([1., 2., 4., 7.])
V = np.vander(x, increasing=True)
n = len(x)
prod_formula = np.prod([x[j] - x[i] for i in range(n) for j in range(i + 1, n)])
print("\nCheck 2: Vandermonde determinant = ∏(x_j − x_i)")
print(f" product formula = {prod_formula:.6f}")
print(f" np.linalg.det(V) = {np.linalg.det(V):.6f}")Determinants can be computed efficiently in Python and applied to all kinds of practical problems. NumPy provides optimized determinant computation that is well suited to scientific computing and engineering applications.
§7.4 answers the question of “how to do it on a computer,” turning from theory to implementation. NumPy’s linalg.det function is based on the LU decomposition, has computational complexity , and is the first choice in practical applications; but floating-point rounding errors can make a determinant that is theoretically zero come out as a tiny nonzero value, so a fixed absolute threshold on the determinant cannot reliably decide singularity; the numerical rank is better judged with a scale-aware SVD tolerance, while exact singularity calls for an algebraic argument. Although recursive cofactor expansion has complexity as high as , it is the most direct encoding of the theoretical logic, corresponding directly to the Laplace expansion theorem, and it helps readers confirm the bridge between theory and computation.
The triangle-area computation (§7.4.3) echoes the geometric theory of §7.3, verifies the concrete meaning of det as a volume scale factor, and demonstrates how a mathematical formula is translated into executable code. The supplementary checks (§7.4.4) further confirm the PLU determinant theorem and the Vandermonde formula with scipy.linalg.lu and np.vander respectively, completing the numerical counterparts of the two main theoretical threads of this chapter. The comparison of the results of the two methods—the exact value -2 versus NumPy’s result, which carries a rounding error on the order of 10-15—also shows vividly how pervasive the issue of numerical precision is. The implementation exercises of this section lay the computational foundation for the core computation of Chapter 8 (finding the roots of the characteristic polynomial ).
7.5 Chapter Summary¶
Review of the Theoretical Thread¶
Chapter 7 starts from an old question: how can a single number capture the essence of a square matrix? §7.1 answers this question in two strikingly different languages. The permutation definition gives a computational rule directly from the Leibniz formula, defining as the sum of the sign-weighted products over all permutations; the axiomatic definition goes the other way, constraining a mapping by three geometric properties—normalization, the row-alternating property, and multilinearity—and then deriving its unique form. The equivalence of the two definitions (Theorem Theorem 10) is the deepest theoretical conclusion of this chapter: the determinant is both a rule of computation and a logical necessity of geometric properties, and the two paths shake hands on the same formula. On this basis, §7.1.3 systematically derives the zero-row and identical-rows properties, the rules for elementary row operations, the determinant of a permutation matrix, the product theorem , and transpose invariance—each of these properties is a fruit that grows naturally from the three axioms, and together they form a complete theoretical arsenal for computing determinants.
§7.2 turns this arsenal into concrete computational methods. The Laplace expansion reveals the recursive structure of the determinant and leads to the adjugate matrix, a closed-form theoretical expression for the inverse matrix; the elementary row operation method lowers the computational complexity from to and has become the practical standard for numerical computation; and the Vandermonde determinant theorem, with its elegant formula as “the product of all the differences,” hints at a deeper connection between determinants and the theory of polynomials. §7.3 widens the view further: Cramer’s rule expresses the solution of a system of linear equations in closed form; the geometric applications establish the determinant’s identity as the signed volume scale factor, and the fact that a change of basis does not change the determinant shows that this is an intrinsic invariant of the linear transformation; the Jacobian determinant extends the idea of scaling to the local linearization of nonlinear mappings and becomes the geometric foundation of the change-of-variables formula for multiple integrals.
Connections to Other Chapters¶
The connection between this chapter and Chapter 6 is both an inheritance of tools and a complementary viewpoint. Gaussian elimination in Chapter 6 centers on row operations and aims at solving systems of equations; in this chapter, the properties of elementary row operations (Theorem Theorem 5) and the PLU decomposition theorem (Theorem Theorem 8) use the same operations to compute determinants and give them an algebraic meaning. The two chapters share Gaussian elimination as their backbone but stand at different vantage points: Chapter 6 looks at the structure of the solution space, while Chapter 7 looks at the effect of a linear transformation on volume. The fact that a zero determinant is equivalent to the matrix not being of full rank (Theorem Theorem 7) is precisely where these two viewpoints meet.
The core tool of Chapter 8—the characteristic polynomial —is built directly on this chapter. The product theorem and the multilinear property are the basis for analyzing the coefficients of the characteristic polynomial; the invariance of the determinant under similarity transformations (the basis invariance of §7.3.2) guarantees that eigenvalues are attributes of the linear transformation rather than quantities that depend on coordinates. The permutations and the sign function introduced in §7.1 will also reappear when the expansion of the characteristic polynomial is discussed. It is fair to say that this chapter lays all the necessary computational groundwork for Chapter 8, while also previewing the geometric intuition of eigenvalue theory: eigenvalues describe the stretching ratios of a transformation along particular directions, and the determinant is the product of all the eigenvalues—the two are unified in the characteristic polynomial, with the fundamental theorem of algebra as the bridge.
The Role of This Chapter in the Book¶
Chapter 7 occupies a pivotal position in the book. The first six chapters successively established the language of sets and mappings, the geometry of vectors, linear transformations and matrices, abstract linear spaces, block matrices, and the theory of solutions of systems of linear equations—tools that are already powerful but still lack a quantity linking the algebraic structure of a matrix to the geometric properties of space. The determinant is exactly this link: with a single scalar, it encodes the overall effect on signed volume of the linear transformation that a square matrix represents.
This idea of “compressing a geometric quantity into a single number” is extremely common in nature and in engineering. In thermodynamics, the Jacobian determinant describes the local compression rate of phase space; in quantum mechanics, determinants appear in the antisymmetrization of many-particle wave functions (the Slater determinant); the controllability of a finite-dimensional linear time-invariant system is decided by whether the controllability matrix has full row rank (row rank equal to the dimension of the state); only in the single-input case is this matrix square, and only then is the criterion equivalent to a nonzero determinant. The determinant is so pervasive precisely because it captures one of the most essential invariants of a linear transformation. If you read on with the viewpoint of this chapter, you will see in Chapter 8 that eigendecomposition is essentially a search for a way to decompose the determinant “direction by direction”—and this decomposition is precisely the completion, at the highest level, of the geometric intuition introduced in Chapter 3.