Your Browser is not longer supported
Please use Google Chrome, Mozilla Firefox or Microsoft Edge to view the page correctly
Loading...
{{viewport.spaceProperty.prod}}
expm1, expm1f, expm1l - compute exponential function
&pagelevel(4)&pagelevel
Syntax | #include <math.h> double expm1(double x); C11 float expm1f(float x); long double expm1l(long double x); (End) |
Description | These functions compute ex-1.0. |
Return val. | e x -1.0 | if successful. |
| HUGE_VAL
HUGE_VALF
HUGE_VALL | depending on the function type, if an overflow occurs. errno is set to indicate the error. |
Errors | expm1() , expm1f() and expm1l() will fail if
|
| ERANGE
| Overflow; the return value is too high. |
Notes | For small x values, the result of expm1( x) can be more accurate than the value of exp( x) -1.0. The functions expm1() and log1p() are helpful for computing the expression ((1+x) n -1)/x, in the format:
expm1( n*log1p( x))/ x in the case of very small values of x. This function can also be used to precisely represent inverse hyperbolic functions. |
See also | exp() , ilogb() , log1p() , math.h .
|