public abstract class MultivariateMinimum extends Object
Modifier and Type | Field and Description |
---|---|
int |
maxFun
maxFun is the maximum number of calls to fun allowed.
|
int |
numFun
total number of function evaluations necessary
|
int |
numFuncStops
numFuncStops is the number of consecutive positive
evaluations of the stop criterion based on function evaluation
necessary to cause the abortion of the optimization
(default is 4)
|
Constructor and Description |
---|
MultivariateMinimum() |
Modifier and Type | Method and Description |
---|---|
void |
copy(double[] target,
double[] source)
Copy source vector into target vector
|
double |
findMinimum(MultivariateFunction f,
double[] xvec)
Find minimum close to vector x
|
double |
findMinimum(MultivariateFunction f,
double[] xvec,
int fxFracDigits,
int xFracDigits)
Find minimum close to vector x
(desired fractional digits for each parameter is specified)
|
abstract void |
optimize(MultivariateFunction f,
double[] xvec,
double tolfx,
double tolx)
The actual optimization routine
(needs to be implemented in a subclass of MultivariateMinimum).
|
boolean |
stopCondition(double fx,
double[] x,
double tolfx,
double tolx,
boolean firstCall)
Checks whether optimization should stop
|
public int numFun
public int maxFun
public int numFuncStops
public double findMinimum(MultivariateFunction f, double[] xvec)
f
- multivariate functionxvec
- initial guesses for the minimum
(contains the location of the minimum on return)public double findMinimum(MultivariateFunction f, double[] xvec, int fxFracDigits, int xFracDigits)
f
- multivariate functionxvec
- initial guesses for the minimum
(contains the location of the minimum on return)fxFracDigits
- desired fractional digits in the function valuexFracDigits
- desired fractional digits in parameters xpublic abstract void optimize(MultivariateFunction f, double[] xvec, double tolfx, double tolx)
f
- multivariate functionxvec
- initial guesses for the minimum
(contains the location of the minimum on return)tolfx
- absolute tolerance of function valuetolx
- absolute tolerance of each parameterpublic boolean stopCondition(double fx, double[] x, double tolfx, double tolx, boolean firstCall)
fx
- current function valuex
- current values of function parameterstolfx
- absolute tolerance of function valuetolx
- absolute tolerance of each parameterfirstCall
- needs to be set to true when this routine is first called
otherwise it should be set to falsepublic void copy(double[] target, double[] source)
target
- parameter arraysource
- parameter arrayCopyright © 2015–2021 Fiji. All rights reserved.