Matrix Calculator

Choose 2x2 or 3x3 matrices, fill in the entries of A and B, pick an operation, and get the exact result.

Quick Presets:

Matrix Dimensions & Operations

Matrix Solution

Advertisement
Sizes: 2 x 2 and 3 x 3
Operations: Add, subtract, multiply, transpose
Advanced: Determinants and inverses
Use case: Linear algebra, graphics, systems of equations

What is a matrix?

A matrix is a rectangular grid of numbers arranged in rows and columns. A 2x2 matrix has two rows and two columns. Matrices are the building blocks of linear algebra, used to solve systems of equations, transform coordinates in graphics, and represent data in machine learning.

Matrix addition and subtraction work entry by entry: add (or subtract) the numbers in matching positions. Multiplication is different: each entry of the product is the sum of row-times-column products, so the matrices must have compatible sizes.

Determinants and inverses

The determinant is a single number computed from a square matrix that tells you about scaling and invertibility. A determinant of zero means the matrix is singular and has no inverse.

The inverse of a matrix is the matrix that, when multiplied by the original, gives the identity matrix. Inverses solve matrix equations the way division solves ordinary equations. The calculator finds 2x2 and 3x3 inverses with cofactor expansion.

How to use this calculator

  1. Choose 2 x 2 or 3 x 3 from the size dropdown.
  2. Enter the entries of matrix A and matrix B.
  3. Pick an operation and press Calculate.
  4. Read the resulting matrix or the scalar value (determinant).

Pro tips

  • For A × B, the number of columns of A must equal the rows of B — the calculator uses square matrices so this always holds.
  • Check a determinant of 0 before trying to invert: the matrix is singular.
  • Multiplying a matrix by its inverse gives the identity matrix — a quick way to verify.

Advantages & considerations

✅ Advantages

  • All core matrix operations in one tool
  • 2x2 and 3x3 support
  • Detects singular matrices before inverting

⚠️ Considerations

  • Limited to 2x2 and 3x3 sizes
  • Matrix entries are numeric only

Frequently asked questions

How do I multiply two matrices?
For each entry in the result, multiply each element of the row in A by the matching element of the column in B and add the products. The calculator does this automatically for square matrices.
What is the determinant of a matrix?
A single number that summarizes a square matrix. For a 2x2 matrix [a b; c d] it is ad - bc. A zero determinant means the matrix has no inverse.
What is an inverse matrix?
The inverse of A, written A⁻¹, satisfies A × A⁻¹ = identity matrix. It acts like division for matrices and only exists when the determinant is not zero.
What is the identity matrix?
A square matrix with 1s on the main diagonal and 0s elsewhere. Multiplying any matrix by the identity of the right size leaves it unchanged.
What are matrices used for?
Solving linear systems, computer graphics transformations, physics simulations, economics models and machine learning.