How many times does a Matlab Function in Simulink run in one time step
Mostra commenti meno recenti
Hello,
I have a Matlab Function in a Simulink model. Because the Matlab Funtion is time-confusing, I just want it to run one time in a step. But it seems to run multiple (>5) times in a step. I was wondering whether the number of times a Matlab function runs in a step depends on the solver (ode1,ode4, etc) selected. Can anyone provide some insights into this question? Thank you.
Regards Pan
Risposta accettata
Più risposte (1)
Ankit Bhatnagar
il 15 Mag 2017
0 voti
Hi,
There are ways to start the block after a particular major step time like using a Clock block from Simulink/Sources and using simulation time feature of a block but currently not possible to execute a block as an independent task in Simulink.
Please refer this MATLAB Answers post for further details:
- https://www.mathworks.com/matlabcentral/answers/262892-how-do-i-make-a-simulink-embedded-function-run-independent-of-the-time-step-of-the-model
1 Commento
Pan Zhao
il 25 Mag 2017
Categorie
Scopri di più su Event Functions in Centro assistenza e File Exchange
Prodotti
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!