Enter the dimensions and entries of matrices A and B. The product A×B is computed live in your browser using the row-by-column dot product — no data leaves your device.
Matrix multiplication combines two matrices into a third. It is defined only when the number of columns in the first matrix equals the number of rows in the second. If A is an m×n matrix and B is an n×p matrix, then the product C = A×B is an m×p matrix. The shared inner dimension n is what makes the operation "conformable."
Each entry of the result is a dot product: to fill cell C[i][j], you walk along row i of A and column j of B, multiply the paired numbers, and add them up. The calculator above does exactly this — the step list shows the running dot product for a chosen cell so you can verify the arithmetic by hand.
A crucial property is that matrix multiplication is not commutative: in general A×B ≠ B×A, and one ordering may not even be defined if the dimensions don't line up. It is, however, associative — (A×B)×C = A×(B×C) — and distributive over addition. The identity matrix I acts like the number 1: A×I = A for any compatible A, which is why the "B = Identity" button leaves A unchanged.
The naive algorithm used here runs in O(m·n·p) time — three nested loops over rows, columns, and the shared dimension. For the small matrices a browser handles this is instantaneous; large-scale numerical libraries use blocked or Strassen-style algorithms to cut the cost. Matrix products underpin linear transformations, graphics pipelines, Markov chains, neural network layers, and solving systems of linear equations, making this one of the most-used operations in applied linear algebra.