incorporating spline interpolation