adds dive iterative dinamic programming