Calculates
ex -
1
. For values of x close to 0, the exact sum of
expm1(x) + 1
is much closer to
the true result of
ex
than exp(x)
.
Reading time: 0 minutes
Calculates
ex -
1
. For values of x close to 0, the exact sum of
expm1(x) + 1
is much closer to
the true result of
ex
than exp(x)
.