Skip to content

Matrix Calculator

Multiplies, inverts, transposes and row-reduces matrices in exact rational arithmetic, and finds determinant, rank and trace.

Multiply, invert, transpose and row-reduce matrices, and read off the determinant, rank and trace. Every entry is an exact rational rather than a floating point number, so a singular matrix has a determinant of exactly 0 and the inverse of an integer matrix comes back as 1/3 rather than 0.3333333333333333.

🔒 Runs entirely in your browsermatrixmathlinear-algebra

Matrix A

One row per line. Entries separated by spaces, commas or tabs. Fractions like 1/3 and decimals both work.

Matrix B

Operation

Compute

Result

2  1
4  3

About matrix A

shape

2 × 2

rank

2

determinant

-2

trace

5

Every entry is an exact rational — a pair of arbitrary-precision integers — not a floating point number. That is why a singular matrix here has a determinant of exactly 0 rather than 3.6 × 10⁻¹⁶, and why the inverse of a matrix of integers comes back as 1/3 rather than 0.3333333333333333.

Eigenvalues are deliberately not offered. Finding them means solving the characteristic polynomial, which past 4 × 4 has no closed form and needs an iterative numerical method whose answers are usually irrational — nothing the exact representation used here can express. A tool that printed floating-point eigenvalues would be making a different promise than this one does.

How to use it

  1. Type the matrix

    One row per line, entries separated by spaces, commas or tabs. Fractions like 1/3 are accepted as they are and stay exact.

  2. Pick the operation

    Some need a second matrix and some do not. Multiplication needs the columns of A to match the rows of B, and says so plainly when they do not.

  3. Read the properties panel

    Shape, rank, determinant and trace for A. Rank below the number of rows is why the inverse does not exist, and reading it saves guessing.

Common questions

Why are eigenvalues not offered?

Finding them means solving the characteristic polynomial, which past 4 × 4 has no closed form and needs an iterative numerical method whose answers are usually irrational — nothing the exact rational representation used here can express. A tool that printed floating-point eigenvalues would be making a different promise than this one does.

The determinant is 0 but my other calculator says 1e-16

That calculator is using floating point, where the rounding of each step leaves a residue. Here the arithmetic is exact, so a singular matrix gives exactly zero and you do not have to decide whether 3.6 × 10⁻¹⁶ counts as zero.

What is RREF for?

Reduced row echelon form solves a linear system, finds the rank and exposes which variables are free. It is what elimination is doing under any of the other operations, made visible.

Feed it from

Next

These accept what this tool produces, so the result can go straight in.