BigInteger.js icon indicating copy to clipboard operation
BigInteger.js copied to clipboard

added log() and log10 functions

Open wopperer opened this issue 3 years ago • 3 comments
trafficstars

wopperer avatar Dec 17 '21 12:12 wopperer

ok do you want me to just return the number? return s.length + Math.log10("0."+s.substring(0,15));

wopperer avatar Dec 17 '21 14:12 wopperer

Logarithms are not integer operations, I'm not sure they fit the scope of this library.

peterolson avatar Dec 17 '21 20:12 peterolson

That's sad if they don't fit here, because there are numerous use cases (like astronomical calculations) where you need logarithms of big integers, and they are not supported by ECMA yet.

wopperer avatar Dec 17 '21 21:12 wopperer