Clear Filters
Clear Filters

how to konw the meaning of xout of simulink

4 views (last 30 days)
盈天 裴
盈天 裴 on 28 Jun 2023
Edited: Suman on 31 Jul 2024 at 9:18
I am trying to trim a 6DOF aircraft model using Trim, and I got this error
"In the command [X,U,Y,DX]=TRIM('SYS',X0,U0,Y0,IX,IU,IY,DX0,IDX) the length of DX0 should be equal to the number of continuous states in the Simulink model."
The output of the model is set to 1×12, and the DX0 is also set to 1×12. But after getting this error, I use sldiagnostics to check the number of continuous states, and with 12 Integrators (4 integrators used actually, but I guess it is the number of the integrated variables), I unexpectedly get 28 continuous states. The xout of the model is also n×28 (n for total steps).
So, I am trying to know the exact meaning of every row of xout, which variable it is. But I don't know how.
And I want to reduce the number of continuous states in my model. But I don't kow how Simulink make the defination of continuous state, or which block would make continuous states, except the variables after the Integrators.

Answers (1)

Suman
Suman on 31 Jul 2024 at 9:02
Edited: Suman on 31 Jul 2024 at 9:18
the xout property refers to the block states at each time point. You can refer to this https://www.mathworks.com/help/simulink/gui/states.html documentation to learn more about it.
You can refer to this MATLAB Answers thread to learn about continuous and discrete states: https://www.mathworks.com/matlabcentral/answers/36663-what-are-continuous-and-discrete-states-in-simulink
You can see the continuous blocks in yoor model by going to the DEBUG > Information Overlays from Simulink toolstrip and enabling the Colors option from Sample Time section.

Categories

Find more on General Applications in Help Center and File Exchange

Products


Release

R2020b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!