From: John on 3 May 2010 19:47 On May 3, 11:13 am, Vladimir Vassilevsky wrote:> Let's say I have an FFT of the given size N, and I want to get an > estimate of a frequency of a noisy tone (input SNR ~ 1/N). > Increasing FFT size is not an option. > > I can do the following processing: > > 1) Average the magnitudes for every bin through several FFTs, then do a > curve fit through max_bin, max_bin-1, max_bin+1 to find the peak. > > 2) Do the FFT, then estimate the frequency by one of the estimators > described in , then do a weighted average of the result of the > estimator through several FFTs. > > 3) Do several FFTs progressively shifting the input by the frequency > from 0 to 1/2 of bin spacing, do some post-processing. > > 4) Anything else? > > What do you think? > >  "Fast, Accurate Frequency Estimators" > E. Jacobsen, P. Kootsookos > p.107 "Streamlining digital Signal Processing" > edited by R. Lyons > (c)IEEE 2007 > > //------------------------------ > > Vladimir Vassilevsky > DSP and Mixed Signal Design Consultanthttp://www.abvolt.com A ML solution is to do FFT #1, wait a fixed time interval, and do FFT #2 of new data. The phase change of the bin of interest from FFT #1 to FFT #2, combined with the know delay, gives the fine frequency. Watch out for wraps though. John From: Ron N. on 4 May 2010 15:09 On May 3, 8:13 am, Vladimir Vassilevsky wrote:> Let's say I have an FFT of the given size N, and I want to get an > estimate of a frequency of a noisy tone (input SNR ~ 1/N). > Increasing FFT size is not an option. > > I can do the following processing: > > 1) Average the magnitudes for every bin through several FFTs, then do a > curve fit through max_bin, max_bin-1, max_bin+1 to find the peak. If you have several offset windows of data with which to do more than one FFT, then phase vocoder techniques can be used to improve the frequency estimates. Depending on the type of noise, the phase error between offset windows may be less than the magnitude error between bins, and/or the difference between a perfect sinc curve fit and your polynomial estimator of choice. Using a phase vocoder is one of the techniques mentioned on my quick and dirty frequency estimation page: http://www.nicholson.com/rhn/dsp.html#1 IMHO. YMMV. -- rhn A.T nicholson d.0.t C-o-M From: Peter K. on 4 May 2010 23:35 On 3 May, 12:43, Rune Allnor wrote: > I haven't read Eric and Peter's piece, so I don't know what they > say about the subject. With that proviso: > > 'Fast' and 'accurate' are contradictions in terms. Any estimator > might be *either* fast *or* accurate, but no one estimator will > be both. Yes and no. Unbiased estimators can generally only be as accurate as the Cramer- Rao Lower bound (CRLB) on the variance of such estimators. There exist many frequency estimators that meet this bound. The ones that Eric and I wrote about meet the CRLB and are faster to calculate than a periodogram. There is certainly a price: these estimators exhibit threshold behavior at lower noise levels than the periodogram. So, you are correct, but it's not quite as straightforward as your text suggests. Ciao, Peter K. From: Rune Allnor on 5 May 2010 05:41 On 5 Mai, 05:35, "Peter K." wrote:> On 3 May, 12:43, Rune Allnor wrote: > > > I haven't read Eric and Peter's piece, so I don't know what they > > say about the subject. With that proviso: > > > 'Fast' and 'accurate' are contradictions in terms. Any estimator > > might be *either* fast *or* accurate, but no one estimator will > > be both. > > Yes and no. > > Unbiased estimators can generally only be as accurate as the Cramer- > Rao Lower bound (CRLB) on the variance of such estimators. > > There exist many frequency estimators that meet this bound. > > The ones that Eric and I wrote about meet the CRLB and are faster to > calculate than a periodogram. One has one of two options to achiev that kind of thing: 1) Compute only parts of the peridogram 2) Use a model-based frequency estimator Both apporaches rely on prior knowledge / assumptions / prejudice / hearsay about what the spectrum actually looks like, and what one will find. The problem with such approaches is that they are not awfully robust with respect to flawed prior assumptions: If the spectrum line is not in the band where one computes the partial periodogram, one will not find it. If the data do not comply to whatever parametric model the estimator is based on, the computed numbers are little more than mumbo-jumbo. Pulling this to the ridiculously extreme, the fastest frequency estimator is to state the number directly. No computations required. Of course, this relies on that the number is (assumed) known up front. If one states the wrong number, one is screwed. Rune From: Peter K. on 5 May 2010 21:18 On 5 May, 05:41, Rune Allnor wrote: > One has one of two options to achiev that kind of thing: > > 1) Compute only parts of the peridogram > 2) Use a model-based frequency estimator > > Both apporaches rely on prior knowledge / assumptions / > prejudice / hearsay about what the spectrum actually looks > like, and what one will find. Exactly. > The problem with such approaches is that they are not > awfully robust with respect to flawed prior assumptions: > If the spectrum line is not in the band where one computes > the partial periodogram, one will not find it. If the data > do not comply to whatever parametric model the estimator > is based on, the computed numbers are little more than > mumbo-jumbo. Agreed. If the signal ain't a sine wave in noise, you'll get garbage. But then anything will give you garbage in that case if you estimate the "frequency". > Pulling this to the ridiculously extreme, the fastest > frequency estimator is to state the number directly. > No computations required. Of course, this relies on that > the number is (assumed) known up front. If one states the > wrong number, one is screwed. Ah, but that's a biased estimator! ;-) Such an estimator can, indeed, give a better estimation error than the periodogram.... for precisely the right constant value. ;-) But then you knew that. Ciao, Peter K.