using cubic spline segments for evaluating foot trajectories