How have a counter in Simulink such that increment with time step and be real positive number

3 vues (au cours des 30 derniers jours)
I have a vector of x(500*1) and I want to write a for loop in S-function (Simulink) such that for every time my model runs, I get diff(x(i:i+1)) . How can I have a counter variable( real positive number) that can be used? I even tried to use some counter blocks but none of them works. I need exactly like writing a for loop in mfile, but the counter needs to be incremented by t(Simulink time step)

Réponses (0)

Catégories

En savoir plus sur Block and Blockset Authoring dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by