how to change the fall time of step input in simulink

1 回表示 (過去 30 日間)
Swasthik Baje Shankarakrishna Bhat
Swasthik Baje Shankarakrishna Bhat 2022 年 9 月 22 日
回答済み: Sam Chak 2022 年 9 月 22 日
Hi,
Can we have a neative sloped step input with programmable fall time?
I tried to follow this way but not able to rreproduce the result.
Thanks and regards,
Swasthik

回答 (1 件)

Sam Chak
Sam Chak 2022 年 9 月 22 日
You reuse the same syntax. I created a general one so that you can enter the desired parameters:
% Syntax:
% u = min(1, max(0, "Linear Line function"));
t = linspace(0, 25, 251);
ramp_start = 10;
ramp_end = 15;
u = min(1, max(0, -1/(ramp_end - ramp_start)*(t - ramp_end)));
plot(t, u, 'linewidth', 1.5), grid on, ylim([-1 2])

カテゴリ

Help Center および File ExchangeEvent Functions についてさらに検索

製品


リリース

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by