# What will be the filtered output?

I tried to solve this question from basic

Here is my work

Image 1

Image 2

But the correct answer is Option $(B)$.What is the mistake i am doing?

• If you sample a signal at a rate of 100 Hz and it has a rate of 150 Hz, you should expect to deal with aliasing. Have you considered this? – hops Oct 2 '17 at 19:24
• @hops can you please help me how to deal with that..I have shown what i know...but not getting how alisaing effecting it.. – Rohit Oct 3 '17 at 3:04

First note that: $$\cos(2\pi 50 t) \longleftrightarrow 0.5 \delta(f+50) + 0.5\delta(f-50)$$

$$\sin(2\pi 150 t) \longleftrightarrow 0.5 j \delta(f+150) -j 0.5\delta(f-150)$$

Hence the baseband spectrum is: $$X(f) = 0.5 j \delta(f+150) + 0.5 \delta(f+50) + 0.5 \delta(f-50) - 0.5 j\delta(f-150)$$

Then a shift to right by 100 Hz yields (without sampling weight): $$X(f-100) = 0.5\left[j \delta(f+50) +\delta(f-50) + \delta(f-150) - j\delta(f-250) \right]$$

Shift left by 100 Hz: $$X(f+100) = 0.5\left[ j\delta(f+250) +\delta(f+150) + \delta(f+50) - j\delta(f-50) \right]$$

Shift right by 200 Hz: $$X(f-200) = 0.5\left[ j \delta(f-50) +\delta(f-150) + \delta(f-250) - j\delta(f-350) \right]$$

Shift left by 200 Hz: $$X(f+200) = 0.5\left[ j\delta(f+350) +\delta(f+250) + \delta(f+150) - j\delta(f+50) \right]$$

The sum of all the shifts for $n=0,\pm 1,\pm2$ : $$X_s(f) = 0.5\left[ j\delta(f+350) +\delta(f+250) + \delta(f+150) - j\delta(f+50) + j\delta(f+250) +\delta(f+150) + \delta(f+50) - j\delta(f-50) + j \delta(f+150) +\delta(f+50) + \delta(f-50) - j\delta(f-150) + j \delta(f+50) +\delta(f-50) + \delta(f-150) - j\delta(f-250) + j \delta(f-50) +\delta(f-150) + \delta(f-250) - j\delta(f-350) \right]$$

After the 100 Hz lowpass filter only those impulses inside $-100<f<100$ band remain: $$LPF\{ X_s(f) \} = 0.5\left[ - j\delta(f+50) + \delta(f+50) - j\delta(f-50) + \delta(f+50) + \delta(f-50) + j \delta(f+50) +\delta(f-50) + j \delta(f-50) \right]$$

Which can be further simplied into: $$LPF\{ X_s(f) \} = \delta(f+50) + \delta(f-50)$$

Hence we arrive (without sampling weight) $$\boxed{ z(t) = 2\cos(2 \pi 50 t)}$$

Therefore we can conclude that the output of the LPF will be proportional to $\cos(2\pi 50 t)$.

• sir in the fourier tranfrom formula there is $X(f-n100)$...so why did you shift the signal only taking $n=1$ and n=-1? – Rohit Oct 3 '17 at 2:13
• sir what is wrong in my solution? in my solution i am not getting outside 100Hz..i considered all the frequency that came inside the 100Hz...please see my solution once....you can see there if i take n=2 then i will get two impulse that came inside 100Hz...and then its cancelling the other two impulse that came earlier...that i shown in third figure of impulse that i cross marked... – Rohit Oct 3 '17 at 9:38
• Or do you mean i can't do this if it has sinusoidal signals? – Rohit Oct 3 '17 at 9:41
• sir i have a simple doubt why did't you take $X(f-200)$ and $X(f+200)$ at n=2 and n=-2 and shifted the signal? if you do like this then also you will get two impulse at frequency 50Hz thats comes under 100Hz...how can you ignore that? – Rohit Oct 3 '17 at 9:59
• Because all the impulses of $X(f-200)$ will be located outside of 100 Hz. Consider $X(f-100) = j\delta(f+50) + \delta(f-50) + \delta(f-150)-j\delta(f-150)$ then $X(f-200) = j\delta(f-50) + \delta(f-150) + \delta(f-250)-j\delta(f-250)$ O you are right! there is a component at $f=50$ due to $X(f-200)$ so will there be due to $X(f+200)$ let's adjust the answer accordingly. – Fat32 Oct 3 '17 at 10:04

I thought I would add a few interesting thoughts I had while looking at this. I believe the answer is (A) and whoever told you the answer is (B) failed to consider the aliasing components resulting from the negative frequencies.

In addition to the very nice answer by Fat32 that involves taking things to the frequency domain and back. There is one very simple way to see that it must be (A) using only a time domain approach. If $t$ were discrete-valued, then the answers (A), (B), and (C) could all be seen as correct thanks to the ambiguity found in signals at the highest frequency representable. However, the low pass filter will remove the discrete nature of the samples (assuming it is an analog low pass filter anyway), and this makes the $\sin(\cdot)$ term incorrect.

To see this, consider your original signal $x(t) = \cos(2 \pi 50 t) + \sin(2 \pi 150 t)$ sampled with the impulse train provided at a rate of $100$Hz. This can be written as a discrete-valued signal where $t=n/f_s$ and $f_s=100$Hz, $$x\left(\frac{n}{100}\right) = \cos\left(\pi n\right) + \sin\left(\pi n\right).$$ Now, after you realize that $\sin(\pi n) = 0$, you will also realize that this could be written as $$x\left(\frac{n}{100}\right) = \cos\left(\pi n\right).$$ For that matter, it could have been written as $$x\left(\frac{n}{100}\right) = \cos\left(\pi n\right) - \sin\left(\pi n\right).$$ Now, passing these samples through an appropriate low pass filter with a cutoff of $100$Hz will yield (A) since it only contains information about the $\cos(\cdot)$ (since the $\sin(\cdot)$ terms are zero).

This happened because both the aliased components and the original $50$Hz cosine violate Nyquist. The Nyquist Theorem says that we will have no loss of information if the sampling rate is strictly greater than twice the highest frequency in our signal. Here, we have it at exactly twice the highest frequency that we are trying to represent (after aliasing). This leads to a phase/amplitude ambiguity in that frequency, and in this case it cancels out the effects of the $\sin(\cdot)$ terms completely.

• Thanks for the answer...thats a nice method to check....will this work in other problems of sampling too ? – Rohit Oct 3 '17 at 16:55
• Yes, but in general it won't be so simple. Problems involving sines and cosines work out nicely this way. – hops Oct 3 '17 at 17:00