How to make a simulink model which runs using a output it calculates at each step and to its next calcuation
3 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Akshay Dhyani
am 22 Mär. 2021
Kommentiert: Akshay Dhyani
am 30 Mär. 2021
Hi,
I am looking to run a piece of simulink model which uses a final output in it's intremin calculations. For example, I have tried using phiFilterTrapped to feedback the value the switch action cases but it throws an error
Input data dependency violation due to action subsystems. See Subsystem Examples in the Simulink library for valid and invalid examples of action subsystems
Component: Simulink | Category: Model error
Component: Simulink | Category: Model error
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/557622/image.jpeg)
0 Kommentare
Akzeptierte Antwort
Kiran Felix Robert
am 24 Mär. 2021
Hi Akshay,
You get the 'Data Dependency Violation error' because you have not latched the inputs to your function-call subsystems. Refer this answer for the procedure Latch your inputs to the switch-case subsystems.
The To Workspace blocks saves the simulation data only after the simulation ends (After the last time step) not intermittently, so Latching your inputs to the subsystem will be the best way to have a feedback loop.
2 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Schedule Model Components finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!