MarkovModels and Factor

Code for markov models.
Working with markov models, building graphs, triangulating it and making junction trees out of it.

Added a few functions in factors which I needed.
???