Operating points error: Error:The simulation inputs must be specified as a vector of doubles while using the trimming tool from model linearizer

47 次查看(过去 30 天)
Hello everyone,
I am having a problem using the trimming tool from the model linearizer (Control Systems Toolbox).
Every time I try to run the tool to find the operating points, I get an error like "The simulation inputs must be specified as a vector of doubles".
I have already checked the dimension of the only two inputs included in the model (HStab and Throttle, which hold values for the elevator angle and throttle setting of the engine), but both are defined as doubles.
The model itself calculates the states of the longitudinal motion of an aircraft (u, w, q and theta) using the 3dof (body axes) block from the aerospace blockset toolbox.
Does anyone know how I can fix this error so that the model linearizer can calculate an operating point?
Thanks in advance

回答(1 个)

Maneet Kaur Bagga
Maneet Kaur Bagga 2024-11-20,4:14
编辑:Maneet Kaur Bagga 2024-11-20,4:14
Hi,
As per my understanding, the "Model Linearizer" requires the inputs to be explicitly defined as a vector of doubles for trimming and linearization. Please refer to the following as a possiblle workaround for the same:
  • Check Signal Types and Dimensions: Use "Signal Specification blocks" from Simulink library to verify the type and dimensions of these inputs.
  • Use Model Diagnostic Tools: Run the "Model Advisor" to check for input signal issues. Enable signal logging and confirm the exact values and types of "HStab" and "Throttle".
  • Set Fixed Initial Values: In the "Trimming Tool", ensure that initial values are provided for all inputs and states.
  • Use Script-Based Trimming: Instead of using the GUI, use the "findop" function to specify operating points programmatically.
op = operspec('YourModelName');
% Set input and state specifications
op.Inputs(1).u = 0; % Throttle
op.Inputs(2).u = 0; % HStab
op.States(1).x = 0; % Example state
options = findopOptions('DisplayReport', 'on');
[opPoint, opReport] = findop('YourModelName', op, options);
Please refer to the following MathWorks documentation for the findop function:
Hope this helps!

类别

Help CenterFile Exchange 中查找有关 Guidance, Navigation, and Control (GNC) 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by