de.jstacs.algorithms.optimization.termination
Class AbsoluteValueCondition

java.lang.Object
  extended by de.jstacs.algorithms.optimization.termination.AbsoluteValueCondition
All Implemented Interfaces:
TerminationCondition

Deprecated. use of the absolute value condition is not recommended and it may be removed in future releases

public class AbsoluteValueCondition
extends Object
implements TerminationCondition

This class stops an optimization if the value of the function becomes less or equal to an absolute value, i.e., $f(\underline{x}_i) \le t$.

Author:
Jens Keilwagen

Constructor Summary
AbsoluteValueCondition(double threshold)
          Deprecated. This constructor creates an instance that stops an minimization when the value of the function is below the given threshold
Be careful!
 
Method Summary
 boolean doNextIteration(int iteration, double f_last, double f_current, double[] gradient, double[] direction, double alpha, Time t)
          Deprecated. This method allows to decide whether to do another iteration in an optimization or not.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbsoluteValueCondition

public AbsoluteValueCondition(double threshold)
Deprecated. 
This constructor creates an instance that stops an minimization when the value of the function is below the given threshold
Be careful! If you set the value too low the minimization will not terminate.

Parameters:
threshold - the threshold for stopping the optimization
Method Detail

doNextIteration

public boolean doNextIteration(int iteration,
                               double f_last,
                               double f_current,
                               double[] gradient,
                               double[] direction,
                               double alpha,
                               Time t)
Deprecated. 
Description copied from interface: TerminationCondition
This method allows to decide whether to do another iteration in an optimization or not.

Specified by:
doNextIteration in interface TerminationCondition
Parameters:
iteration - the number of performed iterations
f_last - last value of the function
f_current - current value of the function
gradient - the gradient of the function
direction - the last direction of the optimization
alpha - the last step size
t - a time object measuring the time that has been elapsed in the optimization
Returns:
true if another iteration should be done