<< Chapter < Page Chapter >> Page >

Given this background, we would now like you to create a spectrogram using your DFTwin() function from the previous section. You will do this by creating a matrix of windowed DFTs, oriented asdescribed above. Your function should be of the form

A = Specgm(x,L,overlap,N)

where x is your input signal, L is the window length, overlap is the number of points common to successive windows, and N is the number of points you compute in each DFT. Within your function, you should plot themagnitude (in dB) of your spectrogram matrix using the command imagesc() , and label the time and frequency axes appropriately.

Important hints

  • Remember that frequency in a spectrogram increases along the positive y-axis, which means that the first few elements of eachcolumn of the matrix will correspond to the highest frequencies.
  • Your DFTwin() function returns the DT spectrum for frequencies between 0 and 2 π . Therefore, you will only need to use the first or second half of these DFTs.
  • The statement B(:,n) references the entire n t h column of the matrix B .
  • In labeling the axes of the image, assume a sampling frequency of 8 KHz. Then the frequency will range from 0 to 4000 Hz.
  • The axis xy command will be needed in order to place the origin of your plot in the lower left corner.
  • You can get a standard gray-scale mapping (darker means greater magnitude) by using the command colormap(1-gray) , or a pseudo-color mapping using the command colormap(jet) . For more information, see the online help for the image command.

Download the file signal.mat , and load it into Matlab. This is a raised square wave that is modulated by a sinusoid.What would the spectrum of this signal look like? Create both a wideband and a narrowband spectrogram using your Specgm() function for the signal.

  • For the wideband spectrogram, use a window length of 40 samples and an overlap of 20 samples.
  • For the narrowband spectrogram, use a window length of 320 samples, and anoverlap of 60 samples.

Subplot the wideband and narrowband spectrograms, and the original signal in the same figure.

Hand in your code for Specgm() and your plots. Do you see vertical striations in the wideband spectrogram? Similarly, do you see horizontalstriations in the narrowband spectrogram? In each case, what causes these lines, and what does the spacing between them represent?

Formant analysis

Download the file vowels.mat for the following section.

The shape of an acoustic excitation for voiced speech is similar to a triangle wave. Therefore it has many harmonics at multiples of itsfundamental frequency, 1 / T p . As the excitation propagates through the vocal tract, acoustic resonances, or standing waves,cause certain harmonics to be significantly amplified. The specific wavelengths, hence the frequencies, of the resonances are determinedby the shape of the cavities that comprise the vocal tract. Different vowel sounds are distinguished by unique sets of these resonances, or formant frequencies . The first three average formants for several vowels are given in [link] .

Average Formant Frequencies for the Vowels. See [link] .

A possible technique for speech recognition would to determine a vowel utterance based on its unique set of formant frequencies.If we construct a graph that plots the second formant versus the first, we find that a particular vowel sound tends to lie within acertain region of the plane. Therefore, if we determine the first two formants, we can construct decision regions to estimatewhich vowel was spoken. The first two average formants for some common vowels are plotted in [link] . This diagram is known as the vowel triangle due to the general orientation of the average points.

Keep in mind that there is a continuous range of vowel sounds that can be produced by a speaker. When vowels are used in speech, their formantsmost often slide from one position to another.

Download the file vowels.mat , and load it into Matlab. This file contains the vowel utterances a,e,i,o , and u from a female speaker. Load this into Matlab, and plot a narrowbandspectrogram of each of the utterances. Notice how the formant frequencies change with time.

For the vowels a and u , estimate the first two formant frequencies using the functions you createdin the previous sections. Make your estimates at a time frame toward the beginning of the utterance,and another set of estimates toward the end of the utterance. You may want to use both the Specgm and DFTwin functions to determine the formants. Plot these four points in the vowel triangleprovided in [link] . For each vowel, draw a line connecting the two points, and draw anarrow indicating the direction the formants are changing as the vowel is being uttered.

Hand in your formant estimates on the vowel triangle.
The Vowel Triangle

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