updated discrete opt algos