# Matrix Calculator — Determinant, Inverse, Multiply & Transpose

> Add, subtract, scalar-multiply, multiply, transpose, and find the determinant and inverse of matrices up to 3×3 — with the result laid out and a magnitude heatmap.

- **Category:** Math
- **Interactive calculator:** https://youcalc.com/en/math/matrix-operations/
- **Price:** Free, no sign-up required

## Overview

This calculator performs the most common matrix operations on matrices up to 3×3: addition, subtraction, scalar multiplication, matrix multiplication, transpose, determinant, and inverse. Enter your matrix values, pick an operation, and the result appears instantly alongside a magnitude heatmap that highlights the relative size of each entry.

## How to read your result

For scalar operations such as the determinant, the headline number is the result. For matrix operations the result card names the operation, and the heatmap grid below it shows the output matrix — each cell is shaded according to how large its absolute value is relative to the biggest entry, so you can spot dominant entries at a glance. The stat strip at the top of the page confirms the current operation and whether the output is a scalar or a full matrix.

## Method

Addition and subtraction add or subtract corresponding entries. Scalar multiplication multiplies every entry by the constant k. Matrix multiplication follows the dot-product rule: entry (i, j) of the result is the dot product of row i of A and column j of B. The transpose flips a matrix over its main diagonal, exchanging rows and columns. The determinant is computed by cofactor expansion along the first row (Wolfram MathWorld: Determinant). The inverse uses the adjugate divided by the determinant (Wolfram MathWorld: Matrix Inverse); a singular matrix with determinant 0 has no inverse.

## Example

- **Setup:** Set both matrices to 2×2, choose Multiply, and use A = [[1, 2], [3, 4]] with B = [[5, 6], [7, 8]].
- **Result:** The product A × B is [[19, 22], [43, 50]]. Entry (1,1) = 1×5 + 2×7 = 19; entry (1,2) = 1×6 + 2×8 = 22; and so on — the heatmap shows 50 as the darkest cell because it is the largest value in the result.

## Frequently asked questions

### When is matrix multiplication defined?

Matrix multiplication A × B is defined only when the number of columns in A equals the number of rows in B. For two square matrices of the same size this is always satisfied, but note that A × B and B × A generally give different results — matrix multiplication is not commutative.

### What does the determinant tell you?

The determinant is a single number that summarises a square matrix. A non-zero determinant means the matrix has a unique inverse and the corresponding system of equations has exactly one solution. A determinant of zero means the matrix is singular — its rows are linearly dependent and no inverse exists.

### How is the inverse calculated?

The calculator uses the adjugate (classical adjoint) method: it forms the cofactor matrix, transposes it to get the adjugate, then divides every entry by the determinant. For the 2×2 case [[a,b],[c,d]] this gives [[d,−b],[−c,a]] divided by (ad − bc). If the determinant is zero an error is shown instead.

## Related calculators

- [System of Equations Solver](https://youcalc.com/en/math/system-of-equations/)
- [Quadratic Equation Solver](https://youcalc.com/en/math/quadratic-equation/)
- [Slope & Line Equation Calculator](https://youcalc.com/en/math/slope-line-equation/)

## Sources

- https://mathworld.wolfram.com/Determinant.html
- https://mathworld.wolfram.com/MatrixInverse.html

---

Interactive version: https://youcalc.com/en/math/matrix-operations/ · From YouCalc — https://youcalc.com
