(Not recommended) Create pattern search options structure
psoptimset
is not recommended. Use
optimoptions
instead. For more information, see Compatibility Considerations.
psoptimset
options = psoptimset
options = psoptimset(@patternsearch)
options = psoptimset('param1',value1,'param2',value2,...)
options = psoptimset(oldopts,'param1',value1,...)
options = psoptimset(oldopts,newopts)
psoptimset
with no input or output arguments displays a complete
list of parameters with their valid values.
options = psoptimset
(with no input arguments) creates a structure
called options
that contains the options, or
parameters, for patternsearch
, and sets
parameters to []
, indicating patternsearch
uses the
default values.
options = psoptimset(@patternsearch)
creates a structure called
options
that contains the default values for
patternsearch
.
options = psoptimset('param1',value1,'param2',value2,...)
creates a
structure options
and sets the value of 'param1'
to
value1
, 'param2'
to value2
, and
so on. Any unspecified parameters are set to their default values. It is sufficient to type
only enough leading characters to define the parameter name uniquely. Case is ignored for
parameter names.
options = psoptimset(oldopts,'param1',value1,...)
creates a copy of
oldopts
, modifying the specified parameters with the specified
values.
options = psoptimset(oldopts,newopts)
combines an existing options
structure, oldopts
, with a new options structure,
newopts
. Any parameters in newopts
with nonempty
values overwrite the corresponding old parameters in oldopts
.
The following table lists the options you can set with psoptimset
.
See Pattern Search Options for a complete description of the options and their
values. Values in {}
denote the default value. You can also view the
optimization parameters and defaults by typing psoptimset
at the command
line.
optimoptions
hides the options listed in
italics, but psoptimset
does not. See Options that optimoptions Hides.
Options for patternsearch
and paretosearch
Option | Description | Values |
---|---|---|
| Tolerance on constraints. For an options structure, use | Positive scalar | |
| Level of display. | 'off' | 'iter' | 'diagnose' | {'final'} |
| Maximum number of objective function evaluations. For an options structure, use | Positive integer | |
| Maximum number of iterations. For an options structure, use | Positive integer | |
| Total time (in seconds) allowed for optimization. For an options structure, use | Positive scalar | |
| Tolerance on the mesh size. For an options structure, use
| Positive scalar | |
| Function that an optimization function calls at each iteration. Specify as a function handle or a cell array of function handles. For an options structure, use | |
| Plots of output from the pattern search. Specify as the name of a built-in plot function, a function handle, or a cell array of names of built-in plot functions or function handles. For an options structure, use
|
For
For |
| Polling strategy used in the pattern search. |
For
|
| Compute objective and nonlinear constraint functions in parallel. See Vectorized and Parallel Options (User Function Evaluation) and How to Use Parallel Processing in Global Optimization Toolbox. |
|
| Specifies whether functions are vectorized. See Vectorized and Parallel Options (User Function Evaluation) and Vectorize the Objective and Constraint Functions. For an options structure, use |
|
Options for paretosearch
Only
Option | Description | Values |
---|---|---|
| Initial points for
| Matrix with |
| Minimum fraction of the pattern to poll. | Scalar from 0 through 1 | |
| Number of points in the Pareto set. | Positive integer | |
| The solver stops when the relative change in a stopping measure over a window of
iterations is less than or equal to
See Definitions for paretosearch Algorithm. The solver stops when the relative change in any
applicable measure is less than
Note Setting | Positive scalar | |
Options for patternsearch
Only
Option | Description | Values |
---|---|---|
Cache | With |
|
CacheSize | Size of the history. | Positive scalar | |
CacheTol | Largest distance from the current mesh point to any point in the history in order for
| Positive scalar | |
FunctionTolerance | Tolerance on the function. Iterations stop if the change in function value is less than
For an options structure, use
| Positive scalar | |
InitialMeshSize | Initial mesh size for the algorithm. See How Pattern Search Polling Works. | Positive scalar | |
InitialPenalty | Initial value of the penalty parameter. See Nonlinear Constraint Solver Algorithm. | Positive scalar | |
MaxMeshSize | Maximum mesh size used in a poll or search step. See How Pattern Search Polling Works. | Positive scalar | |
MeshContractionFactor | Mesh contraction factor for unsuccessful iteration. For an options structure, use | Positive scalar | |
MeshExpansionFactor | Mesh expansion factor for successful iteration. For an options structure, use | Positive scalar | |
MeshRotate | Rotate the pattern before declaring a point to be optimum. See Mesh Options. |
|
PenaltyFactor | Penalty update parameter. See Nonlinear Constraint Solver Algorithm. | Positive scalar | |
PlotInterval | Specifies that plot functions are called at every interval. | positive integer | |
PollOrderAlgorithm | Order of poll directions in pattern search. For an options structure, use |
|
ScaleMesh | Automatic scaling of variables. For an options structure, use |
|
SearchFcn | Type of search used in pattern search. Specify as a name or a function handle. For an options structure, use |
|
StepTolerance | Tolerance on the variable. Iterations stop if both the change in position and the mesh
size are less than For an options structure, use
| Positive scalar | |
TolBind | Binding tolerance. See Constraint Parameters. | Positive scalar | |
UseCompletePoll | Complete poll around the current point. See How Pattern Search Polling Works. For an
options structure, use |
|
UseCompleteSearch | Complete search around current point when the search method is a poll method. See Searching and Polling. For an options structure, use |
|