define frequency of signal from fft output

조회 수: 2 (최근 30일)
Ngoc Lam
Ngoc Lam 2014년 9월 29일
댓글: YAMASANI MANOJ REDDY 2018년 8월 21일
what is the relationship between the sampling frequency Fs and frequency of signal of FFT function in matlab? assUme that, we have a signal with spectrum as follow picture. with Fs= 44.1Khz, I know that X-axis is not the frequecy of signal, right? How to define the frequency of this signal with followed spectrum? for example, at the point X-axis = 10000, with Fs= 44.1Khz, how to define frequency of signal at that point?

채택된 답변

Rick Rosson
Rick Rosson 2014년 9월 29일
편집: Rick Rosson 2014년 9월 29일
dF = Fs/N;
f = dF*(0:N-1)';

추가 답변 (4개)

Ngoc Lam
Ngoc Lam 2014년 9월 30일
편집: Ngoc Lam 2014년 9월 30일
thanks for your opinions! it's helpful for me! But I have a trouble with using fft for analysing spectrum of signals. for example we have a code segment:
%%%% code segment %%%%
t= linspace (0,4*pi,500);
x= sin(100*pi*t)+2*cos(200*pi*t);
X= abs(fft(x));
%%%%%%%%%
with followed picture representing the spectrum of that picture.
  • *
how we can define frequency of any point in X-axis?
at point (125) in X-axis, how can we determine the frequency of that signal at that point?
thanks!* *
  댓글 수: 1
Rick Rosson
Rick Rosson 2014년 9월 30일
The sampling rate in your code is
Fs = 500/(4*pi);
which is approximately 40 samples per second. By the Nyquist Sampling Theorem, the maximum frequency that you can represent without aliasing is Fs/2 or approx 20 Hertz. Your signal, however, contains components at 50 Hertz and 100 Hertz, which are well above the maximum.

댓글을 달려면 로그인하십시오.


Rick Rosson
Rick Rosson 2014년 9월 30일
Please try:
Fs = 1000;
dt = 1/Fs;
N = 12000;
t = dt*(0:N-1)';
x = sin(100*pi*t) + 2*cos(200*pi*t);
X = fftshift(fft(x))/N;
dF = Fs/N;
f = -Fs/2:dF:Fs/2-dF;
plot(f,abs(X));
  댓글 수: 1
Syed Masoud Shah kakakhel
Syed Masoud Shah kakakhel 2017년 3월 23일
편집: Syed Masoud Shah kakakhel 2017년 3월 23일
kindly @Rick Rosson can u comment...variables like what is N?? kindly will be more helpful..m waiting for response

댓글을 달려면 로그인하십시오.


Ngoc Lam
Ngoc Lam 2014년 10월 1일
Ah, I have no pay attention to Nyquyst sampling theorem aplied here! I have solved my problems, thanks for your help!

Ngoc Lam
Ngoc Lam 2014년 10월 1일
Do you know the meaning of the symmetry of spectrum when we plot spectrum of signal?
i thought that It's the negative spectrum of signal? Is it right?

카테고리

Help CenterFile Exchange에서 Fourier Analysis and Filtering에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by