What Is Optimization Toolbox?

What Is Optimization Toolbox? What Is Optimization Toolbox?

cda.psych.uiuc.edu
from cda.psych.uiuc.edu More from this publisher
12.07.2015 Views

5 Optimization ToolThe default value, Reset options to defaults, discards any options youspecified previously in the optimtool. Under this choice, you can select theoption Prompt before resetting options to defaults.Alternatively, you can select Keep current options if possible to preservethe values you have modified. Changed options that are not valid with thenewly selected solver are kept but not used, while active options relevantto the new solver selected are used. This choice allows you to try differentsolvers with your problem without losing your options.Exporting to the MATLAB WorkspaceThe Export to Workspace dialog box enables you to send your probleminformation to the MATLAB workspace as a structure that you may thenmanipulate in the Command Window.To access the Export to Workspace dialog box shown below, selectFile > Export to Workspace.5-44

Importing and Exporting Your WorkYou can specify a structure that contains• The problem and options information• The options information only• The results of running your problem in optimtoolAfter you have exported information from the Optimization Tool to theMATLAB workspace, you can see your data in the MATLAB Workspacebrowser or by typing the name of the structure at the Command Window.Generating an M-FileYou may want to generate an M-file to continue with your optimizationproblem in the Command Window at another time. You can run the M-filewithout modification to recreate the results that you created with theOptimizationTool. YoucanalsoeditandmodifytheM-fileandrunitfromthe Command Window.To export data from the Optimization Tool to an M-file, select File > GenerateM-file.The M-file captures the following:• The problem definition, including the solver, information on the function tobe minimized, algorithm specification, constraints, and start point• The options (using optimset) with the currently selected option valueRunning the M-file at the Command Window reproduces your problem results.5-45

Importing and Exporting Your WorkYou can specify a structure that contains• The problem and options information• The options information only• The results of running your problem in optimtoolAfter you have exported information from the <strong>Optimization</strong> Tool to theMATLAB workspace, you can see your data in the MATLAB Workspacebrowser or by typing the name of the structure at the Command Window.Generating an M-FileYou may want to generate an M-file to continue with your optimizationproblem in the Command Window at another time. You can run the M-filewithout modification to recreate the results that you created with the<strong>Optimization</strong>Tool. YoucanalsoeditandmodifytheM-fileandrunitfromthe Command Window.To export data from the <strong>Optimization</strong> Tool to an M-file, select File > GenerateM-file.The M-file captures the following:• The problem definition, including the solver, information on the function tobe minimized, algorithm specification, constraints, and start point• The options (using optimset) with the currently selected option valueRunning the M-file at the Command Window reproduces your problem results.5-45

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!