# Which antialiasing filter before equispaced sampling

I am using MIT-BIH arrhythmical database where I have a digital signal of 1200 Hz so 1200 samples per second. This means that analog filters have already applied to remove the frequencies over Nyquist frequency, so no aliasing.

However, I want to take equispaced sampling, every two sample, simply by the following in Matlab

data([0:2:1200]);


I am reading Andre Quinquils' book Digital Signal Processing Using Matlab 2008:

It is always necessary to use an anti-aliasing filter before the sampling stage in order to avoid any spectral aliasing risk and to set an appropriate sampling frequency. In practice, a causal approximation of this ideal filter is used. Thus, depending on the chosen filter synthesis method, some imperfections are introduced, such as a passband amplitude ripple, a transition band and a stopband finite attenuation.

Does this mean that I need to apply a new anti-aliasing filter before the sampling stage in oder to avoid aliasing? I think the sampling stage here is the equalspaced sampling. I have not applied any new special anti-aliasing filter.

Which antialiasing filter can you use before equalspaced sampling stage?

• In reality, the sampling frequency is 360Hz in the database and Nyquist frequncy is 180Hz. Here, I used for some reason 1200 Hz as an example. – Léo Léopold Hertz 준영 Dec 16 '13 at 9:32

Yes, you have to apply another filter before downsampling in order to avoid aliasing. Your original signal has been acquired with a sampling rate $f_\mathrm{s} = 1.2\,\text{kHz}$. Taking every second sample effectively means that you divide the sampling rate by two, so your new sampling rate $f_\mathrm{s}'= f_\mathrm{s}/2 = 600\, \text{Hz}$. To avoid aliasing you have to make sure that the signal contains no frequencies above $f_\mathrm{s}'/2 = 300\, \text{Hz}$ before you apply the downsampling. If it is certain that your signal does not contain any frequencies above $f_\mathrm{s}'/2$ then you don't need a filter.
• If the analog filter has a cut-off frequency of $f_\mathrm{s}'/2$ you do not need an additional digital filter before downsampling. If its cut-off frequency is $f_\mathrm{s}/2$, you generally do need a digital filter before downsampling. – Deve Dec 16 '13 at 10:01