Why is Model Linearizer producing incorrect results with single data types in MATLAB R2021b?
5 views (last 30 days)
Show older comments
MathWorks Support Team
on 31 Oct 2022
Answered: MathWorks Support Team
on 24 Jan 2023
When using Simulink Control Design with a Simulink Model in R2021b, if the data type of a constant input source for a model is set as "single", the integrator part is ignored and the results from Model Linearizer are completely incorrect. Is this a Simulink limitation or is there a setting I need to change for the discrete-time integrator?
Accepted Answer
MathWorks Support Team
on 31 Oct 2022
This is a known issue with the Discrete Integrator block. The Discrete Integrator's Jacobian is what is used by Model Linearizer to produce the results, but this Jacobian is currently producing incorrect results for "single" data types.
This issue has been fixed in the release of MATLAB R2022b. However, the fix is not currently available for prior releases. Please use "double" precision data types as a workaround if you are constrained to use earlier releases. The links below provide some guidance on how to do so.
Linearize Blocks with Non-Floating-Point Data Types:
https://www.mathworks.com/help/releases/R2021b/slcontrol/ug/linearize-blocks-with-non-floating-point-signals-or-states.html
Data Type Override:
https://www.mathworks.com/help/releases/R2021b/simulink/ug/control-fixed-point-instrumentation-and-data-type-override.html
0 Comments
More Answers (0)
See Also
Categories
Find more on Trimming and Linearization in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!