Configures the current object.
opt = optimbase_configure(opt, key, value)
The current object of TOPTIM type (tlist).
A string.
The value is assigned in function of key
.
The optimbase_configure
function allows to set the value contained in
the key
.
The following keys are available :
A 1-by-1 matrix of doubles, positive, integer value, set to 1 to enable
verbose logging (default -verbose
= 0).
A 1-by-1 matrix of doubles, positive, integer value, set to 1 to enable
verbose termination logging (default -verbosetermination
= 0).
The initial guess. A n-by-1 matrix of doubles, where n is the number of
variables. There is no default value, i.e. the user must provide -x0
.
The maximum number of function evaluations is a 1-by-1 matrix of doubles,
positive, integer value (default -maxfunevals
= 100).
If this criteria is triggered, the status of the optimization is set to
-maxfunevals
.
The maximum number of iterations is a 1-by-1 matrix of doubles, positive,
integer value (default -maxiter
= 100).
If this criteria is triggered, the status of the optimization is set to
-maxiter
.
The absolute tolerance for the function value is a 1-by-1 matrix of
doubles, positive (default -tolfunabsolute
= 0).
The relative tolerance for the function value is a 1-by-1 matrix of
doubles, positive (default -tolfunrealtive
= %eps).
A 1-by-1 matrix of booleans. Set to %t to enable termination with
tolerance on function value (default -tolfunmethod
= %f).
If this criteria is triggered, the status of the optimization is set to "tolf".
The absolute tolerance on x is a 1-by-1 matrix of doubles, positive
(default -tolxabsolute
= 0).
The relative tolerance on x is a 1-by-1 matrix of doubles, positive
(default -tolxrealtive
= sqrt(%eps)).
A 1-by-1 matrix of booleans. Set to %t to enable the tolerance on x in
the termination criteria (default -tolxmethod
= %t).
If this criteria is triggered, the status of the optimization is set to "tolx".
A function or a list, the objective function. This function computes the value
of the cost and the non linear constraints, if any.
There is no default value, i.e. the user must provide f
.
A function or a list. The function is called back for output.
The number of variables to optimize is a 1-by-1 matrix of doubles, positive,
integer value (default -numberofvariables
= 0).
A 1-by-1 matrix of doubles, positive, integer value. Set to %t to enable the
history storing (default -storehistory
= %f).
The minimum bounds for the parameters. A n-by-1 matrix of doubles where n
is the number of variables (default -boundsmin
= [],
i.e. there are no minimum bounds).
The maximum bounds for the parameters. A n-by-1 matrix of doubles where n
is the number of variables (default -boundsmax
= [],
i.e. there are no maximum bounds).
The number of inequality constraints is a 1-by-1 matrix of doubles, positive,
integer value (default -nbineqconst
= 0).
The name of the log file.
A 1-by-1 matrix of booleans. Set to %t if the algorithm uses derivatives
(default -withderivatives
= 0).
opt = optimbase_new(); // Set number of variables opt = optimbase_configure ( opt , "-numberofvariables" , 10) // Set initial guess opt = optimbase_configure(opt, "-x0", [-1.2 1.0]') // Set maximum number of iteration opt = optimbase_configure(opt,"-maxiter",200) opt = optimbase_destroy(opt); | ![]() | ![]() |