HP-UX Floating-Point Guide

48 Chapter 2
Floating-Point Principles and the IEEE Standard for Binary Floating-Point Arithmetic
Floating-Point Formats
each component is a double-precision IEEE operand type. HP Fortran 90
and HP FORTRAN/9000 support both complex data types and a full
range of complex arithmetic operations.
NOTE HP Fortran 90 and HP FORTRAN/9000 also support the nonstandard
data type names DOUBLE COMPLEX and COMPLEX*16 (equivalent to
COMPLEX(KIND=8)) and COMPLEX*8 (equivalent to COMPLEX).
IEEE Representation Summary
Table 2-6, Table 2-7, Table 2-8, and Table 2-9 summarize how IEEE
values are represented in binary. To determine the class (normalized,
infinity, NaN, and so on) of a floating-point value at run time, you can
Use one of the following macros:
fpclassify to determine the value class
signbit to determine the sign
isnan to determine if the value is a NaN
isinf to determine if the value is an infinity
isfinite to determine if the value is finite (that is, neither
infinity nor NaN)
isnormal to determine if the value is normalized
See “Floating-Point Classification Macro” on page 116 for information
about fpclassify. See the online man pages for information about
all of these macros.
Provide code in your program that writes out the value in
hexadecimal (see “Displaying Floating-Point Values in Binary” on
page 77 for an example) and look up the value in Table 2-6 or Table
2-8
Examine the value in hexadecimal using the debugger