%Input Signal
nx=[-1 0 1 2];
x=[1 0 3 -3];
subplot(3,2,1);
stem(nx,x,'filled');
title('x[n]');
axis ([-5 5 -4 4]);
%Impulse Response h[3-k]
nh=[1 2 3];
h=[1 4 -2];
subplot(3,2,3);
stem(nh,h,'filled');
title('h[3-k]');
axis ([-5 5 -3 5]);
%displacement i =3
%Intermediate output y[3]
ny=[0 1 2 3 0];
y=[0 0  0 -9 0];
subplot(3,2,5);
stem(ny,y,'filled');
title('y[3]');
axis ([-5 5 -10 1]);
%Input Signal
nx=[-1 0 1 2];
x=[1 0 3 -3];
subplot(3,2,2);
stem(nx,x,'filled');
title('x[n]');
axis ([-5 5 -4 4]);
%Impulse Response h[4-k]
nh=[2 3 4];
h=[1 4 -2];
subplot(3,2,4);
stem(nh,h,'filled');
title('h[4-k]');
axis ([-5 5 -3 5]);
%displacement i=4
%Intermediate output y[4]
ny=[0 1 2 3 4];
y=[0 0 0 0 -3];
subplot(3,2,6);
stem(ny,y,'filled');
title('y[4]');
axis ([-5 5 -4 1]);
