EasyUnitConverter.com

Matrix Calculator

Perform matrix operations: add, subtract, multiply, find determinant, transpose, and inverse. See also Percentage Calculator and Exponent Calculator.

How to Use the Matrix Calculator

Select the matrix size (2×2 or 3×3) and the operation you want to perform. Enter values into the matrix grids and click Calculate. For addition, subtraction, and multiplication, you need two matrices. For determinant, transpose, and inverse, only Matrix A is used. The calculator shows the result as a matrix or scalar value.

Matrix Formulas

Addition: C[i][j] = A[i][j] + B[i][j]

Subtraction: C[i][j] = A[i][j] - B[i][j]

Multiplication: C[i][j] = Σ A[i][k] × B[k][j]

Determinant (2×2): ad - bc

Transpose: Aᵀ[i][j] = A[j][i]

Inverse: A⁻¹ = adj(A) / det(A)

Example

Matrix A = [[1, 2], [3, 4]]

Matrix B = [[5, 6], [7, 8]]

A + B = [[6, 8], [10, 12]]

A × B = [[19, 22], [43, 50]]

det(A) = 1×4 − 2×3 = −2

Frequently Asked Questions

What is a matrix determinant?

The determinant is a scalar value computed from a square matrix. It indicates whether the matrix is invertible (non-zero determinant) and is used in solving systems of linear equations, finding area/volume, and eigenvalue problems.

When does a matrix not have an inverse?

A matrix has no inverse when its determinant is zero. Such a matrix is called singular or degenerate. This means the rows (or columns) are linearly dependent.

Is matrix multiplication commutative?

No. In general, A × B ≠ B × A. The order of multiplication matters. However, matrix addition is commutative: A + B = B + A.

Solved Examples — Matrices

Example: Multiply matrices A = [[2, 3], [1, 4]] and B = [[5, 1], [0, 2]]

Solution:

Step 1: C[0][0] = 2×5 + 3×0 = 10

Step 2: C[0][1] = 2×1 + 3×2 = 8

Step 3: C[1][0] = 1×5 + 4×0 = 5

Step 4: C[1][1] = 1×1 + 4×2 = 9

Answer: [[10, 8], [5, 9]]

Example: Find the determinant of [[3, 7], [2, 5]]

Solution:

Step 1: For 2×2 matrix [[a,b],[c,d]], det = ad − bc

Step 2: det = 3×5 − 7×2 = 15 − 14 = 1

Answer: det = 1 (matrix is invertible)

Example: Find the inverse of [[4, 7], [2, 6]]

Solution:

Step 1: det = 4×6 − 7×2 = 24 − 14 = 10

Step 2: Inverse = (1/det) × [[d, −b], [−c, a]]

Step 3: = (1/10) × [[6, −7], [−2, 4]]

Step 4: = [[0.6, −0.7], [−0.2, 0.4]]

Answer: [[0.6, −0.7], [−0.2, 0.4]]

Practice Questions

Try these on your own:

  1. Add [[1,2],[3,4]] + [[5,6],[7,8]] (Answer: [[6,8],[10,12]])
  2. Find the determinant of [[6, 2], [3, 8]] (Answer: 42)
  3. Multiply [[1,0],[0,1]] × [[3,4],[5,6]] (Answer: [[3,4],[5,6]] — identity matrix property)
  4. Find the transpose of [[1,2,3],[4,5,6]] (Answer: [[1,4],[2,5],[3,6]])
  5. Is [[2,4],[1,2]] invertible? (Answer: No, det = 0)
  6. Scalar multiply: 3 × [[2,−1],[0,4]] (Answer: [[6,−3],[0,12]])

Common Mistakes to Avoid

The biggest mistake in matrix multiplication is assuming it works like scalar multiplication. Matrix multiplication is NOT commutative (A×B ≠ B×A in general). Also, you can only multiply matrices when the number of columns in A equals the number of rows in B (e.g., a 2×3 matrix can multiply a 3×2 matrix, giving a 2×2 result). For addition/subtraction, both matrices must have the same dimensions — you cannot add a 2×2 to a 3×3. When computing determinants of 3×3 matrices, students often make sign errors in the cofactor expansion — remember the checkerboard pattern (+, −, +). Finally, a matrix is only invertible when its determinant is non-zero; always check before attempting inversion.

Key Takeaways

  • Matrix addition/subtraction: element-by-element, requires same dimensions.
  • Matrix multiplication: row × column dot products. Result dimensions are (rows of A) × (columns of B).
  • Multiplication is NOT commutative: A×B ≠ B×A (order matters).
  • Determinant of 2×2 [[a,b],[c,d]] = ad − bc. Zero determinant means no inverse exists.
  • The identity matrix (I) acts like 1 in multiplication: A×I = I×A = A.
  • Applications: computer graphics, machine learning, physics simulations, solving systems of equations, and cryptography.

Related Calculators: