Free Matrix Calculator

Matrix algebra written in chalk on a green blackboard
Photo: Yulia Meshkova / Wikimedia Commons, CC BY 4.0

Published: 15 November 2026  Β·  Updated: 15 November 2026

Add, subtract and multiply 2Γ—2 and 3Γ—3 matrices, and find determinants, inverses and transposes β€” with the working shown. It starts with A = [[4, 7], [2, 6]] and B = [[1, 2], [3, 4]], giving A Γ— B = [[25, 36], [20, 28]]. Free, no sign-up, and it never invents an inverse when none exists.

MixKhazana Β· Quick answer

Full-size grids, instant answers. Pick 2Γ—2 or 3Γ—3, type your matrices, choose the operation. Determinants show their working, and singular matrices get an honest β€œno inverse” instead of a wrong answer.

Researched by MixKhazana Team Β· Last updated 15 November 2026 Β· Data: OpenStax Algebra and Trigonometry (Cramer's rule); College Board AP calculator policy

Example: With A = [[4, 7], [2, 6]] and B = [[1, 2], [3, 4]], A Γ— B = [[25, 36], [20, 28]], det(A) = 10, and A⁻¹ = [[0.6, βˆ’0.7], [βˆ’0.2, 0.4]]. Switch the operation box to check each one.
Order matters. Matrix multiplication is not commutative: A Γ— B usually differs from B Γ— A. Addition and subtraction need matching sizes; multiplication needs the columns of A to match the rows of B (always true for two same-size square matrices here).

What is a matrix calculator?

A matrix is a rectangular grid of numbers, and a matrix calculator does arithmetic with whole grids at once: adding, subtracting and multiplying them, and finding the determinant and inverse of a square matrix. Matrices appear in linear algebra, computer graphics, economics and engineering, and solving systems of equations is their most common classroom job: a system of equations can be written as A·x = b, and when A has an inverse the solution is x = A⁻¹·b.

Handheld graphing calculators include matrix menus, but their small screens make entering a 3 Γ— 3 matrix fiddly. This free tool gives you a full-size grid, shows the working for determinants, and refuses to invent an inverse when none exists.

How to use this matrix calculator

  1. Choose the size: 2 Γ— 2 or 3 Γ— 3. The grids refill with worked examples you can overwrite.
  2. Type your numbers into Matrix A and Matrix B.
  3. Pick the operation: add, subtract, multiply, determinant of A, inverse of A, or transpose of A. The result appears instantly.
  4. For the determinant, read the working line under the answer β€” it shows the exact arithmetic, which is what markers want to see.

Matrix formulas

For A = [[a, b], [c, d]] and a 3 Γ— 3 matrix with first row a, b, c:

  • Addition / subtraction: entries combine position by position: (A + B)ij = Aij + Bij
  • Multiplication: (A Γ— B)ij = sum over k of Aik Γ— Bkj β€” row i of A dotted with column j of B
  • Determinant (2 Γ— 2): det(A) = ad βˆ’ bc
  • Determinant (3 Γ— 3): det(A) = a(ei βˆ’ fh) βˆ’ b(di βˆ’ fg) + c(dh βˆ’ eg), expanding along the first row
  • Inverse (2 Γ— 2): A⁻¹ = (1 / (ad βˆ’ bc)) Γ— [[d, βˆ’b], [βˆ’c, a]], valid only when ad βˆ’ bc β‰  0
  • Inverse (3 Γ— 3): A⁻¹ = adj(A) / det(A), where adj(A) is the transpose of the cofactor matrix
  • Transpose: (Aα΅€)ij = Aji β€” rows and columns swap

A matrix has an inverse exactly when its determinant is not zero. The determinant also decides whether a system of equations has a unique solution: with Cramer's rule, each unknown is a ratio of determinants, and a zero determinant means no unique solution exists.

Worked example

Let A = [[4, 7], [2, 6]] and B = [[1, 2], [3, 4]]:

  • A + B = [[5, 9], [5, 10]] β€” add matching entries
  • A Γ— B = [[4Γ—1+7Γ—3, 4Γ—2+7Γ—4], [2Γ—1+6Γ—3, 2Γ—2+6Γ—4]] = [[25, 36], [20, 28]]
  • det(A) = 4Γ—6 βˆ’ 7Γ—2 = 24 βˆ’ 14 = 10
  • A⁻¹ = (1/10) Γ— [[6, βˆ’7], [βˆ’2, 4]] = [[0.6, βˆ’0.7], [βˆ’0.2, 0.4]]
  • Check: A Γ— A⁻¹ = [[1, 0], [0, 1]], the identity matrix, as it must be

Try it above: the defaults are these two matrices β€” switch the operation box to see each result.

Results for the example matrices

OperationResult
A + B[[5, 9], [5, 10]]
A βˆ’ B[[3, 5], [βˆ’1, 2]]
A Γ— B[[25, 36], [20, 28]]
det(A)10
A⁻¹[[0.6, βˆ’0.7], [βˆ’0.2, 0.4]]
Aα΅€[[4, 2], [7, 6]]

For the 3 Γ— 3 default, A = [[2, 1, 1], [1, 2, 1], [1, 1, 2]] has det(A) = 4 and A⁻¹ = [[0.75, βˆ’0.25, βˆ’0.25], [βˆ’0.25, 0.75, βˆ’0.25], [βˆ’0.25, βˆ’0.25, 0.75]].

Solving systems with matrices

To solve 4x + 7y = 1 and 2x + 6y = 3, write the coefficient matrix A = [[4, 7], [2, 6]] and the constants b = [1, 3]. Since det(A) = 10 β‰  0, the solution is unique: x = A⁻¹·b = [[0.6, βˆ’0.7], [βˆ’0.2, 0.4]] Γ— [1, 3] = [0.6 βˆ’ 2.1, βˆ’0.2 + 1.2] = [βˆ’1.5, 1]. Check: 4(βˆ’1.5) + 7(1) = 1 and 2(βˆ’1.5) + 6(1) = 3. Cramer's rule gives the same answer as ratios of determinants, and this tool's determinant is the piece you need for either method.

Frequently asked questions

How do I multiply two matrices?

Multiply row by column: the entry in row i, column j of A x B is the dot product of row i of A with column j of B. For 2x2 matrices that is four dot products. This tool shows the result instantly; the worked example above shows every step.

Why is A x B different from B x A?

Matrix multiplication is not commutative: rows of the first matrix meet columns of the second, so swapping the order pairs different numbers. In general A x B and B x A are different matrices, and for non-square matrices one of the two products may not even exist.

What does the determinant tell me?

For a 2x2 matrix det(A) = ad - bc. It tells you whether the matrix has an inverse (only when it is not zero) and whether a system of equations has a unique solution. Geometrically it measures how the matrix scales areas.

When does a matrix have no inverse?

Exactly when its determinant is zero. Such a matrix is called singular. This tool says so plainly instead of printing a wrong matrix: division by a zero determinant is meaningless.

How is a 3x3 determinant calculated?

By expanding along a row: det(A) = a(ei - fh) - b(di - fg) + c(dh - eg), where each bracket is a 2x2 determinant (a minor) and the signs alternate +, -, +. The same diagonal method taught in textbooks gives the identical number.

How is a 3x3 inverse calculated?

From cofactors: each entry of the cofactor matrix is (-1) raised to i+j times the 2x2 determinant left after deleting that row and column. Transpose the cofactor matrix to get the adjugate, then divide by the determinant.

What is the transpose of a matrix?

The matrix with rows and columns swapped: the entry in row i, column j of A-transpose is the entry in row j, column i of A. The transpose of [[4, 7], [2, 6]] is [[4, 2], [7, 6]].

Can I solve equations with this tool?

Yes, indirectly: find the inverse of the coefficient matrix, then multiply it by the constants column. The section above works a full example. If the determinant is zero, the system has no unique solution and another method is needed to tell whether it has none or infinitely many.

Sources

Disclaimer: a study aid for homework and revision. Results are rounded to four decimal places for display; exact fractions (such as 3/5 for 0.6) are the same values. It is not an approved exam-room device.

Related tools

Function graph plotted on axes on paper with a pencil beside it
πŸ“ˆ

Free Graphing Calculator

Plot functions and read values from the curve.

Open →
Electronic calculator
πŸ“

Free Quadratic Equation Calculator

Roots, vertex and discriminant for any quadratic.

Open →
Scientific calculator close-up on a green background
πŸ”¬

Free Scientific Calculator

Trig, logs and powers with degree and radian modes.

Open →
Electronic calculator
%

Free Percentage Calculator

Percentages, increases and decreases in one step.

Open →

Card photos: Sergey Meshkov / Pexels, Pexels licence Β· Coyau / Wikimedia Commons, CC BY-SA 3.0 Β· Joost J. Bakker / Wikimedia Commons, CC BY 2.0

Your next step

Working with equations? Solve quadratics exactly with the Free Quadratic Equation Calculator, or see the curve with the Free Graphing Calculator.

Share: