Small tools. Clear answers.

ƒ MATH · EIGHT CALCULATION MODES

Matrix Calculator

Add, subtract or multiply real matrices up to 4 × 4. Calculate a determinant, inverse or transpose from row-by-row inputs. How to use it ↓

Matrices

Add, subtract or multiply real matrices up to 4 × 4. Calculate a determinant, inverse or transpose from row-by-row inputs.

One row per line; spaces or commas between cells. Up to 4 × 4. Fraction cells such as 1/2 are accepted.

READY · PRESS ENTER OR =
—

Enter an expression, then press Enter or =.

Memory empty · Calculations stay in this tab

History & notes 0

History

This session · Select a calculation to restore its inputs

A little room for your working.
Your calculations will appear here.

About this result

Results round to 12 significant digits. Exact arithmetic fractions are available where supported.

Expression reference

sin(30) · asin(0.5)
ln(e) · log(8,2)
root(27,3) · 2^3
5! · nCr(5,2)
sinh(1) · conj(3+4i)
re(3+4i) · arg(3+4i)
1e-5 · 200+10%

Use exp(x) for eˣ and mod(a,b) for the remainder. Roots and logarithms may return complex values.

START HERE

How to use the matrix calculator

  1. Choose addition, subtraction, multiplication, determinant, inverse or transpose.
  2. Enter one matrix row per line, separating values with spaces or commas. Fraction entries such as 1/2 are accepted.
  3. For an operation using two matrices, enter Matrix B and check the dimensions.
  4. Select Calculate. Use Copy to copy the result; matrix cells are separated by tabs.

Formula and method

(AB)ᵢⱼ = Σₖ AᵢₖBₖⱼ; det([[a,b],[c,d]]) = ad − bc

When matrix dimensions are compatible

Addition and subtraction require the same number of rows and columns. For A × B, the number of columns in A must equal the number of rows in B. The product has the row count of A and the column count of B. Matrix multiplication generally depends on order: AB need not equal BA.

Determinant, inverse and transpose

A determinant is defined here for a square matrix. An inverse exists only for a nonsingular square matrix. For a 2 × 2 matrix, divide [[d,−b],[−c,a]] by ad−bc. A transpose swaps rows with columns and does not require a square matrix.

ONE TOOL, DIFFERENT TASKS

Choose the mode for your calculation

Scientific Calculator

Powers, roots, logarithms, trigonometry, factorials, combinations and permutations. Decimal and exact arithmetic fraction displays, Ans and memory.

Complex Number Calculator

Calculate with i. Read the rectangular result, magnitude, argument and conjugate. Angle units apply to the argument and trigonometric functions.

Matrix Calculator

Add, subtract and multiply matrices up to 4 × 4. Find a determinant, inverse or transpose. Matrix B is needed only for binary operations.

Numerical Calculus Calculator

Approximate a definite integral or a derivative at a real point. This is numerical calculus; it does not produce symbolic antiderivatives.

Equation Solver

Solve a quadratic, including complex roots, or a system of two or three simultaneous linear equations. Degenerate quadratic inputs are handled as linear equations.

Statistics Calculator

Find count, sum, mean, median, range endpoints, variance and standard deviation for up to 1,000 values. Choose sample or population statistics.

Base-N Calculator

Convert signed integers of up to 128 bits between binary, octal, decimal and hexadecimal. Bitwise operations use unsigned 32-bit operands.

Function Table Calculator

Evaluate a real-valued function over a range of x values. Choose start, end and step; each table supports up to 201 rows.

TRY IT YOURSELF

Matrix Calculator worked examples

Multiply two 2 × 2 matrices

A=[[1,2],[3,4]], B=[[5,6],[7,8]]

[[19,22],[43,50]]

The first cell is 1×5+2×7=19. Repeat each row-by-column dot product for the other cells.

Invert a nonsingular matrix

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

[[-2,1],[1.5,-0.5]]

The determinant is 1×4−2×3=−2. Dividing [[4,−2],[−3,1]] by −2 gives the inverse.

READ THE RESULT WITH CONTEXT

Accuracy, notation and limits

Enter rectangular matrices containing real numeric values, with at most four rows and four columns. Complex matrix entries and symbolic variables are not supported. Fraction inputs are evaluated numerically; matrix output is not an exact rational proof.

Ill-conditioned matrices can amplify rounding errors. For an inverse, check that A × A⁻¹ is approximately the identity matrix rather than relying only on a displayed determinant.

Read our calculation methodology ↗

COMMON QUESTIONS

Matrix Calculator FAQs

Can I multiply rectangular matrices?

Yes, provided the column count of A equals the row count of B and both matrices meet the 4 × 4 size limit.

Why does an inverse return an error?

The input must be square and nonsingular. A zero determinant means no inverse exists. A numerically unstable matrix may also fail or produce an inaccurate inverse.

How do I enter matrix rows?

Start a new line for each row. Enter spaces or commas between values and keep the same number of entries in every row.

Calculation library: math.js. This page is an independent CalcPebble tool.