calculate the variance account

4 次查看(过去 30 天)
Garrik Akken
Garrik Akken 2019-4-19
i am new to matllab, below is the given code, i tried to run it but i think i am missing something
t= 0:0.001:3;
xref = sin(2*pi*t).*cos(2*pi*t);
xs1 = 0.5*sin(2*pi*t).*cos(2*pi*t);
xs2 = 1.0*sin(2*pi*t).*cos(2*pi*t);
xs3 = 1.0*sin(2*pi*t).*cos(2*pi*t)+0.1*sin(2*pi*10*t);
  2 个评论
David Wilson
David Wilson 2019-4-19
Not really clear what the problem is. Do you want to regenerate the plot?
t= [0:0.001:3]'; % changed to column vector.
xref = sin(2*pi*t).*cos(2*pi*t);
xs1 = 0.5*sin(2*pi*t).*cos(2*pi*t);
xs2 = 1.0*sin(2*pi*t).*cos(2*pi*t);
xs3 = 1.0*sin(2*pi*t).*cos(2*pi*t)+0.1*sin(2*pi*10*t);
subplot(3,1,1);
plot(t,[xref, xs1])
subplot(3,1,2);
plot(t,[xref, xs2])
subplot(3,1,3);
plot(t,[xref, xs3])
amin assadi
amin assadi 2020-9-15
figure;
subplot(3,1,1);
plot(t,[xref; xs1])
subplot(3,1,2);
plot(t,[xref; xs2])
subplot(3,1,3);
plot(t,[xref; xs3])

请先登录,再进行评论。

回答(0 个)

Community Treasure Hunt

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

Start Hunting!

Translated by