2×2 Matrix Calculator

Add, subtract, multiply two 2×2 matrices, or find a matrix's determinant.

Formulas

Addition/subtraction combine matching positions. Multiplication uses row-by-column dot products. Determinant of [[a,b],[c,d]] = ad − bc.

Why matrix multiplication doesn't work the way regular multiplication does

Matrix addition and subtraction work intuitively — add or subtract corresponding entries position by position, requiring both matrices to have identical dimensions. Matrix multiplication is where the intuition from ordinary number multiplication breaks down completely: multiplying two matrices requires the number of columns in the first matrix to exactly match the number of rows in the second, and each entry in the result is computed as a sum of products (the dot product of a row from the first matrix and a column from the second) rather than a simple position-by-position multiplication like addition uses.

The most counterintuitive consequence of this is that matrix multiplication is generally not commutative — A × B usually does not equal B × A, which is a genuine departure from how multiplication works with ordinary numbers (where 3 × 5 always equals 5 × 3). This isn't a quirk to memorize around; it reflects what matrices actually represent — each matrix typically encodes a transformation (like a rotation, scaling, or a system of equations), and applying transformation A then transformation B generally produces a different combined result than applying B then A, in exactly the same way that rotating an object then stretching it produces a different final shape than stretching it then rotating it. Matrices are foundational specifically because this transformation-composition behavior underlies computer graphics, systems of linear equations, and much of applied engineering and data science.

Frequently asked questions

Why do matrix dimensions matter so much for multiplication but not for addition?

Matrix addition works position-by-position, so it only requires both matrices to have identical dimensions. Matrix multiplication computes each result entry as a sum of products between a row and a column, which requires the first matrix's column count to exactly match the second matrix's row count — a structural requirement addition doesn't have.

Why isn't matrix multiplication commutative (A×B ≠ B×A)?

Because matrices typically represent transformations, and applying one transformation followed by another generally produces a different combined result than applying them in reverse order — similar to how rotating then stretching an object gives a different result than stretching then rotating it. This is a fundamental property, not an exception to memorize around.

What does it mean for two matrices to be 'compatible' for multiplication?

The number of columns in the first matrix must exactly equal the number of rows in the second matrix. If matrix A is 2×3 (2 rows, 3 columns) and matrix B is 3×4, they're compatible for A×B (producing a 2×4 result), but B×A would not be compatible unless the dimensions happen to also satisfy the reverse requirement.

What are matrices actually used for beyond pure math exercises?

Matrices are foundational to computer graphics (representing rotations, scaling and translations of images and 3D objects), solving systems of linear equations, and much of data science and engineering, where they compactly represent transformations and large sets of relationships between variables.

Related calculators