public class LinearInterpolator extends Object implements UnivariateInterpolator, FieldUnivariateInterpolator
| Constructor and Description | 
|---|
| LinearInterpolator() | 
| Modifier and Type | Method and Description | 
|---|---|
| PolynomialSplineFunction | interpolate(double[] x,
           double[] y)Computes a linear interpolating function for the data set. | 
| <T extends RealFieldElement<T>> | interpolate(T[] x,
           T[] y)Computes a linear interpolating function for the data set. | 
public PolynomialSplineFunction interpolate(double[] x, double[] y) throws MathIllegalArgumentException
interpolate in interface UnivariateInterpolatorx - the arguments for the interpolation pointsy - the values for the interpolation pointsMathIllegalArgumentException - if x and y
 have different sizes.MathIllegalArgumentException - if x is not sorted in
 strict increasing order.MathIllegalArgumentException - if the size of x is smaller
 than 2.public <T extends RealFieldElement<T>> FieldPolynomialSplineFunction<T> interpolate(T[] x, T[] y) throws MathIllegalArgumentException
interpolate in interface FieldUnivariateInterpolatorT - the type of the field elementsx - the arguments for the interpolation pointsy - the values for the interpolation pointsMathIllegalArgumentException - if x and y
 have different sizes.MathIllegalArgumentException - if x is not sorted in
 strict increasing order.MathIllegalArgumentException - if the size of x is smaller
 than 2.Copyright © 2016–2020 Hipparchus.org. All rights reserved.