Fixed division by zero when calculating probabilities of phases without parameters.