Added belief network prolog code.