There’s a classic technique you need to be aware of when working with the Discrete Fourier Transform, and it’s called Zero-Padding.1 As it turns out, it’s possible to interpolate or “fill-in” the output of the DFT by simply appending zeroes to the end of your input signal. Appending zeroes to the end of your signal doesn’t alter the frequency content of your signal in any undue way, it merely interpolates the output spectrum. You can experiment with zero-padding in Figure 1. Drag the slider at the bottom of the figure to the right to append more zeroes to the end of the input signal.

Figure 1.  Zero Padding the Input Interpolates the Output Spectrum

You might be surprised to see little mountains and valleys appear in the DFT output as you begin to zero-pad the signal. We’ll devote the entire next section to understanding this phenomenon. For now, let’s move onto a subtle point about zero-padding which can confuse and confound.

1. You’ll often need to perform this sort of zero-padding to ensure that the input you provide to a FFT (Fast Fourier Transform) routine has a length which is equal to a power of two.


It’s really important to understand that zero-padding does not actually increase the output resolution of the Discrete Fourier Transform. Zero-padding does not add any useful information to our signal. Let’s recall the example from the previous section where we attempted to distinguish between two sinusoidal components which were close in frequency. We were able to accomplish this feat by simply increasing the number of input samples which were fed into the DFT. You might be tempted to think that we can do the same thing using zero-padding. After all, zero-padding does increase the number of input samples, which in turn increases the number of bins in our DFT output.

Figure 2 allows you to apply zero-padding to eight samples of our input signal from the last section. You’ll notice that the zero-padding process does not actually increase the resolution of our DFT output. It doesn’t help us pinpoint, identify, or distinguish between the two sinusoids hidden within the signal. In some sense, this shouldn’t be too terribly surprising. Always remember that you’re not actually adding any additional information to the signal by appending zeroes at the end.

Figure 2.  Zero Padding Does Not Improve DFT Resolution!