Reply by dbd March 22, 20172017-03-22
On Tuesday, March 21, 2017 at 8:32:52 AM UTC-7, Eric wrote:
> Wikipedia has an informative page on Window functions. See this > paragraph for context on dynamic range vs resolution: > > https://en.wikipedia.org/wiki/Window_function#Windowing >
Eric It always saddens me to see an otherwise decent human being subject himself to the technical interpretation of a steaming heap like wiki on windows. Unfortunately, dsp windows have a wide range of applications which have a wide range of jargons and source documentation. The wiki phenomena has no adequate mechanism to achieve a stable accurate (or even self consistent) state when faced with such a wide range view points, vocabularies (both different meanings for the same words and different words for the same meaning, all with no regard for context), short attention spans, personal agendas and practical incompetence. We have discussed "resolution" and "dynamic range" for decades here on comp.dsp. They have always generated heated hand-waving, particularly from new contenders who aren't aware of the existence any contexts but their own. These terms have the characteristic of Justice Stewart's "I can't define it but I know it when I see it". I have always suggested that they have no useful meaning without a specified algorithm. I'll see what I can do with that.
> The second part of that paragraph references tradeoffs between dynamic > range and resolution. > > I'm assuming that the reference to 'dynamic range' means 'difference > between center peak and nearby lobes', This would seem to refer to > rectangular windows as having _low_ dynamic range. > >.But it then goes on to say that windows with high dynamic range suffer >.from 'low sensitivity and resolution'. This seems vague. I don't >.picture rectangular windows as having high resolution. (In fact, is >.there an application that suits them?)
Resolution might be taken to mean "ability to resolve". Resolve what? To resolve frequency many people seem to assume that the algorithm is peak picking the power spectrum. Then, any round topped (in the frequency domain) window function at high SINR could have a tone frequency resolution of Fs / transform size. If you want to resolve that there are two frequencies instead of one, the classical analog case of a swept spectrum analyzer trace on an oscilloscope, you look for a dip between two peaks. In this sense, you could highly upsample the power spectrum and look for a dip between peaks. I would expect a narrow topped (in the frequency domain) window to allow two tones of equal magnitude to be resolved in frequency at a smaller frequency separation than for wider (in the frequency domain-isn't maintaining context tedious?) windows. This is a case where the rectangular window looks good. People don't like to state their algorithms, if they even know them. People in different application areas often pick different parameters as surrogates for a meaningful definition. Things like half-power bandwidth and effective noise bandwidth are common and may even be defensible for some algorithms.
> > I'm still wondering about this in regard to detecting signal within > noise, which is touched on here: > > "At the other extreme of dynamic range are the windows with the > "poorest resolution and sensitivity, which is the ability to reveal > "relatively weak sinusoids in the presence of additive random noise. > "That is because the noise produces a stronger response with > "high-dynamic-range windows than with high-resolution windows. " > > Can anyone shed some light?
"Dynamic range" usually comes from either an application to "resolve" between signals with great difference in amplitude or to "resolve" in the presence of large interference. In instrumentation like dynamic signal analyzers, a common specification is the "two tone dynamic range". This is the ability to measure, to a specified accuracy, the amplitude of each of two simultaneous tones. The larger tone is far enough below full scale to allow the second tone without causing distortion. An example could be "60dB at 8 bins separation", which might be used to verify that a strong Kaiser-Bessel window has been applied (and that the system has adequate full scale to noise floor range to justify the window choice). With two tone dynamic range (i.e. delta bins, delta dB at an given accuracy) as the algorithm, consider the window choices. A wide mainlobe, high sidelobe rejection window requires more delta bins to resolve at 0 delta dB (poor frequency resolution) and is able to resolve (beyond some minimum bin separation) signals at high delta dB (high dynamic range). Rectangular windows require fewer bins separation to resolve at 0 delta dB (good frequency resolution) and may not resolve at all at some high delta dB (poor dynamic range). There really are topics that I believe wiki can provide useful information about. DSP windows just isn't one of them. Good luck Eric, Dale B. Dalrymple
Reply by March 22, 20172017-03-22
On Wed, 22 Mar 2017 08:42:46 -0400, Eric <Eric@spamspamorspam.com>
wrote:

>On Tue, 21 Mar 2017 17:36:06 GMT, eric.jacobsen@ieee.org wrote: > >>On Tue, 21 Mar 2017 15:32:45 -0400, Eric <Eric@spamspamorspam.com> > >>> https://en.wikipedia.org/wiki/Window_function#Windowing >>>This would seem to refer to >>>rectangular windows as having _low_ dynamic range. >>> >>>But it then goes on to say that windows with high dynamic range suffer >>>from 'low sensitivity and resolution'. This seems vague. I don't >>>picture rectangular windows as having high resolution. (In fact, is >>>there an application that suits them?) > >>The rectangular window provides the narrowest main lobe, and a >>generally-used definition of "resolution" in this case is the 3-dB >>width of the main lobe. For this case, the rectangular window >>provides high resolution, so for applications that need that it is a >>good selection (and there are many!). > >OK, that sounds like a reasonable definition. > >>>...detecting signal within >>>noise, which is touched on here: >>> >>>"At the other extreme of dynamic range are the windows with the >>>"poorest resolution and sensitivity, which is the ability to reveal >>>"relatively weak sinusoids in the presence of additive random noise. >>>"That is because the noise produces a stronger response with >>>"high-dynamic-range windows than with high-resolution windows. " > >>That last sentence seems very poorly worded, enough so that I'm not >>sure what they were trying to say. They *may* be saying that >>spreading the main lobe energy over multiple bins reduces the SNR (by >>reducing the power concentration in the main lobe), but it's not clear >>to me. > >Yeah, I keep re-reading that to see if I'm parsing it correctly. The >obvious interpretation is that "sensitivity = the ability to detect >signals in the presence of noise." and that high dynamic range >windows (again, I'm thinking Blackman-Harris here) are -not- good at >detecting signal within noise. > >Assuming that's correct, why would noise produce a stronger response >with high-dynamic-range windows?
That part doesn't make sense to me, as the window generally doesn't change the noise power if it is normalized and the noise statistics are stationary. The other issue regarding "dynamic range", as they're calling it, is just the sidelobe interference from other energy when trying to detect something. The lower the sidelobes, the less likely they are to obscure a small main lobe of some other signal somewhere. That part makes sense, but I don't get what they're trying to say about "noise", unless they count the sidelobe energy as "noise" to other main lobes. It's not clear at all what they mean. --- This email has been checked for viruses by Avast antivirus software. https://www.avast.com/antivirus
Reply by Cedron March 22, 20172017-03-22
>On Tue, 21 Mar 2017 13:07:43 -0500, "Cedron" <103185@DSPRelated> >wrote: > >>> >>>I recommend that you read my blog article titled "Exponential
Smoothing
>>>with a Wrinkle" which can be found here: >>> >>>https://www.dsprelated.com/showarticle/896.php >>> >> >>It seems that the figures are missing from this article. Hopefully, >>they'll be back soon. >> >>Ced > >You mean the 3-color graphs under the captions "Figure 1" etc? >Those show up on my system.
Strange. Thanks for letting me know. They don't show up for me under two different browsers. Ced --------------------------------------- Posted through http://www.DSPRelated.com
Reply by Eric March 22, 20172017-03-22
On Tue, 21 Mar 2017 13:07:43 -0500, "Cedron" <103185@DSPRelated>
wrote:

>> >>I recommend that you read my blog article titled "Exponential Smoothing >>with a Wrinkle" which can be found here: >> >>https://www.dsprelated.com/showarticle/896.php >> > >It seems that the figures are missing from this article. Hopefully, >they'll be back soon. > >Ced
You mean the 3-color graphs under the captions "Figure 1" etc? Those show up on my system.
Reply by Eric March 22, 20172017-03-22
On Tue, 21 Mar 2017 17:36:06 GMT, eric.jacobsen@ieee.org wrote:

>On Tue, 21 Mar 2017 15:32:45 -0400, Eric <Eric@spamspamorspam.com>
>> https://en.wikipedia.org/wiki/Window_function#Windowing >>This would seem to refer to >>rectangular windows as having _low_ dynamic range. >> >>But it then goes on to say that windows with high dynamic range suffer >>from 'low sensitivity and resolution'. This seems vague. I don't >>picture rectangular windows as having high resolution. (In fact, is >>there an application that suits them?)
>The rectangular window provides the narrowest main lobe, and a >generally-used definition of "resolution" in this case is the 3-dB >width of the main lobe. For this case, the rectangular window >provides high resolution, so for applications that need that it is a >good selection (and there are many!).
OK, that sounds like a reasonable definition.
>>...detecting signal within >>noise, which is touched on here: >> >>"At the other extreme of dynamic range are the windows with the >>"poorest resolution and sensitivity, which is the ability to reveal >>"relatively weak sinusoids in the presence of additive random noise. >>"That is because the noise produces a stronger response with >>"high-dynamic-range windows than with high-resolution windows. "
>That last sentence seems very poorly worded, enough so that I'm not >sure what they were trying to say. They *may* be saying that >spreading the main lobe energy over multiple bins reduces the SNR (by >reducing the power concentration in the main lobe), but it's not clear >to me.
Yeah, I keep re-reading that to see if I'm parsing it correctly. The obvious interpretation is that "sensitivity = the ability to detect signals in the presence of noise." and that high dynamic range windows (again, I'm thinking Blackman-Harris here) are -not- good at detecting signal within noise. Assuming that's correct, why would noise produce a stronger response with high-dynamic-range windows?
Reply by Steve Pope March 21, 20172017-03-21
Eric  <Eric@spamspamorspam.com> wrote:

