# 0.11 Lab 7c - power spectrum estimation  (Page 2/2)

 Page 2 / 2

Use your Pgram function to estimate the power spectrumof $y\left(n\right)$ , ${P}_{yy}\left({\omega }_{k}\right)$ . Plot ${P}_{yy}\left({\omega }_{k}\right)$ vs. ${\omega }_{k}$ .

Next, estimate the power spectrum of $y$ , ${P}_{yy}\left({\omega }_{k}\right)$ using $1/4$ of the samples of $y$ . Do this only using samples ${y}_{0}$ , ${y}_{1}$ , $\cdots$ , ${y}_{255}$ . Plot ${P}_{yy}\left({\omega }_{k}\right)$ vs. ${\omega }_{k}$ .

## Inlab report

1. Hand in your labeled plots and your Pgram code.
2. Compare the two plots. The first plot uses 4 times as many samples as the second one. Is the firstone a better estimation than the second one? Does the first give you a smoother estimation?
3. Judging from the results, when the number of samples of a discrete random variable becomes larger,will the estimated power spectrum be smoother?

## Averaged periodogram

The periodogram is a simple method, but it does not yield very good results.To get a better estimate of the power spectrum, we will introduce Bartlett's method, also known as the averaged periodogram . This method has three steps. Suppose we have a length-N sequence $x\left(n\right)$ .

1. Subdivide $x\left(n\right)$ into $K$ nonoverlapping segments of length $M$ . Denote the ${i}^{th}$ segment as ${x}_{i}\left(n\right)$ .
${x}_{i}\left(n\right)=x\left(n+iM\right),\phantom{\rule{0.277778em}{0ex}}\phantom{\rule{0.277778em}{0ex}}i=0,1,\cdots ,K-1,\phantom{\rule{0.277778em}{0ex}}\phantom{\rule{0.277778em}{0ex}}n=0,1,\cdots ,M-1$
2. For each segment ${x}_{i}\left(n\right)$ , compute its periodogram
${P}_{{x}_{i}{x}_{i}}^{\left(i\right)}\left({\omega }_{k}\right)=\frac{1}{M}{\left|\sum _{n=0}^{M-1},{x}_{i},\left(n\right),{e}^{-j{\omega }_{k}n}\right|}^{2}$
${\omega }_{k}=\frac{2\pi k}{M}$
where $k=0,1,\cdots ,M-1$ and $i=0,1,\cdots ,K-1$ .
3. Average the periodograms over all $K$ segments to obtain the averaged periodogram, ${P}_{xx}^{A}\left(k\right)$ ,
${P}_{xx}^{A}\left({\omega }_{k}\right)=\frac{1}{K}\sum _{i=0}^{K-1}{P}_{{x}_{i}{x}_{i}}^{\left(i\right)}\left({\omega }_{k}\right)$
${\omega }_{k}=\frac{2\pi k}{M}$
where $k=0,1,\cdots ,M-1$ .

Write a Matlab function called AvPgram to calculate the averaged periodogram, using the above steps.The syntax for this function should be

[P,w] = AvPgram(x, K)

where $x$ is a discrete random sequence of length $N$ and the $K$ is the number of nonoverlapping segments. The outputs of this command are $P$ , the samples of the averaged periodogram, and $w$ , the corresponding frequencies of the samples. Both $P$ and $w$ should be vectors of length M where N=KM. You may use your Pgram function.

The command A=reshape(x,M,K) will orient length $M$ segments of the vector $x$ into $K$ columns of the matrix $A$ .

Use your Matlab function AvPgram to estimate the power spectrum of $y\left(n\right)$ which was generated in the previous section. Use all 1024 samples of $y\left(n\right)$ , and let $K=16$ . Plot $P$ vs. $w$ .

## Inlab report

1. Submit your plot and your AvPgram code.
2. Compare the power spectrum that you estimated using the averaged periodogram withthe one you calculated in the previous section using the standard periodogram. What differences do you observe? Which do you prefer?

## Power spectrum and lti systems

Consider a linear time-invariant system with frequency response $H\left({e}^{j\omega }\right)$ , where ${S}_{xx}\left(\omega \right)$ is the power spectrum of the input signal, and ${S}_{yy}\left(\omega \right)$ is the power spectrum of the output signal.It can be shown that these quantities are related by

${S}_{yy}\left(\omega \right)=\mid H\left({e}^{j\omega }\right){\mid }^{2}{S}_{xx}\left(\omega \right)\phantom{\rule{4pt}{0ex}}.$

In the "Periodogram" section, the sequence $y\left(n\right)$ was generated byfiltering an i.i.d. Gaussian (mean=0, variance=1) sequence $x\left(n\right)$ , using the filter in [link] . By hand, calculate the power spectrum ${S}_{xx}\left(\omega \right)$ of $x\left(n\right)$ , the frequency response of the filter, $H\left({e}^{j\omega }\right)$ , and the power spectrum ${S}_{yy}\left(\omega \right)$ of $y\left(n\right)$ .

In computing ${S}_{xx}\left(\omega \right)$ , use the fact that $\mid ab{\mid }^{2}=a{b}^{*}\phantom{\rule{4pt}{0ex}}.$
Plot ${S}_{yy}\left(\omega \right)$ vs. $\omega$ , and compare it with the plots from the "Periodogram" and "Averaged Periodogram" sections. What do you observe?

