Home | History | Annotate | Download | only in base

Lines Matching refs:expm1

2158 /* expm1(x)
2170 * 2. Approximating expm1(r) by a special rational function on
2196 * expm1(r) = exp(r)-1 is then computed by the following
2200 * expm1(r) = r + --- + --- * [--------------------]
2204 * expm1(r+c) = expm1(r) + c + expm1(r)*c
2205 * ~ expm1(r) + c + r*c
2207 * expm1(r+c). Now rearrange the term to avoid optimization
2211 * expm1(r+c)~r - ({r*(--- * [--------------------]-c)-c} - --- )
2216 * 3. Scale back to obtain expm1(x):
2218 * expm1(x) = either 2^k*[expm1(r)+1] - 1
2219 * = or 2^k*[expm1(r) + (1-2^-k)]
2223 * (B). To achieve maximum accuracy, we compute expm1(x) by
2234 * expm1(INF) is INF, expm1(NaN) is NaN;
2235 * expm1(-INF) is -1, and
2236 * for finite argument, only expm1(0)=0 is exact.
2244 * if x > 7.09782712893383973096e+02 then expm1(x) overflow
2252 double expm1(double x) {
2601 // |x| in [0,0.5*log2], return 1+expm1(|x|)^2/(2*exp(|x|))
2603 double t = expm1(fabs(x));
2641 * 0 <= x <= 22 : sinh(x) := --------------, E=expm1(x)
2665 double t = expm1(ax);
2697 * 2**-28 <= x < 1 : tanh(x) := -----; t = expm1(-2x)
2700 * 1 <= x < 22 : tanh(x) := 1 - -----; t = expm1(2x)
2731 t = expm1(two * fabs(x));
2734 t = expm1(-two * fabs(x));