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

  man pages->FreeBSD man pages -> remainder (3)              
Title
Content
Arch
Section
 

IEEE(3)

Contents


NAME    [Toc]    [Back]

     copysign, copysignf, finite, finitef, ilogb, ilogbf, nextafter,
     nextafterf, remainder, remainderf, scalbn, scalbnf -- functions for IEEE
     arithmetic

LIBRARY    [Toc]    [Back]

     Math Library (libm, -lm)

SYNOPSIS    [Toc]    [Back]

     #include <math.h>

     double
     copysign(double x, double y);

     float
     copysignf(float x, float y);

     int
     finite(double x);

     int
     finitef(float x);

     int
     ilogb(double x);

     int
     ilogbf(float x);

     double
     nextafter(double x, double y);

     float
     nextafterf(float x, float y);

     double
     remainder(double x, double y);

     float
     remainderf(float x, float y);

     double
     scalbn(double x, int n);

     float
     scalbnf(float x, int n);

DESCRIPTION    [Toc]    [Back]

     These functions are required or recommended by IEEE Std 754-1985.

     copysign() and copysignf() return x with its sign changed to y's.

     finite() and finitef() return the value 1 just when -infinity < x <
     +infinity; otherwise a zero is returned (when |x| = infinity or x is
     NaN).

     ilogb() and ilogbf() return x's exponent, in integer format.
     ilogb(+-infinity) returns INT_MAX and ilogb(0) returns INT_MIN.

     nextafter() and nextafterf() return the next machine representable number
     from x in direction y.

     remainder() and remainderf() return the remainder r := x - n*y where n is
     the integer nearest the exact value of x/y; moreover if |n - x/y| = 1/2
     then n is even.  Consequently the remainder is computed exactly and |r|
     <= |y|/2.	But remainder(x, 0) and remainder(infinity, 0) are invalid
     operations that produce a NaN.

     scalbn() and scalbnf() return x*(2**n) computed by exponent manipulation.

SEE ALSO    [Toc]    [Back]

      
      
     math(3)

HISTORY    [Toc]    [Back]

     The ieee functions appeared in 4.3BSD.

STANDARDS    [Toc]    [Back]

     IEEE Std 754-1985


FreeBSD 5.2.1		       February 25, 1994		 FreeBSD 5.2.1
[ Back ]
 Similar pages
Name OS Title
ieee_functions Tru64 Related miscellaneous IEEE arithmetic functions.
nextafter Tru64 Related miscellaneous IEEE arithmetic functions.
unordered Tru64 Related miscellaneous IEEE arithmetic functions.
copysign Tru64 Related miscellaneous IEEE arithmetic functions.
isnan Tru64 Related miscellaneous IEEE arithmetic functions.
finite Tru64 Related miscellaneous IEEE arithmetic functions.
fp_class Tru64 Related miscellaneous IEEE arithmetic functions.
significandf FreeBSD IEEE test functions
scalbf FreeBSD IEEE test functions
ieee_test NetBSD IEEE test functions
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service