Course contentsShow
← Mathematics
Lesson 2286 of 3,12147. Linear Algebra — Applications and Advanced TopicsFree lesson

SVD and the Matrix Rank

Determine the rank of a matrix by counting nonzero singular values in the SVD.

SVD and the Matrix Rank

You'll learn: How to determine a matrix's rank by counting the nonzero singular values in its Singular Value Decomposition.

The Core Idea

The rank of a matrix tells us the dimension of its column space—essentially, how many truly independent directions it encodes. While you can compute rank by row-reducing to echelon form, the SVD offers a cleaner, numerically stable alternative.

Here's the key insight: When you decompose a matrix A into A = UΣVᵀ, the diagonal matrix Σ contains the singular values. These values measure the "strength" of each independent direction in the transformation. The rank of A equals the number of nonzero singular values in Σ.

Why This Works

Think of singular values as amplification factors. If a singular value is zero (or numerically very close to zero), it means that direction contributes nothing to the output—it's collapsed, not independent. Only the nonzero singular values correspond to genuine dimensions in the range of the matrix.

In practice, floating-point arithmetic rarely produces exact zeros, so you count singular values above a small threshold (like 10⁻¹⁰) as "nonzero."

Example Walk-Through

Suppose you compute the SVD of a 4×5 matrix and find:

Σ = diag(8.3, 5.1, 0.0002, 0, 0)

Depending on your tolerance:

  • Strict count: 3 nonzero values → rank = 3
  • Practical threshold: The 0.0002 might be numerical noise, giving rank = 2

This tells you the matrix's column space is 2- or 3-dimensional.

Key Takeaway: The rank of a matrix equals the number of its nonzero singular values in the SVD—a robust and elegant way to measure true dimensionality.