|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.hedgehog.HObject
com.hedgehog.math.functions.Function
com.hedgehog.math.functions.XYVectorPolynomialFunction
public class XYVectorPolynomialFunction
Title: XYVectorPolynomialFunction - represents two FloatingPointVector vectors typically used in (x,y) data fitting
Description: Represents two FloatingPointVector vectors typically used in (x,y) data fitting.
Copyright: Copyright (c) Hedgehog Software 2007-2009.
Company: Hedgehog Software
| Field Summary | |
|---|---|
protected FloatingPointVector |
mxi
Vector of x values. |
protected FloatingPointVector |
myi
Vector of y values. |
| Fields inherited from class com.hedgehog.math.functions.Function |
|---|
method |
| Fields inherited from class com.hedgehog.HObject |
|---|
mID, mName |
| Constructor Summary | |
|---|---|
XYVectorPolynomialFunction(FloatingPointVector xi,
FloatingPointVector yi)
Constructor. |
|
XYVectorPolynomialFunction(XYVectorPolynomialFunction object)
Copy constructor. |
|
| Method Summary | |
|---|---|
Interval |
findXInterval(double x,
HInteger xminIndex,
HInteger xmaxIndex)
Assumes the x values [x0,x1,x2,....,xn-1] are increasing; ie x[i+1]>x[i]. |
FloatingPointVector |
getXI()
Returns the xi vector. |
FloatingPointVector |
getYI()
Returns the yi vector. |
double |
interpolateY(double x)
Interpolates the yi values for the specified x value. |
boolean |
isValid()
Tests the validity of this object. |
void |
setXI(FloatingPointVector xi)
Sets the xi vector. |
void |
setYI(FloatingPointVector yi)
Sets the yi vector. |
double |
taylorsSeriesFirstDerivative(int xpoint)
Computes the first derivative using Taylor's differentiation. |
double |
taylorsSeriesSecondDerivative(int xpoint)
Computes the second derivative using Taylor's differentiation. |
java.lang.String |
toString()
Returns a String representation of a XYVectorPolynomialFunction object. |
| Methods inherited from class com.hedgehog.math.functions.Function |
|---|
getMethod, setMethod |
| Methods inherited from class com.hedgehog.HObject |
|---|
clone, compare, compareTo, copy, equals, getID, getName, hashCode, hasID, hasName, setID, setName |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected FloatingPointVector mxi
protected FloatingPointVector myi
| Constructor Detail |
|---|
public XYVectorPolynomialFunction(FloatingPointVector xi,
FloatingPointVector yi)
throws java.lang.IllegalArgumentException
xi - Vector of x values.yi - Vector of y values.
java.lang.IllegalArgumentException - Thrown if xi and yi not of te same size.public XYVectorPolynomialFunction(XYVectorPolynomialFunction object)
object - Object to copy.| Method Detail |
|---|
public FloatingPointVector getXI()
public FloatingPointVector getYI()
public void setXI(FloatingPointVector xi)
xi - New xi vector.public void setYI(FloatingPointVector yi)
yi - New yi vector.
public Interval findXInterval(double x,
HInteger xminIndex,
HInteger xmaxIndex)
x - Value in which to find enclosing interval.xminIndex - Set upon return to the xi index of the interval minimum.xmaxIndex - Set upon return to the xi index of the interval maximum.
public double interpolateY(double x)
x - The x value at which to interpolate y.
public double taylorsSeriesFirstDerivative(int xpoint)
throws InvalidObjectException,
java.lang.IllegalArgumentException
xpoint - Point at which derivative is evaluated.
InvalidObjectException - Thrown if less than 3 points.
java.lang.IllegalArgumentException - Thrown if xpoint is out of range.
public double taylorsSeriesSecondDerivative(int xpoint)
throws InvalidObjectException,
java.lang.IllegalArgumentException
xpoint - Point at which derivative is evaluated.
InvalidObjectException - Thrown if less than 3 points.
java.lang.IllegalArgumentException - Thrown if xpoint is out of range.public boolean isValid()
isValid in class Functionpublic java.lang.String toString()
toString in class Function
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||