Skip to main content

Module log_base_10_1_plus_x

Module log_base_10_1_plus_x 

Source
Expand description

LogBase10Of1PlusX and LogBase10Of1PlusXAssign, traits for computing $\log_{10}(1+x)$ of Floats.

Functions§

primitive_float_log_base_10_1_plus_x
Computes $\log_{10}(1+x)$, the base-10 logarithm of one plus a primitive float. Using this function is more accurate than computing (1 + x).log10(), both because $1+x$ may not be representable as a primitive float and because the standard library’s log10 is not always correctly rounded.