![]() Chapter Contents |
![]() Previous |
![]() Next |
| expm1 |
| Portability: | C99 |
| SYNOPSIS | |
| DESCRIPTION | |
| RETURN VALUE | |
| DIAGNOSTICS | |
| RELATED FUNCTIONS | |
| SEE ALSO |
| SYNOPSIS |
#include <math.h> double expm1(double x); float expm1f(float x); long double expm1l(long double x);
| DESCRIPTION |
exmp1 computes the exponential
function of its argument x. This function is
expressed by the relation:
where e is the base of natural
logarithms, 2.7128...
The function name expm1f should be used
for float arguments, and expm1l for long double arguments.
Alternately, if the header file tgmath.h is
included, expm1 may be used with any numeric
argument type.
| RETURN VALUE |
expm1 returns the exponential
function of its argument minus 1, provided this value is expressible.
| DIAGNOSTICS |
If the result of expm1
is too large to represent, it returns HUGE_VAL
in hexadecimal floating point, and either infinity or the largest finite value
in binary floating point, depending on the rounding mode. In this case, the
run-time library writes an error message to the standard error file (stderr).
If an error occurs in expm1, the
_matherr or _matherb routine
is called. You can supply your own version of _matherr
or _matherb to suppress the diagnostic message
or modify the value returned.
| RELATED FUNCTIONS |
exp, log1p, _matherb,
_matherr
| SEE ALSO |
"Mathematical Functions" in Chapter 2, "Function Categories"
![]() Chapter Contents |
![]() Previous |
![]() Next |
![]() Top of Page |
Copyright © 2004 by SAS Institute Inc., Cary, NC, USA. All rights reserved.