Open navigation menu
Close suggestions
Search
Search
en
Change Language
Upload
Sign in
Sign in
Download free for days
0 ratings
0% found this document useful (0 votes)
27 views
14 pages
DSP Lab
Dsp
Uploaded by
Hemanth G
AI-enhanced title
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here
.
Available Formats
Download as PDF or read online on Scribd
Download now
Download
Save DSP lab For Later
Download
Save
Save DSP lab For Later
0%
0% found this document useful, undefined
0%
, undefined
Embed
Share
Print
Report
0 ratings
0% found this document useful (0 votes)
27 views
14 pages
DSP Lab
Dsp
Uploaded by
Hemanth G
AI-enhanced title
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here
.
Available Formats
Download as PDF or read online on Scribd
Download now
Download
Save DSP lab For Later
Carousel Previous
Carousel Next
Download
Save
Save DSP lab For Later
0%
0% found this document useful, undefined
0%
, undefined
Embed
Share
Print
Report
Download now
Download
You are on page 1
/ 14
Search
Fullscreen
R18 B.Tech. ECE Syllabus JNTU HYDERABAD ECGO4PC: DIGITAL SIGNAL PROCESSING LAB B.Tech. Il Year II Semester Ltepe 00 3 15 ‘The Programs shall be implemented in Software (Using MATLAB / Lab View / C Programming! Equivalent) and Hardware (Using TI Analog Devices / Motorola / Equivalent DSP processors) Note: - Minimum of 12 experiments has to be conducted. List of Experiments: 41, Generation of Sinusoidal Wavefom / Signal based on Recursive Difference Equations _2e Histogram of White Gaussian Noise and Uniformly Distributed Noise. To find DFT / IDFT of given DT Signal To find Frequency Response of a given System given in Transfer Function! Differential equation form, §) Obtain Fourier series coefficients by formula and using FET and compare for half sine wave, &. Implementation of FFT of given Sequence 7. 8 Determination of Power Spectrum of a given Signal(s) Implementation of LP FIR Filter for a given SequencelSignal. 9. Implementation of HP IIR Filler for a given SequencelSignal 10. Generation of Narrow Band Signal through Fitering 11, Generation of DTMF Signals 42. Implementation of Decimation Process 'S3. Implementation of interpolation Process 414, Implementation of iD Sampling Rate Converters Impulse Response of First order and Second Order Systems. 310.Introduction Scilab is a scientific software package, first developed by researchers from INRIA and ENPC, and is now developed by the Scilab Consortium. Scilab stands for scientific laboratory. It is similar to Matlab, which is a commercial product. Yet it is almost as powerful as Matlab. Scilab consists of three main components: + an interpreter, + libraries of functions (Scilab procedures), + libraries of Fortran and C routines. Scilab is specialized in handling matrices (basic matrix mar transpose, inverse, etc.) and numerical computations. Also it has an open programming environment that allows users to create their own functions and libraries. To find the usage of any function, type help function name, for example: help sum. A list of common operators in Scilab: + Addition = Subtraction * Multiplication / Division * Power ° Complex conjugate transpose Some common functions in Scilab are: sin, cos, tan,asin, acos, atan, abs, min, max, sqrt, ipulation, concatenation, sum. E.g., when we enter: sin(0.5) then it displays: ans: =0.4794255 Special Constants To enter some special constants and %e respectively. There are also constants %t (true) and %f (false) which are Boolean variables Data Structures Scilab supports many data structures. Examples a1 polyno- mial, Boolean, string, function, list, tlist, sparse,library. Strings To enter strings, enclose the string with either single or double quotations. For example: “This is a string’ or “this is also a string”.To concatenate strings, use the operator + : “Welcome” + “to” +'Scilab!” ans: = ‘Welcome to Scilab! ‘There are some basic string handling functions such as strindex, strsplit, strsubst and part. ¢, i (sqrt(-1) ) and e. It is done by entering %pi, %i usual (real or complex matrices),Saving and Loading Variables To save and load variables, we use save and load functions: save(‘file name’, varl, var2, ... ); Joad(‘file name’, ‘varl’, ‘var2’, .. .); where file name is the name of the file to be saved or loaded, and varl, var2, . . . are names of variable. ; b = %f; s = ‘scilab’; save(‘save.dat’, a, b, s); clear a; // delete the variable a clear b; clear s; load(‘save.dat’, ‘a’, *b’, ‘s"); Entering Matrices There are many ways to enter a matrix. Here is the simplest method: 1. separate each elements in a row using a blank space or a comma; 2. separate each row of elements with a semi-colon; 3. put the whole list of elements in a pair of square brackets. For example, we wish to enter a 3 x 3 magic square and assign to the variable M. M=[816;357;492] asa long vector formed by stacking up the columns of the matrix. E.g.: M(1) = 8, MQ)=3, MG) =4, M(4) = 1, M(5) = ‘Accessing out-of-bound elements will result in an error, like entering: MG,4) ‘error 21 invalid index The Colon Operator ‘The colon operator is one of the most important operators in Scilab. The expression 1:10 results in a row operator with elements 1, 2,..., 10, ie.1:10 ans: 1.2.3.4.5.6.7.8.9. 10. To have non-unit spacing we specify the increment: 1 ans: 10. 8.6.4.2 Notice that expressions like 10:-2:1, 10:-2:0.3 would produce the same result The operator $, which gives the largest value of an index, is handy for getting the last entry of a vector or matrix. For example, to access all elements except the last of the last column, we type:M(L:S-1,If a whole row or a column is required . For example we want all the elements of the second row of M. We enter: MQ,:) an 3.5.7. Coneatenation Concatenation is the process of joining smaller size matrices to form bigger ones. This is rd by putting matrices as elements in the bigger matrix: a=[1 23]; b=[456];¢=(7 1.2.3.4,5.6.7.8.9. Matrix Inverse and Solving Linear Systems The command inv(M) gives the inverse of a matrix M. If the matrix is badly scaled or nearly singular, a warming message will be displayed: inv({1 2;2 4.0000001)) warming matrix is close to singular or badly scaled. Entry-wise arithmetic operations for arrays are: + Addition ~ Subtraction .* Multiplication ! Power ./ Right division -\Left division an almost effortless method is to use the function matrix, which reshapes a matrix to a desired size. M = matrix(1:10,2,5) About Command Line Entering a semi-colon at the end of a command line suppresses showing the result (the answer of the expression).lt suppresses the showing of variables a, b and c.A long command instruction can be broken with line-wraps by using the ellipsis (, . . ) at the end of each line to indicate that the command actually continues on the next line: $= 1-1/2 + 1/3 -1/4 + 1/5 - 1/6 + 1/7... = U8 + 1/9 - 1/10 + W/L - 1/125 The Programming Environment Creating Functions Scilab has an open programming environment that enables users to make their own functions and libraries. It is done by using the built-in editor called SciPad. To call the editor, type scipad() or editor(), or click Editor at the menu bar. The file extensions used by scilab are sce and sci. To begin writing a function, we type: functionfoutl out2,.... J=name(in! in2,. .where function is a keyword that indicates the start of a function, out, out2,.... and int, in2,. .. are variables that are output and input of the function respectively, the variables can be Boolean, numbers, matrices, etc, and name is the name of the function. Then we can enter the body of the function, At the end, type endfunction to indicate the end of the function, Comment lines begin with //. A sample function is given as below: function [d] = distance(x, y) / this function computes the distance M/ between the origin and the point (x, y) d= sqrt(x"2 + y'2); endfunetion ‘Unlike Matlab, Scilab allows multiple function declaration (with different function names) within a single file. Also Scilab allows’ Flow Control A table of logical expressions is given below: equal =not equal eater than or equal to jess than or equal to > greater than
0 = Ofort
1, y(O) is growing exponential If a< 1, y(t) is decaying exponential ALGORITHM: 1. Choose the value of n which represents the number of samples. 2, Generate the elementary discrete time impulse, step, ramp and exponential sequences. 3. Plot all the generated discrete sequences with the help of subplot () and plot2d3() functions. 4, Assign x-axis, y-axis variables and title for each plot.PROCEDURE: 1.Open the SCILAB software. 2.Click on NEW-> SCINOTES 3.Type the program. 4.Save the program as “program name.sce”. 5.Run the file. 6.Check for errors in Command window. 7.1f there are no errors, figure will be displayed on graphic window. PROGRAM: 1) Elementary Discrete Time Signals Mmpluse cle; clear; close; n=10:1:10; impluse=[zeros(1,10),ones(1,1),zeros(1,10)]; subplot(3,3,1); xgridQ; plot2d3(n,impluse); xlabel(‘discrete time n'); ylabel(‘amplitude’); title('unit impluse sequence’); /MOnit step =-10:1:10; step=[zeros(1,10),ones(1,11)]; subplot(3,3,2); xgrid(); plot2d3(n,step); xlabel(‘discerte time n'); ylabel(‘amplitude’); title(unit step sequence’); /Ramp nl=0:1:10 ramp=nl; subplot(3,3,3); xgridQ; plot2d3(n1,ramp); xlabel(‘discrete time nl’);ylabel(amplitude’; titleCramp signal’); /7Exponential sequence n=-10:1:10; 1 for a<0<1 2-08 xI=a."n; subplot(3,3,4); xgridQ: plo2d3(n,x1); xlabel( 1); ylabel('amplitude’); title(Exponential sequence for 0
1 . x2=a."n; subplot(3,3,5); xgrid(s plot2d3(n,x2); xlabel('n'); ylabelamplitude’ titleC Exponential sequence for a>1'); Mor -1
1 105 fs gr>p-++—t+} 2 2 eae é st alll oF os 6 = hn 8 hn exponential signal for a<-1 cosine signal . . jeaieey 2 s T g ieee fae = 2 = | colt] = 2 of ecpeecenyy 2 ooo: w Dats fn n2 11)Signal based on Recursive Difference Equation: ALGORITHM: 1, Choose the value of n which 2. Generate the input sinusoidal signal. 3. Find the coefficients a and b of the difference equation 4. Define the initial states of the system 5. Find the response of the system for the given difference equation 6. Plot the response of the system. PROGRAM: cle; clear; n=0:3; y=10*sin(2*%pi*n/60);disp(y); a=y(3)/y(2); b=(y(4)-a*y3)/¥(2); disp(a); disp(b); disp(y@)); disp(y(4)); for k=1:1:119 p(I)=y(1); p2)=¥2); P(k+2)=a*p(k+1)+b*p(k); end disp(p); plot2d3(p); xlabel(‘k’); ylabel(‘Amplitude’); title('Sinusoidal signal using Recursive difference Equation’); OUTPUT WAVEFORM:a a TE Graphic window File Tools Edit? | | 0 0 2 3 © 69 a 7 BD 0 100 110 120 130 140 | k RESULT: Generation of Elementary Discrete-Time signals / Sinusoidal waveform based on recursive difference equation is performed.
You might also like
Scilab Tutorial Oriented Toward The Practice of Discrete-Time Signal Processing
PDF
No ratings yet
Scilab Tutorial Oriented Toward The Practice of Discrete-Time Signal Processing
21 pages
SCILAB Tutorial For DSP PDF
PDF
No ratings yet
SCILAB Tutorial For DSP PDF
21 pages
Laboratory Activity 1
PDF
No ratings yet
Laboratory Activity 1
10 pages
Scilab and Scicos Revised
PDF
No ratings yet
Scilab and Scicos Revised
143 pages
Intro Scilab
PDF
No ratings yet
Intro Scilab
21 pages
DSP LAB DOC (Sur)
PDF
No ratings yet
DSP LAB DOC (Sur)
71 pages
DSP Lab Manual 2023
PDF
No ratings yet
DSP Lab Manual 2023
85 pages
Course Name: Course Code: Sem /branch:: Software Workshop Lab ET5L006 5 Sem B.Tech in ETC
PDF
No ratings yet
Course Name: Course Code: Sem /branch:: Software Workshop Lab ET5L006 5 Sem B.Tech in ETC
44 pages
Index: S.No Practical Date Sign
PDF
No ratings yet
Index: S.No Practical Date Sign
32 pages
Activity 1
PDF
No ratings yet
Activity 1
10 pages
Lab Work File: 5 Semester ECE (2017 Batch)
PDF
No ratings yet
Lab Work File: 5 Semester ECE (2017 Batch)
24 pages
Control Systems Lab 1
PDF
No ratings yet
Control Systems Lab 1
8 pages
Toaz - Info Control Systems Lab 1 PR
PDF
No ratings yet
Toaz - Info Control Systems Lab 1 PR
8 pages
scilab pracal BScII (3)
PDF
No ratings yet
scilab pracal BScII (3)
45 pages
DSP Lab Manual
PDF
No ratings yet
DSP Lab Manual
22 pages
Introduction To Scilab
PDF
No ratings yet
Introduction To Scilab
14 pages
Lab 00
PDF
No ratings yet
Lab 00
7 pages
Lab 7
PDF
No ratings yet
Lab 7
5 pages
Exercise Notes
PDF
No ratings yet
Exercise Notes
20 pages
A Brief Introduction To Matlab
PDF
No ratings yet
A Brief Introduction To Matlab
8 pages
SS Manual Students
PDF
No ratings yet
SS Manual Students
76 pages
Scilab Part I
PDF
100% (1)
Scilab Part I
36 pages
Lab Activity 1 Engineering Control Systems
PDF
No ratings yet
Lab Activity 1 Engineering Control Systems
8 pages
WYK Scilab Talk
PDF
No ratings yet
WYK Scilab Talk
17 pages
Control Systems Lab Manual in Sci Lab
PDF
No ratings yet
Control Systems Lab Manual in Sci Lab
28 pages
Introduction To MATLAB and Basic Signals: Definition of Variables
PDF
No ratings yet
Introduction To MATLAB and Basic Signals: Definition of Variables
19 pages
Lab 1 Ahmad Sataish Irfa
PDF
No ratings yet
Lab 1 Ahmad Sataish Irfa
16 pages
Scilab: Utility Software II
PDF
No ratings yet
Scilab: Utility Software II
5 pages
Da 304p (Ssmda) Merged
PDF
No ratings yet
Da 304p (Ssmda) Merged
21 pages
EEE-314 Software Based
PDF
No ratings yet
EEE-314 Software Based
100 pages
SciLab For Dummies
PDF
100% (5)
SciLab For Dummies
34 pages
DSP Lab Manual 15ecl57 Final - CBCS
PDF
No ratings yet
DSP Lab Manual 15ecl57 Final - CBCS
46 pages
LAB 1 (Signal Analysis Using MATLAB)
PDF
No ratings yet
LAB 1 (Signal Analysis Using MATLAB)
8 pages
Signal Analysis Using MATLAB
PDF
No ratings yet
Signal Analysis Using MATLAB
8 pages
SN Slab Manual
PDF
No ratings yet
SN Slab Manual
60 pages
Software Toolkit: MATLAB
PDF
No ratings yet
Software Toolkit: MATLAB
15 pages
DSP Lab Manual
PDF
No ratings yet
DSP Lab Manual
57 pages
DSP_LAB_Manual_IEE_Final JU
PDF
No ratings yet
DSP_LAB_Manual_IEE_Final JU
83 pages
Familiarization of Matlab - Part2 - lsdcRNyfAH
PDF
No ratings yet
Familiarization of Matlab - Part2 - lsdcRNyfAH
3 pages
Ssss
PDF
No ratings yet
Ssss
79 pages
Ammmathalli
PDF
No ratings yet
Ammmathalli
83 pages
S&S Lab 1 Handout
PDF
No ratings yet
S&S Lab 1 Handout
11 pages
Control System Lab Manual
PDF
No ratings yet
Control System Lab Manual
52 pages
Signals and Systems Using Matlab
PDF
100% (7)
Signals and Systems Using Matlab
68 pages
Experiment 01
PDF
No ratings yet
Experiment 01
10 pages
Digital Signal Processing: BY:-Ankit Sharma Roll No: - 0657013108 Btech (It)
PDF
No ratings yet
Digital Signal Processing: BY:-Ankit Sharma Roll No: - 0657013108 Btech (It)
33 pages
Lab #1 Introduction To Matlab: Department of Electrical Engineering
PDF
No ratings yet
Lab #1 Introduction To Matlab: Department of Electrical Engineering
18 pages
Lab Manual It406matlab
PDF
No ratings yet
Lab Manual It406matlab
39 pages
DSP LAB Digital Signal Processing Laboratory Manual
PDF
No ratings yet
DSP LAB Digital Signal Processing Laboratory Manual
75 pages
Experiment 1 Avenido CP Final
PDF
No ratings yet
Experiment 1 Avenido CP Final
6 pages
Matlab Slides 2up PDF
PDF
No ratings yet
Matlab Slides 2up PDF
9 pages
DSP_Manual_Updated_v2
PDF
No ratings yet
DSP_Manual_Updated_v2
62 pages
Basic Simulation LAB Manual
PDF
No ratings yet
Basic Simulation LAB Manual
90 pages