Geethanjali College of Engineering and Technology Cheeryal (v), Keesara (M), Ranga Reddy District. DIGITAL SIGNAL PROCESSING LABORATORY STUDENTS’MANUAL For III year II semester ECE A.Y.2015-16 …striving toward perfection DEPARTMENT OF ELECTRONICS & COMMUNICATION ENGINEERING INCHARGES HOD Mr. R.Odaiah Dr. P.Srihari
119
Embed
Geethanjali College of Engineering and · PDF fileGEETHANJALI COLLEGE OF ENGINEERING AND TECHNOLOGY DEPARTMENT OF Electronics And Communications Engineering (Name of
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Geethanjali College of Engineering and Technology Cheeryal (v), Keesara (M), Ranga Reddy District.
DIGITAL SIGNAL PROCESSING
LABORATORY STUDENTS’MANUAL
For III year II semester ECE
A.Y.2015-16
…striving toward perfection
DEPARTMENT OF
ELECTRONICS & COMMUNICATION ENGINEERING
INCHARGES HOD
Mr. R.Odaiah Dr. P.Srihari
Geethanjali College of Engineering and Technology Cheeryal (v), Keesara (M), Ranga Reddy District.
…striving toward perfection
LABORATORY MANUAL
FOR
DIGITAL SIGNAL PROCESSING
Prepared by: Checked by:
Ms.S.Jyothirmaye
Approved by:
Dr. P.Srihari, HOD
Dept., of ECE
Revision No:4 Date: 20/11/2015
GEETHANJALI COLLEGE OF ENGINEERING AND TECHNOLOGY
DEPARTMENT OF
Electronics And Communications Engineering
(Name of the Subject / Lab Course) : DSP Lab
(JNTU CODE - A60493) Programme : UG
Branch: ECE-A, B, C & D Version No : 04
Year: III Updated on :20/11/2015
Semester: II No. of pages :116
Classification status (Unrestricted / Restricted )
Distribution List : Department , Lab, Library, Lab incharge
Prepared by : 1) Names :Ms. S.Jyothirmaye 1) Name : Ms. M. Umarani
Ms. Kavya Mr. R.Odaiah
2) Sign : 2) Sign :
3) Design : Assoc. Prof 3) Design :
4) Date : 4) Date :
Verified by : 1) Name :
2) Sign :
3) Design :
4) Date :
* For Q.C Only.
1) Name :
2) Sign :
3) Design :
4) Date :
Approved by : (HOD ) 1) Name :Dr.P.Srihari
2) Sign :
3) Date :
List of Contents
Sl.No. Title Page No.
1. JNTU syllabus. i
2. Dos and Don’ts. ii
3. Vision and mission of the Department. iii
4. Course objectives and outcomes. v
5. Basic Introduction 1
6. List of Experiments
JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY HYDERABAD
III Year B.Tech. ECE - II Sem
L T/P/D C 0 -/3/- 2 JNTUH Syllabus
DIGITAL SIGNAL PROCESSING LAB
The programs shall be implemented in software (Using MATLAB / Lab view / C programming/
Equivalent) and hardware (Using TI / Analog devices / Motorola / Equivalent DSP processors).
1. Generation of Sinusoidal waveform / signal based on recursive difference equations.
2. To find DFT / IDFT of given DT signal.
3. To find frequency response of a given system given in (Transfer Function/ Differential equation
form).
4. Implementation of FFT of given sequence.
5. Determination of Power Spectrum of a given signal(s).
6. Implementation of LP FIR filter for a given sequence.
7. Implementation of HP FIR filter for a given sequence.
8. Implementation of LP IIR filter for a given sequence.
9. Implementation of HP IIR filter for a given sequence.
10. Generation of Sinusoidal signal through filtering.
11. Generation of DTMF signals.
12. Implementation of Decimation Process.
13. Implementation of Interpolation Process.
14. Implementation of I/D sampling rate converters.
15. Audio application such as to plot a time and frequency display of microphone plus a cosine
using DSP. Read a .wav file and match with their respective spectrograms.
16. Noise removal: Add noise above 3 KHz and then remove, interference suppression using 400
Hz tone.
17. Impulse response of first order and second order systems.
Note: - Minimum of 12 experiments has to be conducted.
JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY HYDERABAD
III Year B.Tech. ECE - II Sem
DIGITAL SIGNAL PROCESSING LAB
Cycle I
1. Generation of Sinusoidal waveform / signal based on recursive difference equations.
2. To find DFT / IDFT of given DT signal.
3. To find frequency response of a given system given in (Transfer Function/ Differential equation
form).
4. Implementation of FFT of given sequence.
5. Determination of Power Spectrum of a given signal(s).
6. Implementation of LP FIR filter for a given sequence.
7. Implementation of LP IIR filter for a given sequence.
8. Implementation of HP IIR filter for a given sequence.
Cycle II:
9. Implementation of HP IIR filter for a given sequence.
10. Implementation of Decimation Process.
11. Implementation of Interpolation Process.
12. Implementation of I/D sampling rate converters.
Additional experiments:
1. Determination of Power Spectrum of a given signal(s).
2. Converting CD DATA TO DVD DATA
Design Experiments
1. Audio application such as to plot a time and frequency display of microphone plus a cosine using
DSP. Read a .wav file and match with their respective spectrograms.
2. Noise removal: Add noise above 3 KHz and then remove interference suppression using 400 Hz
tone.
Open Experiment
1. Impulse response of first order and second order systems.
2. Implementation of I/D sampling rate converters
INSTRUCTIONS / Do’s and Don’t
Instruction to Students:-
1. Do not handle any equipment without reading the instructions /Instruction manuals.
2. Observe type of sockets of equipment power to avoid mechanical damage.
3. Do not insert connectors forcefully in the Sockets.
4. Strictly observe the instructions given by the Teacher/ Lab Instructor.
5. After the experiment is over, the students must hand over the Bread board, Trainer kits, wires,
CRO Probes and other Components to the lab assistant / teacher.
6. It is mandatory to come to lab in a formal dress (Shirts, Trousers, ID card, and Shoes for boys).
Strictly no Jeans for both Girls and Boys.
7. It is mandatory to come with observation book and lab record in which previous experiment
should be written in Record and the present lab‘s experiment in Observation book.
8. Observation book of the present lab experiment should be get corrected on the same day and
Record should be corrected on the next scheduled lab session.
9. Mobile Phones should be Switched OFF in the lab session.
10. Students have to come to lab in-time. Late comers are not allowed to enter the lab.
11. Prepare for the viva questions. At the end of the experiment, the lab faculty will ask the viva
Questions and marks are allotted accordingly.
12. Bring all the required stationery like graph sheets, pencil & eraser, different color pens etc. for
the lab class.
Instructions to Laboratory Teachers:-
1. Observation book and lab records submitted for the lab work are to be checked and signed
before the next lab session.
2. Students should be instructed to switch ON the power supply after the connections are checked
by the lab assistant / teacher.
3. The promptness of submission should be strictly insisted by awarding the marks accordingly.
4. Ask viva questions at the end of the experiment.
5. Do not allow students who come late to the lab class.
6. Encourage the students to do the experiments innovatively.
ECE DEPARTMENT
Vision of the Department
To impart quality technical education in Electronics and Communication Engineering
emphasizing analysis, design/synthesis and evaluation of hardware/embedded software
using various Electronic Design Automation (EDA) tools with accent on creativity,
innovation and research thereby producing competent engineers who can meet global
challenges with societal commitment.
Mission of the Department
i. To impart quality education in fundamentals of basic sciences, mathematics, electronics
and communication engineering through innovative teaching-learning processes.
ii. To facilitate Graduates define, design, and solve engineering problems in the field of
Electronics and Communication Engineering using various Electronic Design
Automation (EDA) tools.
iii. To encourage research culture among faculty and students thereby facilitating them to
be creative and innovative through constant interaction with R & D organizations and
Industry.
iv. To inculcate teamwork, imbibe leadership qualities, professional ethics and social
responsibilities in students and faculty.
Program Educational Objectives of B. Tech (ECE) Program :
I. To prepare students with excellent comprehension of basic sciences, mathematics
and engineering subjects facilitating them to gain employment or pursue
postgraduate studies with an appreciation for lifelong learning.
II. To train students with problem solving capabilities such as analysis and design with
adequate practical skills wherein they demonstrate creativity and innovation that
would enable them to develop state of the art equipment and technologies of
multidisciplinary nature for societal development.
III. To inculcate positive attitude, professional ethics, effective communication and
interpersonal skills which would facilitate them to succeed in the chosen profession
exhibiting creativity and innovation through research and development both as team
member and as well as leader.
Program Outcomes of B.Tech ECE Program:
1. An ability to apply knowledge of Mathematics, Science, and Engineering to solve
complex engineering problems of Electronics and Communication Engineering
systems.
2. An ability to model, simulate and design Electronics and Communication
Engineering systems, conduct experiments, as well as analyze and interpret data
and prepare a report with conclusions.
3. An ability to design an Electronics and Communication Engineering system,
component, or process to meet desired needs within the realistic constraints such as
economic, environmental, social, political, ethical, health and safety,
manufacturability and sustainability.
4. An ability to function on multidisciplinary teams involving interpersonal skills.
5. An ability to identify, formulate and solve engineering problems of
multidisciplinary nature.
6. An understanding of professional and ethical responsibilities involved in the
practice of Electronics and Communication Engineering profession.
7. An ability to communicate effectively with a range of audience on complex
engineering problems of multidisciplinary nature both in oral and written form.
8. The broad education necessary to understand the impact of engineering solutions in
a global, economic, environmental and societal context.
9. Recognition of the need for, and an ability to engage in life-long learning and
acquire the capability for the same.
10. A knowledge of contemporary issues involved in the practice of Electronics and
Communication Engineering profession
11. An ability to use the techniques, skills and modern engineering tools necessary for
engineering practice.
12. An ability to use modern Electronic Design Automation (EDA) tools, software and
electronic equipment to analyze, synthesize and evaluate Electronics and
Communication Engineering systems for multidisciplinary tasks.
13. Apply engineering and project management principles to one's own work and also
to manage projects of multidisciplinary nature.
COURSE OBJECTIVES AND OUTCOMES
Objectives:
1. To generate the elementary signals/ waveforms.
2. To Calculate and Plot DFT / IDFT of given DT signal and prove it theoretical.
3. To plot frequency response of a given LTI system.
4. To Implement FFT of a given sequence.
5. To determine and plot the Power Spectrum of a given signal(s).
6. To Plot Magnitude and Phase of LP FIR filter for any given sequence.
7. To Plot Magnitude and Phase of HP FIR filter for a given sequence.
8. Plot Magnitude and Phase of LP IIR filter for a given sequence.
9. To Plot Magnitude and Phase of HP IIR filter for a given sequence.
10. To generate Sinusoidal signal through filtering.
11. To generate DTMF signals.
12. To Implement Decimation Process of any given sequence.
13. To Implement Interpolation Process of any given sequence.
14. To Implement I/D sampling rate converters.
15. To plot a time and frequency display of microphone plus a cosine using DSP.
16. To do Noise removal: Add noise above 3 KHz and then remove, interference suppression
using 400Hz tone.
17. To plot Impulse response of first order and second order systems.
Learning Outcomes:
The student will be:
1. Able to generate elementary signals/ waveforms and perform arithmetic operations on signals.
2. Able to Calculate and Plot DFT / IDFT of given DT signal.
3. Able to plot frequency response of a given system and verify the properties of LTI system.
4. Able to Implement FFT of given sequence and identify the reduction of computations using FFT.
5. Able to Implement LP FIR filter for a given sequence and calculate the filter coefficients.
6. Able to Implement HP FIR filter for a given sequence and plot the response of the same.
7. Able to Implement and design LP IIR filter for a given sequence.
8. Able to Implement HP IIR filter for a given sequence.
9. Able to generate Sinusoidal signal through filtering.
10. Able to Implement Decimation Process and vary (decrease) the sampling rate.
11. Able to Implement Interpolation Process and vary (increase) the sampling rate.
12. Able to Implement I/D sampling rate converters and identify the importance of multi rate
sampling.
13. Able to generate DTMF signals.
14. Able to determine the Power Spectrum of a given signal(s) and demonstrate the importance of
frequency domain.
15. Able to plot a time and frequency display of microphone plus a cosine using DSP.
16. Able to do Noise removal: Add noise above 3 KHz and then remove, interference suppression
using 400Hz tone.
17. Able to plot Impulse response of first order and second order systems and calculate the
damping factor.
Introduction
Starting MATLAB:
After logging into your account, you can enter MATLAB by double-clicking on the MATLAB
shortcut icon (MATLAB 7.0.4) on your Windows desktop. When you start MATLAB, a special
window called the MATLAB desktop appears. The desktop is a window that contains other
windows. The major tools within or accessible from the desktop are:
The Command Window
The Command History
The Workspace
The Current Directory
The Help Browser
The Start button
Figure 1.1: The graphical interface to the MATLAB workspace When MATLAB is started
for the first time, the screen looks like the one that shown
in the Figure 1.1. This illustration also shows the default configuration of the MATLAB desktop.
You can customize the arrangement of tools and documents to suit your needs.
Now, we are interested in doing some simple calculations. We will assume that you have sufficient
understanding of your computer under which MATLAB is being run. You are now faced with the
MATLAB desktop on your computer, which contains the prompt (>>) in the Command Window.
Usually, there are 2 types of prompt:
>> For full version
EDU> for educational version
Note: To simplify the notation, we will use this prompt, >>, as a standard prompt sign,
Though our MATLAB version is for educational purpose.
Using MATLAB as a calculator
As an example of a simple interactive calculation, just type the expression you want to
evaluate. Let’s start at the very beginning. For example, let’s suppose you want to calculate the
expression, 1 + 2 × 3. You type it at the prompt command (>>) as follows,
>> 1+2*3
ans = 7
You will have noticed that if you do not specify an output variable, MATLAB uses a
default variable ans, short for answer, to store the results of the current calculation. Note that the
variable ans is created (or overwritten, if it is already existed). To avoid this, you may assign a value
to a variable or output argument name. For example
>> x = 1+2*3
x =7
Will result in x being given the value 1 + 2*3=7. This variable name can always
be used to refer to the results of the previous computations. Therefore, computing 4 result
in
>> 4*x
ans =28.0000
Before we conclude this minimum session, Table 1.1 gives the partial list of arithmetic
Operators.
Basic arithmetic operators
Symbol Operation Example
+ Addition 2 + 3
- Subtraction 2 - 3
* Multiplication 2*3
/ Division 2/3
3 Quitting MATLAB
To end your MATLAB session, type quit in the Command Window, or select File
MATLAB in the desktop main menu.
Getting started
After learning the minimum MATLAB session, we will now learn to use some additional
operations.
1 Creating MATLAB variables
MATLAB variables are created with an assignment statement. The syntax of variable assignment is
Variable name = a value (or an expression)
For example,
>> x = expression
Where expression is a combination of numerical values, mathematical operators, variables, and
function calls. On other words, expression can involve:
manual entry
built-in functions
user-defined functions
Overwriting variable
Once a variable has been created, it can be reassigned. In addition, if you do not wish to see the
intermediate results, you can suppress the numerical output by putting a semicolon (;) at the end of
the line. Then the sequence of commands looks like this:
>> t = 5;
>> t = t+1
t =6
Error messages
If we enter an expression incorrectly, MATLAB will return an error message. For example, in the
following, we left out the multiplication sign, *, in the following expression
>> x = 10;
>> 5x
Making corrections
To make corrections, we can, of course retype the expressions. But if the expression is
Lengthy, we make more mistakes by typing a second time. A previously typed command can be
recalled with the up-arrow key When the command is displayed at the command prompt, it can be
modified if needed and executed.
Controlling the hierarchy of operations or precedence
Let’s consider the previous arithmetic operation, but now we will include
example, 1 + 2×3 will become (1 + 2) ×3
>> (1+2)*3
ans =9
and, from previous example
>> 1+2*3
ans =7
By adding parentheses, these two expressions give di errant results: 9 and 7 The order in which
MATLAB performs arithmetic operations is exactly that taught in high school algebra courses
Exponentiations are done first, followed by multiplications and divisions, and finally by additions
and subtractions. However, the standard order of precedence of arithmetic operations can be
changed by inserting parentheses. For example, the result of 1 +2×3 is quite deferent than the similar
expression with parentheses (1+2) ×3. The results are 7 and 9 respectively. Parentheses can always
be used to overrule priority and their use is recommended in some complex expressions to avoid
ambiguity.
Therefore, to make the evaluation of expressions unambiguous, MATLAB has established a series
of rules. The order in which the arithmetic operations are evaluated is given in Table 1.2. MATLAB
arithmetic operators obey the same precedence rules as those in Hierarchy of arithmetic operations
Precedence Mathematical operations
First The contents of all parentheses are evaluated first, starting from the innermost parentheses and
working outward Second All exponentials are evaluated, working from left to right Third All
multiplications and divisions are evaluated, working
from left to right Fourth All additions and subtractions are evaluated, starting
from left to rightmost computer programs. For operators of equal precedence, evaluation is from left
to right Now, consider another example:
In MATLAB, it becomes
>> 1/(2+3^2)+4/5*6/7
ans =0.7766.
or, if parentheses are missing,
>> 1/2+3^2+4/5*6/7
ans =10.1857.
So here what we get: two different results. Therefore, we want to emphasize the importance of
precedence rule in order to avoid ambiguity.
Controlling the appearance of floating point number
MATLAB by default displays only 4 decimals in the result of the calculations, for example -163.
6667, as shown in above examples. However, MATLAB does numerical calculations in double
precision, which is 15 digits. The command format controls how the results of computations are
displayed. Here are some examples of the different formats together with the resulting outputs
>> Format short
>> x=-163.6667
If we want to see all 15 digits, we use the command format long
>> Format long
>> x= -1.636666666666667e+002
To return to the standard format, enter format short, or simply format there are several other formats.
For more details, see the MATLAB documentation, or type help format Note - Up to now, we have
let MATLAB repeat everything that we enter at the prompt (>>). Sometimes this is not quite useful,
in particular when the output is pages en length. To prevent MATLAB from echoing what we type,
simply enter a semicolon (;) at the end of the command. For example,
>> x=-163.6667;
and then ask about the value of x by typing,
>> x
x =-163.6667
Managing the workspace
The contents of the workspace persist between the executions of separate commands. There-fore, it
is possible for the results of one problem to have aneect on the next one. To avoid this possibility, it
is a good idea to issue a clear command at the start of each new independent calculation
>> Clear
The command clear or clear all removes all variables from the workspace. This
frees up system memory. In order to display a list of the variables currently in the memory type
>> Who
While, whose will give more details which include size, space allocation, and class of the variables
Keeping track of your work session
It is possible to keep track of everything done during a MATLAB session with the
diary command.
>> Diary
Or give a name to a created file
>> Diary Filename
Where Filename could be any arbitrary name you choose
The function diary is useful if you want to save a complete MATLAB session.
They Save all input and output as they appear in the MATLAB window. When you want to stop the
recording, enter diary off. If you want to start recording again, enter diary on. The file that is created
is a simple text file. It can be opened by an editor or a word processing program and edited to
remove extraneous material, or to add your comments. You can use the function type to view the
diary file or you can edit in a text editor or print. This command is useful, for example in the process
of preparing a homework or lab submission.
Entering multiple statements per line
It is possible to enter multiple statements per line. Use commas (,) or semicolons (;) to
Enter more than one statement at once. Commas (,) allow multiple statements per line
Without suppressing output
>> a=7; b=cos(a), c=cash (a)
b =0.6570
c =548.3170
Miscellaneous commands
Here are few additional useful commands:
•To clear the Command Window, type clc
•To abort a MATLAB computation, type ctrl-c
• To continue a line, type . . .
Getting help
To view the online documentation, select MATLAB Help from Help menu or MATLAB Help
directly in the Command Window. The preferred method is to use the Help Browser. The Help
Browser can be started by selecting the? Icon from the desktop toolbar. On the other hand,
information about any command is available by typing
>> help Command
Another way to get help is to use the look for command. The look for commandeers
from the help command. The help command searches for an exact function name match, while the
look for command searches the quick summary information in each function for a match. For
example, suppose that we were looking for a function to take
The inverse of a matrix. Since MATLAB does not have a function named inverse, the command
help inverse will produce nothing. On the other hand, the command look for inverse will produce
detailed information, which includes the function of interest, inv
>> look for inverse
Note - At this particular time of our study, it is important to emphasize one main point.
Because MATLAB is a huge program; it is impossible to cover all the details
of each function one by one. However, we will give you information how to get help. Here are some
examples
• Use on-line help to request info on a specific function
>> help sqrt
• In the current version (MATLAB version 7), the doc function opens the on-line version of the help
manual. This is very helpful for more complex commands
>> Doc plot
• Use look for to find functions by keywords. The general form is
>>look for Function Name
Common Procedure to all Programs in MATLAB
1. Click on the MATLAB Icon on the desktop.
2. MATLAB window open.
3. Click on the ‘FILE’ Menu on menu bar.
4. Click on NEW M-File from the file Menu.
5. An editor window open, start typing commands.
6. Now SAVE the file in directory.
7. Then Click on DEBUG from Menu bar and Click Run.
1.GENERATION OF BASIC SIGNALS USING MATLAB
AIM : To generate basic signals like unit impulse, unit step, unit ramp signal and Exponential
signals.
Objective: To generate basic signals like unit impulse, unit step, unit ramp signal and Exponential
signals using MATlab.
Requirements : Computer with MATLAB software
(a). Program for the generation of UNIT impulse signal
clc; close all; clear all;
t=-2:1:2;
y=[zeros(1,2),ones(1,1),zeros(1,2)] figure(1)
subplot(2,2,1); stem(t,y);
title('unit impulse');
(b). Program for the generation of UNIT step signal
clc; close all; clear all;
n=input('enter the n value');
t=0:1:n-1;
y=ones(1,n);
figure(2)
subplot(2,2,2);
stem(t,y);
title('unit step');
(c).Program for the generation of unit RAMP signal
clc; close all; clear all;
n=input('enter the n value');
t=0:n;
y=ones(1,n);
figure(3)
subplot(2,2,3);
stem(t,t);
title('unit ramp');
(d).Program for the generation of Exponential signal
for (i= 1 ; i< (N-1 ); i++) /*bit reversal for resequencing data*/
{
k = N/2;
while (k <= j)
GCET DSP LAB Manual
Department of ECE Page 114
{
j= j - k;
k = k/2;
}
j= j + k;
if (i<j)
{
temp1.real = (Y[j]).real;
temp1.imag = (Y[j]).imag;
(Y[j]).real = (Y[i]).real;
(Y[j]).imag = (Y[i]).imag;
(Y[i]).real = temp1.real;
(Y(i]).imag = temp1.imag;
}
}
return;
}
PROCEDURE:
1 Open code composer studio, make sure the DSP kit is turned on.
2 Start a new project using ‘project-new’ pull down menu, save it in a separate directory
(c:\ccstudio\myprojects) with the name ‘file name. pjt’.
3 Add the source file of linear convolution to the project using ‘project-add files to project’
pull down menu.
4 Add the linker command file ‘hello. cmd’ (c\ccstudio\tutorials\dsk6713\hello1\hello.cmd)
5 Add the run time support library file rts6700.lib c-ccstudio\c6000\cgtools\lib\rts6700.lib)
6 Compile program using the ‘project-compile’ pull down menu or by clicking the short cut
icon on the left side of program window.
GCET DSP LAB Manual
Department of ECE Page 115
7 Build the program using ‘project-build’ pull down menu or by clicking the icon on the left
side of the program window.
8 Load the program in program memory of DSP chip using the ‘file-load program’ pull down
menu.
9 To view o/p graphically, select View -graph-time and frequency.
PRECAUTIONS:
1 Switch ON the computer only after connecting USB cable and make sure the DSP kit
is ON.
2 Perform the diagnostic check before opening code composer studio.
3 All the connections must be tight.
Result : The power density spectrum is obtained and the graphs are plotted.
VIVA QUESTIONS:
1. Define power spectral Density?
2. What is the need for spectral estimation?
3. Determine the power spectrum density?
4. What is the relation between auto correlation & spectral density?
5. Give the estimation of auto correlation function & power density for random Signals?
6. Explain power spectrum estimation using the Bartlett window?
7. Give the formula for PSD?
ADDITIONAL PROGRAMS
1. CD DATA TO DVD DATA
clc;
GCET DSP LAB Manual
Department of ECE Page 116
clear all; fc=44100; t=0:0.000002:0.00002; x=sin(2*pi*fc*t); subplot(3,1,1); stem(t,x); title('original cd signal'); xlabel('no of samples'); ylabel('amplitude'); i=13; d=6; y=resample(x,i,d); subplot(3,1,2); stem(y); title('dvd signal after using the re sample'); xlabel('no of samples'); ylabel('amplitude'); in=interp(x,i); de=decimate(in,d); subplot(3,1,3); stem(de); title('dvd signal after interpolation and decimation'); xlabel('no of samples');
ylabel('amplitude');
GCET DSP LAB Manual
Department of ECE Page 117
2. ESTIMATION OF PSD NOISY SIGNAL
clc ;
clear all;
close all;
f1=input('enter the frequency of first sinosuidal signal');
f2=input('enter the frequency of second sinosuidal signal');
fs=input('enter the frequency of sampling signal');