| ContinuousOptimizationContext Constructor |
Initializes a new instance of the
ContinuousOptimizationContext class
aimed to optimize the specified
continuous function,
with the given initial
guess argument, optimization goal,
range of iterations, and smoothing coefficients.
Namespace:
Novacta.Analytics.Advanced
Assembly:
Novacta.Analytics (in Novacta.Analytics.dll) Version: 2.0.0
Syntax public ContinuousOptimizationContext(
Func<DoubleMatrix, double> objectiveFunction,
DoubleMatrix initialArgument,
double meanSmoothingCoefficient,
double standardDeviationSmoothingCoefficient,
int standardDeviationSmoothingExponent,
double initialStandardDeviation,
double terminationTolerance,
OptimizationGoal optimizationGoal,
int minimumNumberOfIterations,
int maximumNumberOfIterations
)
Public Sub New (
objectiveFunction As Func(Of DoubleMatrix, Double),
initialArgument As DoubleMatrix,
meanSmoothingCoefficient As Double,
standardDeviationSmoothingCoefficient As Double,
standardDeviationSmoothingExponent As Integer,
initialStandardDeviation As Double,
terminationTolerance As Double,
optimizationGoal As OptimizationGoal,
minimumNumberOfIterations As Integer,
maximumNumberOfIterations As Integer
)
public:
ContinuousOptimizationContext(
Func<DoubleMatrix^, double>^ objectiveFunction,
DoubleMatrix^ initialArgument,
double meanSmoothingCoefficient,
double standardDeviationSmoothingCoefficient,
int standardDeviationSmoothingExponent,
double initialStandardDeviation,
double terminationTolerance,
OptimizationGoal optimizationGoal,
int minimumNumberOfIterations,
int maximumNumberOfIterations
)
new :
objectiveFunction : Func<DoubleMatrix, float> *
initialArgument : DoubleMatrix *
meanSmoothingCoefficient : float *
standardDeviationSmoothingCoefficient : float *
standardDeviationSmoothingExponent : int *
initialStandardDeviation : float *
terminationTolerance : float *
optimizationGoal : OptimizationGoal *
minimumNumberOfIterations : int *
maximumNumberOfIterations : int -> ContinuousOptimizationContext
Parameters
- objectiveFunction
- Type: SystemFuncDoubleMatrix, Double
The function to be optimized.
- initialArgument
- Type: Novacta.AnalyticsDoubleMatrix
The means of the Cross-Entropy parameter
initially exploited to sample arguments
of the function while searching
for the optimal one.
- meanSmoothingCoefficient
- Type: SystemDouble
A coefficient to define the smoothing scheme for the
means of the Cross-Entropy parameters
exploited by this context.
- standardDeviationSmoothingCoefficient
- Type: SystemDouble
The coefficient that defines the base smoothing scheme for the
standard deviations of the Cross-Entropy parameters
exploited by this context.
- standardDeviationSmoothingExponent
- Type: SystemInt32
The exponent that defines the dynamic smoothing scheme
for the standard deviations of the Cross-Entropy
parameters exploited by this context.
- initialStandardDeviation
- Type: SystemDouble
The value assigned to each standard deviation in
the initial Cross-Entropy parameter
exploited by this context.
- terminationTolerance
- Type: SystemDouble
The minimal value which, if greater than all the standard
deviations of a Cross-Entropy parameter, signals that
the optimization must be considered as converged
at intermediate iterations.
- optimizationGoal
- Type: Novacta.Analytics.AdvancedOptimizationGoal
A constant to specify if the function
must be minimized or maximized.
- minimumNumberOfIterations
- Type: SystemInt32
The minimum number of iterations
required by this context.
- maximumNumberOfIterations
- Type: SystemInt32
The maximum number of iterations
allowed by this context.
Exceptions Exception | Condition |
---|
ArgumentNullException | objectiveFunction is null.
-or- initialArgument is null.
|
ArgumentException | optimizationGoal is not a field of
OptimizationGoal.
-or- initialArgument is not a row
vector.
-or- minimumNumberOfIterations is greater than
maximumNumberOfIterations.
|
ArgumentOutOfRangeException | meanSmoothingCoefficient is not
in the open interval between 0 and 1.
-or- standardDeviationSmoothingCoefficient is
not in the open interval between 0 and 1.
-or- standardDeviationSmoothingExponent is
not positive.
-or- initialStandardDeviation is not
positive.
-or- terminationTolerance is not
positive.
-or- minimumNumberOfIterations is
not positive.
-or- maximumNumberOfIterations is
not positive.
|
Remarks
It is assumed that the objectiveFunction
will accept row
vectors as valid representations of an argument.
As a consequence, initialArgument is
expected to be a row vector.
As discussed by Rubinstein and Kroese,
Remark 5.2, p. 189[1]
,
typical values for meanSmoothingCoefficient
are between .7 and 1 (excluded), while
standardDeviationSmoothingCoefficient should
be between .8 and 1 (excluded), with
standardDeviationSmoothingExponent
between 5 and 10.
Also, it is expected that
initialStandardDeviation is a big enough
number, such as 100.0.
In this way, during the first execution of the sampling step,
each argument will have a good likelihood of being drawn.
Bibliography
[1]
Rubinstein, R.Y. and Kroese, D.P., The Cross-Entropy Method, A unified Approach to Combinatorial Optimization, Monte-Carlo Simulation, and Machine Learning, Springer, New York. (2004)
See Also