bug fix in probability calculation