Page 1 of 1

Spectrum analyzer absolute levels are off

PostPosted: Thu Jun 21, 2018 1:50 am
by ieronim
I am currently evaluating Multi-Instrument and I am puzzled by some inconsistencies I found with the spectrum analyzer. I simply cannot rely on the spectrum display to read the absolute level of the input signal with any acceptable degree of accuracy. Here's my setup:

Audio Precision System Two used as analog signal generator, putting out a sine wave at 11.8 dBu. My ADC clips at 11.9 dBu, so I'm at -0.1dBFS in the digital domain.
Multi-Instrument correctly displays -0.1 dBFS on the level meter in the top right corner of the screen. The multimeter window also correctly reads 11.8dBu (I calibrated Multi-Instrument to my ADC's sensitivity).
In the spectrum analyzer window, no matter which FFT window size or function I pick, I can never get an accurate absolute level display. The spectrum analyzer processing is set as follows:
Y Scale: dBFS or dBu (they're both off)
Processing: Peaks (1).

When the Y scale is set to dBu, the displayed Peak Level is correct (11.8 dBu), but the top of the spectrum line is at least 2 or 3dB lower on the grid, depending on FFT size and function settings. There's just no combination of FFT size and function that I could set in order to get the spectrum line to show an accurate level.

When the Y scale is set to dBFS, the Peak display is no longer accurate (it shows -3.14dBFS instead of -0.1), and the top of teh spectrum line is even lower, around -5 or -6, depending on FFT settings.

I tried this with various input frequencies and FFT settings, and the spectrum analyzer absolute levels are never accurate.

Am I doing something wrong? If not, what is going on here?

See attached screenshot.

Re: Spectrum analyzer absolute levels are off

PostPosted: Thu Jun 21, 2018 4:42 am
by VirtinsTech
Thank you for your questions. The results are actually all correct (see VIRTINS comment in the screenshot below).

VirtinsComment.png (173.38 KiB) Viewed 4772 times

The spectrum analyzer always shows RMS values while the input peak level indicator at the upper right corner shows the peak value. This is about 3dB difference for a sine wave.

Spectral leakage is the result of the inherent assumption in the DFT/FFT algorithm that the time record in a DFT/FFT segment is exactly repeated throughout all time and that signals contained in a DFT/FFT segment are thus periodic at intervals that correspond to the length of the DFT/FFT segment. If the time record in a DFT/FFT segment has a non-integer number of cycles, this assumption is violated and spectral leakage occurs. A window function can be used to suppress the spectral leakage such that the energy of a sine wave leaks mainly into the few adjacent FFT bins around the main spectral line. But still, the main spectral line will become lower due to the leakage of its energy to its adjacent spectral lines. Despite the spectrum leakage, MI is able to calculate the RMS values of the frequency components accurately and displayed them on the top of the spectrum graph.

The following is a special example in which no spectrum leakage occurs. The FFT segment contains exactly 32768 / 48000 x 1000.4882812 = 683 signal cycles, thus no spectral leakage occurs. The main spectral line in the graph is -3 dBV which is a correct RMS value of a sine wave with an amplitude of 1V. Note under this particular situation, Rectangle window function should be used. If a non-rectangle window function is used instead, spectral leakage will still occurs.

NoSpectralLeakage.png (104.88 KiB) Viewed 4772 times

Re: Spectrum analyzer absolute levels are off

PostPosted: Thu Aug 09, 2018 11:36 pm
by ieronim
Thank you very much for the clarifications.

I still maintain that when the spectrum analyser is set to display absolute levels in dBFS, it should show 0dBFS when a full- scale sine wave is present (under no spectral leakage conditions). I insist that Multi Instrument is incorrect in displaying -3dB FS under such condition. The dBFS is defined such that the RMS value of a full-scale sine wave is designated 0 dB FS. Please see AES standard AES17-1998, and also ITU-T P.381 and P.382.

Re: Spectrum analyzer absolute levels are off

PostPosted: Fri Aug 10, 2018 6:34 pm
by VirtinsTech
Thank you for your comment on the 0dB reference of dBFS (rms).

Unlike other dB units, such as dBV and dBu, which are used only in the context of RMS values, dBFS is often used in the context of peak values and sometime used for RMS values such as the case of RMS amplitude spectrum. There is no ambiguity when dBFS is used in peak values (e.g. input peak level and output amplitude in MI). However, when it is used in RMS values (e.g. the RMS amplitude Spectrum in MI), there exists two different conventions / standards (e.g.

1. 0 dBFS (rms) is FS Square Wave (thus a FS sine wave is -3.01 dBFS)
2. 0 dBFS (rms) is FS Sine Wave (thus a FS square wave is +3.01 dBFS)

The former is more correct mathematically, but as pointed out by you, AES and ITU-T P.38x uses the latter.

In view of your comments, we will follow some other software (e.g. Cool Edit in the past) and provide both options in [Spectrum Analyzer Y Scales]>“dBFS> “0dBFS = FS Sine” and “0dBFS = FS Square”, with the former selected by default.

Thank you again for your comments. It helps to improve the software.

Re: Spectrum analyzer absolute levels are off

PostPosted: Fri Aug 31, 2018 5:31 am
by VirtinsTech
1. Software (V3.8.3) has been updated to allow the selection of 0dBFS reference. (see figure below)
0dBFS_Reference.png (13.84 KiB) Viewed 4141 times

Re: Spectrum analyzer absolute levels are off

PostPosted: Fri Aug 31, 2018 5:50 am
by VirtinsTech
2. Spectral leakage confusion can be eliminated now using the "Mark Peak" option under [Spectrum Analyzer Chart Options]. Basically this option overlays the calculated peak height on the spectrum obtained directly from FFT.
MarkPeak.png (10.88 KiB) Viewed 4141 times

The following are examples.

(1) without peak marked

WithoutMarkPeak.png (147.12 KiB) Viewed 4141 times

(2) Peak Marked
withMarkPeak.png (111.75 KiB) Viewed 4141 times

(3) Peak Marked Closeup
HowPeakMarkingWorks.png (178.14 KiB) Viewed 4141 times