hmm and msm example