Sampling - HW7: Difference between revisions

From Class Wiki
Jump to navigation Jump to search
mNo edit summary
No edit summary
 
Line 8: Line 8:


<b>Solution</b><br>
<b>Solution</b><br>
For frequency components <math> \frac{f_s}{2}<f<f_s\!</math>, our sampled signal <math> x(t)\!</math> in the frequency domain, or <math> X(f)\!</math>, is going to look like this.<br>
For frequency components <math> \frac{f_s}{2}<f<f_s\!</math>, our sampled signal <math> x(t)\!</math> in the frequency domain, or <math> X(f)\!</math>, is going to look like this.<br><br>
[[Image:Sampling1a.jpg]]<br><br>
[[Image:Sampling1a.jpg]]<br><br>
After sampling with frequency <math> f_s\!</math>, the signal is going to be shifted over by <math> \frac{1}{T}\!</math>, since <math> f_s = \frac{1}{T}\!</math>. It will look like this.<br>
After sampling with frequency <math> f_s\!</math>, the signal is going to be shifted over by <math> \frac{1}{T}\!</math>, since <math> f_s = \frac{1}{T}\!</math>. It will look like this.<br><br>
[[Image:Sampling2.jpg]]<br><br>
[[Image:Sampling2.jpg]]<br><br>
To recover the original signal <math> x(t)\!</math>, we need to a use bandpass filter to filter out the parts we don't want, as indicated by the red line in the figure below. <i>(Note: not to scale.)</i><br>
To recover the original signal <math> x(t)\!</math>, we need to a use bandpass filter to filter out the parts we don't want, as indicated by the red line in the figure below. <i>(Note: not to scale.)</i><br><br>
[[Image:Sampling3.jpg]]<br><br>
[[Image:Sampling3.jpg]]<br><br>
This leaves us with the original signal, as shown below.<br>
This leaves us with the original signal, as shown below.<br><br>
[[Image:Sampling1a.jpg]]<br><br>
[[Image:Sampling1a.jpg]]<br><br>
The transfer function of the bandpass filter that will accomplish this for us is <math>H(f)=\begin{cases} T, & \mbox{ } \frac{1}{2T}<|f|< \frac{1}{T} \\ 0, & \mbox{ else } \end{cases}\!</math><br><br>
The transfer function of the bandpass filter that will accomplish this for us is <math>H(f)=\begin{cases} T, & \mbox{ } \frac{1}{2T}<|f|< \frac{1}{T} \\ 0, & \mbox{ else } \end{cases}\!</math><br><br>
Line 25: Line 25:
Also recall <math> sinc(\theta) = \frac{sin(\pi \theta)}{\pi \theta}\!</math>, so <br><br>
Also recall <math> sinc(\theta) = \frac{sin(\pi \theta)}{\pi \theta}\!</math>, so <br><br>
<math> h(t) = \frac{2sin \Big(\frac{2 \pi t}{T} \Big)}{\frac{2 \pi t}{T}} \ - \ \frac{sin \Big(\frac{ \pi t}{T} \Big)}{\frac{ \pi t}{T}} = 2sinc \Bigg(\frac{2t}{T} \Bigg) - sinc \Bigg(\frac{t}{T} \Bigg)\!</math><br><br>
<math> h(t) = \frac{2sin \Big(\frac{2 \pi t}{T} \Big)}{\frac{2 \pi t}{T}} \ - \ \frac{sin \Big(\frac{ \pi t}{T} \Big)}{\frac{ \pi t}{T}} = 2sinc \Bigg(\frac{2t}{T} \Bigg) - sinc \Bigg(\frac{t}{T} \Bigg)\!</math><br><br>
Now that we know <math> h(t) \!</math>, we can find <math> x(t) \!</math> by convolving the function for <math> x(t) \!</math> after sampling with <math> h(t) \!</math>.<br><br>
Now that we know <math> h(t) \!</math>, we can find <math> x(t) \!</math> by convolving the function for <math> x(t) \!</math> after sampling, or <math> \sum_{n=-\infty}^\infty x(nT)\delta(t-nT) \!</math>, with <math> h(t) \!</math>.<br><br>
<math> x(t) = \sum_{n=-\infty}^\infty x(nT)\delta(t-nT) * \Bigg[2sinc \Bigg(\frac{2t}{T} \Bigg) - sinc \Bigg(\frac{t}{T} \Bigg)\Bigg] = \sum_{n=-\infty}^\infty x(nT)\Bigg[2sinc \Bigg(\frac{2(t-nT)}{T} \Bigg) \ - \ sinc \Bigg(\frac{t-nT}{T} \Bigg)\Bigg]\!</math><br><br>
<math> x(t) = \sum_{n=-\infty}^\infty x(nT)\delta(t-nT) * \Bigg[2sinc \Bigg(\frac{2t}{T} \Bigg) - sinc \Bigg(\frac{t}{T} \Bigg)\Bigg] = \sum_{n=-\infty}^\infty x(nT)\Bigg[2sinc \Bigg(\frac{2(t-nT)}{T} \Bigg) \ - \ sinc \Bigg(\frac{t-nT}{T} \Bigg)\Bigg]\!</math><br><br>
Or, if you prefer, <math> x(t) = \sum_{n=-\infty}^\infty x(nT)\Bigg[\frac{2sin\Big(\frac{2\pi (t-nT)}{T}\Big)}{\frac{2\pi (t-nT)}{T}} \ - \ \frac{sin\Big(\frac{\pi (t-nT)}{T}\Big)}{\frac{\pi (t-nT)}{T}}\Bigg]
Or, if you prefer, <math> x(t) = \sum_{n=-\infty}^\infty x(nT)\Bigg[\frac{2sin\Big(\frac{2\pi (t-nT)}{T}\Big)}{\frac{2\pi (t-nT)}{T}} \ - \ \frac{sin\Big(\frac{\pi (t-nT)}{T}\Big)}{\frac{\pi (t-nT)}{T}}\Bigg]\!</math><br><br>

