beta partially re-written for semi-markov