Math and Trignometric - MMULT Function



Description

The MMULT function returns the matrix product of two arrays array1 and array2. The result is an array with the same number of rows as array1 and the same number of columns as array2.

Syntax

MMULT (array1, array2)

Arguments

Argument Description Required/Optional
Array1 The arrays you want to multiply. Required
Array2 Required

Notes

  • The number of columns in Array1 must be the same as the number of rows in Array2, and both arrays must contain only numbers.

  • Array1 and Array2 can be given as cell ranges, array constants, or references.

  • The matrix product array a of two arrays b and c is −

    $$a_{ij} = \sum_{k=1}^{n}b_{ik}c_{kj}$$

    Where i is the row number, and j is the column number.

  • Formulas that return arrays must be entered as array formulas

  • MMULT returns the #VALUE! error when

    • Any of the cells is empty or contains a non-numeric value

    • The number of columns in Array1 is different from the number of rows in Array2

  • If you select additional cells that are not part of the resulting matrix, MMULT returns the #N/A error value in these cells.

  • If you do not highlight the full range of cells for the resulting matrix, Excel will just show the part of the result that fits into the highlighted range. There will be no error message to let you know that your highlighted range is not big enough.

  • If you do not enter the formula as an array formula, the cell in which you enter the formula will just show you the first entry of the resulting matrix and there will be no error message.

Applicability

Excel 2007, Excel 2010, Excel 2013, Excel 2016

Example

MMULT Function
advanced_excel_math_trigonometric_functions.htm
Advertisements