You are on page 1of 3

Table of Contents

........................................................................................................................................ 1

EXERCISE 1................................................................................................................................................1
Comment.......................................................................................................................................................2
EXERCISE 2................................................................................................................................................2
Comment.......................................................................................................................................................3
Conclusion....................................................................................................................................................3

% Name of Student: Shweta Sonkusare


% Roll No.: 222
% Section: C
% Semester: VI
% Course Code: ET2352
% Course Teacher Name: Prof. M S DORLE
% Date of Performance: 14/05/2021
% Department of Electronics and Telecommunication YCCE,NAGPUR

EXERCISE 1
clf;
%M = input('Down-sampling factor = ');
M =2
n = 0:99;
x = sin(2*pi*0.043*n) + sin(2*pi*0.031*n);
y = decimate(x,M,'fir');

subplot(2,1,1);
stem(n,x(1:100));
title('Input Sequence');
xlabel('Time index n');
ylabel('Amplitude');

subplot(2,1,2);
m = 0:(100/M)-1;
stem(m,y(1:100/M));
title('Output Sequence');
xlabel('Time index n');
ylabel('Amplitude');

M =

1
Comment
The frequency of the output signal is decreaased by the factor of 2.

EXERCISE 2
clf;
% M=input('Down Sampling Factor= ');
M=4;
n=0:119;
x=sin(2*pi*0.045*n)+sin(2*pi*0.029*n);
y=decimate(x,M,'fir');

subplot(2,1,1);
stem(n,x(1:120));
title('Input Sequence');
xlabel('Time index n');
ylabel('Amplitude');

subplot(2,1,2);
m = 0:(120/M)-1;
stem(m,y(1:120/M));
title('Output Sequence');
xlabel('Time index n');
ylabel('Amplitude');
Comment
The frequency of the output signal is decreaased by the factor of 3.

Conclusion
All the problem have been performed successfully and desired results have been obtained.

Published with MATLAB® R2021a

You might also like