homework1 for the course in probabilistic graphical models