Analyzer Fundamentals (NI-4551/4552 DSA Instruments)
Overview
This technical note explains the software architecture of the NI-DSA instrument driver that controls the onboard processor of the NI-4551 and NI-4552 dynamic signal acquisition (DSA) devices. This document also explains each mode of the NI 4551 and NI 4552 devices.
Measurement Personalities and Modes
- The NI 4551 and NI 4552 DSA devices can behave in different operational personalities and modes. You can use the devices as data acquisition devices when you use the NI-DAQ driver. You can use the devices as DSA devices when you use the NI-DSA driver. The NI-DSA measurement personality allows you to use different modes, such as FFT Analyzer, Octave Analyzer, and Swept Sine Analyzer.
- Real-time FFT: zoom/baseband
- Auto power spectrum
- Frequency response
- Cross power
- Coherence
- Power spectral density
- Bandpower
- Harmonic Analysis (THD, THD+Noise)
- Volts
- Engineering units
- Custom units
- dB reference
- Log magnitude
- Linear magnitude
- Magnitude squared
- Real & imaginary part
- Phase
- Unwrapped phase
- 1, 2, 3, and 4 simultaneous displays
- Autoscaling
- 100 lines
- 200 lines
- 400 lines
- 800 lines
- 1600 lines (zoom)
- Uniform
- Hanning
- Blackman-Harris (Standard, 4, 7-term)
- Flattop
- Kaiser
- Low sidelobe
- Force
- Exponential
- Forced-exponential
- RMS
- Linear
- Vector
- Peak hold
- Exponential
- Overlap processing
- Periodic single-tone sine
- Periodic dual-tone sine
- Swept sine
- Periodic chirp (with burst)
- Periodic noise (with burst)
- Arbitrary
- Free run
- External - analog
- Internal
- Delay (pre, post-trigger)
- Impulse response
- Cross correlation
- Auto correlation
- Swept sine spectrum
- Nichols
- Nyquist
- Orbit
- Waterfall with skew
- More than 1600 lines
- User Defined
- Correlation Windows
- Equal confidence (Octave)
- White noise
- Pink noise
- Dual-tone sine
- External - digital
- Source
- Linear
- Exponential - slow, fast, custom
- Impulse
- Peak Hold
- Equal Confidence
- Linear (Leq)
- Exponential - slow, fast, custom
- Impulse
- Impulse-Eq
- Peak Hold
The measurement personality of the NI-4551 and NI-4552 determines the processing that is done to the acquired data. With the NI-DAQ personality, the onboard processor does not process data. However, you can transfer the complete time domain data to the host memory through DMA in continuous or non-continuous mode. With the NI-DSA personality, the onboard processor analyzes data in real time using different modes. The FFT Analyzer mode gathers time domain data into time records, processes the data into frequency domain information, averages the data, if necessary, and transfers data to the host for presentation or further processing. The Octave Analyzer mode, passes the data trough a parallel bank of filters and averages the datay, if necessary, before transferring the data to the host memory.
The NI 4551 and 4552 have a green LED that flashes at power up. This LED indicates that the onboard processor is running in the NI-DAQ-compatible personality and is ready to acquire or generate data. The green LED may flash at a faster rate when the NI 4551 or 4552 is accessed by VirtualBench-DSA or by the NI-DSA instrument driver software, therefore working on the NI-DSA personality.
Each of the possible modes has its own set of functions and measurements which are accessible trough the NI-DSA Instrument Driver software functions from LabVIEW, LabWindows/CVI and other compilers, such as MS Visual C++ and Visual Basic. The NI-DAQ personality does not use the NI-DSA driver functions. If you use the NI-DAQ personality, you can use only the NI-DAQ functions available in the previous development environments.
If you use the NI-DAQ driver, the NI 4551 and 4552 can behave as the NI PCI-4451 and 4452 devices, MIO boards with all the features hardware features of the 45 series, like antialiasing filtering, delta sigma converters, and simultaneous sampling, but without the real time capabilities available with an onboard processor. The NI-DAQ personality allows you to use NI-DAQ functions to perform capture or streaming of the time domain waveform. When you use the NI-DAQ personality, you cannot use the NI-DSA instrument driver functions. You can use the NI-DAQ Configuration Utility or Measurement & Automation Explorer with the NI-DAQ personality to test the board using the Test Panels. You also can run most of the LabVIEW examples that use NI-DAQ VIs. You cannot perform single point measurement, but you can do a single shot multipoint measurement. The single shot multipoint measurement does not have to be continuous but must have a hardware sampling rate. The NI-DAQ examples for C and CVI developed for MIO E series boards don ot work unless you make some modifications to the VIs. The functions to set the sampling rate are different, and the way the data buffer is handled is different, using 32 bits instead of 16 bits. You must specify the sampling rate on the NI-DAQ functions or VIs to determine the cut off frequency of the digital filters on the board. You can set the sampling rate (f s) can be between 5 kS/s and 204.8 kS/s, giving you an alias-free bandwidth from DC to 0.464 f s.
FFT Analyzer Mode
When using the FFT Analyzer mode this one is downloaded into the on board processor to allow real time analysis. The input signal after being filtered and digitized with the proper oversampling by the delta sigma converters is transformed to an alias free frequency domain spectrum containing the frequency components of the original time domain signal . As long as the board runs in real time consecutive time records will be captured and transformed to their frequency spectrum on the on board processor. Auto power spectrums, averaging , cross channels measurements and other calculations will be made if desired on the board before the results are sent on demand to the controlling host computer for further analysis, storage or display. The NI 4551 and 4552 in this DSA Instrument personality on FFT Analyzer Mode will be controlled and programmed using the NI-DSA instrument driver functions.
The NI-DSA instrument driver is the essential link between your application development software and your 4551/4552 instrument hardware. It works with LabVIEW, LabWindows/CVI, Visual Basic, and many C/C++ environments. It is used by the ready to run Virtual Bench DSA software panels. The instrument driver controls the hardware details, communicates with different boards, and makes the measurement functionality easily accessible to you. NI-DSA is the instrument driver used to control the DSA instruments. The interface is easy to use and offers complete control over typical DSA settings such as span, averaging, and measurement selections. When compared to instruments that use GPIB-based programmatic control, National Instruments computer-based DSAs can speed up your automated test cycles by as much as 10 to 20 times. The instrument diver has high level vi’s or functions to control the behavior of the board but the functionality and algorithms are run in real time on the on board processor, no implementations of functions like THD,Zoom FFT, Frequency response etc is needed by the user (all that is done on the processor).
Some of the features of the NI-DSA Instrument Driver version 1.0.1 are listed below.
Measurements
Measurements
When using the NI 4551 and 4552 in Octave Analyzer mode the NI-DSA driver is used but some special features are available only in this mode. Some of the features and functionality of the Real-time Fractional Octave Analyzer (RTFOA) in its beta version are listed below.
Fractional-octave analysis for 1/1, 1/3 and 1/12 octave analysis, with the following averaging modes:
NI-DAQ Personality
FFT Analyzer Mode
FFT Analyzer Software Architecture
The DSA FFT Analyzer Engine runs in the on board processor and provides four real time channel analyzers (two dual channel analyzers, 1 containing 2 baseband FFT engines, and the other containing 2 zoom FFT engines) as a powerful and flexible analysis tool.
The first dual channel analyzer is a baseband analyzer, you can select an independent frequency span for each of the two baseband analyzers (0Hz to 95KHzmax) with up to 800 lines of resolution.
Then the two other zoom analyzers can use any starting and ending frequency which determines the zoom span. You can have two different zoom spans with up to 1600 lines of resolution . (The Zoom span is related with the Baseband span and this relation is explained on the Baseband & Zoom Frequency Spans section.)
The four analyzers can be routed to any of the four input channels of the 4552 or any of the two input channels of the 4551. You can have more than one analyzer with different settings routed to the same channel to have proper resolution in different sections of the frequency spectrum.
The general scheme of a dual channel analyzer is shown below , both Zoom and Baseband dual channel analyzers present this scheme. In this case Ch A and Ch B can be routed by software to the desired input channels.

