Sounds Logical
home

WaveWarp 2.0 Example DrawingBoard

Index Current Example DrawingBoard Group Previous Example DrawingBoard Group Next Example DrawingBoard Group Previous Example DrawingBoard Next Example DrawingBoard Bottom of Page

Description | Components Used

AliasingAndImagingEducationalExample1

Description
Aliasing and Imaging Educational Example 1 Illustrates the classic phenomenon of "aliasing" associated with digital sampling. Aliasing is most often discussed in the context of digitisation of analog signals, whereby if the analog material contains spectral content above half of the sample rate (i.e the Nyquist rate), then there will be unwanted "aliased" artefacts appearing as "noise" within the bandwidth of the digitised signal. However, exactly the same thing can happen when an already-digitised signal is re-sampled to a lower sampling rate. This is the phenomenon illustrated in this DrawingBoard. Open the Parameter Window of the upper Spectrum Analyser and start the DrawingBoard. A spike will appear in the display at approximately 8268 Hz, and will be audible as a pure tone. Now open the Parameter Window of the Sine Wave Generator and note that the frequency selected is 13654 Hz. The observed tone at 8268 Hz is not present in the original signal, and is introduced precisely because of "aliasing" caused by down-sampling of the 13654 Hz signal by a factor of 2 ( via the Simple Down:2 block). The explanation is as follows: the original signal of 13654 Hz from the Sine Wave Generator is sampled at 44100 Hz and is thus within the corresponding bandwidth of 22050 Hz (i.e. the original Nyquist rate). However, when down-sampled by a factor of 2, the new bandwidth (Nyquist rate) is 11025 Hz. The original signal of 13654 Hz is thus outside the bandwidth of the down-sampled audio stream -- i.e. it can not be represented. Instead, the original signal is "aliased" by the down-sampling, and creates undesirable artefacts, i.e. the 8268 Hz signal which lies within the bandwidth of the down-sampled audio stream. The only way to avoid aliasing is to filter out all those frequencies above the new Nyquist rate, before carrying out the down-sampling. This process, commonly referred to as "anti-aliasing filtering", is built in to WaveWarp's Nyquist Decimating Down:2 block which, in essence, performs half-band FIR low-pass filtering (i.e. with an edge frequency at half of the original Nyquist rate) followed by the down-sampling by a factor of 2. To observe the effect of the anti-aliasing filter, open the Parameter Window of the lower Spectrum Analyser and start the DrawingBoard. You will notice that the aliased spike at 8268 Hz has been drastically reduced. In fact, if you connect the output of the Nyquist Decimating Down:2 block to the soundcard, you will not be able to hear the aliased tone, such is the power of the filtering ! Although this example used a pure tone as a test signal in order to clearly demonstrate the aliasing phenomenon, aliasing occurs with all digital audio signals (e.g. music) whenever the signal contains frequencies above the Nyquist rate corresponding to the down-sampled sample rate. The undesirable the audio artefacts will always occur, though the extent to which they are perceived can depend on the material itself. In any case, it is generally recommended to perform anit-alias filtering whenever the material is down-sampled. To this end, WaveWarp has a wide range of anti-aliasing down-samplers (and anti-imaging up-samplers) allowing total flexibility in on-the-fly sample rate conversion by any integer factor. Furthermore, some of these (such as the Nyquist Decimator shown here) are implemented in the highly-efficient polyphase structure (a neat trick whereby the anti-alias filtering is actually implemented as a multiple branch filter bank which runs at the low rate after the down-sampling). You can also build your own down-(and -up)-samplers from scratch using WaveWarp's wide range of Digital Filter components in combination with the simple down - (and -up)-samplers. You can even build parallel branch filter banks and create polyphase re-samplers from scratch ! Finally, if you want to use your own filters, you may import them easily into WaveWarp (and routines are provided for import/export to MATLAB).
Components used:

Index Current Example DrawingBoard Group Previous Example DrawingBoard Group Next Example DrawingBoard Group Previous Example DrawingBoard Next Example DrawingBoard Top of Page

home - news - products - store - support - site map - company info
© 2007 Sounds Logical. All rights reserved.
Sounds Logical
legal notice - privacy statement