Updated handling of logarithms. Fixed small bug in Blackboard clause handling.