Max

Max[x1,x2,]

yields the numerically largest of the xi.

Max[{x1,x2,},{y1,},]

yields the largest element of any of the lists.

Details

  • Max yields a definite result if all its arguments are real numbers.
  • In other cases, Max carries out some simplifications.
  • Max[] gives -Infinity.
  • Max works on SparseArray objects.

Examples

open allclose all

Basic Examples  (2)

Maximum of two numbers:

In[1]:=
Click for copyable input
Out[1]=

Maximum of a list:

In[1]:=
Click for copyable input
Out[1]=

Scope  (8)

Generalizations & Extensions  (1)

Applications  (5)

Properties & Relations  (6)

Possible Issues  (2)

Neat Examples  (2)

See Also

Min  MinMax  TakeLargest  MaximalBy  RankedMax  RankedMin  Ordering  Maximize  FindMaximum  MaxDetect  Clip

Tutorials

Introduced in 1988
(1.0)
| Updated in 2003
(5.0)