Class Interpolator

java.lang.Object
gda.analysis.numerical.interpolation.Interpolator

public class Interpolator extends Object
Methods for interpolation of DataVectors
  • Constructor Details

    • Interpolator

      public Interpolator()
  • Method Details

    • linearInterpolatedPoint

      public static double linearInterpolatedPoint(DataVector input_x, DataVector input_y, double desired_x)
      Parameters:
      input_x -
      input_y -
      desired_x -
      Returns:
      interpolated point y
    • cubicSpline

      public static DataVector cubicSpline(DataVector input_x, DataVector input_y, DataVector desired_x)
      Interpolate an x,y data set to a desired x spacing
      Parameters:
      input_x -
      input_y -
      desired_x -
      Returns:
      y values at desired spacing
    • polyInterpolatedPoint

      public static double[] polyInterpolatedPoint(DataVector input_x, DataVector input_y, double desired_x, int noOfPoints)
      Find y for a given point desired_x in the dataset an input_x,input_y Using polynomial interpolation This routine will try to use 7 points adjacent to the desired x point
      Parameters:
      input_x -
      input_y -
      desired_x -
      noOfPoints -
      Returns:
      y value and error in y at desired_x value
    • ratInterpolatedPoint

      public static double[] ratInterpolatedPoint(DataVector input_x, DataVector input_y, double desired_x, int noOfPoints)
      Find y for a given point desired_x in the dataset an input_x,input_y Using rational interpolation
      Parameters:
      input_x -
      input_y -
      desired_x -
      noOfPoints -
      Returns:
      y values at desired_x value
    • main

      public static void main(String[] args)
      Parameters:
      args -