<< Chapter < Page Chapter >> Page >

Put all three plots on the same figure using the subplot command.

Submit the difference equation, system diagram, and the analytical expression of the impulse response for the filter H f ( z ) . Also submit the plot of the magnitude response for the threevalues of θ . Explain how the value of θ affects the magnitude of the filter's frequency response.

In the next experiment, we will use the filter H f ( z ) to remove an undesirable sinusoidal interference from a speech signal.To run the experiment, first download the audio signal nspeech1.mat , and the M-file DTFT.m Load nspeech1.mat into Matlab using the command load nspeech1 . This will load the signal nspeech1 into the workspace. Play nspeech1 using the sound command, and then plot 101 samples of the signal for the time indices (100:200).

We will next use the DTFT command to compute samples of the DTFT of the audio signal.The DTFT command has the syntax

[X,w]=DTFT(x,M)

where x is a signal which is assumed to start at time n = 0 , and M specifies the number of output points of the DTFT. The command [X,w]=DTFT(x,0) will generate a DTFT that is the same duration as the input; if thisis not sufficient, it may be increased by specifying M . The outputs of the function are a vector X containing the samples of the DTFT, and a vector w containing the corresponding frequencies of these samples.

Compute the magnitude of the DTFT of 1001 samples of the audio signal for the time indices (100:1100).Plot the magnitude of the DTFT samples versus frequency for | ω | < π . Notice that there are two large peaks corresponding to the sinusoidalinterference signal. Use the Matlab max command to determine the exact frequency of the peaks.This will be the value of θ that we will use for filtering with H f ( z ) .

Use the command [Xmax,Imax]=max(abs(X)) to find the value and index of the maximum element in X . θ can be derived using this index.

Write a Matlab function FIRfilter(x) that implements the filter H f ( z ) with the measured value of θ and outputs the filtered signal (Hint: Use convolution).Apply the new function FIRfilter to the nspeech1 vector to attenuate the sinusoidal interference.Listen to the filtered signal to hear the effects of the filter. Plot 101 samples of the signal for the time indices (100:200),and plot the magnitude of the DTFT of 1001 samples of the filtered signal for the time indices (100:1100).

Inlab report

For both the original audio signal and the filtered output, hand in the following:
  • The time domain plot of 101 samples.
  • The plot of the magnitude of the DTFT for 1001 samples.
Also hand in the code for the FIRfilter filtering function. Comment on how the frequency content of the signal changedafter filtering. Is the filter we used a lowpass, highpass, bandpass, or abandstop filter? Comment on how the filtering changed thequality of the audio signal.

Design of a simple iir filter

Download the file pcm.mat for the following section.

Location of two poles for a simple IIR filter.

While zeros attenuate a filtered signal, poles amplify signals that are near their frequency.In this section, we will illustrate how poles can be used to separatea narrow-band signal from adjacent noise. Such filters are commonly used to separate modulatedsignals from background noise in applications such as radio-frequency demodulation.

Questions & Answers

how to create a software using Android phone
Wiseman Reply
how
basra
what is the difference between C and C++.
Yan Reply
what is software
Sami Reply
software is a instructions like programs
Shambhu
what is the difference between C and C++.
Yan
yes, how?
Hayder
what is software engineering
Ahmad
software engineering is a the branch of computer science deals with the design,development, testing and maintenance of software applications.
Hayder
who is best bw software engineering and cyber security
Ahmad
Both software engineering and cybersecurity offer exciting career prospects, but your choice ultimately depends on your interests and skills. If you enjoy problem-solving, programming, and designing software syste
Hayder
what's software processes
Ntege Reply
I haven't started reading yet. by device (hardware) or for improving design Lol? Here. Requirement, Design, Implementation, Verification, Maintenance.
Vernon
I can give you a more valid answer by 5:00 By the way gm.
Vernon
it is all about designing,developing, testing, implementing and maintaining of software systems.
Ehenew
hello assalamualaikum
Sami
My name M Sami I m 2nd year student
Sami
what is the specific IDE for flutter programs?
Mwami Reply
jegudgdtgd my Name my Name is M and I have been talking about iey my papa john's university of washington post I tagged I will be in
Mwaqas Reply
yes
usman
how disign photo
atul Reply
hlo
Navya
hi
Michael
yes
Subhan
Show the necessary steps with description in resource monitoring process (CPU,memory,disk and network)
samuel Reply
What is software engineering
Tafadzwa Reply
Software engineering is a branch of computer science directed to writing programs to develop Softwares that can drive or enable the functionality of some hardwares like phone , automobile and others
kelvin
if any requirement engineer is gathering requirements from client and after getting he/she Analyze them this process is called
Alqa Reply
The following text is encoded in base 64. Ik5ldmVyIHRydXN0IGEgY29tcHV0ZXIgeW91IGNhbid0IHRocm93IG91dCBhIHdpbmRvdyIgLSBTdGV2ZSBXb3puaWFr Decode it, and paste the decoded text here
Julian Reply
what to do you mean
Vincent
hello
ALI
how are you ?
ALI
What is the command to list the contents of a directory in Unix and Unix-like operating systems
George Reply
how can i make my own software free of cost
Faizan Reply
like how
usman
hi
Hayder
The name of the author of our software engineering book is Ian Sommerville.
Doha Reply
what is software
Sampson Reply
the set of intruction given to the computer to perform a task
Noor
Got questions? Join the online conversation and get instant answers!
Jobilize.com Reply

Get Jobilize Job Search Mobile App in your pocket Now!

Get it on Google Play Download on the App Store Now




Source:  OpenStax, Purdue digital signal processing labs (ece 438). OpenStax CNX. Sep 14, 2009 Download for free at http://cnx.org/content/col10593/1.4
Google Play and the Google Play logo are trademarks of Google Inc.

Notification Switch

Would you like to follow the 'Purdue digital signal processing labs (ece 438)' conversation and receive update notifications?

Ask