Prev: Pulse shaping + interpolation
Next: FFT in OpenCV
From: Jerry Avins on 19 Feb 2006 17:42 rajgerman wrote: > Thanks for that information but I'm still a little confused. > > The thing is I have a brain signal which is an audio file which I have > fast fourier transformed. Why on earth? Are you sure there isn't something you misunderstood? Now what I have to do is apply the Hamming > window to that. How would I do that using MATLAB?? It seems confusing. Jerry -- Engineering is the art of making what you want from things you can get. ???????????????????????????????????????????????????????????????????????
From: Fred Marshall on 19 Feb 2006 19:12 "rajgerman" <rajgerman(a)msn.com> wrote in message news:qdidnQ5Hzq7-bWXe4p2dnA(a)giganews.com... > Thanks for that information but I'm still a little confused. > > The thing is I have a brain signal which is an audio file which I have > fast fourier transformed. Now what I have to do is apply the Hamming > window to that. How would I do that using MATLAB?? It seems confusing. > It's not likely that you want to window the FFTd sequence - as in multiply the FFTd sequence. It's much more likely that you want(ed) to window the temporal sequence (as in multiply) before the FFT. Or you could convolve in frequency to get the same affect. You have a few choices: 1) Generate the temporal window function. Someone has suggested how to do this in MATLAB. The window should be the same length as the temporal record you have unless you're processing in blocks. Then, either: Using the temporal record, multiply point by point by the window function in time. Then FFT if you need to. Using the FFT record that you have, IFFT it and proceed as above. FFT both the temporal data sequence and the temporal window. Convolve the two in frequency. Fred
From: John Monro on 19 Feb 2006 19:31 rajgerman wrote: > Hi > > Could anyone explain the Hamming window in REALLY simple terms and why it > is useful and how it could be implemented in MATLAB?? > > I would be grateful for any response. > > Radjerman, Assume we have a set of time-domain samples, that have been taken from a signal waveform (if we are going to perform a FFT) or have been calculated from a desired impulse-response function )if we are going to implement a FIR filter.) When we selected the set of time-domain samples the selection process was in effect a 'chopping up' process that introduced high-frequency components that were not present originally in the continuously-sampled signal or in the unlimited impulse-response. These introduced components show up as high-frequency peaks in the FFT or as high-frequency peaks in the response of the FIR filter, both effects are generally undesirable. We can reduce the amplitude of these high-frequency components by 'tapering off' the amplitudes of the samples towards each end of the set in some systematic way, and the Hamming window is one of many similar functions that will do this job for us. If you look at the expression for a Hamming window you will see that if we multiply a set of signal samples by this function, the sample(s) at the centre of the set gets multiplied (or 'windowed')by the largest factor and this factor decreases in a smooth sinusoidal fashion as we go away from the centre, with the samples at each end being multiplied by zero. The end result is that instead of an abruptly 'chopped' set of samples we now have a set of samples that has been heavily modulated by one cycle of a sinusoidal function. The artifacts produced by this modulation are less objectionable for many applications. In the FFT the artifacts show up as spectral 'leakage' into adjacent frequency bins. In a FIR filter the pass-band response is altered sightly. In MATLAB, generate a set of values using the expression for the Hamming window function. Then generate the dot product between the set of Hamming window values and the set of signal samples. Regards, John
From: Clay S. Turner on 19 Feb 2006 23:23 > > It's not likely that you want to window the FFTd sequence - as in multiply > the FFTd sequence. > It's much more likely that you want(ed) to window the temporal sequence > (as in multiply) before the FFT. > Or you could convolve in frequency to get the same affect. > > FFT both the temporal data sequence and the temporal window. > Convolve the two in frequency. > Hello Fred, Since the Hamming window is defined in terms of cosines, the Freq domain version turns out to have only 3 non-zero coefs. This makes for a pretty easy convolution. The coefs are -0.23, 0.54, -0.23 Clay
From: rajgerman on 20 Feb 2006 05:48
So are you saying that I do not need to fast fourier transform the audio signal, but apply the hamminng window first and the nfast fourier transform?? Sorry guys but I'm not to familiar with these topics but thanks for your help. If any of you would provide me their email address I could send you the files to show you what I mean. |