How to plot a transfer function with variable input?

1 回表示 (過去 30 日間)
Emílio Heringer
Emílio Heringer 2019 年 3 月 31 日
コメント済み: Star Strider 2019 年 3 月 31 日
Consider the dynamics described below for the temperature measuring instrument. Get the
(y (t)) as a function of time, if the input (x (t)) varies subsequently, following the
following pattern: 30 Celsius → 35 Celsius → 45 Celsius → 30 Celsius. Note that subsequent entry only occurs after the instrument has presented its final indication.
Ft = 0,754 /(4s + 1)
I really need help.
  2 件のコメント
Walter Roberson
Walter Roberson 2019 年 3 月 31 日
Is it correct that on subsequent time steps, the input x is
30, 35, 45, 30, 30, 35, 45, 30, 30, 35, 45, 30, ...
? Or is it
30, 35, 45, 30, 35, 45, 30, 35, 45, 30, ...
?
Are we given delta t ?
Emílio Heringer
Emílio Heringer 2019 年 3 月 31 日
30, 35, 45, 30, 35, 45, 30, 35, 45, 30, ...

サインインしてコメントする。

回答 (1 件)

Star Strider
Star Strider 2019 年 3 月 31 日
編集済み: Star Strider 2019 年 3 月 31 日
I am not certain exactly what you are asking, or what your system is doing. You need to use the tf (link) function to produce a system object from your transfer function, and the lsim (link) function to do the simulation.
EDIT — (31 Mar 2019 at 02:46)
s = tf('s');
Ft = 0.754 / (4*s + 1);
u = repmat([30, 35, 45], 1, 10);
t = 0:numel(u)-1;
y = lsim(Ft, u, t);
figure
plot(t, u, '--')
hold on
plot(t, y, '-')
hold off
xlabel('Time')
ylabel('Amplitude')
legend('u(t)', 'y(t)', 'Location','SE')
  2 件のコメント
Emílio Heringer
Emílio Heringer 2019 年 3 月 31 日
thank you
Star Strider
Star Strider 2019 年 3 月 31 日
My pleasure.
If my Answer helped you solve your problem, please Accept it!

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeDigital Filter Analysis についてさらに検索

製品


リリース

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by