FFT Measurements
An FFT Analyzer extracts the frequency spectrum of a time domain signal. Fourier’s theorem states that any waveform in the time domain can be represented by the weighted sum of sines and cosines. The same waveform can then be represented in the frequency domain as a pair of amplitude and phase values at each component frequency.
FFT Basics

The Fast Fourier Transform (FFT) transforms digital samples from the time domain into the frequency domain. Each frequency component is the result of a dot product of the time signal with the complex exponential at the component frequency.
The DC component is the dot product of x(n) with [cos(0)-jsin(0)], or with 1.0.
The first “bin”, or frequency component, is the dot product of x(n) with cos(2n/N)-jsin(2n/N). Here, cos(2n/N) is a single cycle of the cosine wave, and sin(2n/N) is a single cycle of a sine wave.In general, the real part of FFT bin k, Re[X(k)], is the dot product of x(n) with k cycles of the cosine wave, and the imaginary part of bin k, Im[X(k)], is the dot product of x(n) with k cycles of the sine wave.
- FFT output is complex, giving magnitude and phase information
Magnitude = sqrt(FFT x FFT*)
Phase = Tan-1(Imag/Real) - Power Spectrum reflects the energy content
Power Spectrum = |FFT|^2 - If normalized to 1 Hz bandwidth, leads to the Power Spectral Density (PSD)
PSD = |FFT|^2/Df
- The first one relates the highest frequency that can be analyzed to the sampling frequency.
- The second one links the frequency resolution to the total acquisition time, which is related to the sampling frequency and the block size of the FFT.

The FFT spectrum output is complex; that is, every frequency component has a magnitude and phase. The phase is relative to the start of the time record, or relative to a cosine wave starting at the beginning of the time record. Single-channel phase measurements are stable only if the input signal is triggered. Dual-channel phase measurements compute phase differences between channels so that if the channels are simultaneously sampled, triggering is usually not necessary.
Normally, the magnitude of the spectrum is displayed. The magnitude is the square root of the FFT times its complex conjugate, or the square root of the sum of the squares of the real and imaginary parts of the FFT. The phase is the arctangent of the ratio of the imaginary and real parts of the FFT, and is usually between 180 and -180 degrees.
Dual Channel FFT Analysis
Dual channel analysis is very common in DSA applications basically in most of the situations a Frequency Response measurement needs to be performed to analyze the response of an under test system to different frequency components on its input.
For instance, to characterize the cutoff frequency of an analog low pass filter designed to attenuate to a certain level frequency components under a given cut off frequency, you would need to send signals of every frequency within the filter range to see how much every of those would be attenuated.
A better way to do it would be to send a signal that has all the frequency components in it and see how each of them is attenuated comparing the response or output of the filter with its input. This procedure of feeding into the DSA instrument both the output sent to the filter and the response obtained from it and comparing the amplitude levels of each frequency component is know as Frequency Response or Transfer Function.
When analyzing two simultaneously-sampled channels, you are no longer interested in the properties of each channel, but rather the differences between them.
In a typical dual-channel analyzer, the instantaneous spectrum is computed using a window function and the FFT for each channel. The averaged spectrum, auto spectrum, and cross spectrum is computed and used in estimating a very important system quantity—the frequency response function. Additionally, the coherence function can be used to check the validity of the frequency response function.

