Hi, I noticed that a LinearInterpolator1D will always return a value of 0 for the derivative at/outside the right boundary of the model you give it, and I don’t think this is correct. It looks to me like it is assumed that the model is a right-open interval and so assumes that the point cannot be interpolated, but this isn’t true/explicitly known.
I think it should either use the previous bounded values (this is continous), or better allow subclassing to define boundary behaviour (this can have all sorts of crazy numerical scheming applied, e.g. blending), or at least throw an UnsupportedOperationException (instead of happily returning a duff value).
One can reproduce the above simply by creaing a InterpolatedDoublesCurve for the line y=x and calculating dy/dx - note that its value is 1 everywhere, except at the right boundary.
Is this correct, or am I going mad?