0% found this document useful (0 votes)
18 views5 pages

Lab Report 08: Muhammad Rafay Tariq FA18-BEE-100 Bee-A

Download as pdf or txt
Download as pdf or txt
Download as pdf or txt
You are on page 1/ 5

Lab Report | 1

MUHAMMAD RAFAY TARIQ


FA18-BEE-100
BEE-A

Lab Report 08
Objective
 The purpose of this lab is to be familiarize with CT Fourier Transform of the signal. To use the inverse Fourier
transform to convert back the signal. To get known about with Convolution in frequency domain.

Required Equipment:
Hardware
 No hardware was used while performing this lab.

Software
MATLAB software was used while performing this lab.

Procedure/ Methodology
 Before starting performing this lab on our software tool, we were instructed and guided by our lab instructor about
how to perform this lab through a recorded lecture.

 Lab Tasks included the continuous Time Fourier Transform (CTFT) of the signal using MATLAB. As
fourier transform represents the signal in frequency domain and sometimes it’s easy to compute the signal
response in frequency domain. Its representation is :
 𝑥 (𝑡 ) → 𝑋 (𝜔 )
 The formula to compute Fourier Transform is shown below:

 𝑋(𝜔) = 𝐹 {𝑥(𝑡)} = ∫−∞ 𝑥 (𝑡). 𝑒 −𝑗𝜔𝑡 𝑑𝑡
 In MATLAB, “fourier”command was used to compute the CTFT of the given signals. Also, the inverse
fourier transform was performed to get back the signal in time domain. For this purpose ,the command
used as “ifourier”. Convolution was also computed and plotted in the lab by the help these two commands.
For this, firstly both signals,for which the convolution is to be made were converted into fourier transform
X(ω) and H(ω) then using convolution property of frequency domain was used and signals were multiplied
as Y(ω) and then converted back to time domain y(t) .
 After knowing all the important things regarding performing this lab we performed pre lab and in lab tasks.

Results and Conclusion


 After performing all the tasks of the lab that were asked to performed by our lab instructor we learned how to To
use the inverse Fourier transform to convert back the signal. To get known about with Convolution in frequency
domain .and as well as to Trace the output response of CTFT in MATLAB. The lab tasks are attached below.
Lab Report | 1
Lab Tasks
PRE LAB 1
Solution
%mrafaytariq
%bee-a
%fa18bee100
%prelab 1
syms w t
m1=exp(5*t).*heaviside(-t);
m2=fourier(m1)
m3=t.*exp(-5*t).*heaviside(t);
m4=fourier(m3)
m5=heaviside(t-1)-heaviside(t+1);
m6=-3:0.01:3;
subplot 131
plot(m6,subs(m2,m6));
title('m3')
subplot 132
plot(m6,subs(m4,m6));
title('m4')
subplot 133
xb=fourier(m5,w);
ezplot(xb, [-40 40])
title('m5');
INLAB TASK 1

Solution
%mrafaytariq
%bee-a
%fa18bee100
%inlab1
%mrafaytariq
%fa18bee100
%bee-a
close all
clear all
syms t w
x=exp(-t^2);
fourier(x,w)
z=int(x*exp(-j*w*t),t,inf,inf)

SOLUTION
Lab Report | 1

%mrafaytariq
%bee-a
%fa18bee100
%inlab2
inverse fourier transform
close all
clear all
syms t w

X=1/(1+j*w);
z=ifourier(X,t)
ezplot(z,t)

SOLUTION
%mrafaytariq
%bee-a
%fa18bee100
%inlab3
close all
clear all
syms t w

x=exp(-t)*heaviside(t);
ezplot(x,t)
X=fourier(x,w)

SOLUTION
%mrafaytariq
%bee-a
%fa18bee100
%inlab4
syms d d1
d2=-2*pi:0.01:2*pi;

d3=-30:0.01:30;
d4=sin(pi.*d1)./(pi.*d1)

subplot 211
ezplot(d4)

plot(d2,subs(d4,d1,d2));
Lab Report | 1
title('Sinc')
d5=fourier(d4)

subplot 212
ezplot(d5)
plot(d3,subs(d5,d,d3));
title('fourier of Sinc');

SOLUTION

%mrafaytariq
%bee-a
%fa18bee100
%inlab5
close all
clear all
syms t w
x=t^exp(-3*t)^heaviside(t);
X=fourier(x,w);
w=-20:0.1:20;
X=subs(X,w);
figure
plot(w,abs(X));
legend('madnitude')

figure
plot(w,abs(X));
legend('angle')

figure
plot(w,real(X))
legend('real')

figure
plot(w,imag(X))
legend('imaginary')
Lab Report | 1
SOLUTION
%mrafaytariq
%bee-a
%fa18bee100
%inlab6
syms w t
g1=exp(-t).*heaviside(t);
g2=exp(-t).*cos(2.*pi.*t).*heaviside(t);

g3=fourier(g1);
g4=fourier(g2);

g5=simplify(g3*g4);

g6=ifourier(g5,w,t);

g7=-3:0.01:3;
subplot 131
plot(g7,subs(g1,g7));

subplot 132
plot(g7,subs(g2,t,g7));
subplot 133
plot(g7,subs(g6.*heaviside(t),t,g7));

You might also like