Matrix Addition and Subtraction Calculator
Add, subtract, and scale matrices up to 12×12 in exact fractions. Compute any αA ± βB and see each entry combine.
Matrices
A and B always share a size, because entries are combined position by position. Resize either one, and the other follows.
Up to 12 rows and 12 columns.
Use integers, decimals, or fractions such as 1/3. Paste rows from a spreadsheet or a Python list into any cell.
Combination
To multiply one matrix by a number, set the other's multiplier to 0.
Input
Result
Updates as you type.
Entry by entry
Each entry of the result uses only the entries in the same position of A and B. Step through to combine them.
How to add and subtract matrices
Two matrices of the same size combine position by position. The entry in row , column of the result uses only the entries in that same position:
The sizes have to match, because otherwise some positions have no partner. That's why this calculator keeps A and B the same size. Multiplication has a different rule, which the Matrix Multiplication Calculator covers.
Scalar multiplication and combinations
Multiplying a matrix by a number scales every entry. Together with addition, this gives every combination:
To scale a single matrix here, set the other's multiplier to . Fractions stay exact, so never picks up rounding error.
Rules worth knowing
Matrix addition behaves like adding numbers:
- Order doesn't matter. , unlike multiplication.
- Grouping doesn't matter. .
- Zero changes nothing. Adding the zero matrix leaves as it is.
- Scaling distributes. .
Addition also pairs well with the Matrix Transpose Calculator: . However, the determinant doesn't add, so usually isn't . Try it with the Determinant Calculator.
Related calculators
Keep working with matrices.
Matrix Calculator
Type a whole matrix expression such as 2AᵀB⁻¹ + I and get an exact answer, with every operation in order, plus the rank, determinant, and other properties of the result.
Matrix Multiplication Calculator
Multiply two to four matrices with exact fractions, entry-by-entry explanations, and Python list import and export.
Matrix Transpose Calculator
Transpose matrices up to 12×12 in exact fractions, watch rows become columns, and check whether a matrix is symmetric or skew-symmetric.
Determinant Calculator
Find the determinant of a square matrix with exact fractions, drag a live area picture, and step through elimination or cofactor expansion.