Your computeEntropy function gives complex outputs. This way the condition Abs[Snew - Sold]/Snew < tolerance never becomes True, because Snew is complex.
computeEntropy
Abs[Snew - Sold]/Snew < tolerance
True
Snew