With a noise-free linear system, the output spectrum, Sy, is the product of the input spectrum Sx and the frequency response, H(f). With a noise injected in the output, some of the output energy is not caused by input energy alone.
The given formula for H(f), as the ratio of the averaged cross spectrum over the auto-spectrum of the input, greatly improves the H(f) estimate by reducing the effects of the injected noise. As the number of averages increases, and because the noise spectrum Sn is uncorrelated with the input spectrum Sx, the Sn Sx term tends to zero and our H(f) estimates improves.

The frequency response of a system is the described by the magnitude, |H|, and phase, <H, at each frequency.
The gain of the system is the same as its magnitude and is the ratio of the output magnitude to the input magnitude at each frequency.
The phase of the system is the difference of the output phase and input phase at each frequency.
The formula for coherence is

The coherence is a measure of the power in the output signal caused by the input. If there is no noise (or external sources independent of the input), all of the output power came from the input, and coherence will be unity. If there is noise contributing to the output signal, the coherence will be reduced.
This means in terms of 2 :
2 =1 when output is caused by input = H(f) measurement is good
2 =0 when input did not cause the output = Injected noise, nonlinearities
Baseband & Zoom Frequency Spans
As explained on the FFT Analyzer Software Architecture section the NI 4551 and 4552 offer Zoom and Baseband analyzers. Some of the specifications and use of these analyzers as well as relation between them are explained below.
Alias Free Bandwidth
Alias Free Bandwidth is the basic Alias Free Frequency Span or “range”, where frequency components of the signal will be converted in a clean manner. It also means that any frequency greater than the maximum frequency set (this is any non desired frequency component of the signal such as high frequency noise) will be rejected and will not alias or (fold ) back into the frequency span to be analyzed.
You need to be aware that there is a very tight relationship between the anti-aliasing filter cutoff frequency and sampling frequency. The NI 4551 and 4552 Dynamic Signal Analyzers (DSA) use delta-sigma converters to convert analog signals into digital data. These converters have built-in anti-aliasing filters whose cutoff frequency is typically 45 to 50% of the sample rate : in this case 46.4 %.
This sort of converter provides very sharp rejection, and the filter cutoff frequency automatically tracks with the sample rate. The DC bin up to the cutoff frequency will therefore determine the baseband alias free span.
By using the real time zoom FFT algorithm you can reach narrow spans without changing the hardware sampling frequency which has a limit , determining therefore a lower limit for baseband spans.
Baseband Spans
A Baseband is a frequency range for a measurement that starts always at DC and can go up to the widest full span or maximum alias free span of the board which corresponds to the fastest sampling rate.
The anti-aliasing filter is non-ideal and is designed to filter frequencies just below Nyquist (Fs/2) and all frequencies above Nyquist. There always exists either aliasing or attenuated signals just below the Nyquist rate as explained in the Alias Free Bandwidth paragraph. The useful frequency span is therefore limited to the region over which the anti-aliasing filtering and sampling is perfectly flat. At the maximum sampling rate of 204.8 KHz, the NI 4551/52 alias-free span is limited to 95 KHz.
For a time record and FFT size of 1024 samples at 204.8 kS/s, a span of 95 kHz corresponds to (95/204.8) * 1024 = 475 useful frequency bins, also known as frequency lines. If you include 0(DC), you would only plot 476 lines out of every 1024 point FFT when displaying the spectrum. With this FFT size and sampling rate the complete time record acquisition will take 5ms. This means that the lowest frequency on the spectrum frequency range is the corresponding to period of the time record it self this is 1/ 5ms = 200Hz.
The obtained spectrum represents the frequency range from DC to 95KHz with 475 bins or lines spaced every 200Hz (FFT resolution = 95K/475 = 204.8k / 1024). So the final spectrum will contain 476 frequency bins, the first one will cover –200Hz/2 to 200Hz/2, the second one 200Hz/2 to 3*200Hz/2 and so on until the 476th will be centered around 95KHz.
Because of the delta sigma converters inherent oversampling, filtering and antilaiasing protection the minimum sampling rate allowed is 5Ks/s which will correspond to a minimum Baseband Span of 5000*(1024/475) = 2320Hz with the extended FFT size and a minimum of 5000*(1024/400) = 1953Hz with the classcial size , and because of the above mentioned reasons the maximum Baseband Span would be 95KHz.
In NI-DSA version 1.0.1 , the maximum FFT size is 2K, this is 2048 samples therefore you can go up to 800 lines on classical and 950 lines on extended frequency span mode for Baseband. More lines might be available in future releases of NI-DSA.
In summary :
- The FFT resolution or number of lines desired determines the length of the time record and therefore number of samples to acquired of the time domain waveform and vice versa.
- The sampling rate determines the frequency span.
- The FFT resolution is the number of lines and the Frequency resolution will be the frequency span divided by the number of lines, the inverse of that is the time record length.
A Classical Span refers to the use of the classical FFT number of lines used in FFT analysis such as 400, 800, 1600. The Extended Span refers to the use of more lines and a widther frequency span taking advantage of the anti-aliasing capabilities of the NI 4551 and 4552 DSA instruments (with 475 and 950 lines for example).
The NI 4551 and 4552 Dynamic Signal Analyzers delta-sigma converters and filters provide anti-aliasing protection up to around 46.4% of the sample rate, this means that for a maximum sampling rate of 204.8 Ks/s the maximum alias free span is 95kHz= 204.8k * 0.464 .
This means that for a time record and FFT size of 1024 samples (1K) at 204.8 kS/s, a span of 95 kHz corresponds to (95/204.8) * 1024 = 475 useful frequency bins, also known as frequency lines. For a 2k FFT size the maximum number of alias free FFT bins or lines will be then 950.
The 475 and 950 number of lines will provide then a maximum alias free spectrum of 95kHz.
Just like the use of classical number of lines like 400 and 800 will provide a maximum span of 400(204800)/1024 = 80KHz.
The Baseband Analyzer spans are specified in extended mode, with a maximum frequency span of 95 kHz for up to 950 lines in NI-DSA 1.0.1. The corresponding maximum classical span is 80 kHz for up to 800 lines in NI-DSA 1.0.1..
The Zoom Analyzer will always provide a classical number of lines up to 1600 lines in NI-DSA 1.0.1 and will be discussed in the Zoom Spans section.
Zoom Spans
If you need better FFT resolution that the one offered by the Baseband analyzers you need to use the narrow spans capabilities of the Zoom analyzers.
The Real Time Zoom FFT Process
As we explained before the time record length is directly related with the frequency resolution. Increasing the time record will then increase the resolution , and to do that you need to take more points on a time record or lower the sampling rate. Taking more samples incurs in memory limitations and processing performance decreasing. Changing the sampling rate is not more practical because of the fact that sampling rate in the converters is directly related with anti-aliasing protection.
A narrow span will allow you to zoom around a center frequency with a selected span improving your frequency resolution. A narrow span has a start frequency , a center frequency and an end frequency. The zoom span is determined by the difference between the end and start frequency.
Ideally, you would like to center the narrow span around any frequency below the Baseband Span. Using decimating filters alone, all spans must begin at 0 (DC). If we frequency shift, or heterodyne, the input signal before the decimation stages, our resulting span would be centered at the modulation frequency allowing you to center your span in any frequency as long as your narrow span stays within the Baseband span..
The real time zoom approach is to digitally filter and down sample the acquired time record, these technique along with an heterodyning process in which the narrowed spectrum (by filtering) is shifted to a desired center frequency other than DC, providing a zoomed spectra (a selected narrowed span that start at a desired center frequency ).
Heterodyning is used by the analyzer to compute “zoomed” spans, those spans starting at frequencies other than DC. The signal processor can heterodyne and filter in real time to provide the appropriate time record at all spans and center frequencies. All of the signal processing computations, including modulation, digital filtering and decimation, and computing the FFT are done is less time than it takes to acquire the data, so the NI 4551 and NI 4552 process every input sample in measuring the signal spectrum.
In the heterodyning process the input points are multiplied by a complex unit vector (cos(wt) and sin(wt)) to yield a real and imaginary time record. The original frequency span center is then shifted to DC or heterodyned, this means that the upper half of the span will stay positive and the lower half (below the span center) will become negative frequencies. This means a span from 0 to 80kHz will become a –40kHz to 40kHz. This data goes through a digital low pass filter which cuts off at +-40kHz , this operation results in a +-40kHz usable span centered at 40kHz. The sampling rate needed is then only 102.4Ks/s instead of the original 204.8Ks/s hardware sampling rate defined by the selected baseband of 80kHz, so only every other point of the original span is used. At this point the original baseband span is represented by a complex time record with half as many points as the original one, half the sampling rate and therefore same duration (each the real and imaginary part of this complex record will have half of the original sample rate and half of the original span).
If we keep the hardware sampling rate constant at 204.8 kHz, the NI 4551 and 4552 can digitally halve the effective sampling rate by passing the digital samples through one stage of a decimate-by-2 lowpass filter. Digital filtering and down-sampling is used to narrow the heterodyned data by zooming around the heterodyne frequency (the center of the original span). So while the first filter reduces the sampling rate by half and the number of samples by splitting the time record in real and imaginary parts ; the second filter cuts off at +-20kHz reducing the sample rate by 2 again but not the number of points. The new record will then have twice the original duration and thus , half of the original span, this is a 40kHz span centered around 40kHz. The time record duration is twice the full span one. The sample rate is ΒΌ of the baseband rate.
Further iterations of this process can reduce the span and provide better resolution for analysis.
If we pass 2048 samples (for a 2K FFT) at 204.8 kHz through this decimating filter, the output will be 1024 samples at 102.4 kHz. Both records correspond to a 10 ms duration, and so the frequency resolution, or bin width, is 1/10ms = 100 Hz. Once again, the length of the time record always determines the frequency resolution of the spectrum.
To make sure the decimating filter is fast and memory efficient, the alias-free range for narrow spans is reduced from 475 lines to the standard 400 lines per 1024-point FFT, this will allow the use of a faster and less sharp filter improving performance. This means the maximum alias free frequency span will be 80kHz for Zoom instead of the 95kHz available for Baseband. The resulting span is (400/1024) * Fs, so that our span for one stage of decimation is (400/1024) * Fs/2 = 40 kHz.
The frequency resolution for a 1024 point FFT at the highest span yielded a frequency resolution of 200 Hz. 1024 points of decimated data corresponds to a time duration of twice that of the highest span, so our frequency resolution is improved to 100 Hz. This process of doubling the time record and halving the span and resolution can be repeated for each additional decimate-by-2 filter stage.
Zoom Spans Characteristics
Zoom Spans should be a power of 2 of the classical Baseband Spans this means that if you want a 12800 Hz Zoom Span you can use a 12800 Hz Baseband span in classical mode (100, 200, 400, 800 lines) or 12800 Hz multiplied by any power of two within the Baseband span. This basically means that if you have a 12800 classical Baseband span you cannot have a 1400 zoom span, but you do can have a 1600 because 1600*8=1600*2^3=12800, , this is : required_classical_baseband_span = zoom_span * 2^n.
If you select to use Baseband on the extended mode which provides a frequency range of 95kHz in baseband, as opposed to the 80kHz on classical mode, you need to perform an additional calculation to determine the correct Baseband span you have to select to be able to have a particular Zoom span. If you need a Zoom span of 12800 you need an extended Baseband of a power of two of 12800 * (475/400) = 15200 Hz, this is : required_extended_baseband_span = zoom_span * (extended_lines / classical_lines) * 2^n. So 15200 or 32400 or 64800 will be adequate. The 475/400 factor converts the classical zoomed span to its extended representation to be able to select the correct extended Baseband span.
It is important to notice that if you select any zoom span the NI-DSA instrument driver will automatically change it to the closest possible span according to the baseband span currently in use.
The Zoom span limits have to be within the Baseband span and the maximum extended Baseband Span as explained above is 95kHz. You can have 100, 200, 400, 800 or 1600 lines with NI-DSA version 1.0.1. Further releases will increase the possible FFT size providing more lines.
When the selected Zoom span is larger than the classical baseband span selected (including the maximum classical baseband span of 80kHz), the driver will make the Zoom Analyzer behave as a Baseband Analyzer and eliminate the modulation and decimation stages. This allows for instance the use of the two dual channel analyzers architecture to perform an FFT analysis in four channels using two Zoom Analyzers and two Baseband Analyzers at the same time on the same frequency span.
An other remark is that when the Zoom Analyzers are used on narrow spans with starting frequency 0 Hz (DC), the driver will not perform the modulation stage (which would not be necessary in this case) and only the decimation filtering will be performed increasing the integrity of the time domain record.
Windowing
In practical applications, you obtain only a finite number of samples of the signal. The FFT assumes that this time record repeats. If you have an integral number of cycles in your time record, the repetition is “smooth” at the boundaries. However, in practical applications, you will usually have a nonintegral number of cycles. In such cases, the repetition results in discontinuities at the boundaries.

