#29
#29 markov manager + add function to algorythm