Académique Documents
Professionnel Documents
Culture Documents
% exp-1
t=0:0.01:10;
nt=length(t);
x=ones(1,nt);
h=2*exp(-1*t);
y1=conv(x,h)*0.01;
y=y1(1,nt);
figure(1);
subplot(3,1,1);
plot(t,x);
subplot(3,1,2);
plot(t,h);
10
10
10
-0.8
-0.6
-0.4
-0.2
0.2
0.4
0.6
0.8
0.2
0.4
0.6
0.8
1.2
1.4
1.6
1.8
0
4
3
subplot(3,1,3);
plot(t,y);
2
1
% exp-2
t1=-1:0.01:0;
x1=-1*ones(size(t1));
t2=0:0.01:1;
x2=ones(size(t2));
t=[t1 t2];
x=[x1 x2];
t3=0:0.01:2;
h=2*exp(-1*t3);
y1=conv(x,h)*0.01;
t4=-1:0.01:3;
nt=length(t4);
y=y1(1:nt);
-1
-1
2
figure(2);
subplot(3,1,1);
plot(t,x);
1
0
subplot(3,1,2);
plot(t3,h);
subplot(3,1,3);
plot(t4,y);
-1
-2
-1
-0.5
0.5
1.5
2.5