// Natural spline
CubicInterpolation f = new CubicInterpolation(
generic_x, generic_y,
CubicInterpolation.DerivativeApprox.Spline, false,
CubicInterpolation.BoundaryCondition.SecondDerivative, generic_natural_y2.first(),
CubicInterpolation.BoundaryCondition.SecondDerivative, generic_natural_y2.last());
f.update();
checkValues("Natural spline", f, generic_x, generic_y);
// cached second derivative
for (int i=0; i<n; i++) {