log package:base
log1mexp x computes
log (1 - exp
x), but provides more precise results if possible.
Examples:
- if x is a large negative number, log (1 -
exp x) will be imprecise for the reasons given in
log1p.
- if exp x is close to 1, log (1
- exp x) will be imprecise for the reasons given in
expm1.
log1p x computes
log (1 + x), but
provides more precise results for small (absolute) values of
x if possible.
log1pexp x computes
log (1 + exp
x), but provides more precise results if possible.
Examples:
- if x is a large negative number, log (1 +
exp x) will be imprecise for the reasons given in
log1p.
- if exp x is close to -1, log
(1 + exp x) will be imprecise for the reasons given in
expm1.
Default implementation for
log1mexp requiring
Ord to test against a threshold to decide which
implementation variant to use.
Compatibility module for pre-ghc-bignum code.
Log base 2 (round down) of natural numbers. Log 0 is
undefined (i.e., it cannot be reduced).
Immediately flush the event log, if enabled.