home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Power-Programmierung
/
CD1.mdf
/
xbase
/
library
/
clipper
/
rettig
/
source
/
mantissa.c
< prev
next >
Wrap
C/C++ Source or Header
|
1990-10-21
|
575b
|
29 lines
/*********
* MANTISSA.C
*
* by Ralph Davis
* modified by Tom Rettig
*
* Placed in the public domain by Tom Rettig Associates, 10/22/1990.
*
* Syntax: MANTISSA( <expN> )
* Return: Number times which 2^(EXPONENT(n)) is multiplied to give <expN>
*********/
#include "trlib.h"
TRTYPE mantissa()
{
if ( PCOUNT==1 && ISNUM(1) )
{
int expon;
double result, n;
n = _parnd(1);
result = _tr_frexp(n,&expon); /* Returns mantissa in result */
_retnd(result);
}
else
_retnd( (double)ERROR );
}