diff --git a/notebooks/COM202 b/notebooks/COM202 index a0d2f9f..d7680d6 160000 --- a/notebooks/COM202 +++ b/notebooks/COM202 @@ -1 +1 @@ -Subproject commit a0d2f9f35cf874056f868ba0eff43f29f8f92f0e +Subproject commit d7680d679e36c90f5692b74d998860d6736b9eb1 diff --git a/teaching/COM303/2023/admin/grades2023.xlsx b/teaching/COM303/2023/admin/grades2023.xlsx index b69ecdc..6703664 100644 Binary files a/teaching/COM303/2023/admin/grades2023.xlsx and b/teaching/COM303/2023/admin/grades2023.xlsx differ diff --git a/teaching/COM303/2023/exams/final.tex b/teaching/COM303/2023/exams/final.tex index 6540aff..aac30f8 100644 --- a/teaching/COM303/2023/exams/final.tex +++ b/teaching/COM303/2023/exams/final.tex @@ -1,1194 +1,1194 @@ \documentclass[a4paper,fleqn,11pt]{article} \usepackage[utf8]{inputenc} \usepackage[parfill]{parskip} \usepackage{cancel} \usepackage{defsDSPcourse} \usepackage{dspTricks} \usepackage{dspFunctions} \usepackage{dspBlocks} \usepackage{comment} \usepackage{pst-plot} \usepackage{enumitem} \usepackage{wrapfig} \usepackage{mathtools} \usepackage{mdframed} \makeatletter \def\dspLegendStyle(#1,#2)#3{% \rput[lt](#1,#2){{% \begin{tabular}{ll} \@dsplegendStyle#3 \@empty \end{tabular}}}} \def\@dsplegendStyle#1 #2 #3{% {\psline[#1](0,0.2)(2,0.2)\rule{2.5em}{0pt}} & #2\\ \space % fbox here to have a visual test \ifx #3\@empty\else \expandafter\@dsplegendStyle \fi #3} \makeatother \newif\ifanswers -%\answerstrue +\answerstrue \begin{document} \def\exver{1} \ifanswers{}\else{ \framebox[\textwidth][l]{\rule{0cm}{1cm}\LARGE STUDENT-NAME}\null \\ \framebox[4cm][l]{\rule{0cm}{1.2em}\LARGE SCIPER} \hfill \framebox[4cm][r]{\rule{0cm}{1.2em}\LARGE PLACE} {\parfillskip=0pt\par} \vspace{6em} }\fi \begin{center}% \sffamily {\LARGE \bfseries COM-303 - Signal Processing for Communications \\ Final Exam \ifanswers{Solution}\fi} \\ \vspace{1em} {\large Monday 19.06.2023 from 15h15 to 18h15 (AAC231, SG1)} \\ \end{center} \centerline{\rule{\textwidth}{.5pt}} \vspace{1em} \ifanswers{}\else{ \begin{center} \LARGE \bfseries Verify that this exam has YOUR last name on top \\ \vspace{1em} DO NOT OPEN THE EXAM UNTIL INSTRUCTED TO DO SO \end{center} \vspace{1em} \centerline{\rule{\textwidth}{.5pt}} \vspace{1em} \begin{itemize} \item {\bf Write your name} on the top left corner of {\bf ALL the sheets you turn in}. \item There are FIVE problems for a total of 90 points; the number of points is indicated for each problem and, in the case of multipart exercises, also for each sub-question. Read \textbf{all} the problem statements very carefully \textbf{before} you begin solving the exam! \item Please \textbf{write your derivations clearly!} \item You can have two A4 sheets of \emph{handwritten} notes (front and back). Please no photocopies, no books and no electronic devices. Turn off your phone and store it in your bag. \vspace{1em} \item When you are done, \textbf{simply leave your solution on your desk \textit{with this page on top} and exit the classroom}. \textbf{Do NOT bring the exam to the front desk.} \end{itemize} \vspace{1em} \centerline{\rule{\textwidth}{.5pt}} \vspace{1em} \newpage }\fi %\onebyone %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{exercise}{(10 points)} Consider the signal \[ x[n] = \begin{cases} 0 & n = 0 \\ 1/n^3 & n \neq 0. \end{cases} \] Show that its DTFT $X(e^{j\omega})$ exists [5p] and that the real part of $X(e^{j\omega})$ is equal to zero [5p]. [\textit{Note: you do not need to compute the DTFT explicitly.}] \ifanswers{\em\vspace{1em}\par{\bfseries Solution: } To show that the DTFT exists, it suffices to show that the signal has finite energy, that is, $\sum_{n}|x[n]|^2 < \infty$. We have \[ S = \sum_{n=-\infty}^{\infty}|x[n]|^2 = 2\sum_{n=1}^{\infty}\frac{1}{n^6} = 2\sum_{n=1}^{\infty}\left(\frac{1}{n^2}\right)^3 \] Since $(1/x)^3 \le (1/x)$ for all $x \ge 1$ we can write \[ S = 2\sum_{n=1}^{\infty}\left(\frac{1}{n^2}\right)^3 \le 2\sum_{n=1}^{\infty}\frac{1}{n^2} = \frac{\pi^2}{3} < \infty. \] Since $x[-n] = -x[n]$, the signal is antisymmetric and therefore its DTFT is purely imaginary; to show the result formally: \begin{align*} X(e^{j\omega}) &= \sum_{n=-\infty}^{\infty}x[n]\,e^{-j\omega n} \\ &= \sum_{n=1}^{\infty}\frac{1}{n^3}(e^{-j\omega n} - e^{j\omega n}) \\ &= \sum_{n=1}^{\infty}\frac{1}{n^3}(-j\sin(\omega n) - j\sin(\omega n)) \\ &= j\left(-2\sum_{n=1}^{\infty}\frac{\sin(\omega n)}{n^3}\right) \end{align*} which is purely imaginary. }\else{\vspace{0em}}\fi \end{exercise} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{exercise}{(30 points)} Consider the following block diagrams, implementing the causal LTI systems $H_1(z)$ and $H_2(z)$: \begin{tabular}{cc|cc} & & & \\ \psscalebox{0.8}{ \begin{dspBlocks}{1}{0.6} $x[n]~~$ & \BDadd & & \BDsplit & $~~y[n]$ \\ & & \BDdelay & & \ncline{->}{1,1}{1,2}\taput{$3$}\ncline{->}{1,2}{1,5} \ncline{->}{2,2}{1,2}\ncline{2,2}{2,3}\taput{$1/2$~~}\ncline{<-}{2,3}{2,4} \ncline{2,4}{1,4} \end{dspBlocks}} & & & \psscalebox{0.8}{ \begin{dspBlocks}{0.5}{0.6} $x[n]~~~$ & \BDsplit & \BDdelay & \BDsplit & \BDdelay & & \\ & & & \BDadd & & \BDadd & $~~~y[n]$ \ncline{->}{1,1}{1,3}\ncline{->}{1,3}{1,5}\ncline{1,5}{1,6} \ncline{1,2}{2,2} \ncline{->}{1,4}{2,4}\tlput{$-7/6$} \ncline{->}{1,6}{2,6}\tlput{$1/3$} \ncline{->}{2,2}{2,4}\ncline{->}{2,4}{2,6}\ncline{->}{2,6}{2,7} \end{dspBlocks}} \\ & & & \\ $H_1(z)$ & & & $H_2(z)$ \end{tabular} \vspace{1ex} The two systems are then connected together in three different configurations to create three new causal LTI systems: \begin{tabular}{c|c|c} & & \\ \psscalebox{0.7}{ \begin{dspBlocks}{.5}{0.6} $x[n]~~$ & \BDfilter{$H_1(z)$} & \BDfilter{$H_2(z)$} & $~~y[n]$ \\ \ncline{->}{1,1}{1,2}\ncline{->}{1,2}{1,3}\ncline{->}{1,3}{1,4} \end{dspBlocks}} & \psscalebox{0.7}{ \begin{dspBlocks}{.5}{0.0} & & \BDfilter{$H_1(z)$} & \\ $x[n]~~$ & \BDsplit & & \BDadd & $~~y[n]$ \\ & & \BDfilter{$H_2(z)$} & \ncline{->}{1,2}{1,3}\ncline{1,3}{1,4} \ncline{2,1}{2,2}\ncline{->}{2,4}{2,5} \ncline{->}{3,2}{3,3}\ncline{3,3}{3,4} \ncline{1,2}{3,2} \ncline{->}{1,4}{2,4}\ncline{->}{3,4}{2,4} \end{dspBlocks}} & \psscalebox{0.7}{ \begin{dspBlocks}{.5}{0.6} $x[n]~~$ & \BDadd & & \BDfilter{$H_1(z)$} & \BDsplit & $~~y[n]$ \\ & & \BDdelay & \BDfilter{$H_2(z)$} & \ncline{->}{1,1}{1,2}\ncline{->}{1,2}{1,4}\ncline{->}{1,4}{1,6} \ncline{2,2}{2,3}\ncline{<-}{2,3}{2,4}\ncline{<-}{2,4}{2,5} \ncline{->}{2,2}{1,2}\ncline{2,5}{1,5} \end{dspBlocks}} \\ & & \\ $H_A(z)$ & $H_B(z)$ & $H_C(z)$ \end{tabular} \vspace{1ex} Determine the stability of $H_A(z)$ [5p], $H_B(z)$ [5p], and $H_C(z)$ [20p]. Please justify your answers. \ifanswers{\em\vspace{1em}\par{\bfseries Solution: } From the block diagrams we can immediately see that: \begin{itemize} \item $H_1(z)$ is a first-order feedback loop (i.e. a leaky integrator) with transfer function \[ H_1(z) = \frac{3}{1 - (1/2)z^{-1}}; \] the single pole of the filter is in $z=1/2$ so $H_1(z)$ is stable. \item $H_2(z)$ is a pure feedforward structure yielding the transfer function $H_2(z) = 1 -(7/6) z^{-1} + (1/3)z^{-2}$ which, being an FIR, is also stable. Since this will be useful later, by finding the zeros of the transfer function, we can factor $H_2(z)$ as \[ H_2(z) = (1 - (2/3)z^{-1})(1 - (1/2)z^{-1}). \] \end{itemize} With this: \begin{enumerate} \item $H_A(z) = H_1(z)\,H_2(z)$ which is stable because it is a cascade of stable subsystems \item $H_B(z) = H_1(z) + H_2(z)$ which is stable because both subsystems are stable and they operate independently \item $H_C(z)$ uses the two subsystems in a feedback loop; the overall transfer function can be computed from the input-output relation in the $z$-domain: \[ Y(z) = H_1(z)[X(z) + z^{-1}H_2(z)Y(z)] \] which yields \[ H_C(z) = \frac{H_1(z)}{1 - z^{-1}H_1(z)H_2(z)} = \frac{1}{1/H_1(z) - z^{-1}H_2(z)} \] By plugging in the expressions for $H_1(z)$ and $H_2(z)$ we have \begin{align*} H_C(z) &= \left[\frac{1 - (1/2)z^{-1}}{3} - z^{-1}(1 - (2/3)z^{-1})(1 - (1/2)z^{-1})\right]^{-1} \\ &= 3\left[(1 - (1/2)z^{-1})[1 - 3z^{-1}(1 - (2/3)z^{-1})]\right]^{-1} \\ &= 3\left[(1 - (1/2)z^{-1})(1 - 3z^{-1} + 2z^{-2}))\right]^{-1}. \end{align*} By finding the roots of the expression in brackets we can determine that the poles of $H_C(z)$ are in $z = 1/2, z = 1$, and $z = 2$; therefore the system is not stable. \end{enumerate} }\else{\vspace{1em}}\fi \end{exercise} \ifanswers{}\else{\vspace{-.5em}}\fi %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{exercise}{(15 points)} The signal $x[n] = n\,u[n]$ (where $u[n]$ is the unit step sequence) % \[ % x[n] = \begin{cases} n & n \ge 0 \\ 0 & n < 0 \end{cases} % \] is the input to the following multirate system: \begin{center} \begin{dspBlocks}{0.9}{0.1} & & & \BDdwsmp{5} & \BDupsmp{2} & \BDdelay & \\ $x[n]~~$ & \BDsplit & & & & & \BDadd & $~~y[n]~~$ \\ & & \BDdelayN{3} & \BDdwsmp{5} & \BDupsmp{2} & & \\ \\ \end{dspBlocks} \ncline{2,1}{2,2}\ncline{->}{2,7}{2,8} \ncline{->}{1,2}{1,4}\ncline{->}{1,4}{1,5}\ifanswers{\taput{$a[n]$}}\fi \ncline{->}{1,5}{1,6}\ifanswers{\taput{$b[n]$}}\fi \ncline{1,6}{1,7}\ifanswers{\taput{$c[n]$}}\fi \ncline{->}{3,2}{3,3}\ncline{->}{3,3}{3,4}\ifanswers{\taput{$d[n]$}}\fi \ncline{->}{3,4}{3,5}\ifanswers{\taput{$e[n]$}}\fi \ncline{3,5}{3,6}\ifanswers{\taput{$f[n]$}}\fi \ncline{3,6}{3,7} \ncline{3,2}{1,2} \ncline{->}{3,7}{2,7}\ncline{->}{1,7}{2,7} \end{center} Compute the values of the output sequence $y[n]$ for $0 \leq n < 10$. \ifanswers{\em\vspace{1em}\par{\bfseries Solution: } Consider the intermediate signals shown in the block diagram: \begin{align*} a[n] &= x[5n] \\ b[n] &= a[n/2] \mbox{ if $n$ even else 0} \\ c[n] &= b[n-1] \\ d[n] &= x[n-3] \\ e[n] &= d[5n] \\ f[n] &= e[n/2] \mbox{ if $n$ even else 0} \end{align*} with, in the end, $y[n] = c[n] + f[n]$. If we write the values for these signals starting at $n = 0$ when the input is $x[n]$, we have \setcounter{MaxMatrixCols}{20} \begin{align*} a &: \quad\begin{matrix} 0, & 5, & 10, & 15, & 20, & \ldots \end{matrix} \\ b &: \quad\begin{matrix} 0, & 0, & 5, & 0, & 10, & 0, & 15, & 0, & 20, & \ldots \end{matrix} \\ c &: \quad\begin{matrix} 0, & 0, & 0, & 5, & 0, & 10, & 0, & 15, & 0, & 20, & \ldots \end{matrix} \\ d &: \quad\begin{matrix} 0, & 0, & 0, & 0, & 1, & 2, & 3, & 4, & 5, & 6, & 7, & 8, & 9, & \ldots \end{matrix} \\ e &: \quad\begin{matrix} 0, & 2, & 7, & 12, & 17, & \ldots\end{matrix} \\ f &: \quad\begin{matrix} 0, & 0, & 2, & 0, & 7, & 0, & 12, & 0, & 17, & \ldots\end{matrix} \\ \end{align*} so that, for $n \ge 0$, \[ y: \quad\begin{matrix} 0, & 0, & 2, & 5, & 7, & 10, & 12, & 15, & 17, & \ldots\end{matrix} \\ \] }\else{\vspace{0.5em}}\fi \end{exercise} \ifanswers{}\else{\vspace{0em}}\fi %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{exercise}{(25 points)} Most of the small, battery-operated remote controls that we use to unlock a car or to open a garage door employ a data communication technique called On-Off-Keying (OOK). When you push the button, the transmitter sends a string of binary digits (the secret password) by switching on or off an analog sinusoidal oscillator according to whether the bit to transmit is one or zero. As an example, here is a sketch of what an idealized OOK signal looks like for the binary sequence $[1, 0, 1, 1, 0, 1]$: \begin{center} \begin{dspPlot}[height=1cm,width=14cm,xout=true,xticks=custom,yticks=none,sidegap=0]{0,1.2}{-1.4, 1.4} \dspFunc[linewidth=1pt]{x 360 mul 55 mul cos x 0.2 lt {1} {x 0.4 lt {0} {x 0.8 lt {1} {x 1 lt {0} {1} ifelse} ifelse} ifelse} ifelse mul} \dspCustomTicks[axis=x]{0 $t$ 0.2 $t+T_b$ 0.4 $t+2T_b$ 0.6 $t+3T_b$ 0.8 $t+4T_b$ 1 $t+5T_b$ 1.2 $t+6T_b$} \dspText(0.1, 1.3){$1$} \dspText(0.3, 1.3){$0$} \dspText(0.5, 1.3){$1$} \dspText(0.7, 1.3){$1$} \dspText(0.9, 1.3){$0$} \dspText(1.1, 1.3){$1$} \end{dspPlot} \end{center} In the figure, $T_b$ is the time (in seconds) used to transmit one bit, so that the data rate is $1/T_b$ bits per second; in most commercial systems the data rate is low, about $1000$~bps, while the oscillator's frequency is usually around 430~MHz. The main advantages of OOK are the simplicity of the modulation and demodulation circuits, together with the inherent low power consumption of the transmitter: since the oscillator is switched off roughly half of the time, battery life is prolonged. The implementation for the transmitter can be modeled by the following block diagram: \begin{center} \begin{dspBlocks}{1.3}{0.4} & $T_b$ & $\cos(2\pi f_c t)$ & {% \psset{xunit=1em,yunit=1em}% \pspicture(-2,-2)(2,0)% \psline[linewidth=1pt](0,-2)(-1.5,0)(1.5,0)(0,-2) \endpspicture}\\ $b[n]$~ & \BDfilter{$I_0$} & \BDmul & \\ \ncline{->}{1,3}{2,3} \ncline{2,1}{2,2} \ncline{->}{2,2}{2,3}\tbput{\color{gray} $p(t)$} \ncline{2,3}{2,4}\tbput{\color{gray} $x(t)$} \ncline{2,4}{1,4} \end{dspBlocks} \end{center} where $b[n]$ is the discrete-time sequence of binary digits to transmit, $I_0$ is a zero-order-hold D/A interpolator working at a rate $T_b$, and $f_c$ is the oscillator's frequency; the signal sent to the antenna is thus the continuous-time signal $x(t) = p(t)\cos(2\pi f_c t)$ where \[ p(t) = \sum_{n=-\infty}^{\infty}b[n]\rect\left(\frac{t - nT_b}{T_b}\right). \] \begin{wrapfigure}{r}{4cm} \centering $B(e^{j\omega})$ \\ \begin{dspPlot}[width=3.5cm,height=2cm,xtype=freq,xticks=2,yticks=none]{-1,1}{0, 2.5} \dspFunc{1} \dspDiracs{0 2.1} \end{dspPlot} \end{wrapfigure} In the following exercise questions, assume the following: \begin{itemize} \item $b[n]$, the binary sequence to transmit, is an infinite-length signal whose DTFT looks as in the picture here on the right; formally, the DTFT can be expressed as $B(e^{j\omega}) = a + b\tilde{\delta}(\omega)$ for some real-valued constants $a$ and $b$ but note that the actual values of $a$ and $b$ are not relevant to the solution and that you do not need to use the explicit expression for $B(e^{j\omega})$ anywhere in your derivations; \item the frequency of the oscillator in the transmitter is $f_c = 3/T_b$. \end{itemize} With these assumptions: \begin{enumerate} \item {[5p]} Sketch the magnitude of $X(f)$, the spectrum of the transmitted analog signal; the exact amplitude of the spectrum is not important but indicate \textit{precisely} the frequencies at which it is equal to zero and try to be the accurate with the \textit{relative}\/ magnitudes of the peaks. [\textit{Advice: start first by working out the shape of $P(f)$, the spectrum of the baseband signal produced by the interpolator}\ifanswers{}\else{\footnote{...and, if you've forgotten to write the relevant formula in your notes, here it is: given a discrete-time signal $x[n]$ whose DTFT is $X(e^{j\omega})$, and given an interpolator with kernel $i(t)$ and Fourier transform $I(f)$, the spectrum of the continuous-time interpolation of $x[n]$ at a rate of $F_s$ samples per second is $X(f) = (1/F_s) \,I\left( f / F_s \right) \, X(e^{j2\pi f / F_s})$}}\fi.] \item {[5p]} Do you see any problems with this implementation of the OOK transmitter? How would you fix them? \end{enumerate} In spite of the issues inherent to this elementary modulation scheme, the design illustrated above is in fact the one used in practical realizations, especially because the simplicity of the transmitter is matched by that of the receiver. Indeed, an estimate of the signal $p(t)$ can be easily obtained using a simple squaring nonlinearity followed by an analog lowpass filter $H(f)$: \begin{center} \begin{dspBlocks}{1.3}{0.4} $x(t)$~~ & \BDfilter{$|\cdot|^2$} & \BDfilter{$H(f)$} & ~~$\hat{p}(t)$ \ncline{->}{1,1}{1,2}\ncline{->}{1,2}{1,3}\taput{$2$} \ncline{->}{1,3}{1,4} \end{dspBlocks} \end{center} \begin{enumerate}\addtocounter{enumi}{2} \item {[5p]} Show that $\hat{p}(t) \approx p(t)$. \item {[10p]} Determine the analog lowpass filter's cutoff frequency $f_L$ that minimizes the mean square error between $\hat{p}(t)$ and $p(t)$. \end{enumerate} \ifanswers{\em\vspace{1em}\par{\bfseries Solution: } The continuous-time signal $p(t)$ is obtained by interpolating $b[n]$ with a zero-order hold at a frequency $F_s = 1/T_b$; the resulting spectrum is \[ P(f) = (1/F_s) \,I_0\left( f / F_s \right) \, B(e^{j2\pi f / F_s}) \] where $I_0(f)$ is the Fourier transform of the zero-order interpolation kernel. The last term in the equation is a rescaled version of the $2\pi$-periodic $B(e^{j\omega})$; since $B(e^{j\omega})$ is full band, we obtain a constant value plus a series of Dirac deltas at multiples of $F_s$: \begin{center} \begin{dspPlot}[height=2cm,width=14cm,xticks=custom,yticks=none,sidegap=0,xout=true,ylabel={$|B(e^{j2\pi f / F_s})|$}]{-5.5,5.5}{0,4.2} \psline(-0.5, 0)(-0.5, 1)(0.5, 1)(0.5, 0) \multido{\i=-5+1}{11}{% \psline[linecolor=gray](! \i\space 0.5 sub 0)(! \i\space 0.5 sub 1)(! \i\space 0.5 add 1)(! \i\space 0.5 add 0) \psline[linecolor=gray]{->}(\i, 0)(\i, 3)} \def\i{0} \psline(! \i\space 0.5 sub 0)(! \i\space 0.5 sub 1)(! \i\space 0.5 add 1)(! \i\space 0.5 add 0) \psline{->}(\i, 0)(\i, 3) \dspCustomTicks[axis=x]{-1 $-F_s$ -2 $-2F_s$ -3 $-3F_s$ -4 $-4F_s$ -5 $-5F_s$ 0 0 1 $F_s$ 2 $2F_s$ 3 $3F_s$ 4 $4F_s$ 5 $5F_s$ -0.5 $-F_s/2$ 0.5 $F_s/2$} \end{dspPlot} \end{center} The interpolation kernel is $i_0(t) = \rect(t)$ and therefore its Fourier transform is $I_0(f) = \sinc(f)$; rescaling with respect to $F_s$ we obtain the following plot: \begin{center} \begin{dspPlot}[height=2cm,width=14cm,xticks=custom,yticks=none,sidegap=0,xout=true,ylabel={$|I_0(f / F_s)|$}]{-5.5,5.5}{0,1.2} \dspFunc{x \dspSinc{0}{1} abs} \dspCustomTicks[axis=x]{-1 $-F_s$ -2 $-2F_s$ -3 $-3F_s$ -4 $-4F_s$ -5 $-5F_s$ 0 0 1 $F_s$ 2 $2F_s$ 3 $3F_s$ 4 $4F_s$ 5 $5F_s$} \end{dspPlot} \end{center} Finally, the magnitude spectrum $|P(f)|$ is obtained from the product of the two spectra above; note that the zeros of $I_0(f / F_s)$ at multiples of $F_s$ cancel out the Diracs in $B(f)$ except in $f=0$: \begin{center} \begin{dspPlot}[height=3cm,width=14cm,xticks=custom,yticks=none,sidegap=0,xout=true,ylabel={$|P(f)|$}]{-5.5,5.5}{0,2.2} \dspFunc{x \dspSinc{0}{1} abs} \dspDiracs{0 2} \dspCustomTicks[axis=x]{-1 $-F_s$ -2 $-2F_s$ -3 $-3F_s$ -4 $-4F_s$ -5 $-5F_s$ 0 0 1 $F_s$ 2 $2F_s$ 3 $3F_s$ 4 $4F_s$ 5 $5F_s$ -0.5 $-F_s/2$ 0.5 $F_s/2$} \end{dspPlot} \end{center} \begin{enumerate} \item since $x(t) = p(t)\cos(2\pi f_c t)$, by the modulation theorem: \[ X(f) = [P(f - f_c) + P(f + f_c)]/2 \] and therefore the magnitude spectrum of the transmitted signal looks like so: \begin{center} \begin{dspPlot}[height=3cm,width=14cm,xticks=custom,yticks=none,sidegap=0,xout=true,ylabel={$|X(f)|$}]{-5.5,5.5}{0,2.2} \dspFunc{x \dspSinc{3}{1} x \dspSinc{-3}{1} add abs} \dspDiracs{3 2 -3 2} \dspCustomTicks[axis=x]{-1 $-F_s$ -2 $-2F_s$ -3 $-3F_s$ -4 $-4F_s$ -5 $-5F_s$ 0 0 1 $F_s$ 2 $2F_s$ 3 $3F_s=f_c$ 4 $4F_s$ 5 $5F_s$} \end{dspPlot} \end{center} % \item The problems are due to the fact that $P(f)$ is not bandlimited because of the zero-order interpolation; as a consequence: \begin{enumerate} \item the two spectral copies created by the modulation overlap with each other, which leads to distortion \item the tails of the modulated copies spill out on neighboring frequency bands, which could create interference with other radio devices \end{enumerate} These problems could be reduced by using a higher-order interpolator and, in the limit, a sinc interpolator\footnote{This is not done in practice because the resulting design would be much more complex and the energy savings obtained by switching off the oscillator during a zero bit would no longer be there.}. % \item First of all notice that the signal $p(t)$ is either equal to one or to zero for all values of $t$ and therefore $p^2(t) = p(t)$. Next, recall the basic trigonometric identity $\cos^2\alpha = (1 + \cos 2\alpha)/2$. With this, the signal entering the lowpass filter is \begin{align*} y(t) &= 2x^2(t) = p^2(t)\cdot 2\cos^2(2\pi f_c t) \\ &= p(t) + p(t)\cos(2\pi (2f_c) t) \end{align*} that is, the original $p(t)$ plus a a copy of $p(t)$ modulated at twice the original frequency. In the frequency domain, we thus have \[ Y(f) = P(f) + (1/2)P(f - 2f_c) + (1/2)P(f + 2f_c) \] If $P(f)$ was bandlimited so that $P(f) = 0$ for $|f| < f_N$ (and $f_N < f_c)$, then we could exactly recover $p(t)$ via a lowpass filter with cutoff $f_N \le f_L < f_c-f_N$. Since $P(f)$ is not banlimited, the tails of the cross-modulation copies $P(f \pm 2f_c)/2$ will ``spill over'' in the baseband and this will cause a certain amount of distortion. Since usually $f_c$ is much much larger than $F_s = 1/T_b$, this distortion will be very small in practical implementations. % \item Because of the spectral overlap between $P(f)$ and $P(f \pm 2f_c)/2$ we want a cutoff frequency that preserves most of the energy in $P(f)$ and eliminates most of the energy from the cross-modulated component. To find the optimal point, remember that $P(f)$ has the shape of a sinc function, whose amplitude is upper bounded by $|\pi f|^{-1}$, while the overlapping $P(f - 2f_c)/2$ decays as $|2\pi(f-2f_c)|^{-1}$, as illustrated in the following figure: \begin{center} \begin{dspPlot}[height=5cm,width=14cm,xticks=custom,yticks=none,sidegap=0,xout=true,ylabel={$|Y(f)|$}]{0,7.5}{0,.4} \begin{dspClip} \dspFunc[linewidth=1.5pt]{x \dspSinc{0}{1} abs} \dspFunc[xmin=0.5, linestyle=dashed,linewidth=2pt]{1 x 3.14 mul div} \dspFunc[linewidth=1.5pt,linecolor=gray]{x \dspSinc{6}{1} 0.5 mul abs} \dspFunc[xmax=5.5, linestyle=dashed,linewidth=2pt,linecolor=gray]{-1 x 6 sub 3.14 mul 2 mul div} \end{dspClip} \dspCustomTicks[axis=x]{0 0 1 $F_s$ 2 $2F_s$ 3 $3F_s=f_c$ 4 $4F_s=4f_c/3$ 5 $5F_s$ 6 $6F_s=2f_c$ 7 $7F_s$} \end{dspPlot} \end{center} The ideal cutoff is therefore the crossover frequency after which the magnitude of $P(f)$ becomes asymptotically smaller than the magnitude of $P(f - 2f_c)/2$; this happens for \[ \frac{1}{f} = \frac{1/2}{2f_c - f} \] that is for \[ f_L = (4/3)f_c; \] For our particular choice of $f_c = 3F_s$, this corresponds to $f_L = 4F_s = 4/T_b$. \end{enumerate} }\else{\vspace{1em}}\fi \end{exercise} \ifanswers{}\else{\vspace{0em}}\fi %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{exercise}{(10 points)} Given a real-valued constant $\beta > 1$, consider the FIR filter with impulse response \[ h[n] = \begin{cases} 1 & n = -1 \\ \beta & n = 1 \\ 0 & \mathrm{otherwise.} \end{cases} \] Let $[-\omega_0, \omega_0]$ be the frequency interval over which, for our practical purposes, the small-angle approximation $\tan\omega \approx \omega$ is sufficiently accurate. Show that the filter's phase response is approximately linear over $[-\omega_0, \omega_0]$, independently of the value of $\beta$. \ifanswers{\em\vspace{1em}\par{\bfseries Solution: } The frequency response of the filter is \begin{align*} H(e^{j\omega}) &= e^{j\omega} + \beta e^{-j\omega} \\ &= \cos\omega + j\sin\omega + \beta\cos\omega - j\beta\sin\omega \\ &= (\beta + 1)\cos\omega - j(\beta - 1)\sin\omega. \end{align*} The phase response is therefore \[ \angle H(e^{j\omega}) = \arctan\left(-\frac{\beta - 1}{\beta+1}\,\frac{\sin\omega}{\cos\omega}\right) = \arctan\left(\lambda\tan\omega\right). \] Since $\beta > 1$ by definition, then $-1 < \lambda < 0$ so, if $\omega \in [-\omega_0, \omega_0]$, then $\lambda\omega \in [-\omega_0, \omega_0]$ as well. Consequently \[ \lambda\tan\omega \approx \lambda\omega \approx \tan\lambda\omega. \] With this, for $|\omega| < \omega_0$, \[ H(e^{j\omega}) = \arctan\left(\lambda\tan\omega\right) \approx \arctan\left(\tan\lambda\omega\right) = \lambda\omega \] which is linear in $\omega$. }\else{\vspace{1em}}\fi \end{exercise} \end{document} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{exercise}{(25 points)} \def\tspec#1#2#3{ \def\w{72 } \def\rho{0.95 } \begin{dspPlot}[xticks=custom,yticks=none,xout=true,sidegap=0,xlabel={#3}]{-500,500}{0,#2} \dspFuncOpt{/A [ -500 1 500 { dup abs #1 gt {pop 0} {dup 1 add \w mul sin \w sin div 1 add exch abs round \rho exch exp mul} ifelse} for ] def} {x \dspDFTMAG{ A aload pop }} \dspCustomTicks[axis=x]{-500 $\pi$ -250 $\pi/2$ 0 0 250 $\pi/2$ 500 $\pi$} \end{dspPlot}} \def\cplt#1#2#3{% \hspace{-2em} \begin{dspPlot}[xtype=freq,xticks=2,yticks=none,width=4cm,height=3cm,xout=true,xlabel={$M=#1$}]{-1,1}{#2,#3} \dspFunc{1 1 1 #1 {x 180 mul mul cos 2 mul add} for} \end{dspPlot}} Consider a finite-energy, infinite-length discrete-time signal $x[n] \in \ell_2(\mathbb{Z})$, whose DTFT $X(e^{j\omega})$ is real-valued and shown in the following figure: \begin{center} \tspec{500}{42}{} \end{center} In this exercise we want to study what happens if we need to estimate $X(e^{j\omega})$ from a limited amount of data samples. Suppose we can collect $2M+1$ values for $x[n]$ over a symmetric time window centered on $n=0$. For any given value of $M \in \mathbb{N}$, the signal \[ \bar{x}_M[n] = \begin{cases} x[n] & |n| \leq M \\ 0 & |n| > M \end{cases} \] is a finite-support truncation of $x[n]$ and we want to compare its DTFT to the original signal's spectrum. To this aim, first notice that we can write $\bar{x}_M[n] = x[n]s_M[n]$, where \[ s_M[n] = \begin{cases} 1 & |n| \leq M \\ 0 & |n| > M \end{cases} \] \begin{enumerate} \item (5p) Derive the formula for $S_M(e^{j\omega}) = \DTFT{s_M[n]}$ \end{enumerate} The DTFT of $s_M[n]$, $S_M(e^{j\omega})$, is real-valued and it is plotted in the following panels for three different values of $M$: \begin{center} \begin{tabular}{ccc} \cplt{2}{-1.6}{5.5} & \cplt{4}{-2.5}{9.9} & \cplt{10}{-6.3}{23.1} \end{tabular} \end{center} \begin{enumerate}\addtocounter{enumi}{1} \item (15p) Looking at the above plots for $X(e^{j\omega})$ and $S_M(e^{j\omega})$ and proceeding graphically, sketch the approximate shape of $\bar{X}_M(e^{j\omega})$ for $M = 10, 4, 2$. Briefly comment on how the value of $M$ affects the resulting spectra. \end{enumerate} Consider now the finite-length signal $x_M[n] \in \mathbb{C}^{2M+1}$, where $x_M[n] = x[n - M], n = 0, 1, \ldots, 2M$ and its DFT $X_M[k], k = 0, 1, \ldots, 2M$: \begin{enumerate}\addtocounter{enumi}{2} \item (5p) express the magnitude of the DFT coefficients $|X_M[k]|$ as a function of $\bar{X}_M(e^{j\omega})$. \end{enumerate} \ifanswers{\em\vspace{1em}\par{\bfseries Solution: } \begin{enumerate} \item The DTFT of the symmetric indicator sequence $s_M[n]$ is \begin{align*} S_M(e^{j\omega}) &= \sum_{n=-\infty}^{\infty} s_M[n]e^{-j\omega n} = \sum_{n=-M}^{M} e^{-j\omega n} = e^{j\omega M}\sum_{n=0}^{2M} e^{-j\omega n} \\ &= e^{j\omega M} \, \frac{1 - e^{-j\omega(2M+1)}}{1 - e^{-j\omega}} \\ &= \frac{e^{j\omega M} - e^{-j\omega(M+1)}}{1 - e^{-j\omega}} \\ &= \frac{e^{-j\omega/2} \left( e^{j\omega(M + 1/2)} - e^{-j\omega(M+1/2)} \right)}{e^{-j\omega/2}\left( e^{j\omega/2} - e^{-j\omega/2} \right)} \\ &= \frac{\sin\left(\omega (M+1/2)\right)}{\sin(\omega/2)} \end{align*} % \item in the frequency domain, multiplication becomes convolution so the DTFT of $\bar{x}_M[n]$ is $\bar{X}_M(e^{j\omega}) = (S_M \ast X)(e^{j\omega})$. Intuitively, if $S_M(e^{j\omega})$ is concentrated in frequency (that is, for large $M$) the resulting convolution will be very close to the original $X(e^{j\omega})$; conversely, if $M$ is small, the main lobe of $S_M(e^{j\omega})$ will ``smear'' the original spectrum. If $M$ is very small, the width of the lobe will obliterate the peaks of the original spectrum: \begin{center} \tspec{10}{20}{$M=10$} \tspec{4}{8}{$M=4$} \tspec{2}{6}{$M=2$} \end{center} % \item We have: \[ \bar{X}_M(e^{j\omega}) = \sum_{n=-\infty}^{\infty} \bar{x}_M[n]e^{-j\omega n} = \sum_{n=-M}^{M} x[n]e^{-j\omega n} \] while \[ X_M[k] = \sum_{n=0}^{2M} x[n-M]e^{-j\frac{2\pi}{2M+1}nk} = \sum_{n=-M}^{M} x[n]e^{-j\frac{2\pi}{2M+1}(n+M)k} = e^{-j2\pi\frac{M}{2M+1}k}\sum_{n=-M}^{M} x[n]e^{-j\frac{2k\pi}{2M+1}n} \] so that \[ |X_M[k]| = |\bar{X}_M(e^{j\frac{2\pi}{2M+1} k})| \] \end{enumerate} }\else{\vspace{1em}}\fi \end{exercise} \ifanswers{}\else{\vspace{0em}}\fi \end{document} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{exercise}{(40 points)} In digital communication systems it is often necessary to precisely establish a \textit{timing reference} between transmitter and receiver. To this end, the transmitter will send a signal that contains a detectable feature at time $t = t_0$; the receiver will receive the signal after a propagation delay $t_d$ and detect the feature at time $t_1 = t_0 + t_d$. From this point on, with the transmitter using $t_0$ as the reference and the receiver using $t_1$, transmitter and receiver will be synchronized. A common method to establish a timing reference is to send a sinusoidal carrier at frequency $f_c$ and to flip its sign at $t=t_0$, as illustrated in the following figure; by detecting the instant $t_1$ in which the phase jump occurs, the receiver achieves synchronization. \begin{center} \begin{dspPlot}[height=1cm,width=10cm,xout=true,xticks=custom,yticks=none,sidegap=0]{0,8}{-1.6, 1.6} \dspFunc{x 360 mul x 2 le {0} {180} ifelse add cos} \dspCustomTicks[axis=x]{2 $t_0$} \dspText(-0.5, 0){TX} \end{dspPlot} \vspace{-1.2em} \begin{dspPlot}[height=1cm,width=10cm,xout=true,xticks=custom,yticks=none,sidegap=0]{0.3,8.3}{-1.6, 1.6} \dspFunc[linecolor=gray]{x 360 mul x 5 le {0} {180} ifelse add cos} \dspCustomTicks[axis=x]{5 $t_1=t_0+t_d$} \dspText(-0.2, 0){RX} \end{dspPlot} \end{center} In this problem consider a simplified all-digital setup where the reference time at the transmitter is $n_0=0$; the transmitter's (infinite-length) timing signal at frequency $\omega_c > 0$ can be written as: \[ s[n] = p[n]\cos(\omega_c n), \quad\mbox{ with }\quad p[n] = \begin{cases} +1 & n < 0 \\ -1 & n \ge 0 \end{cases}. \] Assume that the propagation delay is equal to an integer number of samples so that the received digital signal is simply \[ x[n] = s[n - n_d], \qquad n_d \in \mathbb{N}^+. \] The signal $x[n]$ is processed at the receiver by the following system: \vspace{2ex} \begin{center} \begin{dspBlocks}{1.3}{0.5} & & \BDfilter{$H(z)$} & & & \\ $x[n]$~~ & \BDsplit & & \BDadd & \BDfilter{$D(z)$} & \BDfilter{$|\cdot|$} & ~~~$y[n]$ \\ \ncline{->}{2,1}{2,4} \ncline{->}{2,4}{2,5}^{$a[n]$~~~~} \ncline{->}{2,5}{2,6}^{$b[n]$} \ncline{->}{2,6}{2,7} \ncline{2,2}{1,2} \ncline{->}{1,2}{1,3} \ncline{1,3}{1,4}^{~~$j$} \ncline{->}{1,4}{2,4} \end{dspBlocks} \end{center} where $H(z)$ is an ideal Hilbert filter, $D(z)$ is a length-$N$ FIR with complex-valued impulse response \[ d[n] = \begin{cases} e^{j\omega_c n} & 0 \le n < N \\ 0 & \mbox{otherwise} \end{cases} \] and the last block computes the magnitude of the filter's output, that is, $y[n] = |b[n]|$. (See the hints at the end of the exercise if you're unsure about how the Hilbert filter affects the signal.) \begin{enumerate} \item {[15p]} Assume $n_d = 20$; plot $y[n]$ over the interval $0 \le n \le 50$ for $N = 10$ and $N = 30$. \item {[5p]} Describe a method to determine the value $n_d$ from $y[n]$. \item {[5p]} What is the minimum value of $N$ that you can use in theory? \item {[5p]} Why would you use a larger value than the theoretical minimum for $N$? \end{enumerate} \vspace{3ex} Consider now a situation where the channel introduces an unwanted DC offset and so the received signal is now \[ x[n] = s[n - n_d] + \epsilon, \] where $\epsilon$ is a positive real-valued constant. Assume the frequency of the timing signal is $\omega_c = 2\pi(A/B)$, with $A, B$ positive integers and $A<B$. \begin{enumerate} \setcounter{enumi}{4} \item {[10p]} Determine which values for $N$ minimize the effects of the DC offset on the detection process for $n_d$. \end{enumerate} \vspace{2em} \begin{mdframed}[backgroundcolor=gray!20] \footnotesize Hints: let $\mathcal{H}\{\cdot\}$ denote the result of applying a Hilbert filter to a signal; then you can assume the following: \vspace{-1ex} \begin{itemize} \item for a cosine-modulated signal: $\mathcal{H}\{w[n]\cos(\omega_0 n)\} = w[n]\sin(\omega_0 n)$ \item for a constant signal: $\mathcal{H}\{c\} = 0$ \end{itemize} \end{mdframed} \ifanswers{\em\vspace{3em}\par{\bfseries Solution: } With a propagation delay of zero the received signal would be $x[n] = s[n]$ and so \begin{align*} a[n] &= x[n] + j(x \ast h)[n] \\ &= p[n]\cos(\omega_c n) + j p[n]\sin(\omega_c n) \\ & = p[n]e^{j\omega_c n}. \end{align*} Because of time invariance, with a nonzero propagation delay $n_d$, it is \[ a[n] = p[n-n_d] e^{j\omega_c (n-n_d)}. \] The output of the FIR filter is \begin{align*} b[n] &= (a \ast d)[n] = \sum_{k=0}^{N-1} d[k]a[n-k] \\ &= \sum_{k=0}^{N-1} e^{j\omega_c k} e^{j\omega_c (n - n_d - k)} p[n - n_d - k] \\ &= e^{j\omega_c (n - n_d)}\sum_{k=0}^{N-1} p[n - n_d - k] \end{align*} and so \[ y[n] = |b[n]| = \left| \sum_{k=0}^{N-1} p[(n - n_d) - k]\right|. \] We can now distinguish three cases: \begin{itemize} \item when $n - n_d < 0$, the argument to $p[\cdot]$, i.e. $(n - n_d) - k$, will be negative for all values of $k$ in the sum and so \[ y[n] = \left| \sum_{k=0}^{N-1} 1\right| = N \quad \mbox{for $n < n_d$} \] \item similarly, when $n - n_d \ge N - 1$, the argument to $p[\cdot]$ will be non-negative for all $k$ and so \[ y[n] = \left| \sum_{k=0}^{N-1} -1\right| = N \quad \mbox{for $n \ge n_d + N - 1$} \] \item for the other cases, i.e. for $n_d \le n < n_d + N - 1$ it is \[ y[n] = \left| \sum_{k=0}^{n - n_d} 1 + \sum_{m=n - n_d + 1}^{N - 1} -1 \right| = |N - 2(n - n_d + 1)|. \] \end{itemize} \begin{enumerate} \item For a given value of $n_d$, the output $y[n]$ will be equal to $N$ for $n < n_d$ and for $n > n_d + N - 1$ while, in between these values, it will decrease linearly to a minumum value of zero for $n = n_d + N/2 - 1$ and then climb up back to $N$: \def\yfun#1#2{x #1 1 sub le {#2 } {x #1 #2 1 sub add ge {#2 } {#2 x #1 sub 1 add 2 mul sub abs} ifelse} ifelse} \begin{center} \begin{dspPlot}[height=3cm,width=10cm,xout=true,xticks=10]{0,60}{0,12} \dspFunc{\yfun{20}{10}} \dspTaps{19 10 20 8} \dspCustomTicks[axis=x]{24 24} \dspText(5, 6){$N=10$} \end{dspPlot} \begin{dspPlot}[height=3cm,width=10cm,xout=true,xticks=10]{0,60}{0,32} \dspFunc{\yfun{20}{30}} \dspText(5, 15){$N=30$} \dspTaps{19 30 20 28} \dspCustomTicks[axis=x]{34 34} \end{dspPlot} \end{center} \item In the ideal case, $y[n]$ starts to drop from its initial value of $N$ exactly for $n = n_d$, that is, $y[n] = N$ for $n < n_d$ and $y[n_d] = N-2$. So a simple detection scheme would place a threshold on $y[n]$ and look for its first ``dip'' from $N$ to $N-2$. \item In the ideal case, for the method just described, we need a minimum FIR length $N=2$. \item In non-ideal cases, the presence of noise would make $y[n]$ noisy as well. By using a filter of length $N$ the difference between the maximum and minimum values of $y[n]$ is equal to $N$ and so, if we use a long filter, we increase the noise margin in our estimation process. \item If $x[n] = s[n - n_d] + \epsilon$ then, by linearity, \[ a[n] = p[n-n_d] e^{j\omega_c (n-n_d)} + \epsilon \] and \[ b[n] = e^{j\omega_c (n - n_d)}\sum_{k=0}^{N-1} p[n - n_d - k] + \epsilon\sum_{k=0}^{N-1}e^{j\omega_c k} \] Since $\omega_c = 2\pi(A/B)$, the effect of the DC offset will be eliminated for any value of $N$ that is a multiple of $B$ \[ N = mB, \quad m\in \mathbb{N}^+ \] since the orthogonality of the roots of unity implies that \[ \sum_{k=0}^{mB-1}e^{j\frac{2\pi}{B}Ak} = \frac{1 - e^{j\frac{2\pi}{B}AmB}}{1 - e^{j\frac{2\pi}{B}A}} = \frac{1 - e^{j 2\pi Am}}{1 - e^{j\frac{2\pi}{B}A}} = 0. \] \end{enumerate} \vspace{1em} }\else{\vspace{1em}}\fi \end{exercise} \ifanswers{}\else{\vspace{10em}}\fi %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{exercise}{(20 points)} In the following figure there are four input signals in the left column, four pole-zero plots in the middle, and four output signals on the right. For each input signal $x_i[n]$, $i = 1, 2, 3, 4$, find the filter $h_j[n]$ and the output $y_k[n]$ so that $y_k[n] = (x_i \ast h_j)[n]$. Assume that all filters are causal and all signals are infinite support (continuing in the obvious way outside of the plotted range). In your answer simply list four triples of the form $i \rightarrow j \rightarrow k$. \def\sigPlot#1{ \hspace{-1em} \begin{dspPlot}[height=2.5cm,width=4.5cm,xout=true,xticks=5]{-11,11}{-1.2,1.2} \dspSignal{#1} \end{dspPlot}} \def\xa{\sigPlot{x 0 eq {1} {0} ifelse}} \def\xb{\sigPlot{x 0 ge {1} {0} ifelse}} \def\xc{\sigPlot{x 180 mul cos 0.75 mul 0.25 add}} \def\xd{\sigPlot{x 11 add cvi 8 mod 8 div}} \def\ya{\sigPlot{x 0 lt {0} {x 6 ge {0} {0.1666} ifelse} ifelse}} \def\yb{\sigPlot{x 0 lt {0} {1 0.8 x exp sub} ifelse}} % \dspSignalOpt{\dspSetFilter{0.2}{-0.8}}{x 0 ge {1} {0} ifelse \dspFilter} \def\yc{\sigPlot{0.5}} \def\yd{\sigPlot{x 360 8 div mul 202.5 add cos}} % \dspSignalOpt[linecolor=gray]{\dspSetFilter{1 1.4142 1 0 -1 -1.4142 -1}{}}{x 11 add cvi 8 mod 8 div \dspFilter} \def\zplane#1{ \hspace{-1.3em} \begin{dspPZPlot}[width=3cm,clabel=~]{1.5} #1 \end{dspPZPlot}} \def\za{\zplane{ \dspPZ[type=zero,label=none]{0.5,0.866} \dspPZ[type=zero,label=none]{0.5,-0.866} \dspPZ[type=zero,label=none]{-1,0} \dspPZ[type=zero,label=none]{-0.5,0.866} \dspPZ[type=zero,label=none]{-0.5,-0.866}}} \def\zb{\zplane{ \dspPZ[label=none]{0.8, 0}}} \def\zc{\zplane{\dspPZ[type=zero,label=none]{-1,0}}} \def\zd{\zplane{ \dspPZ[type=zero,label=none]{1,0} \dspPZ[type=zero,label=none]{0,1} \dspPZ[type=zero,label=none]{0,-1} \dspPZ[type=zero,label=none]{-1,0} \dspPZ[type=zero,label=none]{-0.707,0.707} \dspPZ[type=zero,label=none]{-0.707,-0.707}}} \ifanswers{\em\vspace{1em}\par{\bfseries Solution: } In the figure below, the input signals, the filters and the corresponding outputs have been arranged so that each row shows a correct input-filter-output triple. Note that your exam copy used a randomized indexing of the signals so the numbering will not necessarily coincide. To establish each triple, we can look more in detail at each item in the figure. \begin{enumerate} \item Observations about the inputs: \begin{itemize} \item $x_1[n] = \delta[n]$ and so the corresponding output will be the impulse response of the associated filter; \item $x_2[n] = u[n]$ and so the corresponding output will be the integrated impulse response of the associated filter, i.e., $y[n] = \sum_{k=0}^{n}h[k]$; \item $x_3[n]$ is a periodic signal with period 2 (i.e. with the fastest possible frequency); it will therefore contain a term of the form $(-1)^n$ and, from the plot, it is easy to see that $x_3[n] = 0.75\,(-1)^n + 0.25$; \item $x_4[n]$ is a periodic signal with period 8 and so it can be expressed as $x_4[n] = \sum_{k=0}^{7} \alpha_k e^{j\pi kn / 4}$. \end{itemize} \item Observations about the filters: note that a pole-zero plot determine the transfer function of a filter up to an unknown scaling factor $c$; with this, \begin{itemize} \item $H_1(z)$ is the pole-zero plot of a moving average filter of length 6, with impulse response $h_1[n] = c(u[n] - u[n-6])$; \item $H_2(z)$ is the pole-zero plot of a leaky integrator with impulse response $h_2[n] = c \lambda^n$, $0 < \lambda < 1$; \item $H_3(z)$ is an FIR with a single zero in $z=-1$ and thus it implements the CCDE $y[n] = c(x[n] + x[n-1])$; \item $H_4(z)$ is an FIR with zeros at $e^{j\pi k/4}$ for $k = 0, \pm 2, \pm 3, 4$ and so it will cancel out any sinusoidal input component at frequencies $\omega_k = \pi k/4$ except for $k=\pm 1$. \end{itemize} \item Observations about the outputs: \begin{itemize} \item $y_1[n]$ is the impulse response of a moving average of length 6 so $y_1[n] = (x_1 \ast h_1)[n]$; \item $y_2[n]$ starts at zero and grows exponentially and asymptotically; the shape is compatible with an expression of the form $y_2[n] = \sum_{k=0}^{n}\lambda^n$ for $0 < \lambda < 1$ so $y_2[n] = (x_2 \ast h_2)[n]$ \item $y_3[n]$ is a noncausal signal with infinite support and therefore the input can only be $x_3[n]$ or $x_4[n]$. By applying $H_3(z)$ to $x_3[n]$ we obtain $y[n] = x_3[n] + x_3[n-1] = 0.5 = y_3[n]$ \item $y_4[n]$ is a sinusoid of the form $\cos((\pi/4) n + \theta)$; since $H_4(z)$ cancels all frequencies at multiples of $\pi/4$ except $\pm \pi/4$ and since $x_4[n]$ contains only frequencies at multiples of $\pi/4$, $y_4[n] = (x_4 \ast h_4)[n]$ \end{itemize} \end{enumerate} \begin{center} \begin{tabular}{c|c|c} \xa & \za & \ya \\ $x_1[n]$ & $H_1(z)$ & $y_1[n]$ \\[2em] % \xb & \zb & \yb \\ $x_2[n]$ & $H_2(z)$ & $y_2[n]$ \\[2em] % \xc & \zc & \yc \\ $x_3[n]$ & $H_3(z)$ & $y_3[n]$ \\[2em] % \xd & \zd & \yd \\ $x_4[n]$ & $H_4(z)$ & $y_4[n]$ \end{tabular} \end{center} % Triples by exam version:\\ % I:~~~~ $1 \rightarrow 3 \rightarrow 3, \quad % 2 \rightarrow 2 \rightarrow 1, \quad % 3 \rightarrow 1 \rightarrow 4, \quad % 4 \rightarrow 4 \rightarrow 2$. % % II:~~~~ $1 \rightarrow 4 \rightarrow 3, \quad % 2 \rightarrow 1 \rightarrow 4, \quad % 3 \rightarrow 2 \rightarrow 2, \quad % 4 \rightarrow 3 \rightarrow 1$. % % III:~~~~ $1 \rightarrow 4 \rightarrow 3, \quad % 2 \rightarrow 3 \rightarrow 1, \quad % 3 \rightarrow 1 \rightarrow 2, \quad % 4 \rightarrow 2 \rightarrow 4$. }\else{ \ifnum\exver=2 { \begin{center} \begin{tabular}{c|c|c} \xc & \zb & \yd \\ $x_1[n]$ & $H_1(z)$ & $y_1[n]$ \\[2em] % \xb & \za & \ya \\ $x_2[n]$ & $H_2(z)$ & $y_2[n]$ \\[2em] % \xa & \zd & \yc \\ $x_3[n]$ & $H_3(z)$ & $y_3[n]$ \\[2em] % \xd & \zc & \yb \\ $x_4[n]$ & $H_4(z)$ & $y_4[n]$ \end{tabular} \end{center} }\else\ifnum\exver=3 { \begin{center} \begin{tabular}{c|c|c} \xa & \zd & \yb \\ $x_1[n]$ & $H_1(z)$ & $y_1[n]$ \\[2em] % \xb & \zc & \yd \\ $x_2[n]$ & $H_2(z)$ & $y_2[n]$ \\[2em] % \xd & \zb & \ya \\ $x_3[n]$ & $H_3(z)$ & $y_3[n]$ \\[2em] % \xc & \za & \yc \\ $x_4[n]$ & $H_4(z)$ & $y_4[n]$ \end{tabular} \end{center} }\else{ \begin{center} \begin{tabular}{c|c|c} \xc & \za & \yb \\ $x_1[n]$ & $H_1(z)$ & $y_1[n]$ \\[2em] % \xb & \zb & \yd \\ $x_2[n]$ & $H_2(z)$ & $y_2[n]$ \\[2em] % \xa & \zc & \yc \\ $x_3[n]$ & $H_3(z)$ & $y_3[n]$ \\[2em] % \xd & \zd & \ya \\ $x_4[n]$ & $H_4(z)$ & $y_4[n]$ \end{tabular} \end{center} }\fi\fi \vspace{-100em} }\fi \end{exercise} \end{document} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{exercise}{(10 points)} Compute and sketch the DTFT of the following signal \[ x[n] = \delta[n] + u[n+1] - u[n-2] - \sinc(n/3). \] \ifanswers{\em\vspace{3em}\par{\bfseries Solution: } First of all, note that the signal is real and symmetric and therefore its DTFT will also be real and symmetric. Now call \[ a[n] = \delta[n] + u[n+1] - u[n-2] = \begin{cases} 2 & n = 0 \\ 1 & |n| = 1 \\ 0 & \mbox{otherwise} \end{cases} \] and therefore \[ A(e^{j\omega}) = \sum_{n=-1}^{1} a[n]e^{-j\omega n} = e^{j\omega} + 2 + e^{-j\omega} = 2 + 2\cos(\omega). \] The DTFT of $\sinc(n/3)$ is a rect of height three and support $[-\pi/3, \pi/3]$ and so \[ X(e^{j\omega}) = 2 + 2\cos(\omega) - 3\rect(3\omega/2\pi). \] \begin{center} \begin{dspPlot}[xtype=freq,xticks=3,yticks=1]{-1,1}{0, 3.5} \dspFunc{x 180 mul cos 2 mul 2 add x \dspRect{0}{0.666666} 3 mul sub} \end{dspPlot} \end{center} }\else{\vspace{1em}}\fi \end{exercise} \ifanswers{}\else{\vspace{10em}}\fi %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{exercise}{(10 points)} Consider a causal LTI system with transfer function \[ H(z) = \frac{1}{1-e^{j\omega_0} z^{-1}} \qquad \omega_0 \in \mathbb{R}. \] Prove that the system is not BIBO stable by finding a causal bounded input signal that makes the output grow to infinity. \ifanswers{\em\vspace{3em}\par{\bfseries Solution: } From simple inspection, the CCDE describing the system is \[ y[n] = x[n] + e^{j\omega_0}\, y[n] \] so that the impulse response is the sequence \[ h[n] = e^{j\omega_0 n}u[n]. \] Since $|h[n]| = 1$ for $n \ge 0$ the impulse response is not absolutely summable and therefore the system is not BIBO stable. For a generic causal input $x[n]$ the output is \[ y[n] = (x\ast h)[n] = \sum_{k=0}^{n} x[k]e^{j\omega_0(n-k)} = e^{j\omega_0 n}\sum_{k=0}^{n} x[k]e^{-j\omega_0 k}. \] By choosing $x[n] = e^{j\omega_0 n}\, u[n]$, the above result becomes \[ y[n] = e^{j\omega_0 n}\sum_{k=0}^{n} e^{j\omega_0 k}e^{-j\omega_0 k} = (n+1)e^{j\omega_0 n} \] ans since $|y[n]| = n+1$, the output grows unbounded. }\else{\vspace{1em}}\fi \end{exercise} \ifanswers{}\else{\vspace{10em}}\fi %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{exercise}{(10 points)} Although the harmonic series is divergent, i.e., $\sum_{k=1}^{\infty} 1/k = \infty$, very similar derived series are surprisingly convergent. The so-called Leibniz formula, for instance, uses only the odd-indexed terms with alternating sign to yield \[ \sum_{k=0}^{\infty} \frac{(-1)^k}{2k + 1} = 1 - \frac{1}{3} + \frac{1}{5} - \frac{1}{7} + \ldots = \frac{\pi}{4}. \] Consider now a continuous-time square wave $x(t)$ with period $P$, as shown in the figure below. Knowing that the signal can be expressed as the Fourier series \[ x(t) = \frac{4}{\pi}\sum_{k=1}^{\infty}\frac{1}{2k-1}\sin(2\pi(2k-1)f_0 t) \] prove Leibniz formula by a surprising result is that the alternating \ifanswers{\em\vspace{3em}\par{\bfseries Solution: } From simple inspection, the CCDE describing the system is \[ y[n] = x[n] + e^{j\omega_0}\, y[n] \] so that the impulse response is the sequence \[ h[n] = e^{j\omega_0 n}u[n]. \] Since $|h[n]| = 1$ for $n \ge 0$ the impulse response is not absolutely summable and therefore the system is not BIBO stable. For a generic causal input $x[n]$ the output is \[ y[n] = (x\ast h)[n] = \sum_{k=0}^{n} x[k]e^{j\omega_0(n-k)} = e^{j\omega_0 n}\sum_{k=0}^{n} x[k]e^{-j\omega_0 k}. \] By choosing $x[n] = e^{j\omega_0 n}\, u[n]$, the above result becomes \[ y[n] = e^{j\omega_0 n}\sum_{k=0}^{n} e^{j\omega_0 k}e^{-j\omega_0 k} = (n+1)e^{j\omega_0 n} \] ans since $|y[n]| = n+1$, the output grows unbounded. }\else{\vspace{1em}}\fi \end{exercise} \ifanswers{}\else{\vspace{10em}}\fi %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{exercise}{(20 points)} In 1734 Euler famously solved the so-called \textit{Basel problem}\/ by proving that \[ \sum_{n=1}^{\infty} \frac{1}{n^2} = \frac{\pi^2}{6}. \] As a signal processing expert, re-derive Euler's result by using the fact that the Hilbert filter, whose frequency response is allpass, has impulse response \[ h[n] = \begin{cases} 0 & \mbox{$n$ even} \\ \frac{2}{\pi n} & \mbox{$n$ odd}. \end{cases} \] \vspace{1em} {\footnotesize \it Hint: at some point in the proof you may find it useful to split a series into even and odd terms: $\sum_{n=1}^{\infty} a_n = \sum_{n=1}^{\infty} a_{2n} + \sum_{n=1}^{\infty} a_{2n - 1}$.} \ifanswers{\em\vspace{3em}\par{\bfseries Solution: } Since the Hilbert filter is allpass, its $L_2$ norm is one: \[ \|H(e^{j\omega})\|^2 = \frac{1}{2\pi}\int_{-\pi}^{\pi} |H(e^{j\omega})|^2 d\omega = \frac{1}{2\pi}\int_{-\pi}^{\pi} d\omega = 1. \] By Parseval's theorem we therefore have that \[ \|h[n]\|^2 = \|H(e^{j\omega})\|^2 = 1 \] and so \[ \sum_{n=-\infty}^{\infty} |h[n]|^2 = 2\sum_{n=1}^{\infty}\left(\frac{2}{\pi (2n-1)}\right)^2 = \frac{8}{\pi^2}\sum_{n=1}^{\infty}\frac{1}{(2n-1)^2} = 1 \] from which \[ \sum_{n=1}^{\infty}\frac{1}{(2n-1)^2} = \frac{\pi^2}{8}. \] Now we can write \[ \sum_{n=1}^{\infty} \frac{1}{n^2} = \sum_{n=1}^{\infty} \frac{1}{(2n)^2} + \sum_{n=1}^{\infty} \frac{1}{(2n-1)^2} = \frac{1}{4}\sum_{n=1}^{\infty} \frac{1}{n^2} + \sum_{n=1}^{\infty} \frac{1}{(2n-1)^2} \] so that \[ \sum_{n=1}^{\infty} \frac{1}{n^2} = \frac{4}{3} \sum_{n=1}^{\infty} \frac{1}{(2n-1)^2} = \frac{\pi^2}{6}. \] }\else{\vspace{1em}}\fi \end{exercise} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{exercise}{(20 points)} Determine the range of the real-valued feedback parameter $r$ for which the causal system implemented by the following block diagram is stable: \vspace{2em} \begin{center} \begin{dspBlocks}{1.2}{0.4} & & & & \\ $x[n]$~~~~ & \BDadd & \BDsplit & \BDsplit & ~~~~~$y[n]$ \\% & & \BDdelay & & \\% & \BDadd & \BDsplit & & \\% & & \BDdelay & & \\% & & & & \psset{arrows=->,linewidth=1.5pt} \ncline{2,1}{2,2} \ncline{2,2}{2,5} \ncline{-}{4,3}{4,2} \taput{$1/2$} \ncline{-}{6,3}{6,2}\taput{$-1$} \ncline{2,3}{3,3} \ncline{3,3}{5,3} \ncline{-}{5,3}{6,3} \ncline{6,2}{4,2} \ncline{4,2}{2,2} \ncline{1,2}{2,2}\ncline{-}{2,4}{1,4}\ncline{-}{1,4}{1,2}\taput{$r$} \end{dspBlocks} \end{center} \ifanswers{\em\vspace{3em}\par{\bfseries Solution: } The block diagram can be redrawn as \vspace{2em} \begin{center} \begin{dspBlocks}{1.2}{0.4} & & & & \\ $x[n]$~~~~ & \BDadd & \BDfilter{$G(z)$} & \BDsplit & ~~~~~$y[n]$ \\% \psset{arrows=->,linewidth=1.5pt} \ncline{2,1}{2,2} \ncline{2,2}{2,3}\ncline{2,3}{2,5} \ncline{1,2}{2,2}\ncline{-}{2,4}{1,4}\ncline{-}{1,4}{1,2}\taput{$r$} \end{dspBlocks} \end{center} where $G(z)$ is a pure-feedback second order system with transfer function \[ G(z) = \frac{1}{1 + z^{-1} + z^{-2}} = \frac{1}{A(z)}. \] The overall input-output relation is thus $Y(z) = G(z)[X(z) + rY(z)]$ and so the system's transfer function is \[ H(z) = \frac{G(z)}{1 - rG(z)} = \frac{1}{A(z) - r} \] }\else{\vspace{1em}}\fi \end{exercise} \end{document} diff --git a/teaching/COM303/com303-TA b/teaching/COM303/com303-TA index b211bd2..62950b1 160000 --- a/teaching/COM303/com303-TA +++ b/teaching/COM303/com303-TA @@ -1 +1 @@ -Subproject commit b211bd21e616cc4f1dec5242b76872134c1dd117 +Subproject commit 62950b1bcc68d70f4af38d07a054b835978ff2e3 diff --git a/teaching/COM418/lectures/styles/com418.sty b/teaching/COM418/lectures/styles/com418.sty index 2c77344..306b367 100644 --- a/teaching/COM418/lectures/styles/com418.sty +++ b/teaching/COM418/lectures/styles/com418.sty @@ -1,196 +1,198 @@ \ProvidesPackage{dspmooc} % trick to avoid changing TEXINPUTS (hard on Mac) % use a relative path for includes. Set \stylepath in your latex file and then % use \usepackage{\stylepath/dspmooc} \makeatletter \@ifundefined{stylepath}{\def\stylepath{../styles}}{} \makeatother + %% Additional packages \usepackage{etex} \usepackage{amsmath, amsfonts, epsfig, xspace, extarrows,mathtools} \usepackage{multimedia} \usepackage[normal,tight,center]{subfigure} \usepackage[abs]{overpic} \usepackage[absolute,overlay]{textpos} \setlength{\TPHorizModule}{1mm} \setlength{\TPVertModule}{1mm} \usepackage{graphicx} \usepackage{docmute} \usepackage{array} \usepackage{comment} %% Custom packages \usepackage{\stylepath/dspTricks} \usepackage{\stylepath/dspFunctions} \usepackage{\stylepath/dspBlocks} \usepackage{\stylepath/dspComm} % EPFL logo \def\smallEPFL{\begin{textblock*}{56pt}[1,0](\paperwidth,3.5pt) \includegraphics[height=20pt]{\stylepath/EPFLbanner.eps} \end{textblock*}} \addtobeamertemplate{frametitle}{}{\logoEPFL} \def\logoEPFL{} % no logo, useful until final compile %\def\logoEPFL{\smallEPFL} %% Credits \title[CM]{COM418: Computers and Music} + %% Beamer options \def\modnum{} \newcommand{\lect}[1]{\def\lecnum{#1}} \let\oldtitle\title \renewcommand{\title}[2][Lecture \lecnum:]{\subtitle{#1 #2}} \usecolortheme{beaver} \setbeamercolor{local structure}{fg=Dandelion} \setbeamerfont{titlelike}{series=\bfseries} \setbeamercolor{titlelike}{bg=Dandelion!70,fg=White} \setbeamercolor{frametitle}{bg=Dandelion!70,fg=White} \setbeamerfont{frametitle}{series=\bfseries} \setbeamertemplate{items}[square] \setbeamertemplate{navigation symbols}{} \setbeamertemplate{note page}{% \rput[lt](0.8\textwidth,0){\insertslideintonotes{0.42}} \vspace{1em} \\ \footnotesize\insertnote} \setbeamertemplate{footline}{\insertframenumber} \setbeamertemplate{itemize/enumerate subbody begin}{\vspace{0.5em}} % footer \useoutertheme{infolines} \setbeamertemplate{headline}{} \setbeamertemplate{footline}{% \leavevmode% \parbox{\paperwidth}{% \usebeamerfont{date in head/foot}\color{Dandelion} \hspace*{1ex} \modnum \hfill \insertframenumber{}\hspace*{1ex}} \vskip3pt } % title page \defbeamertemplate*{title page}{dsp}[1][]{% \begin{textblock*}{80pt}[1,0](\paperwidth,6.25pt) \includegraphics[height=32pt]{\stylepath/EPFL.eps} \end{textblock*} \begin{textblock*}{25mm}[1,1.2](\paperwidth,\paperheight) \small\insertauthor \end{textblock*} \begin{flushright} \vfill \begin{beamercolorbox}[wd=\paperwidth,ht=3.5ex,dp=2ex,right]{titlelike} \Large\bfseries\inserttitle\hspace{0.8em} \end{beamercolorbox}% \vskip1em\par \normalsize\insertsubtitle\par \small\insertdate\par\vskip1.5em \end{flushright} \vfill } \renewcommand{\maketitle}{% \begin{frame}[plain,noframenumbering] \titlepage \end{frame}} \def\intertitle#1{ \begin{frame}[plain,noframenumbering] \begin{flushright} \vfill \begin{beamercolorbox}[wd=\paperwidth,ht=3.5ex,dp=2ex,right]{titlelike} \Large\bfseries #1\hspace{0.8em} \end{beamercolorbox}% %\vskip1em\par %\normalsize\insertsubtitle\par %\small\insertdate\par\vskip1.5em \end{flushright} \vfill \end{frame}} % cue card (empty white slide with just a sentence across) \def\cueCard#1{% \begin{frame}[plain,noframenumbering] \centering \Huge #1 \par \end{frame}} \def\endModule#1{\cueCard{END OF MODULE #1}} \def\endMoocMod{\endModule{\modnum}} \newcommand{\intro}[2][1]{% \note<#1>{\vspace{10em} #2}} %% stretch the vertical spacing \newlength{\wideitemsep} \setlength{\wideitemsep}{\itemsep} \addtolength{\wideitemsep}{0.8ex} \let\olditem\item \renewcommand{\item}{\setlength{\itemsep}{\wideitemsep}\olditem} \setbeamertemplate{itemize subitem}{$\bullet$} \setbeamertemplate{itemize subsubitem}{$-$} \addtolength{\jot}{0.7ex} \setbeamercovered{transparent} %% Macros \setlength{\subfigcapskip}{-.5em} % dspPlot styles: \def\smallStems{\setlength{\dspStemWidth}{0.8pt}\setlength{\dspDotSize}{4pt}\setlength{\dspLineWidth}{1.5pt}} \def\moocStyle{\smallStems\psset{linecolor=darkred}} \definecolor{darkgreen}{rgb}{0.13,0.54,0.13} % Black slide \def\blackScreen{\bgroup\setbeamercolor{background canvas}{bg=black}\begin{frame}[plain]{}\end{frame}\egroup} % dspPlot sizes: %\def\rowOfTwo{width=0.3\paperwidth,height=0.25\paperheight} % 2 plots in a row \def\rowOfTwo{width=6cm,height=3cm} % 2 plots in a row % Math operators \def\DFT#1{\mbox{DFT}\left\{#1\right\}} \def\IDFT#1{\mbox{IDFT}\left\{#1\right\}} \def\DFS#1{\mbox{DFS}\left\{#1\right\}} \def\IDFS#1{\mbox{IDFS}\left\{#1\right\}} \def\DTFT#1{\mbox{DTFT}\left\{#1\right\}} \def\IDTFT#1{\mbox{IDTFT}\left\{#1\right\}} \def\FT#1{\mbox{FT}\left\{#1\right\}} \def\IFT#1{\mbox{IFT}\left\{#1\right\}} \def\expt#1{\mbox{E}\left[#1\right]} \DeclareMathOperator{\sinc}{sinc} \DeclareMathOperator{\rect}{rect} \DeclareMathOperator{\Real}{Re} \DeclareMathOperator{\Imag}{Im} % line vectors %\def\rowvector#1#2{\left[ \begin{array}{#1} #2 \end{array} \right]^T} \def\myvector#1{\begin{bmatrix} #1 \end{bmatrix}} % highlight box for arrows onto formula elements. % Arguments: [vphantom (optional)]{node name}{color}{text} % ex: \hlBox[\sum_0^0]{t2}{blue!30}{\cos(\omega_0 n)} % followed by \nccurve[angleB=-75]{->}{T1}{t1} \newcommand{\hlBox}[4][X_0^0]{% \rnode{#2}{\psframebox[fillcolor=#3,fillstyle=solid,linewidth=0pt]{\vphantom{#1} #4}}} %% images for the image processing module \def\imagePath{.} % load and display generic image file \newcommand\showImage[2][6cm]{% \dspShowImage[#1]{\imagePath/#2.eps}} \definecolor{dspMainColor}{rgb}{0.54,0,0} \definecolor{dspColorTwo}{rgb}{0,0.33,0.71} \definecolor{dspColorThree}{rgb}{0.03,0.47,0.19} \definecolor{dspColorFour}{rgb}{1,0.56,0} \definecolor{dspColorLight}{rgb}{0.5,0.5,0.5} \definecolor{dspColorLightest}{rgb}{0.75,0.75,0.75} \ No newline at end of file diff --git a/writing/agora/final report/final_scientific_report.doc b/writing/agora/final report/final_scientific_report.doc index 99019bb..4d4dc3f 100644 Binary files a/writing/agora/final report/final_scientific_report.doc and b/writing/agora/final report/final_scientific_report.doc differ