LogExpMath

Provides high-precision mathematical functions for logarithmic and exponential operations, which are crucial in many DeFi reward calculations (e.g., bonding curves, APY adjustments, dynamic pricing). Solidity lacks native high-precision log/exp functions, so this library ensures safe and accurate computations.

Exponentiation and logarithm functions for 18 decimal fixed point numbers (both base and exponent/argument). Exponentiation and logarithm with arbitrary bases (x^y and log_x(y)) are implemented by conversion to natural. Exponentiation and logarithm (where the base is Euler's number).

Last updated

Was this helpful?