internal void AddTransition(string source, string target, string[] actions, Func <double> probability)
        {
            TransitionList ltrans = GetTransitionList(source);

            ltrans.Add(new Transition()
            {
                target = states[target], actions = actions, probability = probability
            });
        }
        TransitionList GetTransitionList(string source)
        {
            var            sourceState = states[source];
            TransitionList ltrans;

            if (!transitions.ContainsKey(sourceState))
            {
                ltrans = new TransitionList();
                transitions.Add(states[source], ltrans);
            }
            else
            {
                ltrans = transitions[sourceState];
            }

            return(ltrans);
        }