About Matrix Multiplication Calculator
This calculator multiplies two matrices. Set the size of A and the number of columns of B, and the rows of B follow automatically, so the product is always defined. A 2 × 3 times a 3 × 2 gives a 2 × 2. It is free, needs no sign-up and runs in your browser, so nothing you enter is uploaded.
Each entry of the product is a row of A multiplied entry by entry with a column of B and summed. For [[1, 2, 3], [4, 5, 6]] times [[7, 8], [9, 10], [11, 12]], the top-left entry is 1×7 + 2×9 + 3×11 = 58 and the full product is [[58, 64], [139, 154]].
Order matters. A times B is usually not equal to B times A, and one of the two products may not exist at all: a 2 × 3 times a 2 × 3 is undefined. Entries can be fractions or decimals, and results are exact fractions unless you tick the decimal option.
How to use Matrix Multiplication Calculator
- Choose an operation, such as Determinant, Inverse or A × B.
- Set the size of matrix A with the row and column selectors. Square operations use a square grid, and two-matrix operations also show matrix B.
- Type the entries. Use integers, decimals or fractions like 3/4, and leave a cell blank for zero.
- The tool opens on a worked example. Read the result, typeset as a determinant, a rank or a matrix.
- Read the steps for the working, and use the decimal switch if you would rather see decimals than fractions.
Features
- Grids up to 6 × 6, with rows and columns set separately for non-square matrices.
- Addition, subtraction and multiplication of two matrices, with a clear message when the sizes do not match.
- Determinant with the 2 × 2 rule, first-row expansion for 3 × 3 and row reduction for larger matrices.
- Inverse by row-reducing [A | I], with a plain message when the matrix is singular.
- Rank and reduced row echelon form with each row operation listed.
- Adjugate and cofactor matrix for square matrices.
- Eigenvalues from the characteristic polynomial, including complex ones, with eigenvectors: exact for rational eigenvalues and numeric (labelled) for irrational ones.
- LU decomposition (with row swaps when a pivot is zero) and QR decomposition by Gram-Schmidt, exact with square roots.
- Fraction entries and fraction results, with a switch to decimals that also applies to the steps.
- Transpose of any matrix.
Matrix product
The entry in row i and column j of AB is the dot product of row i of A and column j of B.
(AB)ᵢⱼ = Σₖ Aᵢₖ × Bₖⱼ
(m × n) × (n × p) = (m × p)Worked examples
[[1, 2], [3, 4]] × [[5, 6], [7, 8]] gives [[19, 22], [43, 50]]
Top-left: 1×5 + 2×7 = 19. Bottom-right: 3×6 + 4×8 = 50.
[[1, 2, 3], [4, 5, 6]] × [[7, 8], [9, 10], [11, 12]] gives [[58, 64], [139, 154]]
A 2 × 3 times a 3 × 2 is 2 × 2. Bottom-left: 4×7 + 5×9 + 6×11 = 139.
Privacy: how it works
- All the arithmetic runs in your browser tab. Your matrices are not sent to Ulkaa or anyone else, and there is nothing to sign in to.
Tips
- Write fractions as 3/4 rather than 0.75 if you want results to stay exact.
- Leave entries blank for zero instead of typing every zero in a large grid.
- To solve a linear system, put the coefficients and constants in one grid and use RREF, or use the equation solver.
- Multiplication is not commutative. To check AB against BA, swap which matrix is A and which is B.
Frequently asked questions
Is it really free?
Yes. There is no price, no trial and no credit card. Ulkaa Tool does the work with your own device, so there is no server bill to pass on to you.
Do I need an account?
No. There is no sign-up and no login. Open the page and use it. An Ulkaa account is not needed for anything on this tool.
Does it run in my browser?
Yes. Your matrices are processed by code running in your browser tab, on your own device.
Is my data uploaded?
No. Your matrices are never sent to Ulkaa or to anyone else. You can check this yourself by watching the Network tab in your browser developer tools while you use the tool.
How do I multiply matrices?
Take each row of the first matrix and each column of the second, multiply matching entries and add them. That sum is one entry of the product.
Is matrix multiplication commutative?
No. A times B is usually not equal to B times A, and one of the two products may not exist at all.
More Matrix Calculator pages
- Matrix CalculatorAdd, multiply, invert, decompose (LU, QR) and analyse matrices up to 6 × 6, with typeset working.
- Matrix Determinant CalculatorFind the determinant of any square matrix up to 6 × 6.
- Inverse Matrix CalculatorFind A⁻¹ for a square matrix, or learn why it does not exist.
- Matrix Addition CalculatorAdd or subtract two matrices of the same size.
- Matrix Transpose CalculatorSwap the rows and columns of a matrix.
- Matrix Rank CalculatorFind how many independent rows a matrix has.
- Eigenvalue CalculatorFind the eigenvalues of a square matrix and see the characteristic polynomial.
- 2x2 Matrix Determinant CalculatorEnter a, b, c and d to get ad − bc.
- 3x3 Matrix Determinant CalculatorExpand a 3 × 3 determinant along the first row with every minor shown.
- 3x3 Inverse Matrix CalculatorInvert a 3 × 3 matrix with every row operation listed.
- RREF CalculatorRow-reduce any matrix up to 6 × 6 to reduced row echelon form.
- Adjugate and Cofactor Matrix CalculatorGet the cofactor matrix, its transpose the adjugate, and the determinant.
- LU Decomposition CalculatorFactor a square matrix into a lower and an upper triangular matrix, with exact fractions.