*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->IRIX man pages -> isnan (3c)              


isnan(3C)							     isnan(3C)

NAME    [Toc]    [Back]

     isnan, isnand, isnanf, finite, fpclass, unordered,	isnanl,	finitel,
     fpclassl, unorderedl - determine type of floating-point number

SYNOPSIS    [Toc]    [Back]

     #include <ieeefp.h>

     int isnand	(double	dsrc);

     int isnanf	(float fsrc);

     int finite	(double	dsrc);

     fpclass_t fpclass (double dsrc);

     int unordered (double dsrc1, double dsrc2);

     fpclass_t fpclassl	(long double dsrc);

     int finitel (long double dsrc);

     int unorderedl (long double dsrc1,	long double dsrc2);

     #include <math.h>

     int isnan (double dsrc);

     int isnanl	(long double dsrc);

DESCRIPTION    [Toc]    [Back]

     (Note that	the long double	routines are only valid	for the	MIPSpro
     compilers.)  Long double functions	have been renamed to be	compliant with
     the ANSI-C	standard, however to be	backward compatible, they may still be
     called with the double precision function name prefixed with a q.
     (Exception:  function isnanl may be called	with the name isnanq.)

     isnan, isnand, isnanf, and	isnanl return true (1) if the argument dsrc or
     fsrc is a NaN; otherwise they return false	(0).  The functionality	of
     isnan is identical	to that	of isnand.

     fpclass and fpclassl return the class the dsrc belongs to.	 The 10
     possible classes are as follows:

	  FP_SNAN      signaling NaN
	  FP_QNAN      quiet NaN
	  FP_NINF      negative	infinity
	  FP_PINF      positive	infinity
	  FP_NDENORM   negative	denormalized non-zero
	  FP_PDENORM   positive	denormalized non-zero
	  FP_NZERO     negative	zero
	  FP_PZERO     positive	zero

									Page 1

isnan(3C)							     isnan(3C)

	  FP_NNORM     negative	normalized non-zero
	  FP_PNORM     positive	normalized non-zero

     In	the case of long doubles, non-zero numbers less	than 2**-916 in
     absolute value are	classified as denormalized, since one of the numbers
     used in their representation may be a denormal double.

     finite and	finitel	return true (1)	if the argument	dsrc is	neither
     infinity nor NaN; otherwise they return false (0).

     unordered and unorderedl return true (1) if one of	their two arguments is
     unordered with respect to the other argument.  This is equivalent to
     reporting whether either argument is NaN.	If neither of the arguments is
     NaN, false	(0) is returned.

     None of these routines generate any exceptions, even for signaling	NaNs.

     Note that the SVR4	function fpclass is distinct from the functions
     documented	in fp_class(3C).

SEE ALSO    [Toc]    [Back]

     fpgetround(3C), fp_class(3C), intro(3M).

									PPPPaaaaggggeeee 2222
[ Back ]
 Similar pages
Name OS Title
signbit FreeBSD determine whether a floating-point number's sign is negative
cvt_ftof Tru64 Converts a floating-point data type to another
isfinite FreeBSD classify a floating-point number
isinf FreeBSD classify a floating-point number
fabs Linux absolute value of floating-point number
isnan FreeBSD classify a floating-point number
uitrunc Tru64 truncate a floating-point number
isnormal FreeBSD classify a floating-point number
fpclassify FreeBSD classify a floating-point number
itrunc Tru64 truncate a floating-point number
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service