Alternatively, a different bandpass filter can be used that will simplify the math we have to do, such as the one indicated by the red line in the figure below. <i>(Note: not to scale.)</i><br><br>
[[Image:Sampling4.jpg]]<br><br>
Leaving us with the signal shown below.<br><br>
[[Image:Sampling5.jpg]]<br><br>
The transfer function of this bandpass filter is <math>H(f)=\begin{cases} T, & \mbox{ } |f|< \frac{1}{2T} \\ 0, & \mbox{ else } \end{cases}\!</math><br><br>
To find the expression for <math> h(t)\!</math>, or the expression for the bandpass filter in the time domain, we can take the inverse Fourier transform of <math>H(f)\!</math>.<br><br>
<math> h(t) = \mathcal{F}^{-1}[H(f)] = \int_{-\frac{1}{2T}}^{\frac{1}{2T}}Te^{j2 \pi ft}df\ = \frac{Te^{j2 \pi ft}}{j2 \pi t} \Bigg|_{f=-\frac{1}{2T}}^{\frac{1}{2T}} = \frac{T}{j2}\Bigg[\frac{e^{j \pi t/T} - e^{-j \pi t/T}}{ \pi t}\Bigg]\!</math><br><br>
Recall again that <math> sin(\theta) = \frac{1}{j2}(e^{j\theta} - e^{-j\theta})\!</math>, so <br><br>
<math> h(t) = \frac{T}{j2}\Bigg[\frac{e^{j \pi t/T} - e^{-j \pi t/T}}{ \pi t}\Bigg] = \frac{T}{ \pi t}sin \Bigg(\frac{ \pi t}{T} \Bigg) \ = \frac{sin \Big(\frac{ \pi t}{T} \Big)}{\frac{ \pi t}{T}} \!</math><br><br>
Also recall again that <math> sinc(\theta) = \frac{sin(\pi \theta)}{\pi \theta}\!</math>, so <br><br>
<math> h(t) = \frac{sin \Big(\frac{ \pi t}{T} \bigg)}{\frac{ \pi t}{T}} = sinc \bigg(\frac{t}{T} \bigg) \!</math><br><br>
Now that we know <math> h(t) \!</math>, we can find <math> x(t) \!</math> by convolving the function for <math> x(t) \!</math> after sampling, or <math> \sum_{n=-\infty}^\infty x(nT)\delta(t-nT) \!</math>, with <math> h(t) \!</math>.<br><br>

<math> x(t) = \sum_{n=-\infty}^\infty x(nT)\delta(t-nT) * \Bigg[sinc \bigg(\frac{t}{T} \bigg)\Bigg] = \sum_{n=-\infty}^\infty x(nT)(sinc \Bigg(\frac{t-nT}{T} \Bigg)\!</math><br><br>
Or, if you prefer, <math> x(t) = \sum_{n=-\infty}^\infty x(nT)\Bigg[\frac{sin\Big(\frac{\pi (t-nT)}{T}\Big)}{\frac{\pi (t-nT)}{T}}\Bigg]\!</math><br><br>

Latest revision as of 20:42, 1 December 2009

Max Woesner

Back to my Home Page

Homework #7 - Sampling


Problem Statement
Figure out what happens if your sampled signal, , has frequency components only for . Can you recover the original signal from it? If so, find the expression for in terms of .

Solution
For frequency components , our sampled signal in the frequency domain, or , is going to look like this.

Sampling1a.jpg

After sampling with frequency , the signal is going to be shifted over by , since . It will look like this.

Sampling2.jpg

To recover the original signal , we need to a use bandpass filter to filter out the parts we don't want, as indicated by the red line in the figure below. (Note: not to scale.)

Sampling3.jpg

This leaves us with the original signal, as shown below.

Sampling1a.jpg

The transfer function of the bandpass filter that will accomplish this for us is

To find the expression for , or the expression for the bandpass filter in the time domain, we can take the inverse Fourier transform of .







Recall , so



Also recall , so



Now that we know , we can find by convolving the function for after sampling, or , with .



Or, if you prefer,

Alternatively, a different bandpass filter can be used that will simplify the math we have to do, such as the one indicated by the red line in the figure below. (Note: not to scale.)

Sampling4.jpg

Leaving us with the signal shown below.

Sampling5.jpg

The transfer function of this bandpass filter is

To find the expression for , or the expression for the bandpass filter in the time domain, we can take the inverse Fourier transform of .



Recall again that , so



Also recall again that , so



Now that we know , we can find by convolving the function for after sampling, or , with .



Or, if you prefer,