Fourier transforms - Basic question
Fourier transforms - Basic question
(OP)
I have uploaded some data into MATLAB and I am attempting to remove the funtamental frequency (1208.6Hz)
What I gather is the easiest way to remove fundamental is to apply a fourier transform to the data and then set 1208.6Hz to zero and then apply the inverse transform.
My problem is I don't know how to set the fundamental to zero.
Any help would be aprreciated
What I gather is the easiest way to remove fundamental is to apply a fourier transform to the data and then set 1208.6Hz to zero and then apply the inverse transform.
My problem is I don't know how to set the fundamental to zero.
Any help would be aprreciated





RE: Fourier transforms - Basic question
Here is an example
fCriticalHz = 1208.6;
fs = 48000;
nSample = 1000;
fStep = fs / nsample;
fftOfData = fft( data, nSample );
fStart = -fs / 2;
fStop = ( fs / 2 ) - fStep;
frequencyPicketHz = fStart : fStep : fStop;
indexZap = find( frequencyPicketHz >= fCriticalHz );
indexZapThese = indexZap + [ -1 0 1 ];
indexZapThese = [ ( nSample - indexZapThese ) indexZapThese ];
fftOfData( indexZapThese ) = zeros( size( fftOfData( indexZapThese ) ) );
dataZapped = real( ifft( fftOfData ) );
% Sorry I did not have time to test or review this, but someof these ideas should help in understanding.
jsolar
RE: Fourier transforms - Basic question
That's a good detailed method described above.
Without providing an alternative with comparable level of detail, I am hesitant to criticize it at all. But I would point out that it implements a very square bandstop filter which will introduce artifacts in the output time waveform in some cases. More sophisticated bandstop filters have smoother transitions with a lot of mathematical thought put into them.
=====================================
Eng-tips forums: The best place on the web for engineering discussions.
RE: Fourier transforms - Basic question
http://www.dspguide.com/ch14/5.htm
=====================================
Eng-tips forums: The best place on the web for engineering discussions.
RE: Fourier transforms - Basic question