1
$\begingroup$

It appears that smoothing the FFT or spectral density plots of a noisy signal is a common practice. I see that common tools like MATLAB and Python have functions built in to their FFT tools to do just such a thing. My question is, if you're using a spectral density plot to determine a noise floor, wouldn't smoothing artificially lower your floor? As I understand it, the noise floor is basically the upper bound of the noise in certain frequency band, which would certainly be affected by smoothing. Thanks.

$\endgroup$
2
  • 2
    $\begingroup$ Can you define smoothing specifically? If you are referring to a moving average on the frequency samples? $\endgroup$ Sep 17, 2020 at 14:10
  • $\begingroup$ Yes, the smoothing that I'm referring to is a moving average. I didn't get specific because I'm assuming that other algorithms can be used, such as a moving Gaussian, just like smoothing in other applications such as image processing, but as I'm not an expert, I could be wrong about this. $\endgroup$
    – benbald
    Sep 18, 2020 at 12:03

1 Answer 1

2
$\begingroup$

This question is specific to smoothing samples in the frequency domain (given by FFT and spectral density) and asking about the impact to the resulting noise floor in the same domain.

The answer depends on the characteristics of the noise and any time domain windowing that is applied. For white noise, with no windowing beyond the rectangular window, each bin of the DFT is independent of the next and with a moving average across the bins the standard deviation of the noise is reduced by $\sqrt{M}$ where $M$ is the number of samples in the average. The standard deviation of a single tone however would be reduced by $M$, and thus the ratio of the two would go down $\sqrt{M}$. We may think we are reducing the noise by smoothing the spectrum, but we are reducing the SNR since the signal components of tones (that occupy single bins) will drop more!!

This makes sense intuitively as after the smoothing through a moving average each frequency bin now includes the noise of the adjacent samples in the average.

This is clear from the additive property of independent identically distributed random variables:

The variance $\sigma^2_M$ of $\sum_{k=0}^{M-1}X_k$ is $\sigma^2_M = M\sigma^2_k$ where $\sigma^2_k$ is the variance of each $X_k$.

While for correlated variables (as we would have with tones) the relationship is $M^2\sigma_k^2$. (The signal increases in magnitude at rate M, while the noise increases in power at rate M).

A very simple example may make this clearer: consider the bell curve distribution of white noise process with a non-zero mean: if you added two independent samples from this process, the mean would go up by a factor of $2$ but the standard deviation would only increase by $\sqrt{2}$, but if the noise samples were dependent or specifically the same, then both mean and standard deviation would both increase by $2$ (a simple scaling of the random process).

So if we are trying to access/characterize a noise floor in the presence of a strong signal, this would be recommended to smooth the variability of that noise floor (equivalent to adjusting the Video Bandwidth rather than Resolution Bandwidth on a spectrum analyzer which basically serves to average the noise floor rather than reduce it). But if we are trying to detect a weak signal in the presence of noise this would not be recommended. Continuing the spectrum analyzer analogy, in which case we would reduce the Resolution Bandwidth (RBW) which will result in reducing the noise relative to our signal... for the DFT this means increasing the number of samples, just as in the spectrum analyzer the sweep rate must reduce when we reduce RBW -- time must increase!).

Windowing in time will reduce this change in SNR since the window will impose correlation on adjacent samples (with its own impact on SNR due to that). Since windowing is a product in the time domain which is a convolution in frequency, we can see how these two effects (windowing in time, moving average in frequency) are one and the same when the time domain window is the (aliased) Sinc function, aka the Dirichlet Kernel.

$\endgroup$
2
  • $\begingroup$ Your answer talks - if I am not mistaken - about smoothing along the frequency axis (neighbouring bins). I would also be interested in smoothing along the axis of several consecutive acquisitions of the same signal (assuming a steady signal). Does it make a difference if we smooth in the time domain or frequency domain? $\endgroup$
    – JLo
    Sep 19, 2020 at 18:04
  • $\begingroup$ @Jlo Yes it does and introduces a frequency dependency (the Dirichlet Kernel specifically)- my first answer was specific to that and then the OP clarified he meant smoothing over frequency $\endgroup$ Sep 19, 2020 at 18:06

Your Answer

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

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