How do I express this function in MATLAB?
when T = 3s, W = Pi rad/s, t has a value, from 0 to 10 seconds.
y(t) = 10 * e^(-t / T) * sin(W * t)
(T is time constant. and W is angular velocity.)

 採用された回答

KALYAN ACHARJYA
KALYAN ACHARJYA 2019 年 9 月 29 日
編集済み: KALYAN ACHARJYA 2019 年 9 月 29 日

0 投票

function y=test1()
T=3;
W=pi;
t=0.01:10
y=10*exp((-t./T).*sin(W.*t))
end
Or Direct
T=3;
W=pi;
t=0.01:10;
y=10*exp((-t./T).*sin(W.*t))

2 件のコメント

Deokgi Hong
Deokgi Hong 2019 年 9 月 29 日
Thank you!
but I wonder why 't' started from 0.01?
KALYAN ACHARJYA
KALYAN ACHARJYA 2019 年 9 月 29 日
t=0:0.1:10;

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

その他の回答 (0 件)

カテゴリ

Community Treasure Hunt

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

Start Hunting!

Translated by