FORTRAN Reference Manual
Intrinsic Functions
FORTRAN Reference Manual—528615-001
8-14
DIM Function
DIM Function
The DIM function returns a positive difference.
The table below shows the argument and function type for the DIM generic function
and its associated specific functions.
Considerations
•
The result type of the DIM function is the same as the type of its arguments. Both
arguments must be the same type.
•
The value of DIM (x, y) is
x - y, if x > y
y - x, if x ≤ y.
Example of the DIM Function
difference = DIM (a, b)
DPROD Function
The DPROD function returns a double precision product.
x
y
are arithmetic expressions of type real.
Syntax Argument Type Function Type
DIM (x, y)
DIM (x, y)Real Real
IDIM (x, y) Integer Integer
IDIM4 (x, y) Integer*4 Integer*4
IDIM8 (x, y) Integer*8 Integer*8
DDIM (x, y) Double Precision Double Precision
x and y are arithmetic expressions.
DPROD (x, y)










