Click or drag to resize

AnnealingMinimizer Class

Class AnnealingMinimizer minimizes a multivariable function using the simulated annealing method.
Inheritance Hierarchy
SystemObject
  CenterSpace.NMath.CoreAnnealingMinimizer

Namespace:  CenterSpace.NMath.Core
Assembly:  NMath (in NMath.dll) Version: 7.3
Syntax
public class AnnealingMinimizer : IMultiVariableMinimizer, 
	ICloneable

The AnnealingMinimizer type exposes the following members.

Constructors
  NameDescription
Public methodAnnealingMinimizer
Constructs an AnnealingMinimizer instance with the given schedule.
Top
Properties
  NameDescription
Public propertyStatic memberDefaultRandomNumberGenerator
Gets and sets the default random number generator for use by AnnealingMinimizer instances.
Public propertyError
Gets the final error associated with the mimimum just computed.
Public propertyHistory
Gets a history of the annealing schedule just performed.
Public propertyKeepHistory
Gets and sets whether to keep a history of the annealing process.
Public propertyRandomNumberGenerator
Gets and sets the random number generator associated with this minimizer.
Public propertySchedule
Gets and sets the annealing schedule.
Public propertyToleranceMet
Returns true if the minimum just computed stopped because the error tolerance was reached; otherwise, false.
Top
Methods
  NameDescription
Public methodClone
Creates a deep copy of this AnnealingMinimizer.
Public methodMinimize(DoubleFunctional, DoubleVector)
Minimizes the given function using the annealing schedule currently associated with this minimizer.
Public methodMinimize(MultiVariableFunction, DoubleVector) Obsolete.
Minimizes the given function using the annealing schedule currently associated with this minimizer.
Public methodOnDeserialized
Restores historySerialized, points history to historySerialized, and clears historySerialized
Public methodOnSerialized
Clear temp serialization var
Public methodOnSerializing
Conditionally store history. If keep history, then set historySerialized (which is serialized) equal to history_ (which is not serialized)
Top
Fields
  NameDescription
Protected fielderror_
Estimate of the error.
Protected fieldhistory_
History of this minimization.
Protected fieldkeepHistory_
Should history be kept?
Protected fieldrand_
Random number generator for annealing.
Protected fieldschedule_
The annealing schedule.
Top
Remarks
Simulated annealing is based on an analogy from materials science, where to produce a solid in a low energy state (such as a perfect crystal), you first heat the system to a high temperature, then cool it gradually. In the computational analogy of this method, a function is iteratively minimized with an added random temperature term. The temperature is gradually decreased according to an annealing schedule as more optimizations are applied, increasing the likelihood of avoiding entrapment in local minima, and of finding the global minimum of the function. The annealing schedule governs the choice of initial temperature, how many iterations are performed at each temperature, and how much the temperature is decremented at each step as cooling proceeds.
AnnealingScheduleBase is the abstract base class for annealing schedules. Two concrete implementations are provided: LinearAnnealingSchedule and CustomAnnealingSchedule.
For help optimizing the annealing schedule for a particular function, set the KeepHistory property to true. There is a cost in memory and execution to keeping the history, but the history contains lots of useful information that can be used to alter the annealing schedule. The history is accessed by the AnnealingHistory property.
See Also