Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

How to plot the magnitude spectrum against its frequency (bode plot)?

Status
Not open for further replies.

luckyvictor

Member level 4
Joined
Dec 1, 2009
Messages
78
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
1,903
Hi

I am new to study DSP, and I would like to ask the following questions:

I have a test wav file, i use wavread to read the file as well as getting its sampling frequency, however I don't know how to plot the wav in FFT, the annoying thing is the frequency axis, I already know the sampling frequency is 8kHz, but I have no idea how can I plot the magnitude spectrum against its frequency.

Hope someone can explain to me the steps.

Many thanks
 

Plot a bode plot

Bode plots are both Magnitude and Phase Shift values vs. frequency.
Are you using MATLAB?there is very nice example howto use and plot FFT on base of Wolf number ( number of stains at the sun).
 

Plot a bode plot

yes, i m using matlab, i just don't know how to get the right frequency axis. I only know the sampling frequency of the signal, and I capture only a 8ms duration of the signal using a 128 points hamming windows.
 

Plot a bode plot

So, you have 8ms of data and you are sampling at 16kHz (128 points captured in 8ms).
The FFT resolution is then 125Hz and the highest frequency is 8kHz (16kHz/2, Nyquist theorem).
In matlab language: f=0:125:8000; is your frequency axis. Keep in mind that matlab will show both sides of your FFT, so you will need to half the FFT result length...
 

Plot a bode plot

I think I sort out understand your explainsion, because the highest frequency in the signal is 8kHz, this is why my sampling frequency is 16kHz, therefore the last point corresponding the highest (last) frequency component in my signal, and because my sampling frequency is 16kHz, and I have 128 points, so resolution is 125Hz. Am I explaining correctly?

I now have 3questions wanna ask you experts, as in this case, I have to use a filter to suppress the tonal interference, I used FIR1 but have no idea for the following terms:

1. What is tonal interference?

2.what is normalized frequency? How to calculate it?

3.When I use filter function in Matlab, how should I determine the order parameter please?
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top