lt.monarch.math
Interface AbstractSpline

All Superinterfaces:
java.lang.Cloneable, java.io.Serializable
All Known Implementing Classes:
CubicSpline, CubicSplineReal

public interface AbstractSpline
extends java.lang.Cloneable, java.io.Serializable

Abstract spline class. It allows different spline strategies.


Method Summary
Modifier and Type Method and Description
 AbstractSpline clone()
          Clones the object
 Point2D[] getLines()
          Gets spline line array
 double[] interpolateYAt(double x)
          Interpolates x value and returns the Y values array
 void setData(double[] x, double[] y, int pointCount, int step)
          Sets spline data
 

Method Detail

getLines

Point2D[] getLines()
Gets spline line array

Returns:
spline line array

interpolateYAt

double[] interpolateYAt(double x)
Interpolates x value and returns the Y values array

Parameters:
x - x value, where to interpolate
Returns:
array of y values

setData

void setData(double[] x,
             double[] y,
             int pointCount,
             int step)
Sets spline data

Parameters:
x - normalized x values
y - normalized y values
pointCount - point count
step - step count

clone

AbstractSpline clone()
                     throws java.lang.CloneNotSupportedException
Clones the object

Returns:
object clone (new instance)
Throws:
java.lang.CloneNotSupportedException - exception if not possible to clone