FREXP(3) NEWLIB FREXP(3)NAME
1.25 `frexp', `frexpf'--split floating-point number
SYNOPSIS
#include <math.h>
double frexp(double VAL, int *EXP);
float frexpf(float VAL, int *EXP);
DESCRIPTION
All nonzero, normal numbers can be described as M * 2**P. `frexp' rep‐
resents the double VAL as a mantissa M and a power of two P. The
resulting mantissa will always be greater than or equal to `0.5', and
less than `1.0' (as long as VAL is nonzero). The power of two will be
stored in `*'EXP.
M and P are calculated so that VAL is M times `2' to the power P.
`frexpf' is identical, other than taking and returning floats rather
than doubles.
RETURNS
`frexp' returns the mantissa M. If VAL is `0', infinity, or Nan,
`frexp' will set `*'EXP to `0' and return VAL.
PORTABILITY
`frexp' is ANSI. `frexpf' is an extension.
SEE ALSOfrexp is part of the library. The full documentation for is maintained
as a Texinfo manual. If info and are properly installed at your site,
the command
info
will give you access to the complete manual.
NEWLIB April 2010 FREXP(3)