These artificial discontinuities were not originally present in your signal and result in a smearing or leakage of energy from your actual frequency to all other frequencies. This phenomenon is known as spectral leakage. The amount of leakage depends on the amplitude of the discontinuity, a larger one causing more leakage
Because the amount of leakage is dependent on the amplitude of the discontinuity at the boundaries, you can use windowing to reduce the size of the discontinuity and hence reduce spectral leakage.

Windowing consists of multiplying the time domain signal by another time domain waveform, known as a window, whose amplitude tapers gradually and smoothly toward zero at edges. The result is a windowed signal with no (or very small) discontinuities, and thus reduced spectral leakage. There are many different types of windows. The one you choose depends on your application.

The frequency domain spectrum of the windowed time domain signal will reduce the noise components that could be generated on the spectrum after the FFT because of the leakage and its discontinuity effects.

Some of the available windows on NI-DSA 1.0.1 are :
- Uniform
- Hanning
- Blackman-Harris (Standard, 4, 7-term)
- Flattop
- Kaiser
- Low sidelobe
- Force
- Exponential
- Forced-exponential
Averaging successive measurements tends to improve measurement accuracy. Averaging is usually performed on measurement results or on individual spectra, but not directly on the time record. In the NI-DSA Instrument Driver Exponential and Linear Averaging are available in RMs, Peak Hold and Vector modes.
- RMS averaging computes the weighted mean of the sum of squared values. RMS averaging reduces fluctuations in the data but does not reduce the actual noise floor.
- Vector averaging uses the complex FFT spectrum. The real part is averaged separately from the imaginary part. This can reduce the noise floor for random signals, because they are not phase coherent from one time record to the next. For single-channel measurements, vector averaging requires a trigger so that the real and imaginary parts of the signal will add in phase instead of canceling randomly.
- Peak Hold averaging retains the peak of the spectral magnitudes on a frequency bin-by-bin basis. The peak values are stored in the original complex form so that all complex forms of the data can be displayed.
- Each new spectral record for RMS and Vector averaging can be weighted using either Linear or Exponential weighting.
- Linear weighting combines N spectral records with equal weighting. When the number of averages has been completed, the analyzer stops averaging and presents the averaged results.
- Exponential weighting emphasizes new spectral data more than old. Averaging takes place according to this formula:
New Average = New Spectra * 1/N + Old Average * (N-1)/N
where N is the number of averages for linear averaging, or is computed from the time constant for exponential averaging.
Analog Output
The NI-DSA version 1.0.1 provides Dual Tone, Periodic Random Noise , Chirp , Periodic Arbitrary and White Noise sources.
The buffer for when the source is configure for arbitrary source has to be 4K samples or less, if it is less it has to be a power of 2. Not limited buffer generation will be available in future releases of NI-DSA.
An important thing to notice is that in NI-DSA 1.0.1 you don't have direct control on the update rate trough this functions, the update rate depends on the scan rate set for the inputs. So if you change the input rate the update rate will be the same if the scan rate is less or equal than 51.2KHz, then it will be half if the input scan rate is between 51.2KHz and 102.4KHz, then it would be one fourth of the input rate if this one is between 102.4KHz and 204.8KHz.
An other important remark is that both outputs on the NI 4551 board will work as a single output if the board is used on DSA Instrument Mode through the NI-DSA 1.0.1 driver. Output channel 0 will generate the selected source and channel 1 will select the same signal with a 180 degrees shift. In the other hand NI-DAQ mode allows the independent use of the two outputs.
Octave Analyzer Mode
In this mode your NI 455X will behave as an Octave Analyzer Instrument allowing you to perform fractional octave analysis in real time and level measurements as well . The basic concepts about the analyzer architecture , features and operation are discussed in this section.
The NIDSA Real-time Octave Analysis Software add-on for the NI 4551 and NI 4552 Dynamic Signal Analyzer boards supports:
1. Fractional-octave analysis for 1/1, 1/3 and 1/12 octave analysis, with the following averaging modes:
- Linear
- Exponential - slow, fast, custom
- Impulse
- Peak Hold
- Equal Confidence
- Linear (Leq)
- Exponential - slow, fast, custom
- Impulse
- Impulse-Eq
- Peak Hold
It is possible to do only octave, only level, or both octave and level measurements, with the additional option of specifying the weighting if required.
Octave and Level Analyzers Software Architecture

