Download as pdf or txt
Download as pdf or txt
You are on page 1of 8

DIGITAL SIGNAL PROCESSING(EL-312)

LAB-02
LAB TASK
TASK-1:

OUTPUT:
clear all;
close all;
clc;
A=2;
t=0:0.01:1;
f=input('Frequency');
x=A*cos(2*pi*f*t);
plot(t,x)
grid on
title('continous time sinsodial signal')

TASK-02:
DIGITAL SIGNAL PROCESSING(EL-312)

OUTPUT:
clear all;
close all;
clc;
A=2;
fa=input('Frequency');
fs=1.5;
t=0:0.1/fs:1/fa;
x=A*cos(2*pi*fs*t);
stem(t,x)
grid on
title('continous time sinsodial signal')

TASK-03:

OUTPUT:
DIGITAL SIGNAL PROCESSING(EL-312)

clear all;
close all;
clc;
A=2;
fa=input('frequency');
fs=2;
t=0:0.1/fs:1/fa;
x=A*cos(2*pi*fs*t);
stem(t,x)
grid on

TASK-04:

OUTPUT:
DIGITAL SIGNAL PROCESSING(EL-312)

clear all;
close all;
clc;
A=2;
fa=input('Frequency');
fs=3;
t=0:0.1/fs:1/fa;
x=A*cos(2*pi*fs*t);
stem(t,x)
grid on

Task-05:
OUTPUT:
DIGITAL SIGNAL PROCESSING(EL-312)

close all;
clc;
A=2;
t=0:0.01:1;
fa=input('frequency');
x1=A*cos(2*pi*fs*t);
subplot(4,1,1)
plot(t,x1)
fs=1.5;
t1=0:0.1/fs:1/fa;
x2=A*cos(2*pi*fs*t1);
subplot(4,1,2)
stem(t1,x2)
fs1=2;
t2=0:0.1/fs1:1/fa;
x3=A*cos(2*pi*fs*t2);
subplot(4,1,3)
stem(t2,x3)
fs2=3;
t3=0:0.1/fs2:1/fa;
x4=A*cos(2*pi*fs2*t3);
subplot(4,1,4)
stem(t3,x4)

TASK-06:
OUTPUT:
DIGITAL SIGNAL PROCESSING(EL-312)

clear all;
close all;
clc;
A=3;
fa=50;
fs=100;
t=0:0.1/fs:1/fa;
x=A*cos(2*pi*fa*t);
stem(t,x)
grid on

TASK-6-2:
clear all;
close all;
clc;
A=3;
fa=50;
fs=200;
t=0:0.6/fs:1/fa;
x=A*cos(2*pi*fa*t);
stem(t,x)
grid on
DIGITAL SIGNAL PROCESSING(EL-312)

TASK-06-3:
ear all;
close all;
clc;
A=3;
fa=50;
fs=75;
t=0:0.2/fs:1/fa;
x=A*cos(2*pi*fa*t);
stem(t,x)
grid on
DIGITAL SIGNAL PROCESSING(EL-312)

You might also like