max
Syntax
Description
returns the
maximum elements of a symbolic input.M
= max(A
)
If
A
is a vector, thenmax(A)
returns the maximum ofA
.If
A
is a matrix, thenmax(A)
is a row vector containing the maximum value of each column.
For an input A
that contains symbolic expression, the
symbolic max
function returns an unevaluated expression that is reduced
by eliminating arguments that do not represent maximum values. The output may have another
argument that represents the condition for the symbolic variable. For example,
syms x; max([1 x])
returns the output max([1, x], [], 2,
'Omitnan', ~in(x, 'real'))
in the Command Window since x
is
complex.