Octave and Level measurements can be performed on 1,2 or 4 channels simultaneously. Up to n=16 simultaneous level measurements can be configured and performed at the time, and only one set of octave measurements. The time domain input signal is passed through a weighting processes if desired , then it is passed to the Level Analyzer and Fractional Octave Analyzer, and finally goes through an averaging process.
The input to either the octave or level analyzers can be either the weighted (W) or unweighted (U) time domain signal. For the same channel, it is possible to simultaneously obtain either:
- Octave measurements, weighted or unweighted, and/or
- Level measurements, weighted and/or
- Level measurements, unweighted
Architecture of the Fractional Octave Analyzer

This figure shows the architecture of the fractional-octave analyzer. There are 3 bandpass filters per octave because the figure corresponds to the third-octave (1/3) analyzer. For the full-octave (1/1) analyzer, there is only one bandpass filter per octave. Similary for the 1/12-octave analyzer, there are 12 bandpass filters per octave.
The following nomenclature is used:
| BPF | Bandpass filter |
| LPF | Lowpass filter |
| 2:1 decimator | The decimator effectively halves the sampling rate. For every 2 samples at the input, there is one sample at the output. |
| Fs | Sampling frequency |
The architecture of the fractional-octave analyzer changes depending on the selected octave mode. There are 3 bandpass filters per octave when used as a third-octave (1/3) analyzer. For the full-octave (1/1) analyzer, there is only one bandpass filter per octave. Similary for the 1/12-octave analyzer, there are 12 bandpass filters per octave.
The input time-domain signal is sampled at a sampling frequency fs. The Band Pass Filters (BPF) in stage 1, corresponding to the highest octave, filter the signal directly at the sampling frequency. The signal is then Low Pass Filtered (LPF), and decimated by 2, thereby effectively reducing the sampling frequency by half to fs/2 (this means that for every 2 samples at the input, there is one sample at the output).This lowpass filtered and decimated signal is passed on to the BPF(s) corresponding to the next highest octave in stage 2. The procedure is repeated for a maximum of 10 stages of BPF(s). Note that this corresponds to a maximum of 9 stages of lowpass filtering and decimation.
The time domain samples at the output of each BPF are squared and averaged accordingly depending on the averaging mode selected. It is this averaged result from the output of each BPF that is returned. Thus, for third-octave analysis, you will get a maximum of 30 results (10 octaves X 3 BPF’s per octave). Similarly, for 1/1-octave analysis, you will get a maximum of 10 results (10 octaves X 1 BPF per octave), for 1/12-octave, you will get a maximum of 120 results (10 octaves X 12 BPF’s per octave).
However, if the frequency range that you choose covers less than 10 octaves, you will get less than the maximum number of results. If the frequency range that you choose covers more than 10 octaves, you will get only the maximum number of results that cover 10 octaves.
Currently only 1/3-octave analysis is supported. In the future, we will also support 1/1-octave and 1/12-octave analysis.
Exact and Preferred Frequencies
The bandpass filters for fractional-octave analysis conform to the ANSI S1.11-1986 standard titled “Specification for octave-band and fractonal-octave-band analog and digital filters.” Since the NIDSA fractional-octave analyzer has been designed to operate over the audio frequency range, the reference frequency (fr) chosen is 1 KHz. The exact midband frequencies, fm, for each BPF, calculated according to this standard, are given by
fm = fr*2^(k/b) for k = . . . . . ,-3, -2, -1, 0, 1, 2, 3,. . . . .
where
k is an integer,
b = 1 for 1/1-octave,
b = 3 for 1/3-octave, and
b = 12 for 1/12-octave.
As an example, for 1/3-octave analysis, for k = 0, we have fm = fr = 1000 Hz. For k positive, the calculated values of fm are above 1000 Hz, and for k negative, the calculated values of fm are below 1000 Hz.
For display purposes, the ANSI standard also specifies what are known as “preferred” frequencies. The exact and preferred frequencies for 1/3-octave analysis, for different values of k, are shown in the following table.
k | Exact frequency (Hz) | Preferred frequency (Hz) |
| -16 | 24.8 | 25 |
| -15 | 31.25 | 31.5 |
| -14 | 39.37 | 40 |
| -13 | 49.61 | 50 |
| -12 | 62.5 | 63 |
| -11 | 78.75 | 80 |
| -10 | 99.21 | 100 |
| -9 | 125 | 125 |
| -8 | 157.49 | 160 |
| -7 | 198.43 | 200 |
| -6 | 250 | 250 |
| -5 | 314.98 | 315 |
| -4 | 396.85 | 400 |
| -3 | 500 | 500 |
| -2 | 629.96 | 630 |
| -1 | 793.7 | 800 |
| 0 | 1000 | 1000 |
| 1 | 1259.92 | 1250 |
| 2 | 1587.40 | 1600 |
| 3 | 2000 | 2000 |
| 4 | 2519.84 | 2500 |
| 5 | 3174.80 | 3150 |
| 6 | 4000 | 4000 |
| 7 | 5039.68 | 5000 |
| 8 | 6349.60 | 6300 |
| 9 | 8000 | 8000 |
| 10 | 10079.37 | 10000 |
| 11 | 12699.21 | 12500 |
| 12 | 16000 | 16000 |
| 13 | 20158.74 | 20000 |

