added control for jumps that cause numerical instability