(11 intermediate revisions by the same user not shown) | |||
Line 6: | Line 6: | ||
a) | a) | ||
− | <math>y[n]= \frac{x[n]+x[n- | + | <math>y[n]= \frac{x[n]+x[n-2]}{2} </math> |
− | Applying Z-transform on both sides and grouping terms, we can obtain the transfer function | + | Applying Z-transform on both sides and grouping terms, we can obtain the transfer function |
<math>\begin{align} | <math>\begin{align} | ||
− | Y[z]&= \frac{X[z]+X[z] | + | Y[z]&= \frac{X[z]+X[z]z^{-2}}{2} \\ |
− | \frac{Y[z]}{X[z]}&= \frac{1+z^{- | + | \frac{Y[z]}{X[z]}&= \frac{1+z^{-2}}{2} \\ |
− | H[z] &= \frac{1+z^{- | + | H[z] &= \frac{1+z^{-2}}{2} \\ |
\end{align}</math> | \end{align}</math> | ||
Frequency Response <math>H(\omega)</math> | Frequency Response <math>H(\omega)</math> | ||
+ | |||
<math>\begin{align} | <math>\begin{align} | ||
− | H[e^{j\omega }] &= \frac{1+e^{- | + | H[e^{j\omega }] &= \frac{1+e^{-2j\omega }}{2} \\ |
− | &= e^{-j | + | &= e^{-j\omega } \left( \frac{e^{j\omega}+e^{-j\omega}}{2} \right) \\ |
− | &= e^{-j | + | &= e^{-j\omega } cos \left( \omega \right) \\ |
\end{align}</math> | \end{align}</math> | ||
+ | |||
+ | Zero-pole plot | ||
[[Image:HW6Q1fig1.jpg]] | [[Image:HW6Q1fig1.jpg]] | ||
+ | |||
+ | Frequency response | ||
+ | |||
+ | [[Image:HW6Q1fig2.jpg]] | ||
b) | b) | ||
Line 29: | Line 36: | ||
<math>y[n]= \frac{x[n]-x[n-1]}{2}</math> | <math>y[n]= \frac{x[n]-x[n-1]}{2}</math> | ||
− | Applying Z-transform on both sides and grouping terms, we can obtain the transfer function | + | Applying Z-transform on both sides and grouping terms, we can obtain the transfer function |
<math>\begin{align} | <math>\begin{align} | ||
− | Y[z]&= \frac{X[z]-X[z] | + | Y[z]&= \frac{X[z]-X[z]z^{-1}}{2} \\ |
\frac{Y_2[z]}{X[z]}&= \frac{1-z^{-1}}{2} \\ | \frac{Y_2[z]}{X[z]}&= \frac{1-z^{-1}}{2} \\ | ||
H[z] &= \frac{1-z^{-1}}{2} \\ | H[z] &= \frac{1-z^{-1}}{2} \\ | ||
Line 38: | Line 45: | ||
Frequency Response <math>H(\omega)</math> | Frequency Response <math>H(\omega)</math> | ||
+ | |||
<math>\begin{align} | <math>\begin{align} | ||
H[e^{j\omega }] &= \frac{1-e^{-j\omega }}{2} \\ | H[e^{j\omega }] &= \frac{1-e^{-j\omega }}{2} \\ | ||
Line 45: | Line 53: | ||
\end{align}</math> | \end{align}</math> | ||
− | [[Image: | + | Zero-pole plot |
+ | |||
+ | [[Image:HW6Q1fig3.jpg]] | ||
+ | |||
+ | Frequency response | ||
+ | |||
+ | [[Image:HW6Q1fig4.jpg]] | ||
+ | |||
---- | ---- | ||
==Question 2== | ==Question 2== | ||
+ | a. Substituting values directly would yield the following - <br> | ||
− | + | <math>\begin{align} | |
+ | n &= ...\text{ -3, -2, -1, 0, 1, 2, 3, 4, 5} ...\\ | ||
+ | y\left[n\right] &= ...\text{ 0, -2, -4, -1, 2, -1, -4, -2, 0} ...\\ | ||
+ | \end{align}</math> | ||
+ | b. h[n] = ? <br> Substitute x[n] = <span class="texhtml">δ[''n'']</span> to obtain y[n] = h[n], <br> h[n] = <span class="texhtml">δ[''n'']</span> + 2<span class="texhtml">δ[''n'' − 1]</span> + <span class="texhtml">δ[''n'' − 2]</span> <br> | ||
+ | |||
+ | Now x[n] = -2<span class="texhtml">δ[''n'' + 2]</span> + <span class="texhtml">δ[''n'']</span> - 2<span class="texhtml">δ[''n'' − 2]</span> <br> | ||
+ | |||
+ | <math>\begin{align} | ||
+ | y[n] &= x[n] * h[n] \\ | ||
+ | &= (-2\delta[n+2] + \delta[n] - 2\delta[n-2]) * (\delta[n] + 2\delta[n-1] + \delta[n-2]) \\ | ||
+ | &= -2\delta[n+2] - 4\delta[n+1] -2\delta[n] + \delta[n] + 2\delta[n-1] + \delta[n-2] - 2\delta[n-2] - 4\delta[n-3] - 2\delta[n-4] \\ | ||
+ | &= -2\delta[n+2] - 4\delta[n+1] - \delta[n] + 2\delta[n-1] - \delta[n-2] - 4\delta[n-3] - 2\delta[n-4] \\ | ||
+ | \end{align}</math> | ||
+ | |||
+ | c. x[n] = <span class="texhtml">''e''<sup>''j''ω''n''</sup></span> <br> (i) <br> <math>\begin{align} | ||
+ | y[n] &= e^{j\omega n} + 2 e^{j\omega (n-1)} + e^{j\omega (n-2)} \\ | ||
+ | &= e^{j\omega n}(1 + 2 e^{-j\omega } + e^{-2j\omega }) \\ | ||
+ | H(e^{j\omega}) &= 1 + 2 e^{-j\omega } + e^{-2j\omega } \\ | ||
+ | \end{align}</math> | ||
+ | |||
+ | (ii) <br> h[n] = <span class="texhtml">δ[''n'']</span> + 2<span class="texhtml">δ[''n'' − 1]</span> + <span class="texhtml">δ[''n'' − 2]</span> <br> H(<span class="texhtml">''e''<sup>''j''ω</sup></span>) = 1 + 2 <span class="texhtml">''e''<sup> − ''j''ω</sup></span> + <span class="texhtml">''e''<sup> − 2''j''ω</sup></span> <br> | ||
+ | |||
+ | (i) and (ii) are the same.<br> | ||
+ | |||
+ | d. x[n] = -2<span class="texhtml">δ[''n'' + 2]</span> + <span class="texhtml">δ[''n'']</span> - 2<span class="texhtml">δ[''n'' − 2]</span> <br> X(<span class="texhtml">''e''<sup>''j''ω</sup></span>) = -2 <span class="texhtml">''e''<sup>2''j''ω</sup></span> + 1 - 2<span class="texhtml">''e''<sup> − 2''j''ω</sup></span> <br> | ||
+ | |||
+ | <math>\begin{align} | ||
+ | Y(e^{j\omega}) &= X(e^{j\omega})H(e^{j\omega}) \\ | ||
+ | &= (-2e^{2j\omega } + 1 - 2e^{-2j\omega } ).(1 + 2e^{-j\omega } + e^{-2j\omega }) \\ | ||
+ | &= -2e^{2j\omega } - 4e^{j\omega } - 2 + 1 + 2e^{-j\omega } + 2e^{-2j\omega } - 2e^{-2j\omega } - 4e^{-3j\omega } - 2e^{-4j\omega } \\ | ||
+ | &= -2e^{2j\omega } - 4e^{j\omega } - 1 - 2e^{-j\omega } - e^{-2j\omega } - 4e^{-3j\omega } - 2e^{-4j\omega } \\ | ||
+ | \\ | ||
+ | \text{Using Inverse DTFT,} \\ | ||
+ | y[n] &= -2\delta[n+2] - 4\delta[n+1] - \delta[n] + 2\delta[n-1] - \delta[n-2] - 4\delta[n-3] - 2\delta[n-4] \\ | ||
+ | \end{align}</math> | ||
+ | |||
+ | All 3 approaches lead to the same y[n]. | ||
---- | ---- | ||
==Question 3== | ==Question 3== | ||
+ | a. Sketch the locations of the poles and zeros. | ||
+ | <math>\begin{align} | ||
+ | H(z) &= \frac{1-\frac{1}{2}z^{-2}}{1-\frac{1}{\sqrt{2}} z^{-1} +\frac{1}{4} z^{-2}} \\ | ||
+ | H(z) &= \frac{(z+\frac{1}{\sqrt{2}})(z-\frac{1}{\sqrt{2}})} | ||
+ | { (z-(\frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}))(z-(\frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}})) } \\ | ||
+ | \end{align}</math> | ||
+ | |||
+ | Zeros: <br> <math>z_1 = \frac{1}{\sqrt{2}}, z_2 = -\frac{1}{\sqrt{2}}</math><br> Poles: <br> <math>p_1 = \frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}, p_2 = \frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}}</math> | ||
+ | |||
+ | [[Image:Zp1.jpg]] | ||
+ | |||
+ | :b. Determine the magnitude and phase of the frequency response <span class="texhtml">''H''(ω)</span>, for | ||
+ | |||
+ | <math>\omega = 0</math> <br/> | ||
+ | [[Image:Zp2.jpg]] | ||
+ | <math> | ||
+ | \left| H(e^{j\omega}) \right| = \left| H(e^{j0}) \right| = \left| H(z=1) \right|</math><br> <math> = \left| \frac{(1+\frac{1}{\sqrt{2}})(1-\frac{1}{\sqrt{2}})} { (1-(\frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}))(1-(\frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}})) } \right| = 0.921</math><br> <math>\angle H(e^{j0}) = \angle c + \angle d - \angle a - \angle b = 0</math> | ||
+ | |||
+ | <br> <math>\omega =\frac{\pi}{4}</math><br> | ||
+ | [[Image:Zp3.JPG]] | ||
+ | <math> | ||
+ | \left| H(e^{j\omega}) \right| = \left| H(e^{j\frac{\pi}{4}}) \right| = \left| H(z=\frac{1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}) \right|</math><br> | ||
+ | <math> = \left| \frac{(\frac{1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}+\frac{1}{\sqrt{2}})(\frac{1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}-\frac{1}{\sqrt{2}})} { (\frac{1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}-(\frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}))(\frac{1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}-(\frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}})) } \right| = 2 | ||
+ | </math> | ||
+ | <br> | ||
+ | <math>\angle H(e^{j\frac{\pi}{4}}) = \angle c + \angle d - \angle a - \angle b = \frac{\pi}{2} + arctan^{-1} \left( \frac{\frac{1}{\sqrt{2}}}{\sqrt{2}} \right) - \frac{\pi}{4} - arctan^{-1} \left( \frac{\frac{1}{\sqrt{2}} + \frac{1}{2\sqrt{2}}}{1-\sqrt{2}-\frac{1}{2\sqrt{2}}} \right) = 0</math> | ||
+ | |||
+ | <math>\omega =\frac{\pi}{2}</math><br> [[Image:Zp4.jpg]] <math>\left| H(e^{j\omega}) \right| = \left| H(e^{j\frac{\pi}{2}}) \right| = \left| H(z=j) \right|</math><br> | ||
+ | |||
+ | <math> = \left| \frac{(j+\frac{1}{\sqrt{2}})(j-\frac{1}{\sqrt{2}})} { (j-(\frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}))(j-(\frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}})) } \right| = 1.455</math><br> | ||
+ | |||
+ | <br> | ||
+ | <math>\angle H(e^{j\frac{\pi}{2}}) = (\angle c + \angle d) - \angle a - \angle b = (\pi) - (arctan^{-1}\left( \frac{1-\frac{1}{2\sqrt{2}}}{\frac{-1}{\sqrt{2}}} \right) + \pi) - (arctan^{-1}\left( \frac{1+\frac{1}{2\sqrt{2}}}{1-\frac{1}{\sqrt{2}}} \right) + \pi) = -0.7563 | ||
+ | </math> | ||
+ | |||
+ | <math>\omega =\frac{3\pi}{4}</math><br/> | ||
+ | [[Image:Zp5.JPG]] | ||
+ | <math>\left| H(e^{j\omega}) \right| = \left| H(e^{j\frac{3\pi}{4}}) \right| = \left| H(z=\frac{-1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}) \right|</math><br> | ||
+ | |||
+ | <math> = \left| \frac{(\frac{-1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}+\frac{1}{\sqrt{2}})(\frac{-1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}-\frac{1}{\sqrt{2}})} { (\frac{-1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}-(\frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}))(\frac{-1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}-(\frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}})) } \right| = \frac{2}{3} | ||
+ | </math> | ||
+ | |||
+ | <math>\angle H(e^{j\frac{3\pi}{4}}) = \angle c + \angle d - \angle a - \angle b = (arctan^{-1}\left( \frac{\frac{1}{\sqrt{2}}}{\frac{-2}{\sqrt{2}}} \right) + \pi) + \frac{\pi}{2} - (arctan^{-1}\left( \frac{\frac{1}{\sqrt{2}} - \frac{1}{2\sqrt{2}}}{\frac{1}{\sqrt{2}} - \frac{1}{2\sqrt{2}}} \right) + \pi) + \frac{3\pi}{4} = -0.9273 | ||
+ | </math> | ||
+ | |||
+ | |||
+ | <math>\omega =\pi</math><br/> | ||
+ | [[Image:Zp6.JPG]] | ||
+ | <math> | ||
+ | \left| H(e^{j\omega}) \right| = \left| H(e^{j\pi}) \right| = \left| H(z=-1) \right|</math><br> | ||
+ | <math> = \left| \frac{(-1+\frac{1}{\sqrt{2}})(-1-\frac{1}{\sqrt{2}})} { (-1-(\frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}))(-1-(\frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}})) } \right| = 0.255 | ||
+ | </math><br> | ||
+ | |||
+ | <math>\angle H(e^{j\pi}) = (\angle c + \angle d) - \angle a - \angle b = 2\pi - 0 - 0 = 2\pi</math> | ||
+ | |||
+ | c. Is the system stable? Explain why or why not? <br/> | ||
+ | The system is causal and the ROC extends outwards from the outermost pole since |<math>p_1</math>| = |<math>p_2</math>| < 1 and this ROC contains the unit circle. Therefore the system is stable. <br/> | ||
+ | |||
+ | d. Find the difference equation for y[n] in terms of x[n], corresponding to this transfer function H(z). <br/> | ||
+ | |||
+ | <math>H(z) = \frac{Y(z)}{X(z)} = \frac{1-\frac{1}{2}z^{-2}}{1-\frac{1}{\sqrt{2}} z^{-1} +\frac{1}{4} z^{-2}}</math><br/> | ||
+ | <math>Y(z)(1-\frac{1}{\sqrt{2}} z^{-1} +\frac{1}{4} z^{-2}) = X(z)(1-\frac{1}{2}z^{-2})</math><br/> | ||
+ | |||
+ | Taking inverse,<br/> | ||
+ | <math>y[n]-\frac{1}{\sqrt{2}}y[n-1] + \frac{1}{4}y[n-2] = x[n] - \frac{1}{2}x[n-2]</math><br/> | ||
+ | <math>y[n] = x[n] - \frac{1}{2}x[n-2] +\frac{1}{\sqrt{2}}y[n-1] - \frac{1}{4}y[n-2]</math><br/> | ||
+ | <br> | ||
---- | ---- | ||
==Question 4== | ==Question 4== | ||
+ | <br/> | ||
+ | <math> | ||
+ | y[n]=\frac{1}{8} \left( x[n]+x[n-1]+x[n-2]+x[n-3]+x[n-4]+x[n-5]+x[n-6]+x[n-7]\right) | ||
+ | </math> | ||
+ | a.<br/> | ||
+ | <math> | ||
+ | h[n]=\frac{1}{8} \left( \delta[n]+\delta[n-1]+\delta[n-2]+\delta[n-3]+\delta[n-4]+\delta[n-5]+\delta[n-6]+\delta[n-7] \right) | ||
+ | </math> <br/> | ||
+ | This is a finite duration response.<br/> | ||
− | + | b. | |
+ | <math> | ||
+ | H[z]=\frac{1}{8} \left( 1+z^{-1}+z^{-2}+z^{-3}+z^{-4}+z^{-5}+z^{-6}+z^{-7} \right) | ||
+ | </math> <br/> | ||
+ | <math> | ||
+ | H[z]=\frac{1}{8} \left( \frac{1-z^{-8}}{1-z^{-1}} \right) | ||
+ | </math> <br/> | ||
+ | c. | ||
+ | |||
+ | <math> | ||
+ | H[z]=\frac{1}{8} \left( \frac{z^{8}-1}{z^{7}(z-1)} \right) | ||
+ | </math> <br/> | ||
+ | [[Image:Zp7.jpg]] | ||
+ | <br/> | ||
+ | Poles: <br/> | ||
+ | <math>p_1 = 1</math><br/> | ||
+ | <math>p_2 = p_3 = ... = p_8 = 0</math><br/> | ||
+ | |||
+ | Zeros: <br/> | ||
+ | <math>z^{8} - 1 = 0 </math><br/> | ||
+ | <math>z^{8} = e^{j2\pi } </math><br/> | ||
+ | |||
+ | Generalizing,<br/> | ||
+ | <math>z_k = e^{j2\pi k/8 }</math> for k = 0,1,2,...,7<br/> | ||
---- | ---- | ||
Line 70: | Line 222: | ||
==Question 5== | ==Question 5== | ||
+ | a. <br/> | ||
+ | <math> | ||
+ | y[n]= \frac{1}{8} \left( x[n]-x[n-8]+y[n-1] \right) | ||
+ | </math> | ||
+ | |||
+ | Using z-transform,<br/> | ||
+ | <math> | ||
+ | Y(z) = \frac{1}{8} \left( X(z)-X(z)z^{-8} + Y(z)z^{-1} \right) | ||
+ | </math><br/> | ||
+ | <math> | ||
+ | Y(z) (1 - \frac{1}{8}z^{-1}) = X(z) \frac{1}{8}(1 - z^{-8}) | ||
+ | </math><br/> | ||
+ | <math> | ||
+ | H(z) = \frac{Y(z)}{X(z)} = \frac{1}{8} \left( \frac{ 1 - z^{-8} } {1 - \frac{1}{8}z^{-1}} \right) | ||
+ | </math><br/> | ||
+ | b. | ||
+ | |||
+ | [[Image:HW6Q5fig1.jpg]] | ||
+ | |||
+ | c. | ||
+ | H(z) can be re-written as <br/> | ||
+ | <math> | ||
+ | H[z]=\frac{1}{8} \left( \frac{1}{1-\frac{1}{8}z^{-1}} - \frac{z^{-8}}{1-\frac{1}{8}z^{-1}} \right) | ||
+ | </math> <br/> | ||
+ | Assuming the ROC: <math>|z|>\frac{1}{8}</math>Taking inverse Z-transform of H(z) - <br/> | ||
+ | <math> | ||
+ | h[n]=\frac{1}{8} \left( (\frac{1}{8})^n u[n] - (\frac{1}{8})^{n-8} u[n-8] \right) | ||
+ | </math> <br/> | ||
+ | |||
+ | This is a infinite duration response.<br/> | ||
---- | ---- | ||
− | Back to [[ | + | Back to [[Hw6_ECE438F11|Homework 6]] |
Back to [[2011_Fall_ECE_438_Boutin|ECE 438 Fall 2011]] | Back to [[2011_Fall_ECE_438_Boutin|ECE 438 Fall 2011]] |
Latest revision as of 10:15, 30 October 2011
Contents
Homework 6, ECE438, Fall 2011, Prof. Boutin
Question 1
a)
$ y[n]= \frac{x[n]+x[n-2]}{2} $
Applying Z-transform on both sides and grouping terms, we can obtain the transfer function
$ \begin{align} Y[z]&= \frac{X[z]+X[z]z^{-2}}{2} \\ \frac{Y[z]}{X[z]}&= \frac{1+z^{-2}}{2} \\ H[z] &= \frac{1+z^{-2}}{2} \\ \end{align} $
Frequency Response $ H(\omega) $
$ \begin{align} H[e^{j\omega }] &= \frac{1+e^{-2j\omega }}{2} \\ &= e^{-j\omega } \left( \frac{e^{j\omega}+e^{-j\omega}}{2} \right) \\ &= e^{-j\omega } cos \left( \omega \right) \\ \end{align} $
Zero-pole plot
Frequency response
b)
$ y[n]= \frac{x[n]-x[n-1]}{2} $
Applying Z-transform on both sides and grouping terms, we can obtain the transfer function
$ \begin{align} Y[z]&= \frac{X[z]-X[z]z^{-1}}{2} \\ \frac{Y_2[z]}{X[z]}&= \frac{1-z^{-1}}{2} \\ H[z] &= \frac{1-z^{-1}}{2} \\ \end{align} $
Frequency Response $ H(\omega) $
$ \begin{align} H[e^{j\omega }] &= \frac{1-e^{-j\omega }}{2} \\ &= e^{-j\frac{\omega }{2}} \left( \frac{e^{j\frac{\omega }{2}}-e^{-j\frac{\omega }{2}}}{2} \right) \\ &= je^{-j\frac{\omega }{2}} \left( \frac{e^{j\frac{\omega }{2}}-e^{-j\frac{\omega }{2}}}{2j} \right) \\ &= je^{-j\frac{\omega }{2}} sin \left( \frac{\omega }{2} \right) \\ \end{align} $
Zero-pole plot
Frequency response
Question 2
a. Substituting values directly would yield the following -
$ \begin{align} n &= ...\text{ -3, -2, -1, 0, 1, 2, 3, 4, 5} ...\\ y\left[n\right] &= ...\text{ 0, -2, -4, -1, 2, -1, -4, -2, 0} ...\\ \end{align} $
b. h[n] = ?
Substitute x[n] = δ[n] to obtain y[n] = h[n],
h[n] = δ[n] + 2δ[n − 1] + δ[n − 2]
Now x[n] = -2δ[n + 2] + δ[n] - 2δ[n − 2]
$ \begin{align} y[n] &= x[n] * h[n] \\ &= (-2\delta[n+2] + \delta[n] - 2\delta[n-2]) * (\delta[n] + 2\delta[n-1] + \delta[n-2]) \\ &= -2\delta[n+2] - 4\delta[n+1] -2\delta[n] + \delta[n] + 2\delta[n-1] + \delta[n-2] - 2\delta[n-2] - 4\delta[n-3] - 2\delta[n-4] \\ &= -2\delta[n+2] - 4\delta[n+1] - \delta[n] + 2\delta[n-1] - \delta[n-2] - 4\delta[n-3] - 2\delta[n-4] \\ \end{align} $
c. x[n] = ejωn
(i)
$ \begin{align} y[n] &= e^{j\omega n} + 2 e^{j\omega (n-1)} + e^{j\omega (n-2)} \\ &= e^{j\omega n}(1 + 2 e^{-j\omega } + e^{-2j\omega }) \\ H(e^{j\omega}) &= 1 + 2 e^{-j\omega } + e^{-2j\omega } \\ \end{align} $
(ii)
h[n] = δ[n] + 2δ[n − 1] + δ[n − 2]
H(ejω) = 1 + 2 e − jω + e − 2jω
(i) and (ii) are the same.
d. x[n] = -2δ[n + 2] + δ[n] - 2δ[n − 2]
X(ejω) = -2 e2jω + 1 - 2e − 2jω
$ \begin{align} Y(e^{j\omega}) &= X(e^{j\omega})H(e^{j\omega}) \\ &= (-2e^{2j\omega } + 1 - 2e^{-2j\omega } ).(1 + 2e^{-j\omega } + e^{-2j\omega }) \\ &= -2e^{2j\omega } - 4e^{j\omega } - 2 + 1 + 2e^{-j\omega } + 2e^{-2j\omega } - 2e^{-2j\omega } - 4e^{-3j\omega } - 2e^{-4j\omega } \\ &= -2e^{2j\omega } - 4e^{j\omega } - 1 - 2e^{-j\omega } - e^{-2j\omega } - 4e^{-3j\omega } - 2e^{-4j\omega } \\ \\ \text{Using Inverse DTFT,} \\ y[n] &= -2\delta[n+2] - 4\delta[n+1] - \delta[n] + 2\delta[n-1] - \delta[n-2] - 4\delta[n-3] - 2\delta[n-4] \\ \end{align} $
All 3 approaches lead to the same y[n].
Question 3
a. Sketch the locations of the poles and zeros.
$ \begin{align} H(z) &= \frac{1-\frac{1}{2}z^{-2}}{1-\frac{1}{\sqrt{2}} z^{-1} +\frac{1}{4} z^{-2}} \\ H(z) &= \frac{(z+\frac{1}{\sqrt{2}})(z-\frac{1}{\sqrt{2}})} { (z-(\frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}))(z-(\frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}})) } \\ \end{align} $
Zeros:
$ z_1 = \frac{1}{\sqrt{2}}, z_2 = -\frac{1}{\sqrt{2}} $
Poles:
$ p_1 = \frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}, p_2 = \frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}} $
- b. Determine the magnitude and phase of the frequency response H(ω), for
$ \omega = 0 $
$ \left| H(e^{j\omega}) \right| = \left| H(e^{j0}) \right| = \left| H(z=1) \right| $
$ = \left| \frac{(1+\frac{1}{\sqrt{2}})(1-\frac{1}{\sqrt{2}})} { (1-(\frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}))(1-(\frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}})) } \right| = 0.921 $
$ \angle H(e^{j0}) = \angle c + \angle d - \angle a - \angle b = 0 $
$ \omega =\frac{\pi}{4} $
$ \left| H(e^{j\omega}) \right| = \left| H(e^{j\frac{\pi}{4}}) \right| = \left| H(z=\frac{1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}) \right| $
$ = \left| \frac{(\frac{1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}+\frac{1}{\sqrt{2}})(\frac{1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}-\frac{1}{\sqrt{2}})} { (\frac{1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}-(\frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}))(\frac{1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}-(\frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}})) } \right| = 2 $
$ \angle H(e^{j\frac{\pi}{4}}) = \angle c + \angle d - \angle a - \angle b = \frac{\pi}{2} + arctan^{-1} \left( \frac{\frac{1}{\sqrt{2}}}{\sqrt{2}} \right) - \frac{\pi}{4} - arctan^{-1} \left( \frac{\frac{1}{\sqrt{2}} + \frac{1}{2\sqrt{2}}}{1-\sqrt{2}-\frac{1}{2\sqrt{2}}} \right) = 0 $
$ \omega =\frac{\pi}{2} $
$ \left| H(e^{j\omega}) \right| = \left| H(e^{j\frac{\pi}{2}}) \right| = \left| H(z=j) \right| $
$ = \left| \frac{(j+\frac{1}{\sqrt{2}})(j-\frac{1}{\sqrt{2}})} { (j-(\frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}))(j-(\frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}})) } \right| = 1.455 $
$ \angle H(e^{j\frac{\pi}{2}}) = (\angle c + \angle d) - \angle a - \angle b = (\pi) - (arctan^{-1}\left( \frac{1-\frac{1}{2\sqrt{2}}}{\frac{-1}{\sqrt{2}}} \right) + \pi) - (arctan^{-1}\left( \frac{1+\frac{1}{2\sqrt{2}}}{1-\frac{1}{\sqrt{2}}} \right) + \pi) = -0.7563 $
$ \omega =\frac{3\pi}{4} $
$ \left| H(e^{j\omega}) \right| = \left| H(e^{j\frac{3\pi}{4}}) \right| = \left| H(z=\frac{-1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}) \right| $
$ = \left| \frac{(\frac{-1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}+\frac{1}{\sqrt{2}})(\frac{-1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}-\frac{1}{\sqrt{2}})} { (\frac{-1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}-(\frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}))(\frac{-1}{\sqrt{2}} + j\frac{1}{\sqrt{2}}-(\frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}})) } \right| = \frac{2}{3} $
$ \angle H(e^{j\frac{3\pi}{4}}) = \angle c + \angle d - \angle a - \angle b = (arctan^{-1}\left( \frac{\frac{1}{\sqrt{2}}}{\frac{-2}{\sqrt{2}}} \right) + \pi) + \frac{\pi}{2} - (arctan^{-1}\left( \frac{\frac{1}{\sqrt{2}} - \frac{1}{2\sqrt{2}}}{\frac{1}{\sqrt{2}} - \frac{1}{2\sqrt{2}}} \right) + \pi) + \frac{3\pi}{4} = -0.9273 $
$ \omega =\pi $
$ \left| H(e^{j\omega}) \right| = \left| H(e^{j\pi}) \right| = \left| H(z=-1) \right| $
$ = \left| \frac{(-1+\frac{1}{\sqrt{2}})(-1-\frac{1}{\sqrt{2}})} { (-1-(\frac{1}{2\sqrt{2}} + j\frac{1}{2\sqrt{2}}))(-1-(\frac{1}{2\sqrt{2}} - j\frac{1}{2\sqrt{2}})) } \right| = 0.255 $
$ \angle H(e^{j\pi}) = (\angle c + \angle d) - \angle a - \angle b = 2\pi - 0 - 0 = 2\pi $
c. Is the system stable? Explain why or why not?
The system is causal and the ROC extends outwards from the outermost pole since |$ p_1 $| = |$ p_2 $| < 1 and this ROC contains the unit circle. Therefore the system is stable.
d. Find the difference equation for y[n] in terms of x[n], corresponding to this transfer function H(z).
$ H(z) = \frac{Y(z)}{X(z)} = \frac{1-\frac{1}{2}z^{-2}}{1-\frac{1}{\sqrt{2}} z^{-1} +\frac{1}{4} z^{-2}} $
$ Y(z)(1-\frac{1}{\sqrt{2}} z^{-1} +\frac{1}{4} z^{-2}) = X(z)(1-\frac{1}{2}z^{-2}) $
Taking inverse,
$ y[n]-\frac{1}{\sqrt{2}}y[n-1] + \frac{1}{4}y[n-2] = x[n] - \frac{1}{2}x[n-2] $
$ y[n] = x[n] - \frac{1}{2}x[n-2] +\frac{1}{\sqrt{2}}y[n-1] - \frac{1}{4}y[n-2] $
Question 4
$ y[n]=\frac{1}{8} \left( x[n]+x[n-1]+x[n-2]+x[n-3]+x[n-4]+x[n-5]+x[n-6]+x[n-7]\right) $
a.
$ h[n]=\frac{1}{8} \left( \delta[n]+\delta[n-1]+\delta[n-2]+\delta[n-3]+\delta[n-4]+\delta[n-5]+\delta[n-6]+\delta[n-7] \right) $
This is a finite duration response.
b.
$ H[z]=\frac{1}{8} \left( 1+z^{-1}+z^{-2}+z^{-3}+z^{-4}+z^{-5}+z^{-6}+z^{-7} \right) $
$ H[z]=\frac{1}{8} \left( \frac{1-z^{-8}}{1-z^{-1}} \right) $
c.
$ H[z]=\frac{1}{8} \left( \frac{z^{8}-1}{z^{7}(z-1)} \right) $
Poles:
$ p_1 = 1 $
$ p_2 = p_3 = ... = p_8 = 0 $
Zeros:
$ z^{8} - 1 = 0 $
$ z^{8} = e^{j2\pi } $
Generalizing,
$ z_k = e^{j2\pi k/8 } $ for k = 0,1,2,...,7
Question 5
a.
$ y[n]= \frac{1}{8} \left( x[n]-x[n-8]+y[n-1] \right) $
Using z-transform,
$ Y(z) = \frac{1}{8} \left( X(z)-X(z)z^{-8} + Y(z)z^{-1} \right) $
$ Y(z) (1 - \frac{1}{8}z^{-1}) = X(z) \frac{1}{8}(1 - z^{-8}) $
$ H(z) = \frac{Y(z)}{X(z)} = \frac{1}{8} \left( \frac{ 1 - z^{-8} } {1 - \frac{1}{8}z^{-1}} \right) $
b.
c.
H(z) can be re-written as
$ H[z]=\frac{1}{8} \left( \frac{1}{1-\frac{1}{8}z^{-1}} - \frac{z^{-8}}{1-\frac{1}{8}z^{-1}} \right) $
Assuming the ROC: $ |z|>\frac{1}{8} $Taking inverse Z-transform of H(z) -
$ h[n]=\frac{1}{8} \left( (\frac{1}{8})^n u[n] - (\frac{1}{8})^{n-8} u[n-8] \right) $
This is a infinite duration response.
Back to Homework 6
Back to ECE 438 Fall 2011