This figure shows the preferred midband frequencies for some of the BPFs of the 1/3-octave analyzer. Observe that these are constant-Q filters. . . . . the bandwidth of the filter increases with increase in the midband frequency such that the ratio fm/BW = Q = constant, where BW is the bandwidth of the filter. All
the bandpass filters have the same value of Q.
Settling Time
The fractional octave filters require a certain amount of time before any changes at the input of the filters are propagated to the output so as to again provide a valid measurement. This time is called the ‘settling time’ and is inversely proportional to the bandwidth of the filter. It is given by
settling time (seconds) = 1/(5*bandwidth)
where the bandwidth is in Hertz. The bandwidth for each band can be calculated by
exact center frequency*(21/2n - 2-1/2n )
where
n = 1 for full-octave
= 3 for 1/3-octave
= 12 for 1/12-octave
and the exact center frequency for each band is returned in the ‘exact center frequencies’ output of the ‘NIDSA Get Octave Frequencies’ function.
The lower frequency bands require a larger settling time because of their smaller bandwidth. You can check whether or not the octave filters have settled by checking the ‘settled’ output of the ‘NIDSA Read Octave Measurements’ function.
If both octave and level measurements are configured in the ‘NIDSA Configure OLM Engine’ function, the averaging process is started only after all the octave filters have settled. If only level measurements are configured, then the averaging process is started immediately.
Overload Detection
Two types of overload detection, ‘sticky’ or ‘non-sticky’, are possible:
- Sticky overload is set whenever an overload is detected on a particular channel, and remains set even after the overload condition has disappeared. It gets reset when you reconfigure, or restart averaging, for that specific channel. The ‘NIDSA get OLM status’ function returns the sticky overload flag.
- Non-sticky overload is set when an overload is detected on any of the input channels, and is reset automatically when the overload condition has passed. The ‘NIDSA check status’ function returns the non-sticky overload flag. The overload information in NIDSA Check Status is bit-encoded.....a '1' means overload in channel 1, a '2' means overload in channel 2, a '4' means overload in channel 3, a '3' means overload in channels 1 & 2, and so on.
- 1-channel 1/1-octave support upto 32 KHz center frequency per channel
- 2-channel 1/1-octave support upto 16 KHz center frequency per channel
- 4-channel 1/1-octave support upto 8 KHz center frequency per channel
- 1-channel 1/3-octave support upto 40 KHz center frequency per channel
- 2-channel 1/3 octave support upto 20 KHz center frequency per channel
- 4-channel 1/3 octave support upto 10 KHz center frequency per channel
Level Measurements
The Octave Analyzer engine includes RMS meters that allow you to perform level measurements on the unweighted or weighted (using A,B or C filters) time domain waveform.
Level measurements are designated by the following nomenclature :
Lxy
Where L means Level and x will define the type of weighting filter used : A, B, C or none. Just like y will define the type of averaging used : Fast (F), Slow (S), Custom (C), Impulse (I), Equivalent (EQ) and Impulse Equivalent (IEQ).
Some examples of possible level measurements are: LAQ, LAF, LEQ, LBEQ, LCI e.t.c.
When exponential averaging is used the time constant varies with the type of averaging : 1s for Slow, 125ms for Fast, 35ms rising and 1500ms falling for Impulse. The time constant for Custom is user defined.
When Equivalent averaging is used the linear RMS average will be calculated over a determined period of time.
Averaging Modes for Octave and Level Analyzers
You can choose between several averaging modes for both the octave and level measurements. Averaging for octave measurements are performed on the filtered outputs of the bandpass filters, whereas averaging for level measurements is performed on the input time domain data. For both octave and level measurements, averaging is done on the power (magnitude squared) value.
An explanation of the various types of averaging modes available are:
None
In this case, no averaging is done. The result of each measurement is made available without combining it with any other measurement.
Linear
For linear averaging, a weighted average is performed over the time duration specified in the ‘NIDSA Configure OLM Averaging’ function. All measurements made over the time duration are weighted equally. The formula for linear averaging is the following:
y[k] = a1*y[k-1] + a2*x[k]
where
x[k] – new measurement
y[k] – new average
y[k-1] – previous average
a1 = (k-1)/k
a2 = 1/k
and k = 1, 2, 3, . . . is the number of measurements averaged so far. Linear averaging returns the arithmetic mean of the measurements.
There are two types of linear averaging available:
- One Shot: In One Shot mode, linear averaging is done once for the specified duration. When the duration is over, the averaging stops. In this mode, the intermediate results (0 <= time <= duration) of averaging are available.
- Auto Restart: In Auto Restart mode, linear averaging is done for the specified time duration. When the time duration is over, linear averaging is restarted and performed again for the same duration. This process continues indefinitely. In this mode, the results are available only at the end of each averaging period (at time = n*duration, n = 0, 1, 2, 3, . . . ). Each result corresponds to the result of linear averaging over a time period of n*duration to (n+1)*duration.
Note: In One Shot mode, you can specify any time duration. If the end of the time duration falls in between a sample interval, the closest sample is included in the duration. In Auto Restart mode, the time duration can only be an integer multiple of 10 milliseconds (n*0.01 seconds, where n = 1, 2, 3, . . . ). If any other duration is specified, it is rounded off to the nearest 10 milliseconds.

