The backward algorithm (also backward algorithm, backward procedure) uses backward variables to calculate the probability of observing a certain symbol sequence in a given hidden Markov model (HMM). The algorithm uses the programming method of dynamic programming .
the initial probability distribution for the possible initial states,
designated.
Task and backward variables
Given a word . The backward algorithm now calculates the probability of actually making the observation in the existing model .
The backward variables are used for this; they indicate the probability of observing the suffix if the HMM was in the state at the time :
algorithm
The backward variables are determined recursively:
initialization
Recursion
Termination
complexity
The matrix of all backward variables needs memory, if the intermediate results are no longer used, the space requirement is reduced , since only two columns of length are required to save the values of and in each recursion step.
Lines are totaled for each individual variable , so the runtime is in .
Other uses
The backward variables are required together with the forward variables for the Baum-Welch algorithm to solve the learning problem given with hidden Markov models.
In addition, knowledge of this enables the determination of the probability of having been in the state at a fixed point in time when observing , because according to Bayes' theorem:
Richard Durbin, Sean R. Eddy, Anders Krogh, Graeme Mitchison: Biological sequence analysis. Probabilistic models of proteins and nucleic acids . 11th printing, corrected 10th reprinting. Cambridge University Press, Cambridge et al. 2006, ISBN 0-521-62971-3 , pp.59-60 .
Web links
Ernst G. Schukat-Talamazzini: Special pattern analysis systems. (PDF, 1.3 MB). Lecture in the winter semester 2012/2013 at the University of Jena. Chapter 5, slide 34 ff.