Matrix Commands
Matrix Commands
Matrix Commands
in Excel
Anthony Murphy
Nuffield College
[email protected]
Matrix Commands in Excel
Excel can perform some useful, albeit basic, matrix
operations:
• Addition & subtraction;
• Scalar multiplication & division;
• Transpose (TRANSPOSE);
• Matrix multiplication (MMULT);
• Matrix inverse (MINVERSE);
• Determinant of matrix (MDETERM);
As well as combinations of these operations.
Matrix Commands in Excel (Cont’d)
• In Excel the matrix commands (and some
other commands) are called ARRAY
commands.
• Can perform more complicated operations
using free add-ins for Excel e.g. MATRIX.
• Alternatively, can use matrix package like
MATLAB (which also does symbolic maths
& matrix algebra).
Excel (Cont’d)
• The matrix commands in Excel are
sufficient for this course.
• If you are really keen, you can play around
with Visual Basic for Applications (VBA),
the Excel programming language.
• For example, see Benninga, S. (2000),
Financial Modelling, MIT Press.
Named Cells
• Most Excel formulae require you to name one or
more cell ranges e.g. b2.c4.
• You can type these in directly or select them
using the mouse.
• However, it is often better to use a named range.
• To assign a name to a range of cells, highlight it
using the mouse and choose Insert ►Name ►
Define and enter a name.
• Choose a useful name.
• Remember Excel does not distinguish between
the names PRICE, Price and price.
Entering a Matrix
• Choose a location for the matrix (or vector)
and enter the elements of the matrix.
• Highlight the cells of the matrix and
choose INSERT ► NAME ► DEFINE.
• Enter a name for the matrix.
• You can now use the name of the matrix in
formulae.
Addition, Subtraction and Scalar
Multiplication Etc.