Package cnuphys.splot.fit
Class Polynomial
java.lang.Object
cnuphys.splot.fit.Polynomial
- All Implemented Interfaces:
- IValueGetter
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptiondouble[]findRoots(double xmin, double xmax) Find the roots of the polynomial in a rangefindXValsOfMaxima(double xmin, double xmax) Find the xy values of the maxima of the polynomial in a given rangeintstatic intmaxNumPositiveRoots(double[] a) doublevalue(double x) 
- 
Constructor Details- 
Polynomialpublic Polynomial(double[] a) 
 
- 
- 
Method Details- 
valuepublic double value(double x) - Specified by:
- valuein interface- IValueGetter
 
- 
findRootspublic double[] findRoots(double xmin, double xmax) Find the roots of the polynomial in a range- Parameters:
- xmin- the min value of the range
- xmax- the max value of the range
- Returns:
- an array of roots, or null
 
- 
findXValsOfMaximaFind the xy values of the maxima of the polynomial in a given range- Parameters:
- xmin- the min value of the range
- xmax- the max value of the range
- Returns:
- and array of xy values, or null
 
- 
getMaxNumberOfPositiveRootspublic int getMaxNumberOfPositiveRoots()
- 
getDerivative
- 
maxNumPositiveRootspublic static int maxNumPositiveRoots(double[] a) 
 
-