0% found this document useful (0 votes)
4 views3 pages

MATLAB Assignment 1: DSP Signals

Uploaded by

Pranav Chaitanya
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views3 pages

MATLAB Assignment 1: DSP Signals

Uploaded by

Pranav Chaitanya
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

EE5130 Digital Signal Processing

Faculty: Dr. R David Koilpillai

MATLAB Assignment 1

Computer Assignment Submission Instructions:

• You can work individually or as a team of two students


• Please submit the following
o Required plots
o Include brief explanation of observations, as
appropriate
o Listing of code written by you

• The submitted file should be in .pdf format

• Please ensure name and roll number of both team members are clearly written
• Use following naming convention for file you
o Roll-number1_assign#. pdf
o example: EE22Mxxx_assign1. pdf

• Assignment submission via Moodle


o Do not send via email

• Honour Code:

o Add this line to your assignment and an electronic signature


o I certify that this assignment submission is my own
work and not from obtained from any other source
Signal Generation
1. Generate the following discrete-time signals of length 21 samples (n = -10 to 10):
• Unit impulse δ[n]
• Unit step u[n]
• Ramp signal r[n] = n·u[n]
• Exponential signal x[n] = 0.9^n·u[n]
• Sinusoidal signal x[n] = sin(0.2πn)
Plot all signals using stem plots.
Basic Operations on Signals
2. Given a sequence x[n] = [1 2 3 4 3 2 1], centered at n = 0 (i.e., n = -3 to 3):
• Plot the signal x[n]
• Obtain and plot the even and odd parts of x[n]
3. You are given a signal with both useful content and noise.
(a) Generate the signal:
x[n]=sin(0.2πn)+0.5⋅sin(0.8πn),n=0 to 50
• The first sine is the desired signal.
• The second sine is high-frequency noise.
(b) Smooth the signal:
• Create a new signal y[n], where each value is the average of 5 points:
y[n]=( x[n−2]+x[n−1]+x[n]+x[n+1]+x[n+2] ) / 5

• For values where indices go out of bounds (like x[−1]), you can skip
computing or set y[n]=0.
(c) Plot the signals:
• Plot both the original noisy signal x[n] and the smoothed signal y[n].
• Observe and explain how the averaging affects the signal.

You might also like