Using Math.log for compatiblity

Closes #246.
Good point.  Done.