Matrix Multiplication Calculator
Linear Algebra, Matrices, Calculators
Solve your matrix problem
Matrix A and Matrix B
Final answer
If you need more help and details, visit https://mathix.co.
Intro: Multiply two matrices online with a clear dimension check and a step-by-step breakdown of each row-by-column dot product. This page is built for quick answers and for learning how matrix multiplication works.
Worked example
- Compute AB where $A = [[1, 2],[3, 4]]$ and $B = [[5, 6],[7, 8]]$.
- We have $A=\begin{pmatrix}1 & 2\\3 & 4\end{pmatrix}$ and $B=\begin{pmatrix}5 & 6\\7 & 8\end{pmatrix}$.
- Matrix A is 2×2 and matrix B is 2×2, so the product AB is defined and will also be 2×2.
- The entry $(AB)_{11}$ is the dot product of row 1 of A with column 1 of B: $1\cdot5 + 2\cdot7 = 5+14=19$.
- The entry $(AB)_{12}$ is row 1 of A with column 2 of B: $1\cdot6 + 2\cdot8 = 6+16=22$.
- The entry $(AB)_{21}$ is row 2 of A with column 1 of B: $3\cdot5 + 4\cdot7 = 15+28=43$.
- The entry $(AB)_{22}$ is row 2 of A with column 2 of B: $3\cdot6 + 4\cdot8 = 18+32=50$.
- So $AB = \begin{pmatrix}19 & 22\\43 & 50\end{pmatrix}$.
- Answer: $\boxed{AB = \begin{pmatrix}19 & 22\\43 & 50\end{pmatrix}.}$
- Check if the product of $A$ and $B$ is defined where $A$ is 2×3 and $B$ is 4×2.
- A has 3 columns but B has 4 rows.
- Because the inner dimensions do not match, AB cannot be computed.
- Adjust the matrices so A is m×n and B is n×p.
FAQs
What matrix sizes are supported?
Any A(m×n) and B(n×p) are allowed as long as the inner dimensions match.
What dimensions can be multiplied?
A must be m×n and B must be n×p. The inner dimensions must match.
Can I use decimals, negatives, or fractions?
The calculator is intended to support common numeric input formats such as integers, decimals, negatives, and fractions.
Why is matrix multiplication not commutative?
In general, AB is not equal to BA because the row-by-column structure depends on order, and the dimensions may also differ.
What happens if the matrices are incompatible?
The calculator should flag the mismatch and explain that the inner dimensions do not match.
How matrix multiplication works and what this calculator shows
- If A is m×n and B is n×p, then the product AB is defined and has size m×p. Each entry in AB is found by taking one row from A and one column from B, then computing their dot product.
- For example, the entry in row i and column j of AB is $(AB)_{ij} = \sum_{k=1}^n a_{ik}b_{kj}$.
- Mathix checks whether the matrices are compatible, computes the result, and shows the exact multiplication used for each cell. That makes it useful both as a calculator and as a study aid.
Matrix multiplication step-by-step
- Enter matrix A and matrix B in the input boxes.
- Check that the number of columns in A equals the number of rows in B.
- Click Get final answer to see the product AB and the value of each output cell.
- Receive the final product matrix for the matrices you enter.
- Clear the inputs and start over.
