MMULT
Supported, behaves as documentedCategory: Math and trigonometry · Last tested 2026-09-01
Real compatibility results for the MMULT function: executed in Excel for the web, Google Sheets and LibreOffice Calc, with desktop Excel behavior from Microsoft’s official documentation (we do not run desktop Excel — Excel for the web is a different application and is executed separately). Syntax and links to that documentation are below.
Support matrix
| Engine | Documented | Live-tested | Verdict |
|---|---|---|---|
| Excel (desktop) | Yes | No — documented only | n/a |
| Excel for the web | — | Yes (recalc, 2026-09-01) | Supported, behaves as documented |
| Google Sheets | Yes | Yes (Drive import, 2026-08-31) | Supported, behaves as documented |
| LibreOffice Calc | Yes | Yes (25.8.7.3, 2026-08-31) | Supported, behaves as documented |
LibreOffice version history
We executed the same test cases under each LibreOffice release to show exactly when MMULT’s support changed — not documentation claims, real results.
| LibreOffice version | Verdict | Tested |
|---|---|---|
| 24.2.0.3 | Supported, behaves as documented | 2026-08-31 |
| 24.8.7.2 | Supported, behaves as documented | 2026-08-31 |
| 25.2.0.3 | Supported, behaves as documented | 2026-08-31 |
| 25.8.7.3 | Supported, behaves as documented | 2026-08-31 |
Executed test cases
Excel for the web (executed 2026-09-01 via OneDrive recalculation)
These values come from Excel for the web, not from desktop Excel. They are two different implementations of the calculation engine, and this run measured only the web one: the corpus was uploaded to OneDrive as .xlsx, recalculated by Excel for the web on open, and downloaded again for readback. Excel for the web is a rolling service with no pinnable version, so the run is identified by its date. Where a value here disagrees with the Expected column — which is Microsoft’s documentation of the desktop product — we cannot tell you whether the web engine diverges from the desktop one or the documentation is wrong about both, because we do not run desktop Excel.
| Formula | Description | Result | Expected | Verdict |
|---|---|---|---|---|
| =MMULT(A2:B3,D2:E3) | The matrix product of two 2x2 ranges | {2, 6, 14, 4} | {{2.0, 6.0}, {14.0, 4.0}}ProvenanceDerived by hand from the documented definition -- the page gives the product as the sum over the shared index, a[i][j] = sum_k b[i][k]*c[k][j] -- in exact integer arithmetic: {1,3; 7,2} x {2,0; 0,2} = {1*2+3*0, 1*0+3*2; 7*2+2*0, 7*0+2*2} = {2,6; 14,4}. The second operand is deliberately a scaling matrix, so every entry of the answer is an obvious multiple of an entry of the first -- an engine that transposed an operand or summed along the wrong index cannot land on this result by accident. The page's own note that "The result is an array with the same number of rows as array1 and the same number of columns as array2" is what fixes the 2x2 shape of the check range. ENTERED AS AN ARRAY FORMULA. The page is explicit -- "the formula must be entered as a legacy array formula by first selecting the output range, entering the formula in the top-left-cell of the output range, and then pressing CTRL+SHIFT+ENTER" -- so the harness writes it as a legacy CSE array formula covering the whole result range, not as a plain scalar formula. Writing it as a scalar string makes even a fully supported matrix function return a single cell or #VALUE!, which would be a harness artefact rather than a finding. |
Matched |
| =MMULT(A2:C3,A6:B8) | A non-square product: a 2x3 array times a 3x2 array gives a 2x2 result | {58, 64, 139, 154} | {{58.0, 64.0}, {139.0, 154.0}}ProvenanceExact integer arithmetic on {1,2,3; 4,5,6} x {7,8; 9,10; 11,12}: 1*7+2*9+3*11 = 58, 1*8+2*10+3*12 = 64, 4*7+5*9+6*11 = 139, 4*8+5*10+6*12 = 154. This is the case that actually tests the documented shape rule -- "The number of columns in array1 must be the same as the number of rows in array2", and the result has array1's rows and array2's columns -- because unlike the square case the two operands are not interchangeable and the answer's dimensions differ from both inputs'. ENTERED AS AN ARRAY FORMULA. The page is explicit -- "the formula must be entered as a legacy array formula by first selecting the output range, entering the formula in the top-left-cell of the output range, and then pressing CTRL+SHIFT+ENTER" -- so the harness writes it as a legacy CSE array formula covering the whole result range, not as a plain scalar formula. Writing it as a scalar string makes even a fully supported matrix function return a single cell or #VALUE!, which would be a harness artefact rather than a finding. |
Matched |
| =INDEX(MMULT({1,3;7,2},{2,0,1}),1,1) | Operands whose inner dimensions do not match | #VALUE! | #VALUE!ProvenanceExcel documents: "MMULT returns the #VALUE! error when: ... The number of columns in array1 is different from the number of rows in array2." Array1 is 2x2 and array2 is 1x3, so the shared index is 2 on one side and 1 on the other and the product is undefined. |
Matched |
| =INDEX(MMULT(A2:B3,A2:B3),1,1) | A range containing a text cell, which the page excludes | #VALUE! | #VALUE!ProvenanceExcel documents: "MMULT returns the #VALUE! error when: Any cells are empty or contain text", and separately that "both arrays must contain only numbers". |
Matched |
| =INDEX(MMULT(A2:B3,D2:E3),2,1) | Multiplying by the identity matrix, which must return the operand unchanged | 7 | 7ProvenanceExact and structural: {1,3; 7,2} x {1,0; 0,1} = {1,3; 7,2}, so the entry at row 2 column 1 is 7. Nothing here depends on a derived constant -- the identity is the multiplicative unit of matrix multiplication -- so any conforming engine returns 7, and an engine that swapped its operands or its indices returns something else. |
Matched |
Google Sheets (executed 2026-08-31 via Drive import)
Google Sheets is a rolling service with no pinnable version, so this run is identified by its date. The corpus was imported to Drive as .xlsx, recalculated by Sheets, and exported back for readback.
| Formula | Description | Result | Expected | Verdict |
|---|---|---|---|---|
| =MMULT(A2:B3,D2:E3) | The matrix product of two 2x2 ranges | {2, 6.0, 14.0, 4.0} | {{2.0, 6.0}, {14.0, 4.0}}ProvenanceDerived by hand from the documented definition -- the page gives the product as the sum over the shared index, a[i][j] = sum_k b[i][k]*c[k][j] -- in exact integer arithmetic: {1,3; 7,2} x {2,0; 0,2} = {1*2+3*0, 1*0+3*2; 7*2+2*0, 7*0+2*2} = {2,6; 14,4}. The second operand is deliberately a scaling matrix, so every entry of the answer is an obvious multiple of an entry of the first -- an engine that transposed an operand or summed along the wrong index cannot land on this result by accident. The page's own note that "The result is an array with the same number of rows as array1 and the same number of columns as array2" is what fixes the 2x2 shape of the check range. ENTERED AS AN ARRAY FORMULA. The page is explicit -- "the formula must be entered as a legacy array formula by first selecting the output range, entering the formula in the top-left-cell of the output range, and then pressing CTRL+SHIFT+ENTER" -- so the harness writes it as a legacy CSE array formula covering the whole result range, not as a plain scalar formula. Writing it as a scalar string makes even a fully supported matrix function return a single cell or #VALUE!, which would be a harness artefact rather than a finding. |
Matched |
| =MMULT(A2:C3,A6:B8) | A non-square product: a 2x3 array times a 3x2 array gives a 2x2 result | {58, 64.0, 139.0, 154.0} | {{58.0, 64.0}, {139.0, 154.0}}ProvenanceExact integer arithmetic on {1,2,3; 4,5,6} x {7,8; 9,10; 11,12}: 1*7+2*9+3*11 = 58, 1*8+2*10+3*12 = 64, 4*7+5*9+6*11 = 139, 4*8+5*10+6*12 = 154. This is the case that actually tests the documented shape rule -- "The number of columns in array1 must be the same as the number of rows in array2", and the result has array1's rows and array2's columns -- because unlike the square case the two operands are not interchangeable and the answer's dimensions differ from both inputs'. ENTERED AS AN ARRAY FORMULA. The page is explicit -- "the formula must be entered as a legacy array formula by first selecting the output range, entering the formula in the top-left-cell of the output range, and then pressing CTRL+SHIFT+ENTER" -- so the harness writes it as a legacy CSE array formula covering the whole result range, not as a plain scalar formula. Writing it as a scalar string makes even a fully supported matrix function return a single cell or #VALUE!, which would be a harness artefact rather than a finding. |
Matched |
| =INDEX(MMULT({1,3;7,2},{2,0,1}),1,1) | Operands whose inner dimensions do not match | #VALUE! | #VALUE!ProvenanceExcel documents: "MMULT returns the #VALUE! error when: ... The number of columns in array1 is different from the number of rows in array2." Array1 is 2x2 and array2 is 1x3, so the shared index is 2 on one side and 1 on the other and the product is undefined. |
Matched |
| =INDEX(MMULT(A2:B3,A2:B3),1,1) | A range containing a text cell, which the page excludes | #VALUE! | #VALUE!ProvenanceExcel documents: "MMULT returns the #VALUE! error when: Any cells are empty or contain text", and separately that "both arrays must contain only numbers". |
Matched |
| =INDEX(MMULT(A2:B3,D2:E3),2,1) | Multiplying by the identity matrix, which must return the operand unchanged | 7 | 7ProvenanceExact and structural: {1,3; 7,2} x {1,0; 0,1} = {1,3; 7,2}, so the entry at row 2 column 1 is 7. Nothing here depends on a derived constant -- the identity is the multiplicative unit of matrix multiplication -- so any conforming engine returns 7, and an engine that swapped its operands or its indices returns something else. |
Matched |
LibreOffice Calc 25.8.7.3 (tested 2026-08-31)
| Formula | Description | Result | Expected | Verdict |
|---|---|---|---|---|
| =MMULT(A2:B3,D2:E3) | The matrix product of two 2x2 ranges | {2, 6, 14, 4} | {{2.0, 6.0}, {14.0, 4.0}}ProvenanceDerived by hand from the documented definition -- the page gives the product as the sum over the shared index, a[i][j] = sum_k b[i][k]*c[k][j] -- in exact integer arithmetic: {1,3; 7,2} x {2,0; 0,2} = {1*2+3*0, 1*0+3*2; 7*2+2*0, 7*0+2*2} = {2,6; 14,4}. The second operand is deliberately a scaling matrix, so every entry of the answer is an obvious multiple of an entry of the first -- an engine that transposed an operand or summed along the wrong index cannot land on this result by accident. The page's own note that "The result is an array with the same number of rows as array1 and the same number of columns as array2" is what fixes the 2x2 shape of the check range. ENTERED AS AN ARRAY FORMULA. The page is explicit -- "the formula must be entered as a legacy array formula by first selecting the output range, entering the formula in the top-left-cell of the output range, and then pressing CTRL+SHIFT+ENTER" -- so the harness writes it as a legacy CSE array formula covering the whole result range, not as a plain scalar formula. Writing it as a scalar string makes even a fully supported matrix function return a single cell or #VALUE!, which would be a harness artefact rather than a finding. |
Matched |
| =MMULT(A2:C3,A6:B8) | A non-square product: a 2x3 array times a 3x2 array gives a 2x2 result | {58, 64, 139, 154} | {{58.0, 64.0}, {139.0, 154.0}}ProvenanceExact integer arithmetic on {1,2,3; 4,5,6} x {7,8; 9,10; 11,12}: 1*7+2*9+3*11 = 58, 1*8+2*10+3*12 = 64, 4*7+5*9+6*11 = 139, 4*8+5*10+6*12 = 154. This is the case that actually tests the documented shape rule -- "The number of columns in array1 must be the same as the number of rows in array2", and the result has array1's rows and array2's columns -- because unlike the square case the two operands are not interchangeable and the answer's dimensions differ from both inputs'. ENTERED AS AN ARRAY FORMULA. The page is explicit -- "the formula must be entered as a legacy array formula by first selecting the output range, entering the formula in the top-left-cell of the output range, and then pressing CTRL+SHIFT+ENTER" -- so the harness writes it as a legacy CSE array formula covering the whole result range, not as a plain scalar formula. Writing it as a scalar string makes even a fully supported matrix function return a single cell or #VALUE!, which would be a harness artefact rather than a finding. |
Matched |
| =INDEX(MMULT({1,3;7,2},{2,0,1}),1,1) | Operands whose inner dimensions do not match | #VALUE! | #VALUE!ProvenanceExcel documents: "MMULT returns the #VALUE! error when: ... The number of columns in array1 is different from the number of rows in array2." Array1 is 2x2 and array2 is 1x3, so the shared index is 2 on one side and 1 on the other and the product is undefined. |
Matched |
| =INDEX(MMULT(A2:B3,A2:B3),1,1) | A range containing a text cell, which the page excludes | #VALUE! | #VALUE!ProvenanceExcel documents: "MMULT returns the #VALUE! error when: Any cells are empty or contain text", and separately that "both arrays must contain only numbers". |
Matched |
| =INDEX(MMULT(A2:B3,D2:E3),2,1) | Multiplying by the identity matrix, which must return the operand unchanged | 7 | 7ProvenanceExact and structural: {1,3; 7,2} x {1,0; 0,1} = {1,3; 7,2}, so the entry at row 2 column 1 is 7. Nothing here depends on a derived constant -- the identity is the multiplicative unit of matrix multiplication -- so any conforming engine returns 7, and an engine that swapped its operands or its indices returns something else. |
Matched |
Docs & syntax
- Excel (desktop): official documentation
- Google Sheets: official documentation
- LibreOffice Calc: official documentation