DFT, Resampling, Interpolation.
Cuthbert Nyack
If a signal is sampled at a rate which is only slightly more than twice the highest frequency in the signal then it can be problematic to filter out the part of the spectrum between
ws/2 and ws because of the very sharp filter
cutoff characteristics required.
One way to solve this problem is to resample the signal at a
higher frequency.
The applet below attempts to illustrate how this works.
eg parameters (1.0, 0.84, -0.04, -0.47, -1.0, -0.52, -0.12, 0.02, 0.0, 0.0) show 8 samples and the corresponding spectrum.
eg parameters (1.0, 0.84, -0.04, -0.47, -1.0, -0.52, -0.12, 0.02, 24.0, 0.0) show the signal sampled at 4 times the original sampling rate. This means that 3 zeros(red dots) have been added
between each pair of samples. The spectrum now goes between 0 and 4 times the original sampling frequency.
Unfortunately this has not helped because of the spectral lines
between
ws/2 and
4ws -
ws/2.
The next step is to use some form of interpolation to obtain
non zero values for the added samples. In this applet a simple
linear interpolation is used to illustrate what happens to the
spectrum as the added samples are interpolated. Linear interpolation assumes a straight line is drawn joining the top of the original samples, the interpolated samples are then increased so their tops lie along this line. To see this
increase Sg from 0.0 to 1.0. The undesired spectral lines are
reduced and the effect increases with Np(eg Np = 120 increases the sampling rate by 16).
Linear resampling is not normally used for practical systems. Instead the interpolated samples are usually obtained by using
a low pass filter.
The applet below attempts to illustrate the approach.
parameters (23, 0.026, NA, NA, NA, 0, 0.25, 10.0, NA, 0.4) show
a sinusoid, samples and spectra. The spectra is calculated using
the samples shown in cyan.
Changing Fn to 1 show the samples resampled at twice the original sampling frequency with 1 interpolated sample.
Changing Fn to 2 show the samples resampled at 4 times the original sampling frequency with 3 interpolated samples.
Changing Fn to 3 show what happens when the sequence with 1
interpolated sample is passed through a low pass filter with N
taps and cutoff frequency fc/fs. The impulse response of the
filter is in pink and the interpolated samples is shown by
the closer set of magenta samples. The undesired frequencies shown in blue are reduced.
Changing Fn to 4 and N to 77 show what happens when the sequence with
3 interpolated samples is passed through a low pass filter with 77 taps and cutoff frequency fc/fs = 0.25. The resampled sequence
now looks like a sinusoid and the undesired frequencies in blue are
attenuated. The DTFT spectrum of the sequence with interpolated samples after filtering is in green.
Return to main page
Return to page index
COPYRIGHT © 2007 Cuthbert Nyack.