How to evaluate logarithms