## Inlab report

2. Submit your analytical calculations for ${S}_{xx}\left(\omega \right)$ , $H\left({e}^{j\omega }\right)$ , ${S}_{yy}\left(\omega \right)$ .
3. Compare the theoretical power spectrum of ${S}_{yy}\left(\omega \right)$ with the power spectrum estimated using the standard periodogram. What can you conclude?
4. Compare the theoretical power spectrum of ${S}_{yy}\left(\omega \right)$ with the power spectrum estimated using the averaged periodogram. What can you conclude?

## Estimate the power spectrum of a speech signal

Download the file speech.au for this section. For help on the following Matlab topics select the corresponding link: how to load and play audio signals and specgram function .

The methods used in the last two sections can only be applied to stationary random processes. However, most signals in nature are not stationary. For a nonstationary random process,one way to analyze it is to subdivide the signal into segments (which may be overlapping)and treat each segment as a stationary process. Then we can calculate the power spectrum of each segment. This yieldswhat we call a spectrogram .

While it is debatable whether or not a speech signal is actually random, in many applications it is necessary to model it as being so.In this section, you are going to use the Matlab command specgram to calculate the spectrogram of a speech signal. Read the help for the specgram function . Find out what the command does, and how to calculate and draw aspectrogram.

Draw the spectrogram of the speech signal in speech.au . When using the specgram command with no output arguments, the absolute value of the spectrogram will be plotted.Therefore you can use

speech=auread('speech.au');

to read the speech signal and use

specgram(speech);

to draw the spectrogram.

## Inlab report

1. Hand in your spectrogram plot.
2. Describe the information that the spectrogram is giving you.

do you think it's worthwhile in the long term to study the effects and possibilities of nanotechnology on viral treatment?
absolutely yes
Daniel
how to know photocatalytic properties of tio2 nanoparticles...what to do now
it is a goid question and i want to know the answer as well
Maciej
Abigail
Do somebody tell me a best nano engineering book for beginners?
what is fullerene does it is used to make bukky balls
are you nano engineer ?
s.
fullerene is a bucky ball aka Carbon 60 molecule. It was name by the architect Fuller. He design the geodesic dome. it resembles a soccer ball.
Tarell
what is the actual application of fullerenes nowadays?
Damian
That is a great question Damian. best way to answer that question is to Google it. there are hundreds of applications for buck minister fullerenes, from medical to aerospace. you can also find plenty of research papers that will give you great detail on the potential applications of fullerenes.
Tarell
what is the Synthesis, properties,and applications of carbon nano chemistry
Mostly, they use nano carbon for electronics and for materials to be strengthened.
Virgil
is Bucky paper clear?
CYNTHIA
so some one know about replacing silicon atom with phosphorous in semiconductors device?
Yeah, it is a pain to say the least. You basically have to heat the substarte up to around 1000 degrees celcius then pass phosphene gas over top of it, which is explosive and toxic by the way, under very low pressure.
Harper
Do you know which machine is used to that process?
s.
how to fabricate graphene ink ?
for screen printed electrodes ?
SUYASH
What is lattice structure?
of graphene you mean?
Ebrahim
or in general
Ebrahim
in general
s.
Graphene has a hexagonal structure
tahir
On having this app for quite a bit time, Haven't realised there's a chat room in it.
Cied
what is biological synthesis of nanoparticles
what's the easiest and fastest way to the synthesize AgNP?
China
Cied
types of nano material
I start with an easy one. carbon nanotubes woven into a long filament like a string
Porter
many many of nanotubes
Porter
what is the k.e before it land
Yasmin
what is the function of carbon nanotubes?
Cesar
I'm interested in nanotube
Uday
what is nanomaterials​ and their applications of sensors.
what is nano technology
what is system testing?
preparation of nanomaterial
Yes, Nanotechnology has a very fast field of applications and their is always something new to do with it...
what is system testing
what is the application of nanotechnology?
Stotaw
In this morden time nanotechnology used in many field . 1-Electronics-manufacturad IC ,RAM,MRAM,solar panel etc 2-Helth and Medical-Nanomedicine,Drug Dilivery for cancer treatment etc 3- Atomobile -MEMS, Coating on car etc. and may other field for details you can check at Google
Azam
anybody can imagine what will be happen after 100 years from now in nano tech world
Prasenjit
after 100 year this will be not nanotechnology maybe this technology name will be change . maybe aftet 100 year . we work on electron lable practically about its properties and behaviour by the different instruments
Azam
name doesn't matter , whatever it will be change... I'm taking about effect on circumstances of the microscopic world
Prasenjit
how hard could it be to apply nanotechnology against viral infections such HIV or Ebola?
Damian
silver nanoparticles could handle the job?
Damian
not now but maybe in future only AgNP maybe any other nanomaterials
Azam
Hello
Uday
I'm interested in Nanotube
Uday
this technology will not going on for the long time , so I'm thinking about femtotechnology 10^-15
Prasenjit
how did you get the value of 2000N.What calculations are needed to arrive at it
Privacy Information Security Software Version 1.1a
Good
Berger describes sociologists as concerned with
Got questions? Join the online conversation and get instant answers!