modified spline from TA comments