MATLAB Manual
MATLAB Manual
Experiment No. 01
INTRODUCTION TO MATLAB
The name MATLAB stands for MATrix LABoratory. MATLAB was written
originally to provide easy access to matrix software developed by the
LINPACK (linear system package) and EISPACK (Eigen system package)
projects.
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
Experiment No. 02
Aim: - Determine transpose, inverse values of given matrix.
Theory: -
A = [1 2 0; 2 5 -1; 4 10 -1]
A=
1 2 0
2 5 -1
4 10 -1
B = A'
B=
1 2 4
2 5 10
0 -1 -1
Inverse of matrix
X = inv(A)
X=
5 2 -2
-2 -1 1
0 -2 1
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
Experiment No. 03
Aim: - Plot the pole-zero configurations in s-plane for the given transfer
function.
Theory: -
>> p1 = [8 56 96] ; q1 = [1 4 9 10 0]
Q1=
1 4 9 10 0
Transfer function :
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
Experiment No. 04
Aim: - Determine the transfer function for given closed loop system in block
diagram representation.
num/den =
num/den =
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
>> n3 = [1 0] ; d3 = [0 1];
num/den =
num/den =
num/den =
Num/den =
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
Experiment No. 05
Aim: - Plot unit step response of given transfer function and find peak
overshoot, peak time.
Theory: -
num =
4 4
>> den = [1 2 5]
den =
1 2 5
Transfer function :
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
Experiment No. 06
Aim: - Plot unit step response and to find rise time and delay time.
num/den =
n4 =
0 1 2
d4 =
1 2 2
num/den =
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
Experiment No 7
Aim: - The open loop transfer function of a unity feedback system is given
below:
Theory:-
P=1
>>q= [1 4 6 4 0]
Q=
1 4 6 4 0
Transfer function:
>>rlocus (sys 5)
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
Experiment No 8
Aim: - Sketch the root locus plot for open-loop transfer function
Theory:-
>>P=1
P=1
>>q=[1 4 3 0]
Q= 1 4 3 0
>>sys 3=tf(p,q)
Transfer function :
>>rlocus (p,q)
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
Experiment No 9
Aim: - A unity feedback control system has its forward path transfer function as
Theory:-
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
>>sys=tf(n1,d1)
Transfer function:
>>[num.den]=cloop(n1,d1)
Num =
0 0 0 0 210
Den=
>>sys1=tf(num,den)
Transfer function:
>>roots (den)
Ans=
-31.9898
-11.5578
-0.2262+0.71891
-0.2262-0.71891
>>sisotool(sys)
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
Experiment No 10
Aim: - sketch the Bode plot for the transfer function given below.
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
Theory:-
Den=
>>sys1=tf(num,den)
Transfer function:
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
>>margin(sys1)
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
Experiment No. 11
Aim: - Draw the Nyquist plot for the open loop transfer function given below
and Comments on closed-loop stability
Theory:-
Num=2.2000
>>den=[1 3 4 2 0]
Den=1 3 4 2 0
>>sys 4 = tf(num,den)
Transfer function:
>>load ltiexamples
>>ltiview
Software lab-III
(EC-506) Lab Manual
Institute of Engineering & Science, IPS Academy Indore
Department of Electronics & Communication Engg
Software Lab-III (EC- 506)
Experiment No. 12
Aim: - Plot the Nyquist plot for given transfer function and to discuss closed
loop stability, gain and phase margin.
Theory: -
n1=
10-10
>>d1=[1 5 6]
d1=1 5 6
Transfer function:
>>load ltiexamples
>>ltiview
Software lab-III
(EC-506) Lab Manual