@PublicationReference(author="R. Fletcher", title="Practical Methods of Optimization, Second Edition", type=Book, year=1987, pages={34,39}, notes={"Equation 2.6.2 and Equation 2.6.4","Fletcher assumes that the initial slope is negative (WOLOG), and this class automatically adjusts itself to positive-slope guesses."}) public class LineMinimizerDerivativeBased extends AbstractAnytimeLineMinimizer<DifferentiableUnivariateScalarFunction>
Modifier and Type | Class and Description |
---|---|
class |
LineMinimizerDerivativeBased.InternalFunction
Internal function used to map/remap/unmap the search direction.
|
Modifier and Type | Field and Description |
---|---|
static double |
DEFAULT_CURVATURE_CONDITION
This is a fairly accurate line search, 0.1.
|
static LineBracketInterpolator<? super DifferentiableUnivariateScalarFunction> |
DEFAULT_INTERPOLATOR
Default interpolator to use to create a new candidate point to evaluate
|
static double |
DEFAULT_MIN_FUNCTION_VALUE
Default minimum function value, 0.0.
|
static double |
DEFAULT_SLOPE_CONDITION
This is a fairly accurate line search, 0.01.
|
protected static double |
TAU1
Suggested value given in PMOO=9.0, bottom of p.34, 5.0
|
protected static double |
TAU2
Suggested value given in PMOO=0.05, top of p.36 (given as 0.05 on p.69), 0.1
|
protected static double |
TAU3
Suggested value given in PMOO=0.50, top of p.36, 0.5
|
DEFAULT_MAX_ITERATIONS, DEFAULT_TOLERANCE
initialGuess, result, tolerance
data, keepGoing
maxIterations
DEFAULT_ITERATION, iteration
Constructor and Description |
---|
LineMinimizerDerivativeBased()
Default constructor
|
LineMinimizerDerivativeBased(double minFunctionValue)
Creates a new instance of LineMinimizerDerivativeBased
|
LineMinimizerDerivativeBased(LineBracketInterpolator<? super DifferentiableUnivariateScalarFunction> interpolator,
double minFunctionValue)
Creates a new instance of LineMinimizerDerivativeBased
|
Modifier and Type | Method and Description |
---|---|
boolean |
bracketingStep()
Continues the bracketing phase of the algorithm, which attempts to
place a bracket around a known minimum.
|
double |
getMinFunctionValue()
Getter for minFunctionValue
|
protected boolean |
initializeAlgorithm()
Called to initialize the learning algorithm's state based on the
data that is stored in the data field.
|
boolean |
sectioningStep()
Continues the sectioning phase of the algorihtm.
|
void |
setMinFunctionValue(double minFunctionValue)
Setter for minFunctionValue
|
cleanupAlgorithm, getBracket, getInitialGuessFunctionValue, getInitialGuessSlope, getInterpolator, isValidBracket, minimizeAlongDirection, setBracket, setData, setInitialGuess, setInitialGuessFunctionValue, setInitialGuessSlope, setInterpolator, setValidBracket, step
getInitialGuess, getResult, getTolerance, setResult, setTolerance
clone, getData, getKeepGoing, learn, setKeepGoing, stop
getMaxIterations, isResultValid, setMaxIterations
addIterativeAlgorithmListener, fireAlgorithmEnded, fireAlgorithmStarted, fireStepEnded, fireStepStarted, getIteration, getListeners, removeIterativeAlgorithmListener, setIteration, setListeners
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getInitialGuess, getTolerance, learn, setTolerance
clone
getMaxIterations, getResult, setMaxIterations
addIterativeAlgorithmListener, getIteration, removeIterativeAlgorithmListener
isResultValid, stop
public static final double DEFAULT_CURVATURE_CONDITION
public static final double DEFAULT_SLOPE_CONDITION
public static final LineBracketInterpolator<? super DifferentiableUnivariateScalarFunction> DEFAULT_INTERPOLATOR
public static final double DEFAULT_MIN_FUNCTION_VALUE
protected static final double TAU1
protected static final double TAU2
protected static final double TAU3
public LineMinimizerDerivativeBased()
public LineMinimizerDerivativeBased(double minFunctionValue)
minFunctionValue
- Direction of the search. Because Fletcher assumes the slope of the
initialGuess is less than 0.0, we have to flip around the direction
of search if the initial guess has positive slope. Thus, direction=1.0
means that the initial slope was negative, while direction=-1.0 means
that the initial slope was positive.public LineMinimizerDerivativeBased(LineBracketInterpolator<? super DifferentiableUnivariateScalarFunction> interpolator, double minFunctionValue)
interpolator
- Type of algorithm to fit data points and find an interpolated minimum
to the known points.minFunctionValue
- Direction of the search. Because Fletcher assumes the slope of the
initialGuess is less than 0.0, we have to flip around the direction
of search if the initial guess has positive slope. Thus, direction=1.0
means that the initial slope was negative, while direction=-1.0 means
that the initial slope was positive.protected boolean initializeAlgorithm()
AbstractAnytimeBatchLearner
initializeAlgorithm
in class AbstractAnytimeLineMinimizer<DifferentiableUnivariateScalarFunction>
public boolean bracketingStep()
LineMinimizer
bracketingStep
in interface LineMinimizer<DifferentiableUnivariateScalarFunction>
bracketingStep
in class AbstractAnytimeLineMinimizer<DifferentiableUnivariateScalarFunction>
public boolean sectioningStep()
LineMinimizer
sectioningStep
in interface LineMinimizer<DifferentiableUnivariateScalarFunction>
sectioningStep
in class AbstractAnytimeLineMinimizer<DifferentiableUnivariateScalarFunction>
public double getMinFunctionValue()
public void setMinFunctionValue(double minFunctionValue)
minFunctionValue
- Minimum value of the target function. In other words, the user will
accept a solution less than or equal to minFunctionValue.