Skip to content

Matrix Rank

Formula

\[ \operatorname{rank}(A)=\dim(\operatorname{col}(A))=\dim(\operatorname{row}(A)) \]

Parameters

  • \(A\): matrix
  • \(\operatorname{col}(A)\): column space
  • \(\operatorname{row}(A)\): row space

What it means

Rank is the number of linearly independent rows/columns of a matrix.

What it's used for

  • Checking solvability and identifiability.
  • Diagnosing redundancy and singularity.

Key properties

  • \(\operatorname{rank}(A)\le \min(m,n)\) for \(A\in\mathbb{R}^{m\times n}\).
  • Full rank depends on matrix shape and dimension.

Common gotchas

  • Numerical rank depends on tolerance in floating-point computations.
  • Tall and wide matrices have different "full rank" meanings.

Example

If one column is a multiple of another, the matrix rank drops.

How to Compute (Pseudocode)

Input: matrix A
Output: rank(A)

compute a rank-revealing factorization (for example, row echelon form, QR, or SVD)
count the number of nonzero pivots / singular values above tolerance
return that count

Complexity

  • Time: Depends on the chosen method (dense QR/SVD-based rank computation is typically polynomial and often cubic in matrix dimensions)
  • Space: Depends on matrix storage and factorization workspace
  • Assumptions: Numerical rank depends on tolerance and factorization choice in floating-point computations

See also