Quick Answer
To multiply matrices, multiply each row of A by each column of B and add the products. For A = [1 2; 3 4] and B = [5 6; 7 8], A × B = [19 22; 43 50]. The determinant of A is 1 × 4 − 2 × 3 = −2.
Embed this calculator
Adjust the size if needed, then copy the code below into your page or blog. The calculator will load in an iframe and stay updated automatically.
Table of Contents
How This Matrix Calculator Works
A matrix is a grid of numbers. Choose a size and an operation, enter your values, and press Calculate. Addition and subtraction work cell by cell, while multiplication combines rows with columns.
Quick explanation: each result cell in A × B is a row of A multiplied by a column of B.
- Size: 2 × 2 or 3 × 3.
- Determinant: a single number that describes the matrix.
- Inverse: exists only if the determinant is not 0.
How to Use the Matrix Calculator
- Choose a 2 × 2 or 3 × 3 matrix size.
- Choose an operation: add, subtract, multiply, determinant or inverse.
- Enter the numbers for matrix A, and for matrix B if the operation needs it.
- Press Calculate.
- Read the result matrix or value in the results table.
Core Formulas
- 2 × 2 determinant: ad − bc
- 2 × 2 inverse: (1 ÷ (ad − bc)) × [d −b; −c a]
- Product: cell (i, j) = the sum of A(i, k) × B(k, j)
Key Terms
- Matrix: a rectangular grid of numbers in rows and columns.
- Square matrix: a matrix with the same number of rows and columns.
- Identity matrix: a square matrix with 1s on the diagonal and 0s elsewhere. It acts like the number 1.
- Determinant: a number from a square matrix that shows whether it can be inverted.
- Inverse: the matrix that undoes another, so A × A⁻¹ = I.
- Singular matrix: a square matrix with a determinant of 0, which has no inverse.
Worked Example
Find the inverse of A = [1 2; 3 4].
- Determinant = (1 × 4) − (2 × 3) = −2
- Swap and change signs: [4 −2; −3 1]
- Divide by −2: [−2 1; 1.5 −0.5]
Real-Life Examples
- Solving two equations: for 2x + y = 5 and x + 3y = 10, write A = [2 1; 1 3]. The determinant is 5, so A has an inverse, and x = 1 and y = 3.
- Shop totals: a row of prices [2 3] times a column of quantities [4; 5] gives 2 × 4 + 3 × 5 = 23, the total bill.
- Computer graphics: a 2 × 2 matrix such as [0 −1; 1 0] rotates a point 90° around the origin, turning (1, 0) into (0, 1).
- Checking an inverse: multiply A by its inverse. The result should be the identity matrix [1 0; 0 1].
Determinant vs Inverse
- Determinant: a single number from a square matrix. It shows how the matrix scales area or volume.
- Inverse: a matrix that undoes A, so A × A⁻¹ gives the identity matrix.
- The link: a matrix has an inverse only if its determinant is not 0.
- For 2 × 2: the inverse of [a b; c d] is 1 ÷ (ad − bc) × [d −b; −c a].
Which Operations Need What
| Operation | Size rule | Result |
|---|---|---|
| Add or subtract | A and B the same size | Matrix of the same size |
| Multiply A × B | Columns of A = rows of B | Rows of A × columns of B |
| Determinant | Square matrix | One number |
| Inverse | Square, determinant not 0 | Matrix of the same size |
Common Mistakes
- Order matters: A × B is usually not the same as B × A.
- Multiplying cell by cell: matrix multiplication uses rows and columns.
- Zero determinant: the matrix has no inverse.
Frequently Asked Questions
Multiply each row of the first matrix by each column of the second, adding the products in each case.
For a 2 × 2 matrix, it is ad − bc. For a 3 × 3 matrix, this calculator expands along the first row.
When its determinant is 0.
No. A × B and B × A usually give different results.
It supports 2 × 2 and 3 × 3 square matrices.
It has 1s down the main diagonal and 0s everywhere else. Multiplying any matrix by it leaves the matrix unchanged.
Multiply the original matrix by the inverse. If you get the identity matrix, the inverse is correct.
For a 2 × 2 matrix, it means the matrix flips orientation, like a mirror, as well as scaling area.
It tells you whether a system of three equations has one solution, and how a 3D shape's volume changes under the matrix.
It swaps rows and columns, so the first row becomes the first column.
No. The number of columns in the first must equal the number of rows in the second.
References & Sources
| Source | Used For | Link |
|---|---|---|
| Wikipedia, Matrix (mathematics) | Matrix operations. | https://en.wikipedia.org/wiki/Matrix_(mathematics) |
| Wikipedia, Determinant | Determinant formulas. | https://en.wikipedia.org/wiki/Determinant |
| Wikipedia, Invertible matrix | Matrix inverse. | https://en.wikipedia.org/wiki/Invertible_matrix |