>Wikipedia has an informative page on Window functions. See this >paragraph for context on dynamic range vs resolution: > > https://en.wikipedia.org/wiki/Window_function#Windowing > >The second part of that paragraph references tradeoffs between dynamic >range and resolution. > >I'm assuming that the reference to 'dynamic range' means 'difference >between center peak and nearby lobes', This would seem to refer to >rectangular windows as having _low_ dynamic range. > >But it then goes on to say that windows with high dynamic range suffer >from 'low sensitivity and resolution'. This seems vague. I don't >picture rectangular windows as having high resolution. (In fact, is >there an application that suits them?) > >I'm still wondering about this in regard to detecting signal within >noise, which is touched on here: > >"At the other extreme of dynamic range are the windows with the >"poorest resolution and sensitivity, which is the ability to reveal >"relatively weak sinusoids in the presence of additive random noise. >"That is because the noise produces a stronger response with >"high-dynamic-range windows than with high-resolution windows. " > >Can anyone shed some light?
I would delete the word "sensitivity" from the above Wiki entry, the rest of it is largely correct, but should be supplemented with the information that _for a given total window length_ there is a tradeoff between (frequency) resolution and dynamic range. Dynamic range is usually thought to consider the entire stopband, not just nearby side-lobes, unless one is just looking at a frequency domain plot of the window and making an quick statement about dynamic range. Steve
Reply by Cedron March 21, 20172017-03-21
> >I recommend that you read my blog article titled "Exponential Smoothing >with a Wrinkle" which can be found here: > >https://www.dsprelated.com/showarticle/896.php >
It seems that the figures are missing from this article. Hopefully, they'll be back soon. Ced --------------------------------------- Posted through http://www.DSPRelated.com
Reply by Cedron March 21, 20172017-03-21
> >Thanks for posting that, Cedron. I'll definitely take a close look. >
You're welcome. It isn't difficult to implement so you can try it easily and see if it works in your application.
>For now: Your smoothing function looks a bit like an LPF (a Fibonacci >filter! :-). Are you recommending using it before the DFT? And >instead of a window??! >
The averaged version does act like a (poor) low pass filter. The difference version will accentuate the amplitudes of the higher frequency components so I don't think the description fits. Yes, and yes. Although you could still apply a window on the smoothed signal, depending what your goals are. If tonal decomposition is your goal, then I don't think windows are helpful. If a nice display is what you seek, then a Hann window does a wonderful job.
>I believe that the Wikipedia article on windowing was referring to >noise sensitivity from the subsequent FFT, but perhaps I >misinterpreted that. I didn't think there was much point in windowing >unless some type of DFT was to follow.
That is my understanding. For the smoothing, I would recommend including parts of the surrounding frames as the smoothing operation takes a few samples to get accurate. Ced --------------------------------------- Posted through http://www.DSPRelated.com
Reply by March 21, 20172017-03-21
On Tue, 21 Mar 2017 15:32:45 -0400, Eric <Eric@spamspamorspam.com>
wrote:

