Stochastic chains with memory of variable length
Stochastic chains with memory of variable length are a family of stochastic chains of finite order in a finite alphabet, such as, for every time pass, only one finite suffix of the past, called context, is necessary to predict the next symbol. These models were introduced in the information theory literature by Jorma Rissanen in 1983, as a universal tool to data compression, but recently have been used to model data in different areas such as biology, linguistics and music. Definition. A stochastic chain with memory of variable length is a stochastic chain  formula_1, taking values in a finite alphabet formula_2, and characterized by a probabilistic context tree formula_3, so that History. The class of stochastic chains with memory of variable length was introduced by Jorma Rissanen in the article "A universal system for data compression system". Such class of stochastic chains was popularized in the statistical and probabilistic community by P. Bühlmann and A. J. Wyner in 1999, in the article "Variable Length Markov Chains". Named by Bühlmann and Wyner as “variable length Markov chains” (VLMC), these chains are also known as “variable-order Markov models" (VOM), “probabilistic suffix trees” and “context  tree models”. The name “stochastic chains with memory of variable length” seems to have been introduced by Galves and Löcherbach, in 2008, in the article of the same name. Examples. Interrupted light source. Consider a system by a lamp, an observer and a door between both of them. The lamp has two possible states: on, represented by 1, or off, represented by 0. When the lamp is on, the observer may see the light through the door, depending on which state the door is at the time: open, 1, or closed, 0. such states are independent of the original state  of the lamp. Let formula_10 a Markov chain that represents the state of the lamp, with values in formula_11 and let formula_9 be a probability transition matrix. Also, let formula_13 be a sequence of independent random variables that represents the door's states, also taking values in formula_2, independent of the chain formula_10 and such that where formula_17. Define a new sequence formula_18 such that In order to determine the last instant that the observer could see the lamp on, i.e. to identify the least instant formula_21, with formula_22 in which formula_23. Using a context tree it's possible to  represent the past states of the sequence, showing which are relevant to identify the next state. The stochastic chain formula_24 is, then, a chain with memory of variable length, taking values in formula_2 and compatible with the probabilistic context tree formula_3, where Inferences in chains with variable length. Given a sample formula_28, one can find the appropriated context tree using the following algorithms. The context algorithm. In the article "A Universal Data Compression System", Rissanen introduced a consistent algorithm to estimate the probabilistic context tree that generates the data. This algorithm's function can be summarized in two steps: Be  formula_29 a sample of a finite probabilistic tree formula_3. For any sequence formula_31 with formula_32, it is possible to denote by formula_33 the number of occurrences of the sequence in the sample, i.e., Rissanen first built a context maximum candidate, given by formula_35, where formula_36 and formula_37 is an arbitrary positive constant. The intuitive reason for the choice of formula_38 comes from the impossibility of estimating the probabilities of sequence with lengths greater than formula_39 based in a sample of size formula_40. From there, Rissanen shortens the maximum candidate through successive cutting the branches according to a sequence of tests  based in statistical likelihood ratio. In a more formal definition, if bANnxk1b0 define the probability estimator of the transition probability formula_9 by where formula_43. If formula_44, define formula_45. To formula_46, define where formula_48 and Note that formula_50 is the ratio of the log-likelihood to test the consistency of the sample with the probabilistic context tree formula_3 against the alternative that is consistent with formula_52, where formula_4 and formula_54 differ only by a set of sibling knots. The length of the current estimated context is defined by where formula_37 is any positive constant. At last, by Rissanen, there's the  following result. Given formula_57 of a finite probabilistic context tree formula_3, then when formula_60. Bayesian information criterion (BIC). The estimator of the context tree by BIC with a penalty constant formula_61 is defined as Smallest maximizer criterion (SMC). The smallest maximizer criterion is calculated by selecting the smallest tree "τ" of a set of champion trees "C" such that