|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectbijnum.BIJfit
public class BIJfit
This class implements useful linear and polynomial regression and root finding from Press, Flannery, Teukolsky, Vetterling, Numerical Recipes in C 2nd ed, Cambridge University Press, 1986 Copyright implementation (c) 1999-2004, Michael Abramoff. All rights reserved.
| Field Summary | |
|---|---|
static double |
CGOLD
|
static int |
ITMAX
ITMAX is the maximum allowed number of iterations; CGOLD is the golden ratio; ZEPS is a small number that protects against trying to achieve fractional accuracy for a minimum that happens to be exactly zero. |
static double |
ZEPS
|
| Constructor Summary | |
|---|---|
BIJfit()
|
|
| Method Summary | |
|---|---|
static double[] |
linear(float[] x,
float[] y)
Given a line with points x, y, fit a line y = a1 + a2x through them with linear least squares regression. |
static double[] |
minimumParabolic(float[] x,
float[] y)
Find the minimum y in a vector y (with x values in x) using parabolic interpolation and Brent's algorithm. |
static double[] |
minimumStraight(float[] x,
float[] y)
Find the minimum value in a vector x,y. |
static double[] |
poly(float[] x,
float[] y)
Given a line with points x, y, fit a line y = bx + a through them with linear least squares regression. |
static double[] |
polynomialInterpolation(float[] xa,
float[] ya,
double x)
From Press NR. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int ITMAX
public static final double CGOLD
public static final double ZEPS
| Constructor Detail |
|---|
public BIJfit()
| Method Detail |
|---|
public static double[] linear(float[] x,
float[] y)
x - a float array with x values.y - a float array with y values.
public static double[] poly(float[] x,
float[] y)
x - a float array with x values.y - a float array with y values.
public static double[] polynomialInterpolation(float[] xa,
float[] ya,
double x)
throws java.lang.Exception
xa - float[] x values of the functionya - float[] y values of the functionx - double where the function should be interpolated.
java.lang.Exception
public static double[] minimumStraight(float[] x,
float[] y)
x - float[] the x values of the vectory - float[] the y values of the vector.
public static double[] minimumParabolic(float[] x,
float[] y)
throws java.lang.Exception
x - float[] the x values of the vectory - float[] the y values of the vector.
java.lang.Exception
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||