Matrix Rank Calculator
Compute the rank of a matrix via row reduction.
About this tool
Enter a matrix to get its rank, the number of linearly independent rows. [1 2 3; 2 4 6; 1 0 1] has rank 2 because row 2 is twice row 1.
How to use
How it works
Row reduction turns the matrix into echelon form, and the rank is the count of non-zero rows left. The rank can never exceed the smaller of the row and column counts. A square matrix has full rank exactly when its determinant is non-zero.
rank(A) = number of pivots after row reduction rank ≤ min(rows, columns)
Worked example
A dependent row
- Input
- [1 2 3; 2 4 6; 1 0 1]
- Output
- 2
- Walkthrough
- Row 2 − 2×Row 1 = 0, so one row vanishes. The two remaining rows are independent, giving rank 2.
Limitations
- Entries must be real numbers; complex entries are refused.
- Works on rectangular matrices, e.g. a 2×4 one.
- The matrix can be any size, but every row needs the same number of entries.
Questions
What is the rank of [1 2 3; 2 4 6; 1 0 1]?
What is the rank of [1 2; 3 4]?
What is the rank of [1 0 2 3; 0 1 1 1]?
Features
- Row reduction steps
- Rectangular matrices
- Runs in your browser
Related resources
Guides and videos from around the web—opens on YouTube or the publisher’s site.
Vectors | Essence of linear algebra
3Blue1Brown
Linear algebra intuition for matrix and vector tools.
Watch on YouTubeVariables, expressions, and equations
Khan Academy
Expression language for scientific and expression calculators.
Watch on YouTube
- Scientific Notation
Math is Fun
Powers of ten for scientific calculator displays.
- Order of Operations
Math is Fun
PEMDAS/BODMAS when expression calculators surprise you.