主要内容

optimizationResults

Class: mbcrunner

Retrieve optimization results

Since R2024b

Syntax

results = optimizationResults(obj,optimizationName)
results = optimizationResults(obj,optimizationName,Name=Value)

Description

results = optimizationResults(obj,optimizationName) returns a table containing the optimization results from the optimization specified by optimizationName in the CAGE project specified by obj, including the optimization exit flags in a separate column. If more than one optimization is run, each run is returned as a table column.

results = optimizationResults(obj,optimizationName,Name=Value) returns a table containing the optimization results using additional options specified by one or more name-value arguments.

Input Arguments

expand all

Handle to the CAGE project, specified as an mbcrunner object.

Optimization name, specified as a string scalar.

Data Types: string

Name-Value Arguments

expand all

Specify optional pairs of arguments as Name1=Value1,...,NameN=ValueN, where Name is the argument name and Value is the corresponding value. Name-value arguments must appear after other arguments, but the order of the pairs does not matter.

Example: optimizationResults(r,'Torque_Optimization',AcceptableOnly=false)

Option to return Pareto solutions for multiobjective optimizations, specified as false or true.

Example: ParetoSolutions=true

Data Types: logical

Option to return only the acceptable solutions, specified as true or false.

Example: AcceptableOnly=false

Data Types: logical

Option to evaluate the models at the optimization results, specified as true or false.

Example: EvaluateModels=false

Data Types: logical

Version History

Introduced in R2024b