have output equations displayed in term of inputs of Simulink model

17 views (last 30 days)
Say I have a Simulink model with n inputs and m outputs. Is there a way to display the m output equations analytically in terms of the n inputs: output(k) = f_k(input(1), input(2),...,input(n)) for k = 1 to m. Cheers.
Boris Konig
Boris Konig on 21 Jan 2020
Nishant, thanks for your comment. Actually, I want to calculate an operating point of a Simulink model ("findop") and then linearize the model around that operating point ("linmod"). I have tried the "Steady State Manager" suggesting values and using different optimization algorithms but it just does not converge although physically there should definitely be a stable operating point.
My idea then was to have output equations calculated so I could use those to algebraically try to calculate a stable operating point by pen and paper or using the Matlab "solve" function or elsewise.
The model and the constants are attached. Thank you very much. Boris

Sign in to comment.

Answers (1)

Nishant Gupta
Nishant Gupta on 22 Jan 2020
For the given model, you can use Linear Analysis Tool to linearize the model. Refer this link to know more about this tool.
You can also refer to the following videos on trimming and linearization:
  1. Trim, Linearization, and Control Design for an Aircraft
  2. Batch Mode Trimming and Linearization
  1 Comment
Boris Konig
Boris Konig on 9 Jan 2021
Edited: Boris Konig on 9 Jan 2021
Unfortunately this issue still is not solved. We put this problem aside and now need to revisit Thank you for the advise to use the Linear Analysis Tool. I got it to find various operating points, but unfortunately not the one I need. (The one I need is: state_2 = 52.4, state_4 = 73.3 and state_13 = 52.4). I am sure it exists; but I assume the solution to be very narrow. Now it all comes down to finding the right initial conditions. My understanding is that one has to start in the correct "valley" for the solver to converge to the desired operating point. Problem is that I do not know those initial conditions well enough. I tried to use the Linear Analysis Tool on all subsystems to get a feeling for the range. But those ranges are too wide (also this was extremely time consuming).That is why I had the idea for Matlab/Simulink to return the analytical functions that lie behind this Simulink model, so I can manually try to find initial conditions and then use the Linear Analysis Tool... Is there any way to retrieve those equations?
Regards. Boris

Sign in to comment.


Find more on Simulink Functions 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!