I'm working on a device that produces a signal with sampling rate of 100 kHz. Every 40 ms, I receive 16000 points, from which I have to extract a frequency close to 3.55 kHz. I have developed a method that extracts the frequency of the signal very close to the Cramér-Rao lower bound, but I need to extract the amplitude of the signal at that frequency very precisely.

The first idea that occured to me was using a digital implementation of a lock-in amplifier, but the problem is that a lock-in amplifier needs a low-pass filter. And I'm trying to avoid using filters as much as I could, because filters introduce a systematic shift in my readings, while I need extremely high precission and accuracy.

What's the best amplitude estimation algorithm I should use?

  • 1
    $\begingroup$ Welcome to DSP.SE! Is it not possible to just form the one-bin DFT of your signal at the estimated frequency? Something like $|\sum_{n=0}^{N-1} x_n e^{-j 2\pi\hat{f} n}|$, where $\hat{f}$ is your frequency estimate (in Hz)? $\endgroup$
    – Peter K.
    Oct 2, 2013 at 12:11
  • 1
    $\begingroup$ By "filters introduce a systematic shift in my readings" do you mean that they change the magnitude or mean of your readings? That does not necessarily need to be so, if you design your filter carefully. $\endgroup$
    – Jim Clay
    Oct 2, 2013 at 13:19
  • $\begingroup$ Are there other frequency components present in the signal that you observe? Noise? $\endgroup$
    – Jason R
    Oct 2, 2013 at 13:31
  • $\begingroup$ @PeterK. Not really for two reasons, first one technically no, because the number of points isn't high enough to hit the right resolution, and second is that I need a really fast way, and DFTs (even FFTs) are not fast enough. FFT maybe fast, but I'll have to chop my data and play with it, which I can't do. $\endgroup$ Oct 2, 2013 at 14:14
  • 3
    $\begingroup$ @TheQuantumPhysicist: The solution that Peter K was suggesting was not a full DFT. Instead, what he suggested was essentially cross-correlating the signal with a complex sinusoid at the estimated frequency, then taking its magnitude. This is equivalent to calculating one bin of a DFT that is centered at your estimated frequency, and is a very reasonable approach. $\endgroup$
    – Jason R
    Oct 2, 2013 at 14:18

1 Answer 1


Generally, the frequency estimation problem decouples from the amplitude + phase estimation problem.

As I said in the comments, you could just do:

$$ \hat{A} = \left|\sum_{n=0}^{N-1} x_n e^{-j 2\pi\hat{f} n} \right| $$ where $\hat{f}$ is your frequency estimate.

Regarding your issues:

because the number of points isn't high enough to hit the right resolution

I'm not sure what you mean by "resolution" here? Resolving the amplitude?

second is that I need a really fast way

The suggested technique will only take $N$ complex multiplications and $N-1$ complex additions, plus whatever you need to calculate the absolute value (two complex multiplications and one addition).

That's pretty fast, and linear in $N$. And certainly faster than an FFT (which would be $N\log_2 N$).


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.