# Does upsampling require a low-pass filter?

I am currently wondering about the frequency spectrum when performing upsampling using linear interpolation. As far as I know, linear interpolation corresponds to a $$\text{sinc}^2$$ function. If I apply a low-pass filter up to the Nyquist frequency before multiplying this filtered signal with the spectrum of linear interpolation, do I need to filter the signal again to reconstruct it? Can interpolation introduce aliasing?

Lets say I have a bandpass signal up to $$0.1f_s$$ and I do linear Interpolation with a rate of $$8$$ (insert $$7$$ linear interpolated points between two samples). I would assume the spectrum will be repeated by fs and smeared by the form of $$\text{sinc}^2$$.

Is the spectrum also shrunk with zero insertion? What is the lowpass filter cutoff that follows this system?

If you're linearly interpolating, there is that $$\operatorname{sinc}^2 \left( \frac{f}{f_\mathrm{s}} \right)$$ filtering, this puts zeros exactly on all non-zero integer multiples of your sample rate (where the images go). That kills a lot of your images, at least at low frequencies (that are close to $$k \cdot f_\mathrm{s}$$). Perhaps you might want to LPF to remove high frequency components that will image at frequencies distance away from these zeros.

But you'll lose content. You might want to consider doing a simple polyphase resampling, but if you wanna do it with linear interpolation, that works well in many cases.

Can interpolation introduce aliasing?

Crappy interpolation can. Aliasing can happen during resampling if those images aren't well attenuated.

This is a paper that Duane Wise and I wrote about polynomial interpolation about a quarter century ago. Linear interpolation is 1st-order polynomial interpolation. The more that you're oversampled (that is the lower the ratio of content bandwidth to Nyquist frequency), the better that linear interpolation will sound.

But you might very well want to low-pass filter a little before the linear interpolation. And in doing so, you can compensate for some of the rolloff that naturally comes from linear interpolation. I'll try to post up a figure showing this later.

• Thank you to the answer. I have following questions: -Is in my case aliasing produced because we are resampling at a frequency less than double the nyquist frequency? -Do you mean by sample rate the original one or the sample rate after resampling (samples+resamples)
– hajo
Commented Dec 4, 2023 at 23:56
• The aliasing happens because the images (images are not the same as aliases) are not completely killed by the implied LPF that occurs when your interpolating. What survives of those images can then fold back into your baseband whenever the resampling frequency is different than the original sample rate. It doesn't matter whether the resampling frequency is little greater or a little less than the original. It's because it's different and that your images are not completely dead zero. Commented Dec 5, 2023 at 0:11
• I am thinking of how my spectrum will look like after all. Sampling my bandpass signal with fs will replicate the image of the spectrum every k*fs. Now I am trying to interpolate the values between the samples which will lead the spectrum to a multiplication with sinc^2(f/fs) creating zeros of my replicated image.
– hajo
Commented Dec 5, 2023 at 11:27
• The $\operatorname{sinc}^2 \left( \frac{f}{f_\mathrm{s}} \right)$ will cause some rolloff in the high end. Now, if you want to compensate for that with a little boost in your pre-LPF before it cuts off, that might be good. For a biquad LPF it's a $Q > \sqrt{\frac12}$ that will put a little bump up there. But your main problem might become aliasing if there is content in your original signal that is close to Nyquist. That content will alias. The rolloff of linear interpolation is down by -7.8448 dB at Nyquist. Commented Dec 5, 2023 at 13:33