Handle derivative discontinuities.