This should be a somewhat fast and numerically stable implementation of a subset of hidden Markov algorithms.