Confusion about hidden Markov model I've gone through Hidden Markov models (HMM) for the past few months. However there are a few things that are confusing.
The set up is simple: I have to model some human gestures such as walking, jumping, and falling. The observed data have been obtained via an accelerometer while the person was doing the movements.
I trained theses observations using the famous Baum-Welch algorithm to get the parameters of an HMM for some states. Further, using the Forward and Backward procedures, the likelihood of the observation sequences given the model (i.e., the parameters) were found.
Using a model selection criteria such as Akaike information criterion (AIC), I got the optimum states that represented the data: 
a)Walking: 2 states
b)jumping: 2 states
c)Falling: 4 states

All these HMMs are then stored in a directory.
Lastly, Viterbi decoding is used to get the most likely sequence of hidden states that produced the data.
My questions are:


*

*Suppose I performed the experiment again and I just get the data without knowing what kind of movement has been done. After getting the data trained, I got 2 states. How will the machine differentiate which kind of movement has been done, especially if walking and jumping are represented by 2 states?

*Suppose the person has performed a different kind of gesture, e.g., sliding, what is the expected output after training? Will the machine be able to detect that or generate a false negative result?
 A: Let us start with the second part because it is easy. An trained HMM cannot output an unknown state. For instance if you train a speech recognition algorithm for Danish sounds and you play the sound of a car accident, the model will output a Danish sound.
Regarding the first part, you can run your 3 HMMs and return the log-likelihood. You can then pick the one that has the highest log-likelihood, or use BIC or AIC to choose which model is more appropriate.
I have to add that this is not a standard way of using HMMs. In general, you build a single HMM in which the states correspond to the inference you want to make. This means that you would have a single model with 3 states (walk, jump, fall), or more if each corresponds to a succession of typical moves. In my opinion, your best option is to build a model with 8 parameters, but you still have to estimate the transitions between walk, jump and fall. This way you will be able to decompose a long sequence of measurements in discrete segments where the person is walking, jumping or falling.
