%Experiment No. 3
%Name: Anurag Rameshwar Kados
%Roll No.:EC2162
%Class:SY-A(E&TC)
%Batch:A-5
%Aim :To study and perform use of convolution tool for LTI Discrete time system Analysis
clc;
clear all;
close all;
%linear convolution of two signals
x=[1,2,3,4,5];
subplot(3,2,1);
stem(x);
xlabel('n');
title('First Signal');
ylabel('Amplitude');
y=[5,4,3,2,1];
subplot(3,2,2);
stem(y);
xlabel('n');
title('Second Signal');
ylabel('Amplitude');
z=conv(x,y);
subplot(3,2,3);
stem(z);
xlabel('n');
title('Convolution of Signal');
ylabel('Amplitude');
c=deconv(z,y);
subplot(3,2,4);
stem(c);
xlabel('n');
title('Deconvolution of First Signal');
ylabel('Amplitude');
b=deconv(z,x);
subplot(3,2,5);
stem(b);
xlabel('n');
title('Deconvolution of Second Signal');
ylabel('Amplitude');