adsp report 2 2
TRANSCRIPT
-
8/8/2019 ADSP Report 2 2
1/7
M. ENG. IN ELECTRONICS ENGINEERING
SEMESTER 1
ADVANCED DIGITAL SIGNAL PROCESSING
Filter Bank Based Short-time Spectral Analyser.
Project Team Members:
Aoife ByrneJoel George MathewPhilip Creevy
Supervisor
Mohamed Medjaou
-
8/8/2019 ADSP Report 2 2
2/7
REPORT-2
(Team members current project status and future plan.)AIM:
To ascertain the current status of all team members, with a view to smooth
progression of the project.
MEMBERS PRESENT
October 15th 2010 (Wednesday) at 11AM in AG06Aoife Byrne, Joel George Mathew, Philip Creevy.
Basic matlab codes for developing the application are beinginvestigated with a view to improving efficiency once the basic codeis complete.
Philip
Write a program to implement the short-time spectrum analyser given in figure 1 of
project specification.
To apply each speech signal at the input and plot output every 16ms.
While Aoife is finalising the sine wave code I will be researching thecumtrapz function to make sure it is correct. The code will need to be modified to allow an audio file to beprocessedas it will only run for 16mS.
Matlab code written by Philip.
for m=1:19for n=1:1000,
y(m,n)= -b1(m)*y(m,n-1)-b2(m)*y(m,n-2) + a0(m)*x(m,n)- a1(m)*x(m,n-1); if y(m,n)
-
8/8/2019 ADSP Report 2 2
3/7
AoifeTo write and submit a report including all relevant material specified.
Final Report PlanA final report template is shown below; it includes but is not limited
to.Header Page
Title
Subject
Team Members
Date
Wit crest
LecturerOverviewTable of Contents
Table of figuresIntroduction
Project requirements as laid out in specification sheet.Discussion
Break project into parts and discuss each part individually
Speech signal generation
Sinusoid signal generation
BPF bank
Rectifier
LPF bank
IntegratorMethod
Discuss how the parts of the project were allocated to eachteam member
Explain how each section is implemented and then how it isincorporated into the main project
Include Matlab plots and codeResults
Bode plots
Graphs
Debugging methods Code changes
Personal statements of work by each studentConclusion
Difficulties encountered
Recommendations made in hindsight on the running of theproject
How robust the code was found to beReferenceAppendix
-
8/8/2019 ADSP Report 2 2
4/7
-
8/8/2019 ADSP Report 2 2
5/7
Write a program to calculate the digital filter coefficients of each band pass filtergiven the information given in the specification sheet.
Calculate the filter coefficients of the low pass filter.
Calculating the Band Pass Filter (BPF) coefficients.
The second order analogue band pass filter transfer function isgiven by,
Input-Output Equation
From the above transfer function, it is clear that,
The Matlab code for calculating the BPF coefficients s shown below:
Fs=8000;T=1/Fs;
DELTAp = [240 360 480 600 720 840 1000 1150 1300 1450 1600 1800 2000 22002400 2700 3000 3300 3750];bp=[120 120 120 120 120 150 150 150 150 150 150 200 200 200 200 200 300 300500];
for i=1:19,
a0(i)=(2*(bp(i))*T)/((4+(2*(bp(i)*T))+(DELTAp(i)).^2*T.^2));a1(i)=a0(i);
b1(i)=(2*(DELTAp(i)).^2*T.^2-8)/((4+(2*(bp(i)*T))+DELTAp(i).^2*T.^2));
b2(i)=((4-(2*(bp(i)*T))+(DELTAp(i)).^2*T.^2))/((4+(2*(bp(i)*T))+(DELTAp(i)).^2*T.^2));
end
-
8/8/2019 ADSP Report 2 2
6/7
i.e,
In discrete time domain,
Therefore,
The above equation is the output from the BPF. Its Matlab code iswritten as shown below,
Calculating the Low Pass Filter (LPF) coefficients.
The Matlab code for calculating the LPF coefficients s shownbelow:
fc=30;%-------------------------------->Cut off frequency of the low
pass filter.%Fs=8000 ;%-------------------------->Speech signal frequency.%T=1/Fs ;%--------------------------->Speech signal sampling period.
DELTAc=2*pi*fc;
Wc=DELTAc*T;
LPF_a0= (2-cos (Wc))-sqrt ((2-cos (Wc)). ^2-1);
for m=1:19for n=1:1000
y(m,n)= -b1(m)*y(m,n-1)-b2(m)*y(m,n-2) +a0(m)*x(m,n)- a1(m)*x(m,n-1);
if y(m,n)
-
8/8/2019 ADSP Report 2 2
7/7
Input-Output Equation
From the above transfer function,
i.e,
In discrete time domain,
NOTE: Changed y(n), y(n-1) and x(n)to z(n), z(n-1) and y(n) respectively to avoid
confusion with the variables used in the above code.
The Matlab code for the above input-output relation is as shown below,
for m=1:19%****** The varible "m" and "n" might need to be renamed.*****%for n=1:1000,
z(m,n)= LPF_a0*z(m,n-1)+y(m,n);end
g(m)=trapz(n,z(m));
g_db(m) =20*log(g(m));
end
NOTE: The codes in red are written by Joel.