differentiation and interpolation stuff