Numerical smoothing and differentiation