For level measurements, the linear average is denoted as Leq (equivalent sound power over the specified time duration.)
Exponential
Exponential averaging is a continuous averaging process that weighs both current as well as past data. The amount of weight given to past data as compared to current data depends on the exponential time constant. The higher the time constant, the more weight given to past data, whereas the lower the time constant, the more weight is placed on the current data. The formula for exponential averaging is:
y[k] = a1*y[k-1] + a2*x[k]
where
x[k] – new measurement
y[k] – new average
y[k-1] – previous average
a1 = exp(-1.0/time_constant*sampling_rate)
a2 = 1 - a1
The value of the time_constant depends on the type of exponential averaging selected. The various types of exponential averaging available are:
- Slow – The time constant for slow exponential averaging is 1.0 second. This type of averaging is useful for tracking the energy levels of signals whose energy levels vary slowly.
- Fast – The time constant for fast exponential averaging is 0.125 seconds. This type of averaging is useful for tracking the energy of signals whose energy levels are quickly varying.
- Custom – You can specify the time constant suitable for your particular application.
- Impulse – The time constant for signals with increasing energy levels is 0.035 seconds, whereas for signals with decreasing energy levels is 1.5 seconds. This type of averaging is useful for tracking sudden changes in the signal and holding on to these changes so that they don’t disappear too fast.
While exponential averaging is in progress, the time for which the averaging process has elapsed is returned in the ‘averaging seconds’ output of the ‘NIDSA Read Octave Measurements’ and the ‘NIDSA Read Level Measurements’ functions. There is a one-to-one correspondence between the time returned and the measured values read from these functions.
Impulse + Linear
This is available only for level measurements. It is a combination of linear averaging and the exponential impulse averaging. Impulse averaging is performed over the time duration specified in the ‘NIDSA Configure OLM Averaging’ function, and the corresponding measured values are weighted equally to form the average. Similar to linear averaging, the averaging process stops at the end of the time duration.
While impulse + linear averaging is in progress, the time for which the averaging process has elapsed is returned in the ‘linear averaging seconds’ output of the ‘NIDSA Read Octave Measurements’ and the ‘NIDSA Read Level Measurements’ functions. There is a one-to-one correspondence between the time returned and the measured values read from these functions. In Auto Restart mode, you will see that the time returned increments in intervals of the ‘duration’ specified in the ‘NIDSA Configure OLM Averaging’ function.
Peak
In peak (or peak hold) averaging, the largest measured energy value is held. The formula for peak averaging is:
y[k] = max(y[k-1] , x[k])
where
x[k] – new measurement
y[k] – new average
y[k-1] – previous average
Similar to exponential averaging, the averaging process continues indefinitely.
Strictly speaking, peak hold is not really a form of averaging because successive measurements are not mathematically averaged. However, as with any of the other averaging processes, it combines the results of several measurements into one final measurement, and could thus be considered a kind of averaging.
Equal Confidence
This is available only for octave measurements. It is similar to exponential averaging with the difference being that the time constant is dependent on the particular band. The time constant for each band is such that the results are within +/- of the confidence level (in dB, specified in the ‘confidence level’ input of the ‘NIDSA Configure Octave Averaging’ function) of the correct mean with a probability of 68%. The probability that the results are within twice the confidence level of the correct mean is 96%.
As an example, if you specify a confidence level of 1 dB, and the correct mean is 10 dB, there is a 68% confidence that the measured value is between 9 - 11 dB, and a 96% confidence that the measured value is between 8 - 12 dB.
The following table shows the modes that are available for each of the octave or level measurements.
Averaging Mode | Octave | Level |
| None | Y | |
| Linear | Y | Y |
| Exponential - slow | Y | Y |
| Exponential - fast | Y | Y |
| Exponential - custom | Y | Y |
| Exponential - impulse | Y | Y |
| Impulse + linear | Y | |
| Peak hold | Y | Y |
| Equal confidence | Y |
Reader Comments | Submit a comment »
Legal
This tutorial (this "tutorial") was developed by National Instruments ("NI"). Although technical support of this tutorial may be made available by National Instruments, the content in this tutorial may not be completely tested and verified, and NI does not guarantee its quality in any way or that NI will continue to support this content with each new revision of related products and drivers. THIS TUTORIAL IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND AND SUBJECT TO CERTAIN RESTRICTIONS AS MORE SPECIFICALLY SET FORTH IN NI.COM'S TERMS OF USE (http://ni.com/legal/termsofuse/unitedstates/us/).
