Text preview for : www.thinksrs.com-AboutFFTs.pdf part of Stanford Research Systems www.thinksrs.com-AboutFFTs Stanford Research Systems www.thinksrs.com-AboutFFTs.pdf
Back to : www.thinksrs.com-AboutFFT | Home
www.thinkSRS.com
About FFT Spectrum Analyzers
Application Note #1
What is an FFT Spectrum Analyzer? frequency points as there are time points. (Remember
Nyquist's theorem.) Suppose that you take 1024 samples at
FFT Spectrum Analyzers, such as the SR760, SR770, SR780 256 kHz. It takes 4 ms to take this time record. The FFT of this
and SR785, take a time varying input signal, like you would record yields 512 frequency pointsbut over what frequency
see on an oscilloscope trace, and compute its frequency spectrum. range? The highest frequency will be determined by the period
of two time samples or 128 kHz. The lowest frequency is just
Fourier's theorem states that any waveform in the time domain the period of the entire record or 1/(4 ms) or 250 Hz.
can be represented by the weighted sum of sines and cosines. Everything below 250 Hz is considered to be DC. The output
The FFT spectrum analyzer samples the input signal, spectrum thus represents the frequency range from DC to
computes the magnitude of its sine and cosine components, 128 kHz, with points every 250 Hz.
and displays the spectrum of these measured frequency
components. Advantages of FFT Analyzers
Why Look at a Signal's Spectrum? The advantage of this technique is its speed. Because FFT
spectrum analyzers measure all frequency components at the
For one thing, some measurements which are very hard in the same time, the technique offers the possibility of being
time domain are very easy in the frequency domain. Consider hundreds of times faster than traditional analog spectrum
the measurement of harmonic distortion. It's hard to quantify analyzers. In the case of a 100 kHz span and 400 resolvable
the distortion of a sine wave by looking at the signal on an frequency bins, the entire spectrum takes only 4 ms to
oscilloscope. When the same signal is displayed on a spectrum measure. To measure the signal with higher resolution, the
analyzer, the harmonic frequencies and amplitudes are time record is increased. But again, all frequencies are
displayed with amazing clarity. Another example is noise examined simultaneously providing an enormous speed
analysis. Looking at an amplifier's output noise on an advantage.
oscilloscope basically measures just the total noise amplitude.
On a spectrum analyzer, the noise as a function of frequency In order to realize the speed advantages of this technique we
is displayed. It may be that the amplifier has a problem only need to do high speed calculations. And, in order to avoid
over certain frequency ranges. In the time domain it would be sacrificing dynamic range, we need high-resolution ADCs.
very hard to tell. SRS spectrum analyzers have the processing power and front-
end resolution needed to realize the theoretical benefits of
Many of these measurements were once done using analog FFT spectrum analyzers.
spectrum analyzers. In simple terms, an analog filter was used
to isolate frequencies of interest. The signal power which Dual-Channel FFT Analyzers
passed through the filter was measured to determine the signal
strength in certain frequency bands. By tuning the filters and One of the most common applications of FFT spectrum
repeating the measurements, a spectrum could be obtained. analyzers is to measure the transfer function of a mechanical
or electrical system. A transfer function is the ratio of the
The FFT Analyzer output spectrum to the input spectrum. Single-channel
analyzers, such as the SR760, cannot measure transfer
An FFT spectrum analyzer works in an entirely different way. functions. Single-channel analyzers with integrated sources,
The input signal is digitized at a high sampling rate, similar to such as the SR770, can measure transfer functions but only by
a digitizing oscilloscope. Nyquist's theorem says that as long assuming that the input spectrum of the system is equal to the
as the sampling rate is greater than twice the highest spectrum of the integrated source. In general, to measure a
frequency component of the signal, the sampled data will general transfer function, a two-channel analyzer (such as
accurately represent the input signal. In the SR7xx (SR760, the SR785) is required. One channel measures the spectrum of
SR770, SR780 or SR785), sampling occurs at 256 kHz. To the input, the other measures the spectrum of the output, and
make sure that Nyquist's theorem is satisfied, the input signal the analyzer performs a complex division to extract the
passes through an analog filter which attenuates all frequency magnitude and phase of the transfer function. Because the
components above 156 kHz by 90 dB. This is the anti-aliasing input spectrum is actually measured and divided out, you're
filter. The resulting digital time record is then mathematically not limited to using a predetermined signal as the input to the
transformed into a frequency spectrum using an algorithm system under test--any signal will do.
known as the Fast Fourier Transform, or FFT. The FFT is
simply a clever set of operations which implements Fourier's Frequency Spans
theorem. The resulting spectrum shows the frequency
components of the input signal. Before continuing, a couple of points about frequency span
need clarification. We just described how we arrived at a
Now here's the interesting part. The original digital time DC to 128 kHz frequency span using a 4 ms time record.
record comes from discrete samples taken at the sampling Because the signal passes through an anti-aliasing filter at the
rate. The corresponding FFT yields a spectrum with discrete input, the entire frequency span is not useable. The filter has a
frequency samples. In fact, the spectrum has half as many flat response from DC to 100 kHz and then rolls off steeply
Stanford Research Systems phone: (408)744-9040
www.thinkSRS.com
About FFT Spectrum Analyzers
from 100 kHz to 156 kHz. No filter can make a 90 dB starts at DC. The resulting FFT yields a spectrum offset by the
transition instantly. The range between 100 kHz and 128 kHz heterodyne frequency.
is therefore not useable, and the actual displayed frequency
span stops at 100 kHz. There is also a frequency bin labeled Heterodyning allows the analyzer to compute zoomed spectra
0 Hz (or DC). This bin actually covers the range from 0 Hz to (spans which start at frequencies other than DC). The digital
250 Hz (the lowest measurable frequency) and contains the filter processor can filter and heterodyne the input in real time
signal components whose period is longer than the time record to provide the appropriate filtered time record at all spans and
(not only DC). So the final displayed spectrum contains center frequencies. Because the digital signal processors in the
400 frequency bins. The first covers 0 to 250 Hz, the second SR7xx are so fast, you won't notice any calculation time while
250 to 500 Hz, and the 400th covers 99.75 to 100.0 kHz. taking spectra. All the signal processing calculations,
heterodyning, digital filtering and Fourier transforming are
Spans Less Than 100 kHz done in less time than it takes to acquire the data. So the
SR7xx can take spectra seamlessly, i.e. there is no dead time
The length of the time record determines the frequency span between one time record and the next.
and resolution of our spectrum. What happens if we make the
time record 8 ms (twice as long)? Well, we ought to get Measurement Basics
2048 time points (sampling at 256 kHz) yielding a spectrum
from DC to 100 kHz with 125 Hz resolution containing An FFT spectrum is a complex quantity. This is because each
800 points. But the SR7xx places some limitations on this. frequency component has a phase relative to the start of the
One is memory. If we keep increasing the time record we will time record. (Alternately, you may wish to think of the input
need to store more and more points. (1 Hz resolution would signal being composed of sines and cosines.) If there is no
require 256 k values.) Another limitation is processing time. triggering, the phase is random and we generally look at the
The time it takes to calculate an FFT with more points magnitude of the spectrum. If we use a synchronous trigger,
increases more than linearly. each frequency component has a well defined phase.
To overcome this problem, the analyzer digitally filters and Spectrum
decimates the incoming data samples (at 256 kHz) to limit the
bandwidth and reduce the number of points in the FFT. This is The spectrum is the basic measurement of an FFT analyzer. It
similar to the anti-aliasing filter at the input except the digital is simply the complex FFT. Normally, the magnitude of the
filter's cutoff frequency can be changed. In the case of the spectrum is displayed. The magnitude is the square root of the
8 ms record, the filter reduces the bandwidth to 64 kHz with a FFT times its complex conjugate. (Square root of the sum of
filter cutoff of 50 kHz (the filter rolls off between 50 kHz the real (sine) part squared and the imaginary (cosine) part
and 64 kHz). Remember that Nyquist only requires samples squared.) The magnitude is a real quantity and represents the
at twice the frequency of the highest signal frequency. Thus, total signal amplitude in each frequency bin, independent of
the digital filter only has to output points at 128 kHz, or half phase.
of the input rate (256 kHz). The net result is the digital filter
outputs a time record of 1024 points, effectively sampled at If there is phase information in the spectrum, i.e. the time
128 kHz, to make up an 8 ms record. The FFT processor record is triggered in phase with some component of the
operates on a constant number of points, and the resulting FFT signal, then the real (cosine) or imaginary (sine) part or the
will yield 400 points from DC to 50 kHz. The resolution or phase may be displayed. The phase is simply the arctangent of
linewidth is 125 Hz. the ratio of the imaginary and real parts of each frequency
component. The phase is always relative to the start of the
This process of doubling the time record and halving the span triggered time record.
can be repeated by using multiple stages of digital filtering.
The SR7xx can process spectra with a span of only 191 mHz Power Spectral Density (PSD)
with a time record of 2098 seconds if you have the patience.
However, this filtering process only yields baseband The PSD is the magnitude of the spectrum normalized to a
measurements (frequency spans which start at DC). 1 Hz bandwidth. This measurement approximates what the
spectrum would look like if each frequency component were
Starting the Span Somewhere Other Than DC really a 1 Hz wide piece of the spectrum at each frequency bin.
In addition to choosing the span and resolution of the What good is this? When measuring broadband signals (such
spectrum, we may want the span to start at frequencies other as noise), the amplitude of the spectrum changes with the
than DC. It would be nice to center a narrow span around any frequency span. This is because the linewidth changes, so the
frequency below 100 kHz. Using digital filtering alone frequency bins have a different noise bandwidth. The PSD, on
requires that every span start at DC. We need to frequency the other hand, normalizes all measurements to a 1 Hz
shift, or heterodyne, the input signal. Multiplying the bandwidth, and the noise spectrum becomes independent of
incoming signal by a complex sine will frequency shift the the span. This allows measurements with different spans to be
signal. The resulting spectrum is shifted by the frequency of compared. If the noise is Gaussian in nature, the amount of
the complex sine. If we incorporate heterodyning with our noise amplitude in other bandwidths may be approximated by
digital filtering, we can shift any frequency span so that it scaling the PSD measurement by the square root of the
Stanford Research Systems phone: (408)744-9040
www.thinkSRS.com
About FFT Spectrum Analyzers
bandwidth. Thus, the PSD is displayed in units of V/Hz or 0 to 1. If the coherence is 1, all the power of the output signal
dBV/Hz. is due to the input signal. If the coherence is 0, the input and
output are completely random with respect to one another.
Since the PSD uses the magnitude of the spectrum, the PSD is Coherence is related to signal-to-noise ratio (S/N) by the
a real quantity. There is no real or imaginary part, or phase. formula:
2 2
Time Record S/N = /(1- )
2
The time record measurement displays the filtered and where is the traditional notation for coherence.
decimated (depending on the span) data points before the FFT
is taken. In the SR760 and SR770, this information is Correlation
available only at full span. In the SR780 and SR785, time
records can be displayed at all spans. For baseband spans The SR780 and SR785 analyzers also compute auto and cross-
(spans that start at DC), the time record is a real quantity. For correlation. Correlation is a time domain measurement which
non-baseband spans, the heterodyning discussed earlier is defined as follows:
transforms the time record into a complex quantity which can
be somewhat difficult to interpret. Auto Correlation = x*(t)x(t-)dt
Two-Channel Measurements
Cross Correlation = x*(t)y(t-)dt
As we discussed earlier, two-channel analyzers (such as the
SR780 and SR785) offer additional measurements such as
transfer function, cross-spectrum, coherence and orbit. These where x and y are the channel 1 and channel 2 input signals
measurements, which only apply to the SR780 and SR785, are and the integrals are over all time. It is clear that the auto
discussed below. correlation at a time t is a measure of how much overlap a
signal has with a delayed-by-t version of itself, and the cross-
Transfer Function correlation is a measure of how much overlap a signal has
with a delayed-by-t version of the other channel. Although
The transfer function is the ratio of the spectrum of channel 2 correlation is a time-domain measurement, the SR780 and
to the spectrum of channel 1. For the transfer function to be SR785 use frequency-domain techniques to compute it in
valid, the input spectrum must have amplitude at all order to make the calculation faster.
frequencies over which the transfer function is to be
measured. For this reason, broadband sources (such as noise, Spectrum
or periodic chirps) are often used as inputs for transfer
function measurements. The most common measurement is the spectrum and the most
useful display is the log magnitude. The log magnitude
Cross Spectrum display graphs the magnitude of the spectrum on a logarithmic
scale using dBV as units.
The cross spectrum is defined as:
Why is the log magnitude display useful? Remember that the
cross spectrum = FFT2