fpclassify

Is a macro that determines the floating-point class of an argument.

Library:LibC
Classification:ANSI
Service:Math

Syntax

  #include <math.h> 
   
  fpclassify ( x );
  

Parameters

x

(IN) Specifies the argument whose floating-point class is to be determined.

Return Values

Returns one of the following values:

Decimal

Flag

Description

1

FP_NAN

Not a number

2

FP_INFINITE

Infinity, + or -

3

FP_ZERO

Zero, + or -

4

FP_NORMAL

Normalized values

5

FP_SUBNORMAL

Denormalized values

Remarks

The macro can be used with double, float, and long double arguments.

See Also