>Wikipedia has an informative page on Window functions. See this >paragraph for context on dynamic range vs resolution: > > https://en.wikipedia.org/wiki/Window_function#Windowing > >The second part of that paragraph references tradeoffs between dynamic >range and resolution. > >I'm assuming that the reference to 'dynamic range' means 'difference >between center peak and nearby lobes', This would seem to refer to >rectangular windows as having _low_ dynamic range. > >But it then goes on to say that windows with high dynamic range suffer >from 'low sensitivity and resolution'. This seems vague. I don't >picture rectangular windows as having high resolution. (In fact, is >there an application that suits them?)
The rectangular window provides the narrowest main lobe, and a generally-used definition of "resolution" in this case is the 3-dB width of the main lobe. For this case, the rectangular window provides high resolution, so for applications that need that it is a good selection (and there are many!). Pretty much any application where the signal is a single sinusoid (rather than a spectrally rich signal), the rectangular window is a good candidate. Even for spectrally rich signal it really depends on what you're doing whether a different window, or which window, makes the most sense.
>I'm still wondering about this in regard to detecting signal within >noise, which is touched on here: > >"At the other extreme of dynamic range are the windows with the >"poorest resolution and sensitivity, which is the ability to reveal >"relatively weak sinusoids in the presence of additive random noise. >"That is because the noise produces a stronger response with >"high-dynamic-range windows than with high-resolution windows. " > >Can anyone shed some light?
That last sentence seems very poorly worded, enough so that I'm not sure what they were trying to say. They *may* be saying that spreading the main lobe energy over multiple bins reduces the SNR (by reducing the power concentration in the main lobe), but it's not clear to me. --- This email has been checked for viruses by Avast antivirus software. https://www.avast.com/antivirus
Reply by Eric March 21, 20172017-03-21
On Tue, 21 Mar 2017 11:15:10 -0500, "Cedron" <103185@DSPRelated>
wrote:

>If your goal is to detect a signal within noise, may I suggest a different >approach than using window functions? > >I recommend that you read my blog article titled "Exponential Smoothing >with a Wrinkle" which can be found here: > >https://www.dsprelated.com/showarticle/896.php > >By smoothing your signal like this you lower the relative impact of noise. > This is because the DFT (implicitly a least squares fit) is more >sensitive to outliers (i.e. noise) in the signal. By smoothing the signal >you smear the outliers against the signal reducing their distortive >effect.
Thanks for posting that, Cedron. I'll definitely take a close look. For now: Your smoothing function looks a bit like an LPF (a Fibonacci filter! :-). Are you recommending using it before the DFT? And instead of a window??! I believe that the Wikipedia article on windowing was referring to noise sensitivity from the subsequent FFT, but perhaps I misinterpreted that. I didn't think there was much point in windowing unless some type of DFT was to follow.