Optimal policy for minimizing risk models in Markov decision processes