Diagnostic information for troubleshooting linearization results
When you linearize a Simulink® model, you can create a LinearizationAdvisor
object that
contains diagnostic information about individual block linearizations. You can
troubleshoot your linearization results by reviewing this diagnostic
information.
To access the diagnostic information, use the getBlockInfo
function.
There are several ways to create a LinearizationAdvisor
object when
linearizing a Simulink model. When you linearize a model using:
The linearize
function, first
create a linearizeOptions
option set,
setting the StoreAdvisor
option to true
.
Then, linearize the model using linearize
, returning the
info
argument.
An slLinearizer
interface, first
create a linearizeOptions
option set, setting the
StoreAdvisor
option to true
. Then,
create the slLinearizer
interface. When you obtain a linear
model from the interface using a linearization function, such as
getIOTransfer
, return the info
argument.
An slTuner
interface, first
create a slTunerOptions
option set,
setting the StoreAdvisor
option to true
.
Then, create the slTuner
interface. When you obtain a
linear model from the interface using a linearization function, such as
getIOTransfer
, return the info
argument.
You can then access the LinearizationAdvisor
object using
info.Advisor
. If you linearize the model at multiple operating
points or using parameter variation, info.Advisor
is an array of
LinearizationAdvisor
objects.
Also, the advise
and find
functions return a LinearizationAdvisor
object that contains diagnostic
information for blocks that satisfy the relevant search criteria.
advise | Find blocks that are potentially problematic for linearization |
highlight | Highlight linearization path in Simulink model |
find | Find blocks in linearization results that match specific criteria |
getBlockInfo | Obtain diagnostic information for block linearizations |
getBlockPaths | Obtain list of blocks in LinearizationAdvisor
object |
You can interactively troubleshoot linearization results using the Linearization Advisor in the Model Linearizer. For an example, see Troubleshoot Linearization Results in Model Linearizer.