class CombinedInterpolatorExtrapolator extends Interpolator1D {

  @Override
  public double firstDerivative(final Interpolator1DDataBundle data, final Double value) {
    Validate.notNull(data, "data");
    Validate.notNull(value, "value");
    if (value < data.firstKey()) {
      if (_leftExtrapolator != null) {
        return _leftExtrapolator.firstDerivative(data, value);
      }
    } else if (value > data.lastKey()) {
      if (_rightExtrapolator != null) {
        return _rightExtrapolator.firstDerivative(data, value);
      }
    }
    return _interpolator.firstDerivative(data, value);
  }

  public  CombinedInterpolatorExtrapolator(final Interpolator1D interpolator);
  public  CombinedInterpolatorExtrapolator(final Interpolator1D interpolator, final Interpolator1D extrapolator);
  public  CombinedInterpolatorExtrapolator(final Interpolator1D interpolator, final Interpolator1D leftExtrapolator, final Interpolator1D rightExtrapolator);

}