{\LARGE\bfseries COM-303 - ``Mock'' Midterm Exam - Spring 2020}\\
\vspace{1em}
{\large}
\vspace{1em}
\end{center}
\centerline{\rule{\textwidth}{.5pt}}
\begin{itemize}
\item This mock midterm exam is not graded and it is designed to test your understanding of the material so far
\item Tlthough the test is take-home, try to work on the problems as if taking a real exam; this means \textbf{no internet, no group work and a maximum time of three hours.}
\item The scores indicate the difficulty of the problem; the total is 100 points.
\item The solution will be discussed in the first class after the break.
Since we will need to determine the stability of the system later, we can already factorize $A(z)$ by simple inspection as
\[
A(z)=(1-\frac{1}{2}z^{-1})^2.
\]
We can also try to see if the root of $A(z)$ is also a root of $B(z)$: indeed $B(1/2)=0$. We can now factor $B(z)$ either by performing polynomial division or by noticing that both $+1$ and $-1$ are also roots; we have
% \item multiplication by $e^{-j\omega_k n}$ in time corresponds to a left shift by $\omega_k = k(\pi/3)$ in frequency. Because of the $2\pi$-periodicity of the spectrum, the shift appears as a circular shift over the $[-\pi, \pi]$ range: \\ \vspace{0.6em} \\
{\bfseries Frequency-domain solution:}$(1/2)\sinc(n/2)$ is the impulse response of an ideal lowpass with cutoff frequency $\omega_c =\pi/2$. Therefore, the left-hand side is the impulse response of an ideal highpass with cutoff frequency $\omega_c =\pi/2$. The right-hand side is the lowpass impulse response modulated by $\cos(\pi n)$, which shifts the frequency response by $\pi$; therefore that too is the impulse response of an ideal highpass with cutoff frequency $\omega_c =\pi/2$.
To plot these spectra, we just need to pay attention to the potential aliasing introduced by the modulation; in the following plots, first we show the distinct spectral terms and then their sum:
\ifanswers{\em\vspace{3em}\par{\bfseries Solution: } The convolution is defined as
\[
y[n]=\sum_{k=-\infty}^{\infty}x[k]h[n-k].
\]
If we plot $x[k]$ and, correspondigly, the nonzero portion of $h[n-k]$ for varying values of $n$ we can easily see that the nonzero portions of $x[k]$ and $h[n-k]$ overlap only for eight values of $n$, namely for $-2\leq n \leq5$:
Consider a Type-IV linear phase filter of length 6. If you know that one of the zeros is at $z =0.5\,e^{j\pi/5}$, write out the remaining zeros of the transfer function.
Any 6-tap FIR has 5 zeros, since its transfer function is a polynomial of degree 5. A type-IV filter has always a zero in $z=0$ and any other zero is subject to the symmetry constraints for linear-phase FIRs; in particular, for a complex-valued zero $z_0$, also $z^*_0$, $1/z_0$ and $1/z^*_0$ are zeros. So the five zeros are: