Control Systems Lab
Control Systems Lab
AIM:
a) Draw the theoretical step response of the given II order system on a graph sheet and
clearly mark tp, tr ,µp , td .
b) Draw the theoretical (asymptotic and exact) Bode plot and mark µr & r
THEORY:
( )
Where and are two parameter that describes the dynamic behavior of the system. is the
damping ratio and is the undamped natural frequency of the system. It is the frequency at
which the system would oscillate if the damping were reduced to zero. i.e., when the
system is called an undamped system, If is between 0 and 1, the system is said to be under
damped. For , the system response exhibits, decaying oscillation of frequency
√ . Where is the damped natural frequency. With approaches . With
approaching one, the system response approaches the final value without over shooting it and
consequently there are no oscillations. The effect of increasing damping ratio beyond its critical
value is to make the system response sluggish. System with greater that one are called over
damped system. The parameter , may be obtained from the physical parameters of the system.
A typical second order system is given in fig. a, note that R = 560Ώ, L = 1H and C =
0.1µF
( ) ∫
( ) ∫
42
( ) ( )
( )
( )
[ ] ( )
STEP RESPONSE:
( ) ( ) ( ) ( )
√
[ ]
Maximum overshoot, √
Time for
√
For given values of R, L and C calculate the theoretical and compare with the actual response.
FREQUENCY RESPONSE:
43
Sinusoidal transfer function M(j) =( ) ( )
[ ] [ ]
Put
( ) ( )
[ ]
[ ]
√( ) ( )
Obtain magnitude and phase angle plot experimentally and compare the results with the
theoretical plots
.PROCEDURE:
Damping factor, √
We have,
44
( ) ( ) ( )
√
Where
√
[ ] √
√
Peak overshoot, ,
√
Calculate as follows
Fig a
45
Step Response
1.6
1.4
1.2
1
Amplitude
0.8
0.6
0.4
0.2
0
0 0.05 0.1 0.15 0.2 0.25 0.3
Time (sec)
Fig b
Give a low frequency (20 to 30Hz) square wave input of magnitude 1Volt to the circuit
and obtain the output on the CRO. Plot the actual response.
,
( )
the approximate theoretical (asymptotic)bode (magnitude plot) is a straight line having a slope
of -40db/sec and corner frequency ( ).
b) Exact plot:
| ( )| ( ) ( )
√( ) ( ) √( ) ( )
phase= ( ) [ ] ( )
| ( )|
( ) deg
dB
0.2 632.5 100.7 0.17 -2.110
0.4 1264.9 201.4 1.48 -4.820
0.6 1897.4
0.8 2529.8
1 3162.27
1.2 3794.7
1.4 4427
1.6 5060
1.8 5692
2 6325
2.5 7906
3 9487
4 12649 2014
where
The exact magnitude and phase plot can be now drawn on a semilog sheet taking on the log
scale.
47
5) Experimental (actual) plot
Give a sinusoidal supply of variable frequency varying from 100Hz to 1500Hz and obtain
the output voltage e0 (voltage across the capacitor) in each case. Take peak to peak input voltage
need be 2 volts. Find the phase angle from the lissageous pattern in each case.
f (Hz) E0 a b (
⁄ ⁄
100
2
200
2
300
2
400
2
500
2
600
2
700
2
800
2
900
2
1000
2
1100
2
1200
2
,
2
,
2
,
2
,
2
2000
The actual magnitude and phase angle plots are then drawn.
48
Bode Diagram
20
Magnitude (dB) 10
-10
-20
-30
-40
0 Freuency (rad/sec)
-45
Phase (deg)
-90
-135
-180
1 2 3
10 10 10
Frequency (rad/sec)
RESULT
Time domain and frequency domain response of the second order system are obtained by
conducting suitable experiments and compared the theoretical and experimental results.
Time domain
Frequency domain
49
EXPERIMENT 2
AC SERVOMOTOR
1. Aim:
2. Theory:
An Ac servo motor is basically a two phase induction motor. In normal induction motor, the
torque speed characteristics have both a positive slope region (unstable region) and negative slope
region (stable region). For an AC servomotor T-S characteristics should not have a negative slip
region to ensure stability. The torque developed should linearly decrease with speed. Therefore the
value of the rotor circuit resistance of an ac servomotor must be high. The servomotor should also
have quick acceleration from standstill and the rotor should have low inertia. Hence the rotor is
constructed with a smaller diameter to length ratio.
Figure shows:-
Fig a
The rotor is of squirrel cage type with short circuited conductor of high resistance embedded
in slots. The stator has reference winding and control winding displaced 900 electrical apart in
space. These windings are excited with two phase currents to produce a revolving magnetic field.
6
The field causes induced currents in the rotor producing a torque. The rotor thus starts by itself and
accelerates.
One of the two windings is supplied with an AC voltage of constant magnitude. This
winding is called the reference winding. The other winding supplied with variable voltage is called
the control winding by varying the control winding voltage, the speed can be varied. When the
control winding voltage is reversed, the rotor rotates in the opposite direction.
The slope of the T-S curve is B0. The torque developed is function of motor speed N and control
voltage Vc
( )
( ) ( ) ( ) ( )
( )
( )
( )
( )
( )
7
Fig b
It may be noted that the viscous damping coefficient B of the mechanical system combines with
the inherent electromagnetic parameters B0. Hence tests on the machine during normal operating
conditions yield the sum directly.
8
3. Procedure:
Connections are made as shown in Fig c. The reference voltage is kept constant at 50V. The control
voltage is adjusted to 25volts. Vary the load applied, for each load setting note down the values of
load and speed. Draw the torque-speed characteristics as shown in fig.a. the same procedure is
repeated for a control voltage 50 volts also.
Vc=25volts
,,
50
Vc=50volts
,,
50
4. Calculation :
Take the average of ‘Kc’ and obtained from the two curves.
9
( J = 10-6 Kgm2)
RESULTS
10
EXPERIMENT 3
AIM:
To obtain the transfer function of the given D.C.shunt motor under constant field excitation.
THEORY:
The major phenomena influencing the steady state and transient performance of a DC motor are:
1) The rise and fall of the armature and field currents and the electromagnetic interaction
between these circuits.
For constant field excitation, the control input is the armature supply and output is speed.
Let Ra, La, be the armature resistance and inductance Eb be the back emf developed. Let T be the
torque developed by the motor; be the speed of the rotor J and B be the effective moment of inertia
and damping of the rotating system. Then the armature input voltage at any time (fig. a)
But is constant
The torque developed is balanced by the reaction offered by rotating system i.e.,
1
Equating (3) and (4)
Where,
Let
There are two gain constants Kb and Kt. Both correspond to constant field excitation and have the
same numerical value.
i.e.
But
From and
The coefficient is obtain by conducting a no load test, keeping the field current constant
and varying the voltage applied to the armature over a wide range so as to run the machine rated speed
down to 20% of rated speed. characteristics is a straight line through the origin, slope of which
gives Kb.
To evaluate ‘J’ retardation test is conducted at no load, keeping the field excitation constant as before.
During the deceleration.
2
During deceleration, there is no developed torque. Constant ‘A’ is the virtual load torque and is
neglected in the derivation of T.F.
3
Fig c. Connection Diagram
PROCEDURE:
a) No Load Test
Do connection as in fig. 3 switch on D.C. supply. With switch closed, vary applied voltage so as to run
the motor at rated speed down to 20% of speed, keeping field current constant.
4
b) Retardation test:
Field current is kept constant to run the machine under no load condition at a speed greater than rated
speed. Now switch off armature supply, by opening the switch in fig.3, Machines slows down. Note
down rpm and time. Tabulate reading and draw N Vs t.
V N Ia Eb P P/
N t
RESULTS
5
EXPERIMENT 4
SYNCHRO COMPONENTS
AIM:
1. To study the synchro components (a) Transmitter (Tx), (b) Receiver (Tr) and to set their
electrical zero.
THEORY:
A system used to transmit mechanical shaft angles to remote location by means of electrical
voltage is known as a synchro system. There are six general types of synchro units, each classified
according to the function. These include the synchro transmitter(Tx), synchro receiver(Tr), synchro
differential transmitter(TDX), synchro differential receiver(TDR), synchro control transformer (CT)
and synchro resolver (SR). they are classified as a control or torque unit.
Synchro transmitter Tx
The synchro receiver, also called the synchro motor, torque receiver or repeater, is electrically
similar to the transmitter. It is basically a decoding unit that decodes the three single phase stator
voltages back to mechanical angle.The rotor which is free to turn, usually positions a light load-pointer
dial, or some other indicating device directly or through a light gear train. The angular position the
rotor depends upon the voltage received from the synchro transmitter. The receiver rotor differs from
transmitter rotor in that it is equipped with an inertia damper(having large moment of inertia) and
bearing with low friction losses. The inertia ring that is friction mounted on a sleeve exerts a breaking
action on the rotor, preventing any rapid overshoot or oscillation. Because of the damper in a synchro
11
receiver, the transmitter and receiver are not entirely interchangeable. A receiver may be used as a
transmitter, but not vice versa.
Synchro transmitter Tx
This unit is also known as the synchro generator or torque transmitter is basically a coding
device, which codes the mechanical angle of the rotor into a set of 3 ac voltages, in all phases.
Tx has a stator connected stator winding which resembles the stator of a 3 phase induction
motor. The rotor is a salient pole damp- bell shaped magnet with single winding, single phase voltage is
applied to the motor through two slip rings.
Let the voltage applied to the rotor be when the rotor winding is as shown in fig. a
Since the winding, S1 and S3 are 1200 and 2400 apart from S2.
The stator voltage voltages are single phase voltages. Suppose the rotor is turned through an angle ,
in the clock wise direction then
It can be seen that the three voltages are single phase voltages and the maximum or r.m.s values of the
stator voltages are representative of the rotor shaft position at any instant.
12
Synchro receiver (TR)
The construction of synchro receiver is similar to that of transmitter except that the rotor is
cylindrically shaped. The rotor has low friction and is free to run and decode the three stator voltages
back to mechanical angle.
Electrical zero:
When mechanical displacement of rotor maximum voltage is induced in the stato coil,
is zero. This position of the rotor is defined as the ‘electrical zero’ of the transmitter and is
used as reference for specifying the angular position of the rotor.
PROCEDURE:-
Connections are made as shown in fig. b, the rotor terminals are excited from single phase
supply. This causes induction of voltages in the stator windings In electrical zero position rotor
windings is in alignment with stator winding in this position the voltmeter
reads zero. Voltmeter reads is the maximum voltage induced
in the stator. If the rotor is 1800 displaced then reads . Rotor is turned until
reads zero and reads minimum.
Fine setting of electrical zero is done as follows. Connection are as in fig.c. Rotate the rotor
until the voltmeter reads zero. This position of the rotor indicates the electrical zero of synchro.
b) Transmitter characteristics
Connections are made in fig. d .Electrical zero of Tx should be set before doing connections. Set Tx
rotor angle at various angles from 00 to 3600 at intervals of 300 and read off
Plot Tx characteristics .
Connections are made as in fig. f. Electrical zero of both TX and Tr should be set before doing
connection. Both these units are excited from the same single phase ac supply. Set the transmitter rotor
angle from 300 to 3600 and read off the receiver position . Plot . Note the relative sense
of rotation of the receiver rotor with respect to the transmitter rotor.
13
Next interchange of the synchro receiver and repeat the experiment. Plot
. Finally interchange of receiver unit and repeat the experiment. Again Plot
. (Refer fig f)
Fig a Fig b
Fig c Fig d
14
Fig e
Fig f
RESULTS
15
COMPENSATING NETWORKS
For example, the steady state error in a control system can be reduced by increasing
forward path gain but on the other hand this increase in forward path gain results in making the
system more oscillatory or sometimes unstable.
Thus the gain adjustment improves the steady state accuracy of the system at the cost of
driving the system towards instability. However, improvement in steady state performance of a
control system by gain adjustment is possible in cases where the system is found to be within
desirable stability limit even after altering forward path gain. The forward path gain adjustment
method is not suitable where in the system becomes unstable due to such adjustment. In such
cases a compensation network is introduced in the system.
The compensation network introduces additional poles/zeros in the original system there
by altering its original transfer function. The effect of adding zero to an unstable system results
in making the system stable as shown in root locus plots of fig. (c ) & (d)
28
EXPERIMENT 5
AIM :
A) Design a compensating network and draw the theoretical Bode plot (Asymptotic and
exact) to provide a maximum phase lead of 30 0 at 200 Hz.
Fig a. shows a phase lead network in which the phase angle of the output voltage leads the phase
of the input voltage for the sinusoidal inputs.
( ) ( )[ ] ------------ (1)
( ) ( ) (2)
( ) ( )
( ) ( )
( )
( )
( )
ie, ( )
----------------- (3), where
( )
( ) ( ) ( )
( )
( ) ( ) ( )
( ) ( )
Sinusoidal transfer function ------------- (5)
( ) ( )
29
Fig a
Fig b
30
( )
( )
Since zero is near to the axis than the pole for a phase lead network. Hence the effect
of zero is dominant and therefore the phase lead network when introduced in cascade with
forward path of a transfer function, the phase shift is increased.
Fig c
( ) ( ) ( )
31
We know that, i.e, corresponding to maximum phase angle
√
=
√ √
Choose
Exact plot:
( )
√
√( )
√
From eqn (5), magnitude of gain⌊ ( )⌋
√
√ √ ( )
( )
32
( )
corresponding to
( )
√
Corresponding to , gain is
(
√
Gain =
√
(
√
= √
(√ )
=
√
(√ )
=
√
= *
√
=√
From (6)
( ) ( ) ( )
√ √
( ) (√ )
√
√
√
√ √
√
( )
= ------------------- (11)
33
Design;
Given
For the frequencies, the gain in db can be computed using eqn. (7).
Similarly, the phase angle using eqn. (6)
⌊ ⌋ G**
√
Thus, the exact bode plot both magnitude and phase) can be drawn in semilog sheet.
PROCEDURE:
For obtaining the gain and phase plots experimentally, make the connection with
the designed values as shown in figure. The input signal may be of varying frequency and it can
be obtained from a function generator. Vary the frequency of the input signal (sinusoidal) from
20Hz to 100Hz. The magnitude of the input voltage may be kept constant at 2 volts (peak to
peak). Corresponding to each frequency, the peak to peak value of the output signal e0(t) can be
measured. The phase angle where ‘a’ and ‘b’ are the measurements obtained from
the lissajeous pattern for the x-y mode of the operation of CRO.
34
( ) ( ) ⌈ ⌉
voltage Voltage
( ) ( ⁄ )
30 2
, ,
, ,
, ,
100K 2
1. A phase lead network for a maximum phase lead of 300 at 200Hz is designed and its
theoretical Bode plot (asymptotic and exact) is obtained.
3. The theoretical and experimental plots results are tabulated as follows for comparison.
Note: The bode plot of the phase lead network reveals that the lead network allows to pass high
frequencies and low frequencies are attenuated.
RESULTS
35
EXPERIMENT 6
AIM :
1. Design a phase lag network and draw the theoretical Bode plot (Asymptotic and exact) to
provide a maximum phase lag of 280 at 300Hz.
Fig a
Fig a. shows a phase lag network in which the phase of the output voltage lags the phase of the
input voltage for sinusoidal inputs. The transfer function of the circuit can be derived as follows.
( ) ( ) [ ] ( )
( ) ( ) [ ] ( )
36
( )
( ) ( )
( )
( ) ( )
( )
( )
( )
( )
( ) ( )
( )
As the gain is reduced at low frequencies additional gain is needed in the system to account for
the reduction in gain.
( ) ( ) ( )
The pole-zero configuration and Bode plot for the T F eqn(2) is as shown in fig b.
37
Fig b
As the frequency ‘ , increases, the variation in phase angle is as shown inn fig.
corresponding to frequency, , the phase angle , . At this frequency,
( ) ( )
( )
√ √
√ √
38
To draw theoretical Bode plot:
Exact Plot
√ √
As for the phase lead network, obtain the exact plot theoretically (both magnitude and phase).
( )
√
( ) ( )
√ √
( ) (√ )
√
( √ )
√
√
√
39
√
As is negative indicating that ‘ ’ is negative which means that the phase angle is
√
lagging.
From the pole zero configuration of phase lag network , it is observed that the pole is
nearer to origin compared to zero, hence the effect of pole is dominant. Hence, the phase lag
network when introduced in cascade with forward path of a transfer function, the
phase shift is reduced. The bode plot of phase lag network reveals that the lag network allows to
pass low frequencies and high frequencies are attenuated.
DESIGN:
( ) ( ) ,
PROCEDURE;
TABULATION :
40
RESULT:
41
EXPERIMENT 7
AIM:
i) To study the level process control system.
ii) To compare the performance characteristics of ON- OFF controller with proportional
controller in each case.
Fig a
Working Principle
The level process controller is used to perform the control action of level
process and study the characteristics of I/P converter. The RF capacitance level
transmitter is used to measure the level of the process tank. In level control action,
pumps sucks the water from reservoir and give it to control valve. Every internal
transaction are in voltage. Here IBM-PC acts as error detector and controller.
According to the error signal, corresponding control signal is given to the I/P
66
converter. It controls the flow of fluid in pipe line by varying stem position of the
control valve. For maintaining the level of process tank, flow is manipulated level
signal is given to the Data acquisition card. Bypass line is provided to avoid the pump
overloading.
From this controller also study the characteristics of level transmitter, I/P converter,
control valve and justify the various control action in the process.
CONTROLLERS
One of the most widely used type of control is the ON/OFF control. ON/OFF control
is also referred as “TWO POSITION” control or “ OPEN AND CLOSE” control.
Two position control is a position type of controller action in which the manipulated
variable is quickly changed to either a maximum or minimum value depending upon
whether the controlled variable is greater or less than the set point.
If the controlled variable is below the set point the controller output is 100%. If the
controlled variable is above the set point, the controller O/P is 0% when the
differential gap is 0. The tuning parameters for ON/OFF control are, Differential Gap
and Time delay.
Differential Gap is the region in which the control causes the manipulated variable to
maintain its previous value until the controlled variable has moved slightly beyond the
set point.
Small differential dap is not preferred because it will introduce oscillations and
reduces the life of the final control element.
This is the delay given to the controller between successive corrective actions.
2) PROPORTIONAL CONTROL
67
“It is a controller action in which there is a continuous linear relation between the value
of the controlled variable and position of the final control element within the
proportional band”.
Narrow Band proportional control gives a comparatively large corrective action to the final
actuating element (Thyristor unit) for a small change in the measurement.
For a Wide Proportional bands the corrective action to the final actuating element (Thyristor
unit) is small and therefore the offset will be large. Usually narrow proportional band is
preferred. If proportional band is zero the controller behaves as Two position control.
It is the proportional control factor which is used to determine the proportional band.
3) COMBINATION OF CONTROLLERS
68
Integral (OR) reset action combined with proportional control gives us a controller
which will always act to maintain the controlled variable at its desired value (the set point).
The proportional control mode provides a stabilizing influence while the integral mode will
help to overcome the OFFSET. Integral controller will provide corrective action as long as
there is a deviation in the controlled variable from the set point value. Integral control has a
phase lag of 900 over proportional control. This lagging feature of reset will result in a slow
response and oscillation will come into picture. The combination of proportional plus reset
(P+I) is most popular on application such as temperature control where the process has little
lag but required a wide proportional band for stability. The small process lag permits the use
of a large amount of integral action.
When all three control effects are combined together, we obtain the benefits of each
control action and moreover the effect duplicates the action of a good human operator on a
control application. A three mode controller contains the “stability” of proportional control
and the ability to eliminate offset because of reset control and the ability to provide an
immediate correction for the magnitude of a disturbance because of rate control.
PROCEDURE
69
5. Select suitable control action required from the control tab (ON/OFF, Proportional
control etc) and set the parameters.
6. Switch ON the compressor
7. Switch on the trainer kit
8. From the file menu of the computer, select START
9. Obtain the response of the system and save it.
RESULTS
70
MATLAB – I
Aim:
(I) Defining matrices and matrix algebra
(II) Creating and Running m-files and Simulink
(III) Plots and Subplots
(IV) Use control system toolbox to design control using root locus
Note that a semicolon at the end of the script is used to prevent the output from being
displayed on screen. Try without using the semicolon.
Problems:
I.1. Define any two 3x3 matrices A and B
(a) Compute: size(A), A+B, A-B, A/B, A-1 (inv(A)), A+i*B
(b) Differentiate between A*B &A.*B, A^2 & A.^2
(c) Create the following (n is the size of the matrix)
Identity matrix -- eye(n)
Matrix of zeros – zeros(n)
Matrix of ones – ones(n)
Diagonal matrix – diag(n)
16
Randomly generated matrix – rand(n)
Problems
III.1
𝒙 = −𝟒: 𝟎. 𝟎𝟏: 𝟒;
𝒚 = 𝒔𝒊𝒏(𝒙);
plot(x,y)
hold on;
y=cos(x);
III.2
(i)
III.3
17
III.4
Problems:
III.5 Write a MATLAB programme to plot the half wave rectified sine wave.
Hint: Construct a range of values of x from 0 to 3pi in steps of 0.1 and compute
corresponding values of sine function for these values of x in degrees. Construct a vector
of values of sin(x) which picks only the positive values of sin(x).
Aim: To enter a Transfer function of a system and to plot is step response, Bode plot and
root locus.
num=[1 2 3];
den=[4 5 6];
sys=tf(num,den)
Output:
18
Continuous-time transfer function.
>>sys
sys =
s^2 + 2 s + 3
---------------
4 s^2 + 5 s + 6
(ii)
Script:
s=tf('s');
sys=(s^2+2*s+3)/(4*s^2+5*s+6)
Output:
s^2 + 2 s + 3
---------------
4 s^2 + 5 s + 6
Problems
IV.2 Write a MATLABprogramme to obtain the step response of the given electrical
system, (RLC series circuit). Given R = 1000 ohms, L =1 H, C= 0.1µF. Obtain
the plots for different damping ratio by changing the value of R to 200 Ω , 600 Ω
and 1200 Ω
(Hint: Derive the TF of a sires RLC circuit, substitute the values of R, L and C.
Use step(sys) to obtain the step response of the system. See Help step in MATLAB)
19
Find the range of values of ‘K’ for which the system is stable.
Plot the locus of the closed-loop poles,as K is varied from 200 to 1460
Also obtain the step responses for K=200, 800 and 1460
(Hint: For root locus consider the open loop system and step response consider the
closed loop systemGo to help rlocus.)
\
IV.5 In the control system Gc(s) shown is a proportional controller K. Find
(b) Value of K for the complex dominant-poles damping ratio of 0.6. For this value of
K obtain the frequency response, GM and PM. Also obtain the step response and
the time-domain specifications.
IV.6 Obtain the unit step response for the system with the following closed-loop
transfer function
Use the damp function to obtain the roots of the characteristic equation, damping
factors and natural frequencies
(Hint: See help damp)
IV.7
Obtain the step response and time domain specifications for the control system given
20
Hint:
Script:
Gc=tf([50 70],[1 7]);
Gp=tf([1],[1 5 4 0]);
H=1;
G=series(Gc,Gp)
T=feedback(G,H)
ltiview('step',T)
21
RESULTS
22
MATLAB-II
STABILITY ANAYSIS USING FREQUENCY RESPONSE METHODS
1
1. Consider the system with transfer function 𝐺 𝑠 = 𝑠(0.2𝑠+1)(𝑠+1). Find the PM
and GM of the system. Simulate the unity feedback system and obtain the step
response using SIMULINK. Also compare the response using MATLAB step
command.
1 + 0.377 𝑠 12
1 + 0.128 𝑠 𝑠(𝑠 + 1)
3. Using MATLAB, obtain the phase margin of the compensated system for the given
1+5𝑠
plant using Bode plot, such that 𝐺𝑐 𝑠 = Obtain the bode plot of the
1+𝑠
uncompensated and compensated systems.
r(t) c(t)
1
𝐺𝑐 (𝑠) 𝐺 𝑠 =
𝑠(𝑠 + 2)
) )
74
MATLAB – III
Design a lag compensator to have the velocity error constant𝐾𝑣 = 30 and PM = 40°.
Compare the Bode plots of the uncompensated as well as the compensated systems.
3. The open loop transfer function of certain unity feedback control system is given by,
𝐾
𝐺 𝑠 =
𝑆(𝑆 + 4)(𝑆 + 80)
It is desired to have the phase margin to be at least 33o and a velocity error 𝐾𝑣 =30
sec-1. Design a phase lag compensator using MATLAB.
4
4. A system has open loop transfer function 𝐺𝑐 𝑠 =
𝑠(2𝑠+1)
It is desired to have the phase margin as 40°. Design a lead compensator to meet the
above specification. Represent the transfer function of the compensated system with
a block diagram. Compare the Bode plots of the uncompensated as well as the
compensated systems
76
5. An uncompensated system has plant transfer function
𝐾
𝐺(𝑠)
𝑠(1 + 0.1𝑠)(1 + 0.2𝑠)
The system must satisfy the following performance specifications. The magnitude of
steady state error of the system due to unit ramp function input is 0.01 and Phase
margin ≥ 400. Design a lead compensator and compare the Bode plots of the
compensated and uncompensated systems.
RESULTS
77
MATLAB-IV
PID Controller Design
AIM : Design and analysis of PID controller for a given system using MATLAB /
SIMULINK
1. For the control system shown below for K=1, 2, 5 and 10 obtain the step response and
steady state error theoretically and verify the result using MATLAB SIMULINK.
1
𝐾
1+5𝑠
2. Determine the step response of the system analytically for the following values of Kp
and Ki. Verify the answer using SIMULINK.
𝐾𝑖
r(t) c(t)
𝑠 1
𝐺 𝑠 =
1+2𝑠
) 𝐾𝑝 )
𝑲𝒑 1 1 1 1
𝑲𝒊 0 0.01 0.1 1
74
3. A unity feedback system has open loop transfer function
200
𝐺 𝑠 = .
(𝑠+2)(𝑠+10)
4. Design a PID controller for speed control of DC Motor transfer function model
developed in first cycle.
75
MATLAB - V
State Space Model for Analysis and Design
AIM : Study and analyse state space model of given system, and design a controller
by pole placement technique.
J = 0.01;
b = 0.1;
K = 0.01;
R = 1;
L = 0.5;
These state-space equations have the standard form shown below where the state vector and the
input .
J = 0.01;
b = 0.1;
74
K = 0.01;
R = 1;
L = 0.5;
A = [-b/J K/J
-K/L -R/L];
B = [0
1/L];
C = [1 0];
D = 0;
sys = ss(A,B,C,D);
Recall that the characteristic polynomial for this closed-loop system is the determinant of 𝑠𝐼 − (𝐴 − 𝐵𝐾) where 𝑠 is
the Laplace variable. Since the matrices A and BK are both 2x2 matrices, there should be 2 poles for the system.
This fact can be verified with the MATLAB command order. If the given system is controllable, then by designing a
full-state feedback controller we can move these two poles anywhere we'd like. Whether the given system is
controllable or not can be determined by checking the rank of the controllability matrix [B AB]. The MATLAB
command ctrb constructs the controllability matrix given matrices A and B. Additionally, the
command rank determines the rank of a given matrix. The following commands executed at the command line will
verify the system's order and whether or not the system is controllable.
75
sys_order = order(sys)
sys_rank = rank(ctrb(A,B))
sys_order =
sys_rank =
From the above, we know that our system is controllable since the controllability matrix is full rank. We will first place
the poles at -5+i and -5-i (note that this corresponds to a 𝜁 = 0.98 which gives close to 0% overshoot and a 𝜎 = 5
which provides a 0.8 second settling time). Once we have determined the pole locations we desire, we can use the
MATLAB commands place or acker to determine the controller gain matrix, 𝐾𝑐 , to achieve these poles. We will use
the command place since it is numerically better conditioned than acker. However, if we wished to place a pole
with multiplicity greater than the rank of the matrix 𝐵, then we would have to use the command acker. Add the
following code to the end of your m-file. Running in the command window will generate the feedback gain matrix
output below.
p1 = -5 + 1i;
p2 = -5 - 1i;
Kc = place(A,B,[p1 p2])
Kc =
12.9900 -1.0000
Referring back to the state-space equations at the top of the page, we see that substituting the state-feedback
law 𝑢 = 𝑟 − 𝐾𝑐 𝑥 for 𝑢 leads to the following expression, 𝑥 = 𝐴 − 𝐵𝐾𝑐 𝑥 + 𝐵𝑟.
We can then see the closed-loop response by simply adding the following lines to the end of your m-file. Running
your m-file in the command window will then give the plot shown below.
t = 0:0.01:3;
sys_cl = ss(A-B*Kc,B,C,D);
step(sys_cl,t)
grid
76
77
2. The state space model of motor position control is given below. Design a full state feedback
controller such that the poles are placed at 𝑠 = −100 + 100𝑖, −100 − 100𝑖, −200.
J = 3.2284E-6;
b = 3.5077E-6;
K = 0.0274;
R = 4;
L = 2.75E-6;
78