# A signal sampling related doubt

1. Mar 3, 2013

### dexterdev

Hi PF,
I have a signal which is sum of 2 sinusoids having frequencies 6KHz and 12KHz. Now if I sample it at a rate of 16KHz and pass it through a ideal Low pass filter having 16KHz cutoff frequency, what is the signal I obtain. What frequency contents does it have. Please help me visualize in frequency domain using comb.

-Devanand T

2. Mar 4, 2013

### milesyoung

A magnitude plot of the spectrum of your signal will show sinusoids at +-6 kHz and +-12 kHz (usually pictured as vertical lines).

Passing this signal through the ideal sampler will replicate its spectrum at integer multiples of your sampling frequency - maybe try to make a quick sketch of this. The 6 kHz and 12 kHz sinusoids will thus fold down and produce aliases at +-10 kHz and +-4 kHz, respectively, and your brick-wall low pass filter will cut off anything above/below +-16 kHz.

The resulting signal will thus have components at +- 4, 6, 10 and 12 kHz.

3. Mar 4, 2013

### AlephZero

Either this is a "trick" question about the Nyquist frequency and aliasing, or there are some typos in your question.

4. Mar 4, 2013

### milesyoung

I don't see the confusion. Using a brick-wall low-pass filter at 16 kHz for reconstructing the signal from its samples is perfectly valid.

5. Mar 4, 2013

### dexterdev

thanks milesyoung

6. Mar 4, 2013

### dexterdev

this is just a competitive exam question from India.

7. Mar 4, 2013

### skeptic2

This is an interesting problem especially if we change a few parameters. First let's specify the two signals are in phase such the the maxima of the 12 kHz signal coincide with the maxima and minima of the 6 kHz signal and that the sample time is 12 kHz and coincides with the maxima of the 12 kHz signal. Now with a Fourier Transform we can reconstruct both signals even though the sampling frequency is below the Nyquist limit of the higher frequency.

8. Mar 4, 2013

### AlephZero

What (if anything) do you think a low pass filter with a cut-off frequency of 16 KHz will do, after you have already sampled the data with a Nyquist frequency of 8 kHz??

The specification of the filter makes no sense, unless you are supposed to guess that you convert the signal back to analog or re-sample it at a higher rate before you filter it.

9. Mar 4, 2013

### marcusl

This makes no sense. If you specify the signals as you did, then they are already known exactly and you don't need an FT. If you don't know what they are, then you are lost: The 12 kHz signal aliases to 0 (DC). The 6 kHz signal, because it is at exactly 1/2 the sampling frequency, is ambiguous--you can't tell if it is at 6 kHz or 0. There's no chance of correctly identifying what you have.

10. Mar 4, 2013

### milesyoung

Are you somehow under the impression that the low-pass filter is there as an anti-aliasing filter? In that case, of course it's absurd to place it _after_ sampling with a cutoff frequency that high.

The low-pass filter is there as an ideal signal reconstruction device. A zero-order hold usually takes its place in practical systems.

11. Mar 5, 2013

### rbj

the question does strictly speaking make sense. it's just that the sampling setup does not. there is no difference between sampling the 12 kHz sinusoid at $f_s$ = 16 kHz is the same as sampling a 4 kHz sinusoid. that's why they call it an "alias".

so, if you filter with cutoff of 16 kHz, what you will see are components at 4 kHz and 6 kHz as well as 10 kHz and 12 kHz (and at their negatives).

12. Mar 5, 2013

### rbj

it could be an anti-imaging filter, but the sampling rate is still 1/2 of what it should be.

oh, there certainly could be an additional LPF after the ZOH, to smooth it out a little. BTW, the ZOH is inherent to the D/A converter. you don't really replace anything with a device called a "ZOH". it's just there.

13. Mar 5, 2013

### milesyoung

The OP's question is a classic example that asks you to consider the effect of sampling a signal below its Nyquist rate. It makes perfect sense and there's no ambiguity.

Yes, it's a anti-imaging filter (a reconstruction filter). The sampling frequency doesn't have to be any value in particular - the OP isn't asking what sampling frequency to choose in order to avoid aliasing.

Did I say there couldn't?

I'm well aware of that, but I haven't said anything with regards to the actual implementation of the filters - I have only included descriptions of mathematical models in my posts, i.e. the DAC is usually modeled as a ZOH.

14. Mar 5, 2013

### sophiecentaur

If you sample a 12kHz signal at 16kHz, no amount of filtering will remove the aliasing (except a notch filter at 4kHz).

15. Mar 6, 2013

### milesyoung

Again, the OP isn't asking how to avoid aliasing, i.e. the purpose is not to reconstruct the original signal. If he/she wants to bandlimit the signal to 16 kHz then that's perfectly valid.

16. Mar 6, 2013

### AlephZero

But in the real world, "wanting to bandlinit a signal to 16kHz" when it is already bandlinited to 8KHz is nonsensical. It should also be nonsensical in the world of "competetive exam questions", IMO.

There's nothing nonsensical about the first part of the question (i.e. answering it requires an understanding of aliasing), but the filtering part is meaningless.

17. Mar 6, 2013

### milesyoung

The sampled signal is certainly not bandlimited - the star transform of the original signal replicates its spectrum at integer multiples of the sampling frequency.

18. Mar 6, 2013

### sophiecentaur

If this thread is really the result of a test question then the setter should be shot. You can set up 'nonsense' scenarios, informally in class and make sure they are resolved properly before people go away but if this question was set merely to show that oversampling is dangerous then it was worded wrongly and can only confuse and worry the poor students.
If it had been worded "Why wouldn't the following system work? etc. etc." then no one would be looking for a reason for it to work and then they'd stand a chance..

19. Mar 6, 2013

### milesyoung

I guess I just don't see what it is about this question that rubs people the wrong way. There's no denying that this is a terrible setup if you want to avoid aliasing, but I don't see that as part of the question.

As a test question, I don't think its uncommon to make the student include only the first few aliases. If the low-pass filter wasn't included after sampling, the signal wouldn't be bandlimited.

20. Mar 6, 2013

### rbj

i thought it was a clear question of what may not have been intended. but it had a clear answer. it had 4, 6, 10, and 12 kHz in the output. might not have been what the original questioner expected.