ieee_is_normal
- Date:
10-12-2011
NAME
IEEE_IS_NORMAL - Tests if x is normal
SYNOPSIS
IEEE_IS_NORMAL ([X=]x)
IMPLEMENTATION
Cray Linux Environment (CLE)
STANDARDS
Fortran
IEEE Standard for Binary Floating-point Arithmetic
DESCRIPTION
The IEEE_IS_NORMAL intrinsic function returns the value TRUE if x is normal, that is, x is not an infinity, a NaN, nor a denormal. Otherwise, IEEE_IS_NORMAL returns the value FALSE.
IEEE_IS_NORMAL accepts the following argument:
- x
Must be of type real.
IEEE_IS_NORMAL is an elemental function. The name of this intrinsic cannot be passed as an argument.
IEEE_IS_NORMAL will not be invoked if IEEE_SUPPORT_DATATYPE(X) has the value false.
NOTES
The IEEE intrinsic procedures use the named constants contained in a system module, so you must include the following statement in your program:
USE, INTRINSIC :: IEEE_ARITHMETIC
RETURN VALUES
The result type and type parameter is default logical.
The result has the value true if the value of x is normal. That is, the IEEE_CLASS(x) must be one of the following values:
IEEE_NEGATIVE_NORMAL
IEEE_NEGATIVE_ZERO
IEEE_POSITIVE_NORMAL
IEEE_POSITIVE_ZERO
EXAMPLES
Example 1:
USE, INTRINSIC :: IEEE_ARITHMETIC
REAL x
! Compute X.
IF (IEEE_IS_NORMAL(x)) THEN
! Do something.
ELSE
! Do something else.
END IF
SEE ALSO
ieee_suppport_datatype(3i)