calculate the variance account

7 views (last 30 days)
Garrik Akken
Garrik Akken on 19 Apr 2019
Commented: amin assadi on 15 Sep 2020
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 Comments
David Wilson
David Wilson on 19 Apr 2019
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 on 15 Sep 2020
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])

Sign in to comment.

Answers (0)

Categories

Find more on MATLAB in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!