Hidden constants in SIMULINK?

Hello
I am attempting to modify someone else's Simulink model. There are constant blocks with constant names as opposed to numbers. For example, rotor RPM input is 'Omega'.
In my experience, this should be defined in the workspace through some appropriate script file. In this model it will run fine without any script file and without any constants defined in the workspace. After the simulation has run no constants appear in the workspace.
Please tell me where the simulink model might be getting these values from! Thanks

 Accepted Answer

Sebastian Castro
Sebastian Castro on 13 May 2015
They could be in the Model Workspace, which is a great place to "protect" variables from the MATLAB base workspace.
You can go there by selecting View > Model Explorer, or Ctrl+H on Windows. Once you're there, you can navigate through your open model and find the Model Workspace section. See if those variables are there.
Another way to get the Model Explorer opened up is by right-clicking the model and selecting Find Referenced Variables. That will show you the locations of all variables used by that model, and where they are.
- Sebastian

2 Comments

Thanks Sebastian. So simple yet has saved me so much time!
I also have a similar problem to romeo but I didnt solve it by Sebastians answer

Sign in to comment.

More Answers (0)

Categories

Products

Community Treasure Hunt

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

Start Hunting!