using log to calc probabilities