libaoan
2010-06-02, 22:09
dt=0.01;
t=-1:0.01:6;
x=(t>0)-(t-2>0);
t=-1:0.01:6;
y1=(t-1>0);
y2=(t-3>0);
y=y1-y2;
z=dt*conv(x,y);
subplot(3,1,1);
plot(t,x);
axis([-1 6 0 2.1]);
subplot(3,1,2);
plot(t,y);
axis([-1 6 0 2.1]);
subplot(3,1,3);
plot(t,z);
axis([-6 8 0 2.1]);
哪位大哥帮我看看那有问题呀
t=-1:0.01:6;
x=(t>0)-(t-2>0);
t=-1:0.01:6;
y1=(t-1>0);
y2=(t-3>0);
y=y1-y2;
z=dt*conv(x,y);
subplot(3,1,1);
plot(t,x);
axis([-1 6 0 2.1]);
subplot(3,1,2);
plot(t,y);
axis([-1 6 0 2.1]);
subplot(3,1,3);
plot(t,z);
axis([-6 8 0 2.1]);
哪位大哥帮我看看那有问题呀