mislabeled empty.matrix changed to initial.matrix
adding some comments
pseudocode for probabilities