logBase 10 erroneous

Basics.logBase is implemented as log number / log base, where log is just Math.log from Javascript. The rounding errors you are seeing comes from the floating-point division happening here.

There also exists Math.log10 in Javascript, which yields better results, but does not exist in Internet Explorer. As always, there already exists an issue matching your problem, and a pull request proposing to use said javascript function.

2 Likes