FORTRAN Reference Manual
Intrinsic Functions
FORTRAN Reference Manual—528615-001
8-24
MIN Function
MIN Function
The MIN function returns the smallest number from its argument list.
The table below shows the argument and function type for the MIN generic function
and for its associated specific functions.
Considerations
•
All arguments to the MIN function must be of the same type.
•
The result type of the MIN function is the same as the type of its arguments.
•
You can specify up to 63 arguments to the MIN function. If you need to use more
than 63 arguments, you can distribute the arguments among several MIN functions
and then take the MIN of those functions:
MIN (MIN (a, b, c, ... , x), MIN (a1, b1, c1, ... , x1))
Example of the MIN Function
REAL mon
day = MIN (mon, tues, wed, thu, fri)
Syntax Argument Type Function Type
MIN (x1, ... , xn)
MIN0 (x1, ... , xn) Integer Integer
MIN04 (x1, ... , xn) Integer*4 Integer*4
MIN08 (x1, ... , xn) Integer*8 Integer*8
AMIN0 (x1, ... , xn) Integer Real
AMIN04 (x1, ... , xn) Integer*4 Real
AMIN08 (x1, ... , xn) Integer*8 Real
MIN1 (x1, ... , xn) Real Integer
MIN14 (x1, ... , xn) Real Integer*4
MIN18 (x1, ... , xn) Real Integer*8
AMIN1 (x1, ... , xn) Real Real
DMIN1 (x1, ... , xn) Double Precision Double Precision
Each xi is an arithmetic expression.










