フィルターのクリア

plotting complex exponential function

1 回表示 (過去 30 日間)
yann mushid mushid
yann mushid mushid 2023 年 1 月 20 日
回答済み: Raghvi 2023 年 2 月 17 日
i need help for this code
since i plot this code i get a line on the graphe is it normal or i made a mistake on the code?
f=(0:10);
t=(0:0.1);
w=2*pi*f;
rin=0.71;
%y=rin*exp(*-1i*w*t);
y=0.71*exp(-1i*w*t);
%rin=abs(y);
plot(real(f),imag(y));

回答 (1 件)

Raghvi
Raghvi 2023 年 2 月 17 日
Hey yann,
You have a problem in this line of your code:
t=(0:0.1);
This just sets t to 0. You must specify the steps in creating the array. Use:
t=(0:0.01:0.1);
You can vary the step size according to your needs. Additionally, use .* operator instead of * to get your code running.

カテゴリ

Help Center および File ExchangeSearch Path についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by