What is the MMULT function?
=MMULT(array1, array2)MMULT multiplies two matrices. Each result cell pairs one row of array1 with one column of array2, multiplies and adds.
array1's column count must equal array2's row count, and the result has (array1 rows) × (array2 columns). A2:C4 is matrix 1, E2:G4 is matrix 2, and the result fills from column I. Drag a range to change the matrix size.
Arguments
- array1
- The left matrix. A blank or text cell returns #VALUE!.
- array2
- The right matrix.
MMULT examples
Example 1. 2×2 product
=MMULT(A2:B3, E2:F3){19,22;43,50}. The first cell is 1×5+2×7=19.
Example 2. 2×3 result
=MMULT(A2:B3, E2:G3)The result has 2 rows and 3 columns.
Common mistakes
Sizes don't fit
If array1's column count differs from array2's row count, you get #VALUE!.
Order of multiplication
MMULT(A,B) and MMULT(B,A) are usually different.
FAQ
- In older versions?
- Select the result range first, type the formula and press Ctrl+Shift+Enter.
- Multiply matching cells?
- Use =A2:B3*E2:F3. That is different from a matrix product.