# Practice Quiz 2

The questions below are due on Monday March 29, 2021; 10:00:00 PM.

You are not logged in.

Note that this link will take you to an external site (https://shimmer.csail.mit.edu) to authenticate, and then you will be redirected back to this page.

You will have one hour and fifty minutes to complete this quiz. During the quiz, you may reference one sheet (front and back) of hand-written or printed notes, but you may not make use of other outside resources, including other pages on the Internet. You may use as much scratch paper as you like during the quiz, and your scratch work will not be collected.

This practice quiz consists of 5 questions. Please make sure to submit your answer to each question (you may submit as many times as you like during the quiz).

• omega represents \omega
• OMEGA represents \Omega
• sin and cos represent \sin(\cdot) and \cos(\cdot), respectively
• sqrt represents the square root function
• e, j, and pi represent e, j, and \pi, respectively

## 1) Peaks and Valleys

Consider a family of signals that can be described by the following equation (where \alpha and m are parameters):

\displaystyle x[n] = \sum_{i=0}^\infty \alpha^{i}\delta[n - im]

An example of such a function is shown below, for \alpha = 0.9 and m = 3.

Consider also the following graphs, each of which shows the magnitude of the DTFT of such a signal when

Which plot shows the magnitude of the DTFT when \alpha=0.7 and m=1?

Which plot shows the magnitude of the DTFT when \alpha=-0.5 and m=3?

Which plot shows the magnitude of the DTFT when \alpha=-0.8 and m=2?

Which plot shows the magnitude of the DTFT when \alpha=0.8 and m=2?

## 2) DFTs

The left column below shows six discrete-time signals for 0\le n\le31. The right column shows plots of the magnitudes of six DFTs computed for N=32. For each discrete-time signal in the left column below, find the matching DFT magnitude (one of plots A--F).

Which plot shows the magnitude of the DFT of x_1[n]?

Which plot shows the magnitude of the DFT of x_2[n]?

Which plot shows the magnitude of the DFT of x_3[n]?

Which plot shows the magnitude of the DFT of x_4[n]?

Which plot shows the magnitude of the DFT of x_5[n]?

Which plot shows the magnitude of the DFT of x_6[n]?

## 3) Trigonometric Fourier Series

#### Part 1

We would like to represent the following CT signal

f(t) = 2\cos\left({\pi\over 3}t\right)\sin\left({\pi\over 4}t\right) + 3

using a trigonometric Fourier series of the following form:

f(t) = \sum_{k=0}^M c_k\cos\left({2\pi k\over T}t\right) + \sum_{k=1}^M d_k\sin\left({2\pi k\over T} t\right)

Determine the following parameters of the trigonometric representation:

The fundamental period T of this signal:
T = ~

M, which represents the highest harmonic needed for this signal (i.e., where all c_k and d_k are 0 for k>M):
M =~

All nonzero values of c_k, for 0\leq k\leq M. Enter your answer as a Python dictionary mapping k values to the corresponding c_k values. Enter a single number for each c_k value (not a more complicated expression).

Nonzero c_k values:

All nonzero values of d_k, for 0< k\leq M. Enter your answer as a Python dictionary mapping k values to the corresponding d_k values. Enter a single number for each d_k value (not a more complicated expression).

Nonzero d_k values:

#### Part 2

Let f[n] represent a discrete-time signal whose Fourier series coefficients F[k] are periodic in N=5, i.e., F[k]=F[k+5] for all integers k. The following plots show the magnitude and angle of F[k] over one period:

We wish to find the coefficients of a trigonometric representation for f[n] with the following form:

f[n] = \sum_{k=0}^M c_k\cos\left({2\pi k\over N}n\right) + \sum_{k=1}^M d_k\sin\left({2\pi k\over N} n\right)

Determine the following parameters of the trigonometric representation:

The fundamental period N of this signal:
N = ~

M, which represents the highest harmonic needed for this signal (i.e., where all c_k and d_k are 0 for k>M):
M =~

All nonzero values of c_k, for 0\leq k\leq M. Enter your answer as a Python dictionary mapping k values to the corresponding c_k values. Enter a single number for each c_k value (not a more complicated expression).

Nonzero c_k values:

All nonzero values of d_k, for 0< k\leq M. Enter your answer as a Python dictionary mapping k values to the corresponding d_k values. Enter a single number for each d_k value (not a more complicated expression).

Nonzero d_k values:

## 4) Signal Facts

Suppose we are given the following facts about a signal x[\cdot] (and its Fourier series coefficients X[\cdot]):

• x[\cdot] is periodic and real-valued.

• \displaystyle \max\left(x[n]\right) = 5

• X[k-6] = X[k] for all k

• X[2] = 0

• y[n] = x[n] - 1 is a antisymmetric function of n.

• \displaystyle \frac{1}{6}\sum_{n=-2}^{3}(-1)^nx[n] = 0

• {\rm Im}(X[1]) > 0

Answer the following questions about this signal. If there is not enough information to solve any of the questions, enter {\tt NEI} (for not enough information'') in those boxes.

What is this signal's fundamental period?
N =~

Determine a closed-form expression for x[n] that does not include complex exponential functions.
x[n] =~

## 5) DTFT Matching

Let x_0[n] = \delta[n+1] + \delta[n] + \delta[n-1], and let x_1[\cdot] be a scaled and periodically-extended version of x_0[\cdot], with repetitions every N_0 samples:

x_1[n] = \sum_{m=-\infty}^\infty Ax_0[n - mN_0] = \sum_{m=-\infty}^\infty A\delta[n-mN_0+1] + A\delta[n-mN_0] + A\delta[n-mN_0-1]

As an example of the general shape of this function, here is an example with N_0=17 (though you should not assume that N_0=17 throughout the problem):

Also let x_2[n] = B\cos(\Omega_0 n) for some value \Omega_0, and let x_3[n] = x_1[n]+x_2[n].

Also consider the following plots, each of which shows the (purely real) DTFT of some function.

Which of the graphs (1-6) corresponds to X_3(\Omega), the DTFT of x_3[n] = x_1[n]+x_2[n]? And what are the values of A, N_0, B, and \Omega_0? Enter a single number in each box below.

Matching Graph:

A =~

N_0 =~

B =~
\Omega_0 =~