properly handling negative epsilons