Math

Matrix Calculator

Add, subtract and multiply matrices, or find a transpose, determinant or inverse in one workspace.

Exact method explained belowEditable inputs
Matrix workspace
Matrix workspace

One row per line. Choose an operation; dimensions are checked before calculation.

See the method

Enter your matrices

Runs on your device

Matrix result

Your result

Let’s calculate.

Use the Calculate button to see your result.

Review the method below for assumptions and conventions.

How to use this tool

  1. Enter matrix a — one row per line, matrix b — used for add, subtract or multiply, operation.
  2. Select Calculate to view the result.
  3. Check the method and assumptions below before using the result.

The method, explained

Addition and subtraction combine matching entries. Matrix multiplication uses row-column dot products. Transpose swaps rows and columns. Determinant and inverse use elimination with partial pivoting.

A WORKED EXAMPLE

Using matrix a — one row per line = 2, 1 1, 3, matrix b — used for add, subtract or multiply = 1, 0 0, 1, operation = multiply, the result is 2 1 1 3. Change these example inputs to match your task; use the method above to check each step.

What to keep in mind

Real numbers only, up to 10 × 10. Matrix B is ignored for unary operations. Near-singular matrices use a scale-based numerical threshold; floating-point results are approximate. Finite-precision arithmetic is used. Check the domain and the stated convention before using an approximation.

Common questions

How do I enter matrix rows?

Put each row on a separate line or separate rows with semicolons. Within a row, separate numbers with spaces or commas. All rows must have the same number of entries.

Why can an inverse fail?

A singular matrix has no inverse. A nearly singular matrix can amplify rounding error so strongly that this calculator rejects it rather than present an unreliable result.

Methodology maintained by ClarityKit. How these tools are built and checked.