Page 1 of 1

Consider the signal 𝑥3[𝑛]={1, 0≤𝑛≤6 0, 7≤&#119899

Posted: Tue Apr 26, 2022 3:22 pm
by answerhappygod
Consider the signal 𝑥3[𝑛]={1, 0≤𝑛≤6


0, 7≤𝑛≤31 ,
which has a fundamental period of 𝑁=32.
using matlab
a) [2 pts] Plot two periods of the signal 𝑥3[𝑛].
(Note: We will want an array with just one period for later parts.
Define an array with one
period and then define a new array that is several of the original
arrays concatenated, i.e.,
b_plot = [b, b])

b) [4 pts] Calculate one period of the Fourier series coefficients
using fft. Create plots of
the real and imaginary parts of the Fourier series coefficients
over two periods.

c) [3 pts] How can we relate this signal to the general square wave
form

d) [6 pts] Use the Fourier series coefficients found in part b) to
evaluate the following
partial sum approximations of 𝑥3[𝑛]:

𝑥3_5[𝑛]=∑𝑎𝑘𝑒𝑗𝑘(2𝜋
32)𝑛
2
−2


𝑥3_17[𝑛]=∑𝑎𝑘𝑒𝑗𝑘(2𝜋
32)𝑛
8
−8


𝑥3_32[𝑛]=∑𝑎𝑘𝑒𝑗𝑘(2𝜋
32)𝑛
16
−15


Create a separate plot for each of the three approximations. (Each
one showing two
periods.)