(symbolic, multidimensional) arrays
MuPAD® notebooks are not recommended. Use MATLAB® live scripts instead.
MATLAB live scripts support most MuPAD functionality, though there are some differences. For more information, see Convert MuPAD Notebooks to MATLAB Live Scripts.
DOM_ARRAY is a multidimensional container
type, storing arbitrary MuPAD® objects at integer indices.
Arrays are a fundamental data type in many programming languages: For a fixed number of indices (“dimensions”), for each index an integer from a fixed range, an array provides space to store an arbitrary piece of data at this combination.
Using an array as a function symbol creates the list obtained
by using each array entry as a function symbol for the operands used,
array(1..2, [f, g])(x, y) results in
[f(x, y), g(x, y)]).
As with any container, the most important operation on an array
is reading and writing its entries, which is performed by indexed access, as in
A[1, 2] or
3, 2] := exp(x). Trying to access an element outside the
boundaries of an array raises an error.
some function or transformation to each element of an array, returning
an array of the same format as its input, with the results of the
calls as its entries.
A is an array,
the number of elements in
A is an array, the 0th
op(A, 0), will
be the sequence starting with the number of dimensions (an integer n)
followed by n ranges
of integers, which denote the acceptable ranges of indices for each
dimension, including both numbers listed in the range.
For 1 ≤ i ≤ nops(A),
A is the ith
A, in the lexicographic order of indices.
One-dimensional arrays are displayed as row vectors, two-dimensional
arrays as matrices. Higher-dimensional arrays are written in functional
form, using the
index = value notation, and do
not have a typesetting version. This also causes typesetting to be
disabled for any surrounding expression in the same output.
The primary way of creating arrays is the function
array. Beside that,
convert a number of data types, such as matrices into
arrays and a number of MuPAD functions, especially in the