function [prob_val] = prob_computation(Prob, prob_path)
prr=1;
for i=1:size(prob_path,2)-1,
    idx = prob_path(i)+1;
    idx_next = prob_path(i+1)+1;
    prr=prr*Prob(idx,idx_next);
end
prob_val=prr;
end