Matrix multiplication combines two matrices into a new one using row-by-column dot products, not simple entry-by-entry multiplication. This calculator computes A×B for matrices up to 4×4, shows the full dot-product expansion for every cell of the result, and checks the dimension rule that decides whether the multiplication is even possible.
How row-by-column multiplication works
Matrix multiplication does not multiply matrices entry-by-entry the way addition does. Instead, every entry of the product C comes from a dot product: to find C[i][j], the calculator walks along row i of matrix A and down column j of matrix B at the same time, multiplying matching pairs of numbers and adding the results together. For a 2×3 matrix A and a 3×2 matrix B, each entry of C is the sum of three products, one for each shared index.
The Steps tab lists this expansion for every cell in the product, so C[1][1] = A[1][1]·B[1][1] + A[1][2]·B[2][1] + A[1][3]·B[3][1], with the running total shown at the end of the line. Because the number of terms in each dot product always equals the shared inner dimension — the columns of A, which must match the rows of B — larger matrices simply add more terms per cell rather than changing the underlying method. Working through one row by hand alongside the Steps tab is the fastest way to build intuition for the formula.
Reading the dimension rule
Two matrices can only be multiplied when the number of columns in the first matches the number of rows in the second — if A is m×n and B is n×p, only then does A×B exist, and the result is always m×p. This calculator keeps matrix A and matrix B on fully independent size selectors precisely so you can explore both sides of that rule: pick compatible sizes and the product appears immediately, or pick incompatible ones and the Dimension Check tab explains exactly why the multiplication fails.
The rule is easy to misremember as "the matrices must be the same size," but that's only true for square matrices of equal dimension; in general A×B and B×A can have completely different shapes, or one may exist while the other doesn't. Watching the ✓/✗ indicator update live as you change either matrix's row or column count is a quick way to internalize which dimension pairs actually work.
Limits and edge cases
This calculator supports matrices up to 4×4 on each side, which covers the vast majority of hand-worked and homework-style problems while keeping every dot-product step readable on screen. Multiplication is not commutative — swapping the order to compute B×A can produce a different matrix entirely, or may not even be defined if the dimensions no longer line up — so the calculator always computes A×B in the order the matrices are entered, never the reverse.
Multiplying any matrix by a compatible identity matrix leaves it unchanged (A×I = A), which is a useful sanity check available directly from the preset strip. For operations beyond multiplication — addition, subtraction, scalar multiplication, transpose, determinant, inverse, or solving systems of equations — the general-purpose Matrix Calculator handles all of those in one tool, while the dedicated Matrix Determinant and Matrix Inverse calculators offer deeper step-by-step breakdowns for those two specific operations.