Exemple #1
0
        private double Interpolate(IInterpolation interpolation, double x)
        {
            if (interpolation is null)
            {
                throw new InvalidOperationException("Missing Interpolation type.");
            }

            if (Changed)
            {
                Sort();
                interpolation.Calculate(Points);
            }

            return(interpolation.Interpolate(x));
        }