Sei sulla pagina 1di 69

1

Lecture Notes

Control Systems

Xiaoping Liu Department of Electrical Engineering Lakehead University

Contents
1 Mathematical Models: Dierential Equations 1.1 1.2 Electrical Systems: . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Mechanical Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1.2.1 1.2.2 1.3 Translational Motion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Rotational Motion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 1 2 3 3 5 7 8 9 11 11 12 12 15 21 21 21 21 22 22 23 24 25 25 29 29 30 32 33 35

Thermal Systems: Temperature Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

2 Laplace Transform 2.1 2.2 Partial Fraction Expansion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Using Laplace Transforms to Solve DE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

3 Mathematical Models: Transfer Function Representation 3.1 3.2 3.3 Transfer Function for the 1st Order System . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Transfer function for the 2nd order system: . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

4 Mathematical Models: Block Diagrams 5 Dynamic Responses 5.1 First Order Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5.1.1 5.1.2 5.1.3 5.1.4 5.2 5.2.1 5.2.2 5.2.3 Impulse Response . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Step Response . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Ramp Response . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Step Response . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Performance Measures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Second-Order Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

6 Steady-State Errors 6.1 6.2 Type of System . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Steady-State Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6.2.1 6.2.2 6.2.3 Steady-State Errors for Closed-Loop Systems with Unity Feedback . . . . . . . . . . . . . . . . . . . . Steady-State Errors for General Closed-Loop Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . Steady-State Errors for Systems with Disturbances . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

0 7 The Routh Stability Criterion 7.1 7.2 7.3

CONTENTS 39 39 39 40 43 43 44 49 55 55 56 61 61 63 63 64 64

Poles and Zeros . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Stability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . The Routh Stability Criterion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

8 Root Locus Analysis 8.1 8.2 Denition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Construction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

9 PID Controllers 10 Frequency Response 10.1 Steady-State Response . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10.2 Bode Plots . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 Control of Discrete Processes and PLC 11.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11.2 PLC Programming . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11.3 Internal Relays . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11.4 Timers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11.5 Counters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Chapter 1

Mathematical Models: Dierential Equations


1.1 Electrical Systems:

Basic Building Blocks

Resistor

v = Ri

i=

v R

Capacitor v =

1 C

idt

i = C dv dt

di Inductor v = L dt

i=

1 L

vdt

Example 1 Consider an RC circuit shown to the left. Input: v ; Output: vC . It follows from Kirchhos voltage law that v = iR + vC
C Replacing i with C dv dt gives

v = RC

dvC + vC dt

Moving all the terms related to the output to the left-hand side and the rest to the right-hand side, we get RC which is a rst-order system. General form for the rst order system is given by a1 with input u and output y . 1 dy + a0 y = b0 u dt dvC + vC = v dt

CHAPTER 1. MATHEMATICAL MODELS: DIFFERENTIAL EQUATIONS Example 2 Consider an RL circuit shown to the left. Input: v ; Output: iL . It follows from Kirchhos voltage law that v = iL R + vL
L Replacing vL with L di dt gives

v = RiL + L

diL dt

Moving all the terms related to the output to the left-hand side and the rest to the right-hand side, we get L which is also a rst-order system. diL + RiL = v dt

Example 3 Consider an RLC circuit shown to the left. Input: v ; Output: vC . It follows from Kirchhos laws that i = iL + iC v = iR + vC Substituting the rst equation to the second equation and replacing iL with v=R 1 L vC dt + C dvC dt + vC
1 L
C vC dt and iC with C dv dt gives

Dierentiating the equation with respect to t produces R dv d2 vC dvC = vC + RC 2 + dt L dt dt Moving all the terms related to the output to the left-hand side and the rest to the right-hand side, we get RC which is a second-order system. General form for a second-order system is given by a2 d2 y dy du + a0 y = b1 + b0 u + a1 dt2 dt dt R d2 vC dvC dv + vc = + dt2 dt L dt

1.2

Mechanical Systems

The basic building blocks for mechanical systems are shown below.

1.2. MECHANICAL SYSTEMS

1.2.1

Translational Motion

Translational Damper Damper represents the type of forces experienced when we endeavor to push an object through a uid or move an object against frictional forces. The faster the object is pushed, the greater the opposing forces. In the ideal case, the damping or resistive force Ff is proportional to the velocity v of the piston or object, that is , Ff = cv = c dx dt

c is a damping coecient constant. The larger the value of c the greater the damping force at a particular velocity. Translational Spring: Suppose a spring is xed at one end. When you try to pull or to push the spring at the other end, you are experiencing some kinds of resistive forces exerted by the stretched or compressed spring. This force will be in the opposite direction and equal in size to the force used to stretch or compress the spring, which is proportional to the extension or compression, that is, displacement Fs = kx where k is a spring constant called stiness. The bigger the value of k , the greater the forces have to be to stretch or compress the spring so the greater the stiness. Translational Mass The mass building block exhibits the property that the bigger the mass the greater the force required to give it a specic acceleration. Newtons second law gives d dx d2 x F = ma = m =m 2 dt dt dt where the constant of proportionality between the force and the acceleration is the constant called the mass m. a is the rate dx of change of velocity, i.e., a = dv dt , and velocity v is the rate of change of displacement x, i.e., v = dt .

1.2.2

Rotational Motion

Rotational Damper: A disc is rotated in a uid and the resistive torque f is proportional to the angular velocity (radians/second) f = c = c is the rate of change of angular displacement (rotated angle) . Torsional Spring: The tortue produced by a rotation spring is directly proportional the angle rotated . s = k Moment of Inertia: Moment of inertia exhibits the property that the greater the moment of inertia J the greater the torque needed to produce an angular acceleration (radians/second2) T = J = J d dw =J dt dt d dt =J d2 dt2 d dt

Example 4 Consider a mechanical system shown to the left. Input: F ; Output: x. since the net force is Fnet = F kx cv = F kx c dx dt . It follows from Newtons second law that Fnet = ma = m d2 x dt2

CHAPTER 1. MATHEMATICAL MODELS: DIFFERENTIAL EQUATIONS Replacing Fnet with F kx c dx dt yields F kx c d2 x dx =m 2 dt dt

Moving all the terms related to the output to the left-hand side and the rest to the right-hand side, we get m dx d2 x + kx = F +c dt2 dt Example 5 Consider a mechanical system shown to the left. Input: ; Output: . Since the net torque is net = k c = k c d dt . It follows from Newtons second law that net = J = J Replacing net with k c d dt yields k c d2 d =J 2 dt dt d2 dt2

Moving all the terms related to the output to the left-hand side and the rest to the right-hand side, we get J d2 d + c + k = 2 dt dt Example 6 Armature Controlled DC Motors In the armature controlled dc motor, vf is kept constant, so is V if = Rf . The input to the system is va and the output is . The f load torque is considered as a disturbance. The equivalent circuit for the armature controlled dc motor is shown in the gure to the left. The equations described the armature controlled dc motor are given below. va = Ra ia + La dia + ea dt ea = Ke if = K3 (1.1) (1.2) (1.3) (1.4) (1.5)

d = K if ia = K4 ia f = c d d L f = J dt Substituting (1.3) and (1.4) into (1.5) gives K4 ia L c = J Solving this equation for ia yields ia = Dierentiating ia produces dia J d2 1 dL c d = + + 2 dt K4 dt K4 dt K4 dt Substituting (1.6), (1.7) and (1.2) into (1.1), it follows that va = Ra c 1 J d + + L K4 dt K4 K4 + La 1 dL c d J d2 + + K4 dt2 K4 dt K4 dt + K3 c J d 1 + + L K4 dt K4 K4 d dt

(1.6)

(1.7)

1.3. THERMAL SYSTEMS: TEMPERATURE CONTROL which can be rewritten as La J d2 Ra J + La c d Ra c + K3 K4 Ra La dL + + = va L K4 dt2 K4 dt K4 K4 K4 dt Taking Laplace transform on both sides gives La J 2 Ra J + La c Ra c + K3 K4 Ra La s (s) + s (s) + (s) = Va (s) L (s) s L (s) K4 K4 K4 K4 K4 Solving this equation for (s) produces (s) = K4 La s + Ra Va (s) L (s) La Js2 + (Ra J + La c)s + Ra c + K3 K4 La Js2 + (Ra J + La c)s + Ra c + K3 K4 K4 La s + Ra = Va (s) L (s) (La s + Ra )(Js + c) + K3 K4 (La s + Ra )(Js + c) + K3 K4

(1.8)

(1.9)

La Note that the electrical time constant 1 is dened by 1 = R and the mechanical time constant 2 is dened by 2 = a Then, La = 1 Ra and J = 2 c. By replacing Ra and J by 1 Ra and 2 c, respectively, (1.8) becomes

J c.

1 Ra 2 c d2 Ra 2 c + 1 Ra c d Ra c + K3 K4 Ra La dL + + = va L 2 K4 dt K4 dt K4 K4 K4 dt which is equivalent to (1 2 Ra c) or
K3 K4 d2 1 + 2 d 1 + R K4 1 1 dL ac + va L + = dt2 1 2 dt 1 2 1 2 Ra c 1 2 c 2 c dt

dL d2 d + (Ra c + K3 K4 ) = K4 va Ra L La + (2 Ra c + 1 Ra c) dt2 dt dt

(1.10)

(1.11)

which is in the standard form. Variable Rf Lf vf if ea Ke L J 1 Description Field resistance Field inductance Field voltage Field current Back electromotive force (emf) Voltage constant (emf) Angular velocity Load torque Moment of inertia Electrical time constant Variable Ra La va ia d K f K3 = Ke i f c 2 Description Armature resistance Armature inductance Armature voltage Armature current Developed torque Torque constant Torsional resistive torque K4 = K i f Damping coecient Mechanical time constant

1.3

Thermal Systems: Temperature Control

Thermal resistance: The head ow rate q is proportional to the temperature dierence T1 T2 and ows toward the lower temperature T1 T2 q= R Then the constant R is called the thermal resistance. Thermal capacitance C is the head required for a 10 C temperature rise. In order to raise temperature from T to T + dT, the total head required is dQ = CdT . The heat ow rate required is q= dT dQ =C dt dt

CHAPTER 1. MATHEMATICAL MODELS: DIFFERENTIAL EQUATIONS Example 7 Consider a thermal system shown to the left. The ambient temperature is Ta and the temperature inside the box is T . The heat produced by the heater ows into the box at a rate qi . The thermal capacitance of the air inside the box is C and the thermal resistance of the box wall is R. Find the model for the system with input qi and output T . Solution: The heat ow rate out of the box through the box wall is qo = T Ta R

The net heat ow rate into the box is qi qo . The heat required to raise the inside temperature from T to T + dT is CdT , which implies that the heat rate required is C dT dt . As a result, C T Ta dT = qi q0 = qi dt R

Rearranging the equation gives C dT T Ta + = qi + dt R R

where Ta can be considered a disturbance to the system. Example 8 Consider a thermometer at temperature T which has just been inserted into a liquid at temperature TL . If the thermal resistance to heat ow from the liquid to the thermometer is R, then the heat ow rate from the liquid to the thermometer is TL T q= R which is used up to raise the thermometer temperature from T to T + dT . Then we have q= that is, dT TL T =C R dt Rearranging the equation gives T TL dT + = dt R R which is a rst-order system with input TL and output T. C TL T dT =C R dt

Chapter 2

Laplace Transform
The Laplace transform is a method of transforming dierential equations into more easily handled algebraic equations.. Let f (t) be a function dened on [0, T ]. Then, its Laplace transform is dened by

L[f (t)] = F (s) =


0

f (t)est dt

The inverse Laplace transform is dened by f (t) = L1 [F (s)] = 1 2j


b+j

F (s)est ds
bj

The lower case letters are used to denote the functions in time domain. The upper case letters are used to denote the functions in s domain. As an example, let us calculate the Laplace transform for a unit step function 1(t) = Its Laplace transform is

1 0

t0 t<0

L[1(t)] =
0

1 est dt = est s

=
0

1 s

Generally speaking, its not easy to calculate the Laplace transform and the inverse Laplace transform for a given function. Fortunately, for those functions which are commonly used in this course, we dont need to calculate them ourself. There is Laplace Transform Table available, where you can nd what you want. But it is useful to remember some commonly used Laplace transforms, for instance: L[ (t)] = 1, L[t] = 1 , s2 L[eat ] = 1 , s+1 L[sin t] = , s2 + 2 L[cos t] = s s2 + 2

Basic Rules: L[f1 (t) + f2 (t)] = F1 (s) + F2 (s) L[f1 (t) f2 (t)] = F1 (s) F2 (s) L[af (t)] = aF (s) L[f (t T )] = eT s F (s) d L[ dt f (t)] = sF (s) f (0) df (0) d2 2 L[ dt 2 f (t)] = s F (s) sf (0) dt n d n n1 L[ dt f (0) n f (t)] = s F (s) s t L[ 0 f (t)dt] = 1 s F (s) Limit f (t) = Limit sF (s)
t0 s s0

L1 [F1 (s) + F2 (s)] = f1 (t) + f2 (t) L1 [F1 (s) F2 (s)] = f1 (t) f2 (t) L1 [aF (s)] = af (t) L1 [eT s F (s)] = f (t T )

dn1 f (0) dtn1

The initial value theorem The nal value theorem

Limit f (t) = Limit sF (s)


t

8 Laplace Transform Table (t) 1(t) t e teat t2 eat 1 eat t


1eat a t2 2 at

CHAPTER 2. LAPLACE TRANSFORM

1
1 s 1 s2 1 s3 1 s+a 1 (s+a)2 2 (s+a)3 a s(s+a) a s2 (s+a) a s(s+a)2
2

(1 at)eat
e
at

e ba b at b ae

bt

a bt ba e

sin t cos t eat sin t eat cos t 1 cos t 2 et sin[


1

1 2 t] 1 2 t + cos1 ( )]

s (s+a)2 1 (s+a)(s+b) ab s(s+a)(s+b) s2 + 2 s s2 + 2 (s+a)2 + 2 s+a (s+a)2 + 2 2 s(s2 + 2 ) 2 s2 +2s+ 2 ,


2

<1 <1

t eat ateat Example 1

1 et 1 2

sin[

s(s2 +2s+ 2 ) ,

1.L[4 1(t)] = 4L[1(t)] = 4 1 s = 3.L[3t] = 3L[t] =


3 s2

4 s

4 2s 2.L[4 1(t 2)] = 4L[1(t 2)] = 4e2s L[1(t)] = 4e2s 1 s = se

4.L[3 (t 2)] = 3L[ (t 2)] = 3e2s L[ (t)] = 3e2s


10 5.L[2 sin(10t)] = 2L[sin(10t)] = 2 s2 +100 = 20 s2 +100
2

6.L[t2 (1 + eat )] = L[t2 eat + t2 ] = L[t2 eat ] + L[t2 ] = L[t2 eat ] + L 2 t2 7.L1
2 s

2 (s+a)2

2 s3

= 2L1 [ 1 s ] = 2 1(t)
3 1 2 s+ 1 2 1 =3 2L 1 s+ 1 2 2t =3 2e
1

1 8.L1 [ 2s3 +1 ] = L

2.1
1.

Partial Fraction Expansion


Linear factors in the denominator
f (s) (s+a)(s+b)(s+c)

A s+a

B s+b

C s+c

2. Repeated linear factors in the denominator


f (s) (s+a)n

A s+a

B (s+a)2

C (s+a)3

++

N (s+a)n

3. Quadratic factors in the denominator


f (s) as2 +bs+c

As+B as2 +bs+c

4. More general case


f (s) (as2 +bs+c)(s+d)

As+B as2 +bs+c

C s+d

Example 2 Determine the partial fractions of Solution:


s+5 s2 +3s+2 s+5 s2 +3s+2 resolved A s+5 = (s+1)(s+2) s+1

B s+2

A(s+2)+B (s+1) (s+1)(s+2)

So, s + 5 = A(s + 2) + B (s + 1) Choose two dierent values for s to nd A and B. s = 2 = 3 = B (1) = B = 3 s = 1 = 4 = A(1) = A = 4 So,
s+5 s2 +3s+2

4 s+1

3 s+2

2.2. USING LAPLACE TRANSFORMS TO SOLVE DE

2.2
1.

Using Laplace Transforms to Solve DE


Determine initial conditions

2. Take Laplace transform to change the dierential equations to algebraic equations 3. Solve the algebraic equations for unknown variables 4. Carry out partial fraction expansion to put the resulting equations into the sum of fractions which can be found in the Laplace transform table. 5. Take inverse Laplace transform to change s-domain functions into t-domain functions Example 3 Solve the dierential equation RC dvC + vC = v dt

with zero initial condition and step input v = V 1(t), which is a model for the RC circuit to the left. Solution: Taking Laplace transform on both sides gives RCsVC (s) + VC (s) = Solving for VC (s) yields VC (s) = V s(RCs + 1) V s

Converting it into the form that you can nd in Laplace transform table, it follows that VC (s) = V Taking the inverse transform produces VC (t) = V 1 e RC Example 4 Solve the dierential equation C dT 1 1 + T = TL , dt R R T (0) = 0
t

1 RC

s s+

1 RC

which is the mathematical model for the thermal system shown in the gure to the left. Solution: Taking L transform gives CsT (s) + Solving for T (s) produces T (s) =
1 R

1 1 T (s) = TL (s) R R 1 TL (s) RCs + 1

Cs +

1 R

TL (s) =

Case 1 Unit-impulse response TL (t) = (t) = TL (s) = 1. The temperature in s-domain is given by T (s) = with = RC . Taking L1 transform yields 1 t e Case 2 Unit-step response TL (t) = 1(t) = TL (s) = 1 s . The temperature in s-domain is given by T (t) = T (s) =
1 1 1 = 1 s + 1 s s(s + ) 1 1 = s + 1 s+ 1

10 Taking L1 transform gives Case 3 Unit ramp response TL (t) = t = TL (s) =


1 s2 .

CHAPTER 2. LAPLACE TRANSFORM

T (t) = 1 e The temperature in s-domain is given by


1 1 1 = 1 s + 1 s2 s(s + )

T (s) = Taking L1 transform produces

T (t) = t

(1 e )
1

Chapter 3

Mathematical Models: Transfer Function Representation


Suppose we have a system where the inputs u is related to the output y by the dierential equation: a2 d2 y dy du + a0 y = b1 + b0 u + a1 2 dt dt dt

where a2 , a1 , a0 , b1 , and b0 are constants. If all the initial conditions are zero, then the Laplace transform of this equation is a2 s2 Y (s) + a1 sY (s) + a0 Y (s) = b1 sU (s) + b0 U (s) Solving for Y (s) gives Y (s) = Hence, Y (s) b1 s + b0 = 2 U (s) a2 s + a1 s + a0 This is the transfer function of the system. The transfer function G(s) of a linear system is dened as the ratio of the Laplace transform of the output variable Y (s) to the Laplace transform of the input variable U (s), with all initial conditions assumed to be zero. Y (s) G(s) = U (s) For the system described by the dierential equation above G(s) = Y (s) b1 s + b0 = U (s) a2 s2 + a1 s + a0 b1 sU (s) + b0 U (s) b1 s + b0 = U (s) a2 s2 + a1 s + a0 a2 s2 + a1 s + a0

3.1

Transfer Function for the 1st Order System


Dierential Equation Laplace Tansform General Form Transfer Function Dierential Equation Standard Form Laplace Tansform Transfer Function a1 dy zero initial conditions dt + a0 y = b0 u a1 sY (s) + a0 Y (s) = b0 U (s) (s) b0 G(s) = Y U (s) = a1 s+a0 zero initial conditions dy dt + y = Ku sY (s) + Y (s) = KU (s) (s) K G(s) = Y U (s) = s+1 11

12

CHAPTER 3. MATHEMATICAL MODELS: TRANSFER FUNCTION REPRESENTATION

3.2

Transfer function for the 2nd order system:


Dierential Equation Laplace Tansform General Form Transfer Function Dierential Equation Standard Form Laplace Tansform Transfer Function
dy y zero initial conditions a2 d dt2 + a1 dt + a0 y = b0 u 2 a2 s Y (s) + a1 sY (s) + a0 Y (s) = b0 U (s) (s) b0 G(s) = Y U (s) = a2 s2 +a1 s+a0 2 2 + 2n dy zero initial conditions dt + n y = Kn u 2 2 s Y (s) + 2n sY (s) + n Y (s) = Kn U (s) 2 Kn (s) G(s) = Y U (s) = s2 +2n s+ 2
n 2

d2 y dt2 2

3.3

Examples
Example 1 Find the transfer function for the dierential equation RC dvC + vC = v dt

which is a model for the RC circuit to the left. Solution: Taking Laplace transform on both sides, with zero initial conditions, gives RCsVC (s) + VC (s) = V (s) Solving for VC (s) yields VC (s) = Then the transfer function is given by G(s) = 1 VC (s) = V (s) RCs + 1 V (s) RCs + 1

Example 2 Find the transfer function for the dierential equation L diL + iL = v R dt which is a model for the RL circuit to the left. Solution: Taking Laplace transform on both sides, with zero initial conditions, gives L sIL (s) + IL (s) = V (s) R Solving for IL (s) produces IL (s) = which implies that G(s) = IL (s) = V (s)
L Rs L Rs

1 V (s) +1 1 +1

Example 3 Find the transfer function for the dierential equation RC d2 vC R dvC dv + vC = + 2 dt dt L dt

which is a model for the RLC circuit to the left. Solution: Taking Laplace transform on both sides, with zero initial conditions, gives RCs2 VC (s) + sVC (s) + R VC (s) = sV (s) L

3.3. EXAMPLES Solving for VC (s) produces VC (s) = which implies that G(s) = IL (s) s = 2 V (s) RCs + s +
R L

13

s RCs2 + s +

R L

V (s)

Example 4 Find the transfer function for the dierential equation La J d2 Ra J + La c d Ra c + K3 K4 Ra La dL + + = va L K4 dt2 K4 dt K4 K4 K4 dt which is a model for the armature controlled dc motor shown to the left. Solution: Taking Laplace transform on both sides, with zero initial conditions, gives Ra J + La c Ra c + K3 K4 La J 2 s (s) + s (s) + (s) K4 K4 K4 Ra La = Va (s) L (s) s L (s) K4 K4 Solving this equation for (s) produces (s) = K4 La s + Ra Va (s) L (s) 2 La + (Ra J + La c)s + Ra c + K3 K4 La Js + (Ra J + La c)s + Ra c + K3 K4 K4 La s + Ra = Va (s) L (s) (La s + Ra )(Js + c) + K3 K4 (La s + Ra )(Js + c) + K3 K4 Js2 Example 5 Find the transfer function for the dierential equation C 1 1 dT + T = TL dt R R

which is the mathematical model for the thermal system shown in the gure to the left. Solution: Taking L transform gives CsT (s) + Solving for T (s) produces T (s) = Then, the transfer function is given by G(s) = 1 T (s) = TL (s) RCs + 1
1 R

1 1 T (s) = TL (s) R R 1 TL (s) RCs + 1

Cs +

1 R

TL (s) =

14

CHAPTER 3. MATHEMATICAL MODELS: TRANSFER FUNCTION REPRESENTATION

Chapter 4

Mathematical Models: Block Diagrams


(s) Consider a transfer function G(s) = Y U (s) with U (s) and Y (s) being its input and output. It is obvious that Y (s) = G(s)U (s), which can be represented by a block diagram as shown in the gure below.

Arrows are used to represent the directions of signal ow. Comparator can be represented by a summing point. Where a signal is taken o from some point in a signal path, the take-o point is used. Closed-loop system Forward path is used for those elements through which a signal passes when moving in the direction from input to output for a system as a whole, as shown in the gure to the left. The transfer function of the forward path is called the feedforward transfer function. Feedback path is used for those elements through which a signal passes when being fed back from the output towards the input, as shown in the gure to the left. The transfer function of the feedback path is called the feedback transfer function. Series Connection: The transfer function of a system composed of several subsystems connected in series is the product of transfer functions of individual subsystems, as shown in the gure below.

Parallel Connection: The transfer function of the system composed of two systems connected in parallel, as shown in the gure below, is the sum of transfer functions of individual subsystems.

15

16

CHAPTER 4. MATHEMATICAL MODELS: BLOCK DIAGRAMS

Feedback Connection: The open-loop transfer function is dened as the ratio of the feedback signal Uf (s) to the actuating error signal U (s) Uf (s), which is given by Uf (s) = G(s)H (s) U (s) Uf (s)

Go (s) =

The closed-loop transfer function is dened as the ratio of the output signal Y (s) to the input signal X (s), which is derived as follows: Y (s) = G(s)X (s) = G(s)[U (s) Uf (s)] = G(s)[U (s) H (s)Y (s)] = G(s)U (s) G(s)H (s)Y (s) which implies that [1 + G(s)H (s)]Y (s) = G(s)U (s) Therefore, the transfer function is Gc (s) = G(s) 1 + G(s)H (s)

Example 1: Find transfer functions for the systems shown in the gure to the left. Solution: The transfer function for the rst system is G(s) = G1 (s) + G2 (s) = 1 5(s + 1) 5s + 6 1 +5= + = s+1 s+1 s+1 s+1

The transfer function for the second system is G(s) = Gc (s) = 1 G(s)H (s) 1 Example 2 Armature controlled dc motor
2 s+1 2 s+1

5s

2 s+1 s+110s s+1

2 9s + 1

17

The equivalent circuit for the armature controlled dc motor is shown in the gure to the left. The system can be divided into four parts, armature winding, Ea versus , d versus ia , and load. The transfer functions for all parts are derived below. Armature Winding: It follows from Kirchhos voltage law that dia va ea = Ra ia + La dt Taking Laplace transform on both sides gives Va (s) Ea (s) = Ra Ia (s) + La sIa (s) that is, Ia (s) 1 = Va (s) Ea (s) La s + Ra Ea versus : It is obvious that ea = K3 Taking Laplace transform on both sides gives Ea (s) = K3 (s) that is, Ea (s) = K3 (s) d versus ia : It is easily seen that d = K4 ia Taking Laplace transform on both sides gives d (s) = K4 Ia (s) that is, d (s) = K4 Ia (s) Load: It follows from Newtons second law that d L f = J Replacing f by c , we get d L c = J which is equivalent to d L = J d + c dt d dt d dt

Taking Laplace transform on both sides gives

18

CHAPTER 4. MATHEMATICAL MODELS: BLOCK DIAGRAMS

d (s) L (s) = Js (s) + c (s) that is, Ia (s) 1 = d (s) L (s) Js + c These blocks are shown in the gure in previous page. Now we can put all four block diagrams together to create a block diagram for the armature controlled dc motor, which is shown in the gure below.

In the following, we will determine the transfer function Ga (s) from Va (s) to (s) and the transfer function G (s) from L (s) to (s). Ga (s) can be determined by letting L (s) = 0. The process for determining Ga (s) is shown in the gure below, from which we get K4 Ga (s) = (La s + Ra )(Js + c) + K3 K4

19 G (s) can be determined by letting Va (s) = 0. The process for determining Ga (s) is shown in the gure below, from which we get La s + Ra G (s) = (La s + Ra )(Js + c) + K3 K4

The output from the armature controlled dc motor is given by (s) = Ga (s)Va (s) + G (s)[L (s)] = K4 La s + Ra Va (s) L (s) (La s + Ra )(Js + c) + K3 K4 (La s + Ra )(Js + c) + K3 K4

20

CHAPTER 4. MATHEMATICAL MODELS: BLOCK DIAGRAMS

Chapter 5

Dynamic Responses
There are four kinds of responses, namely impulse response, step response, ramp response, and frequency response, which are commonly used in control systems. The impulse response is the output of the system corresponding to an impulse input. The step response is the output of the system corresponding to a step input. The ramp response is the output of the system corresponding to a ramp input. The frequency response is the output of the system corresponding to a sinusoidal input.

5.1

First Order Systems


a1 a0 , K b0 a0

A rst-order system can be described by a dierential equation or a transfer function as shown below. = a1 dy dt + a0 y = b0 u L1 L b0 G(s) = a1 s +a0 = dy dt + y = Ku L1 L K G(s) = s +1

a1 = , a0 = 1, b0 = K

5.1.1

Impulse Response

Input u = A (t) or U (s) = A Output in s-domain is given by Y (s) = G(s)U (s) = Output in t-domain is given by (taking inverse Laplace transform) y (t) = KA t e KA s + 1

5.1.2

Step Response

Input u = A 1(t) or U (s) = A s Output in s-domain is given by Y (s) = G(s)U (s) =


1 KA = KA 1 s( s + 1) s(s + )

Output in t-domain is given by (taking inverse Laplace transform) y (t) = KA(1 e ) = KA KAe where the rst term is called the forced response or steady-state response, which is caused by the input, whereas the second term is referred to as transient response or dynamic response, which represents the transient process experienced by the system after an input is applied. 21
t t

22

CHAPTER 5. DYNAMIC RESPONSES

K is called a steady-state gain, which is the ratio between the steady-state output and input. is referred to as a time constant, which shows how fast the system responds to the step input. The output will reach to 60% of its steady-state value at one moment, 95% at 3 times .

5.1.3

Ramp Response

A Input u = At or U (s) = s 2 Output in s-domain is given by

Y (s) = G(s)U (s) =

s2 ( s

1 AK = KA 2 1 + 1) s (s + )

Output in t-domain is given by (taking inverse Laplace transform) y (t) = KA t 1 e


t

5.1.4

Example

Example: A thermocouple has the dynamics of 10 dTo + To = 30 106 Ti dt

with output To in volt and input Ti in C . Answer the following questions: 1. Transfer function. 2. Time constant and steady-state gain. 3. The nal steady-state value when there is a step input of 100 C . 4. What will be the output of the thermocouple 5s after it was subject to a temperature impulse of 100 C by suddenly and very briey coming into contact with a hot subject of 100 C . 5. When the thermocouple is subject to a steadily rising temperature input of 5 C/s, what will be the thermocouple output after 12s. Solution: 1. Taking Laplace transform on both sides of the dierential equation gives 10sTo(s) + To (s) = 30 106 Ti (s) Solving this equation for To (s) produces To (s) = which implies that the transfer function is G(s) = 30 106 10s + 1 30 106 Ti (s) 10s + 1

2. Since G(s) is in the standard form, = 10s and K = 30 106 V / C . 3. The input is Ti (t) = 100 1(t) and its Laplace transform is Ti (s) = To () = lim sTo (s) = lim sG(s)Ti (s) = lim s
s0 s0 s0 100 s .

It follows from the nal value theorem that

3000 106 30 106 100 = lim = 3000 106 V s0 10s + 1 s 10s + 1

5.2. SECOND-ORDER SYSTEMS 4. The input is Ti (t) = 100 (t) and its Laplace transform is Ti (s) = 100. Then, the output in s-domain is To (s) = G(s)Ti (s) = Taking inverse Laplace transform gives To ( t ) = Therefore To (t) at t=5s is given by To (5) =
5 3000 106 10 e = 1.8 104 V 10

23

1 3000 106 30 106 100 = = 3000 106 10 1 10s + 1 10s + 1 s + 10

3000 106 t e 10 10

5. The input is Ti (t) = 5t and its Laplace transform is Ti (s) = To (s) = G(s)Ti (s) = Taking inverse Laplace transform gives

5 s2 .

Then, the output in s-domain is

1 30 106 5 150 106 6 10 = 150 10 = 10s + 1 s2 s2 (10s + 1) s2 (s +

1 10 )

To (t) = 150 106 t 10 1 e 10 Therefore To (t) at t=12s is given by To (12) = 150 106 12 10 1 e 10
12

= 7.5 104 V

5.2

Second-Order Systems

A second-order system can be described by a dierential equation or a transfer function as shown below. 2n =
dy y a2 d dt2 + a1 dt + a0 y = b0 u 1 L L 0 G(s) = a2 s2 +ba 1 s+a0
2

a1 2 a 2 , n

a0 2 a2 , Kn

b0 a2

2 2 a2 = 1, a1 = 2n , a0 = n , b0 = Kn

d2 y dt2

2 2 + 2n dy dt + n y = Kn u 1 L L 2 Kn G(s) = s2 +2n s+2


n

The equation obtained by letting the denominator of a transfer function equal to zero is called the characteristic equation. For the second order system, the characteristic equation is as follows:
2 s2 + 2n s + n =0

Roots of this characteristic equation are s1,2 =


2 (2n )2 4n 2 2 4 2 2n 4 2 n n = 2 = n n 2 1

2n

(5.1) (5.2) (5.3)

Case 1: > 1. The system is called overdamped. In this case, the characteristic equation has two dierent real roots. Case 2: = 1. the system is called critically damped. In this case, the characteristic equation has two equal real roots. Case 3: < 1. the system is called underdamped. In this case, the characteristic equation has two complex conjugate roots.

24

CHAPTER 5. DYNAMIC RESPONSES

5.2.1

Step Response

Input u = A 1(t) or U (s) = A s Output in s-domain is given by Y (s) = G(s)U (s) =


2 Kn 2) s(s2 + 2n s + n

Output in t-domain will be discussed for overdamped, critically damped and underdamped systems, respectively. Case 1: < 1 (overdamped). In this case, the characteristic equation has two dierent real roots and the denominator of the transfer function can be factored into
2 = (s s1 )(s s2 ) s2 + 2n s + n

with s1 and s2 given by (5.3). As a result, we have Y (s) = It follows from the Laplace transform table that ab b at a bt 1 e e + s(s + a)(s + b) ba ba Now let a = s1 = n n 2 1 and b = s2 = n + n ab = (n n
2 2 Kn s(s s1 )(s s2 )

2 1. Then, 2 1)

2 1)(n + n 2 1)
2

= (n ) (n =
2 n

b a = n + n

2 1 n + n

2 1 = 2n

2 1

n + n 2 1 b = ba 2n 2 1 = + 2 1 2 2 1

n n 2 1 a = ba 2n 2 1 = Now we have y (t) = K 1 + 2 2 1 2 1 e


n +n 2 1 t

2 1

2 2 1

2 1 2 1

e
n n 2 1 t

Case 2: = 1 (Critically damped). In this case, the characteristic equation has two equal real roots and the denominator of the transfer function can be factored into
2 s2 + 2n s + n = (s s1 )2

with s1 = n . As a result, we have Y (s) = It follows from the Laplace transform table that a2 1 eat ateat s(s + a)2
2 Kn s(s s1 )2

5.2. SECOND-ORDER SYSTEMS Now let a = s1 = n . Then, y (t) = K 1 en t n ten t Case 3: < 1 (Underdamped). In this case, the characteristic equation has two complex conjugate roots. Then, Y (s) = It follows from the Laplace transform table that
2 n , < 1 1 2) s(s2 + 2n s + n

25

s(s2

2 Kn 2) + 2n s + n

1 1 2

en t sin n

1 2 t + cos1 ( )

Therefore, we have y (t) = K 1 1 1 2 en t sin n 1 2 t + cos1 ( )

5.2.2

Performance Measures

1. The rise time tr is the time taken for the response y (t) to rise from 0 to the steady-state value y . It is a measure of how fast a system responds to the input. When < 1, this is the time for the oscillating response to complete a quarter of a cycle, i.e. d tr = with = 1 (damped frequency). As a result, d n 2 tr = = 2d 2n 1

2. The peak time tp is the time taken for the response to rise from 0 to the rst peak value. This is the time for the oscillating response to complete a half cycle, i.e. d tp = . As a result, tp = = d n 1

3. Overshoot is the maximum amount by which the response overshoots the steady-state value. It is thus the amplitude of the rst peak. It is sometimes written as a percentage of the steady-state value. % Overshoot = e
1

100%

4. Settling time ts is the time taken for the oscillation to fall within and remain 5% of the steady-state value. ts = 3 n

5.2.3

Examples

Example 1 A second order system has a natural frequency of 2rad/s and a damped frequency of 1.8rad/s. Find the damping factor (ratio), the 100% rise time, the percent overshoot, and the 5% settling time. Solution: It follows from d = n 1 2 that
2 2 d = n (1 2 ) 2 d = 1 2 2 n

Thus, the damping factor is = The 100% rise time is tr = 1


2 d = 2 n

1.82 = 0.44 22

= 0.87s = 2d 2 1.8

26 The percent overshoot is %Overshoot = e The 5% settling time is ts = 3 3 = 3.4s = n 0.44 2



1 2

CHAPTER 5. DYNAMIC RESPONSES

100% = e

0.44

10.442

100% = 21%

Example 2 An armature controlled dc motor speed system is described by the following dierential equation: d2 d +5 + 100 = 100va 2 dt dt What is the 5% settling time for the system? Solution: Comparing the model above with the standard form d2 d 2 2 + n + 2n = Kn va dt2 dt produces
2 n = 100 n = 10 5 2n = 5 = = 0.25 2n 100 2 Kn = 100 K = 2 = 1 n

Thus, the 5% settling time is ts = 3 3 = 1.2s = n 0.25 10

Example 3 A second-order system has an overshoot of 10% and a rise time of 0.4s when subject to a step input. Find the damping ratio, damped frequency and natural frequency. Solution: It follows from the denition of the percent overshoot that e that is

1 2

100% = 10% 1 2

e Multiplying both sides by

1 2

= 0.1

= ln 0.1 = 2.3

1 2 gives = 2.3 1 2 2 2 = 2.32 (1 2 )

Solving for yields = Since the rise time is given by tr =


2d ,

2.3 = 0.6 2 + 2.32

it is obtained that d = = 3.9rad/s = 2tr 2 0.4 3.9 = 4.9rad/s 1 0.62

It follows from d = n

1 2 that n = d 1 2 =

Example 4 A second-order system has a damping ratio of 0.4, a natural frequency of 10rad/s and a steady-state gain of 10. Find the transfer function, percent overshoot, rise time, and unit step response.

5.2. SECOND-ORDER SYSTEMS Solution: The transfer function is given by G(s) = The percent overshoot is %Overshoot = e The 100% rise time is tr = 2n

1 2

27

2 Kn 10 102 1000 = = 2 2 s2 + 2n s + n s2 + 2 0.4 10s + 102 s + 8s + 100

100% = e =

0.4

10.42

100% = 25.4%

1 2

= 0.17s 2 10 1 0.42

The unit step input is u = 1(t) with Laplace transform of U (s) = 1 s . Therefore, the output in s-domain is given by Y (s) = G(s)U (s) = It follows from the Laplace transform table that y (t) = 10 1 1 e0.410t sin 10 1 0.42 t + cos1 (0.4) 1 0.42 = 10 1 1.09e4t sin 9.2t + 66.4 )] 10 100 s(s2 + 8s + 100)

Example 5 Consider a second-order system of RLC circuit 1 v d2 i R di + i= + dt2 L dt LC LC with R = 100, L = 2H , and C = 20 106 F . Find the natural frequency, damping ratio, damped frequency, and unit impulse response. Solution: Comparing the model in the example with the standard form d2 y dy 2 2 + n + 2n y = Kn u dt2 dt produces
2 n =

1 1 1 = 25000 n = = 158rad/s = LC 2 20 106 LC


R R R = 50 = L = 1 L 2 2 LC 1 LC 1 LC

2n =
2 Kn =

100 C = L 2 =1

20 106 = 0.16 2

1 1 = 25000 K = LC = 2 LC n

The damped frequency is d = n The transfer function is G(s) = The impulse response in s-domain is I (s) = G(s)V (s) = Taking inverse Laplace transform gives i( t) = en t sin n 1 2 t 1 2 158 = e0.16158t sin (156t) 1 0.162 = 160e25.28t sin (156t) n 25000 s2 + 50s + 25000 1 2 = 158 1 0.162 = 156rad/s
2 Kn 25000 = 2 2 2 s + 2n s + n s + 50s + 25000

28 Example 6 A robot arm has a transfer function of G(s) = Find the unit ramp response. Solution: The input is u(t) = t and its Laplace transform is U (s) = Y (s) = G(s)U (s) = Carrying out partial fraction expansion, we have 9 B D A C + = + 2+ s2 (s + 3)2 s s s + 3 (s + 3)2 Multiplying both sides by s2 (s + 3)2 gives s2 (s
9 s2 .

CHAPTER 5. DYNAMIC RESPONSES

9 (s + 3)2

Hence, the output in s-domain is

9 + 3)2

9 = As(s + 3)2 + B (s + 3)2 + Cs2 (s + 3) + Ds2 Let s = 3. Then, 9 = 9D, that is D = 1. Let s = 0. Then, 9 = 9B , that is, B = 1. Let s = 1 and s = 1, respectively. Then, we get 9 = 16A + 16B + 4C + D 9 = 4A + 4B + 2C + D Replacing B and D by 1 produces 8 = 16A + 4C 2 = 4A + C 4 = 4A + 2C 2 = 2A + C
2 Subtracting the second equation from the rst equation gives 4 = 6A, that is A = 3 . It follows from the second equation 4 2 that C = 2 + 2A = 2 3 = 3 . As a result, we have 2 2 3 1 1 + 2+ 3 + s s s + 3 (s + 3)2

Y (s) =

By taking inverse Laplace transform, the output in t-domain is given by 2 2 y (t) = 1(t) + t + e3t + te3t 3 3

Chapter 6

Steady-State Errors
6.1 Type of System

Consider a closed-loop system with unity feedback described in the gure below.

Note that the open-loop transfer function of the closed-loop system is Go (s), which is the same as the feedforward transfer function. Generally speaking, an nth order system can be put into the form of Go (s) = K (sm + bm1 sm1 + + b1 s + b0 ) + anq1 snq1 + + a1 s + a0 )

sq (snq

The integer q is called the type or class of the system. The closed-loop transfer function is given by Gc (s) = Go (s) 1 + Go (s)

Example Identify the types of the closed-loop systems with unity feedback, which have the following open-loop transfer functions: 5 Type 0 s+2 2(s+1) Type 0 s2 +2s+1 6 Type 1 s(s+3) 2 2 = s2 +4s s(s+4) Type 1
2(s+3) s2 (s2 +2s+1)

Type 2

29

30

CHAPTER 6. STEADY-STATE ERRORS The types of general closed-loop systems, as shown in the gure below, can be identied by the following procedure.

1. Convert the system to one with unity feedback as shown in the gure above. 2. Calculate the open-loop transfer function for the equivalent closed-loop system with unity feedback. 3. Convert the open-loop transfer function into the form as in the denition of the type of a system Example See the gures on the next page.

6.2

Steady-State Errors

The following constants are useful for the calculation of steady-state errors. The proportional error constant kp is dened as kp = lim Go (s)
s0

The velocity error constant kv is dened as kv = lim sGo (s)


s0

The acceleration error constant ka is dened as ka = lim s2 Go (s)


s0

It is not dicult to verify the table below. kp kv ka Type 0 b0 Ka 0 0 0 Type 1 b0 Ka 0 0 Type 2 b0 Ka 0

6.2. STEADY-STATE ERRORS

31

32

CHAPTER 6. STEADY-STATE ERRORS

Steady-state error is dened as ess (t) = lim e(t) = lim sE (s)


t s0

where e(t) = u(t) y (t) and E (s) = U (s) Y (s) with input u(t) or U (s) and output y (t) or Y (s).

6.2.1

Steady-State Errors for Closed-Loop Systems with Unity Feedback

In the closed-loop system with unity feedback as shown in the gure below, the error in s-domain is given by

E (s) = U (s) Y (s) = U (s) Go (s)E (s) which implies that E (s) = 1 U (s) 1 + Go (s)

6.2. STEADY-STATE ERRORS Therefore, the steady-state error is given by s ess = lim e(t) = lim sE (s) = lim U (s) t s0 s0 1 + Go (s) s 1 U (s) = 1 lims0 1+Go (s) s s 1 1 s U ( s ) = = lims0 1+G 2 s2 o (s) s 1 s lims0 U (s) = s1 3 1+Go (s) s3 1 1 U (s) = s lims0 1+Go (s) 1 U (s) = s1 = lims0 s+sG 2 o (s) 1 1 lims0 2 2 U ( s ) = s +s Go (s) s3 1 1 U (s) = s 1+lims0 Go (s) 1 U (s) = s1 = 2 lims0 sGo (s) 1 1 U ( s ) = 2 lims0 s Go (s) s3 1 U (s) = 1 1+kp s 1 U (s) = s1 = 2 k v 1 1 U ( s ) = ka s3 As a result, the following table is veried. Type 0
1 s 1 s2 1 s3 1 1+kp

33

Type 1 0
1 kv

Type 2 0 0
1 ka

6.2.2

Steady-State Errors for General Closed-Loop Systems

The following procedure is given for computing steady-state errors for general closed-loop systems as shown in the gure below.

1. Convert a system to one with unity feedback.

2. Find the open-loop transfer function for the equivalent closed-loop system with unity feedback.

3. Calculate kp , kv , or ka .

4. Calculate steady-state errors.

34 Example See the gure below.

CHAPTER 6. STEADY-STATE ERRORS

Go (s) =

s3

6(s + 3) + 5s2 12
s0

18 3 6(s + 3) = = s3 + 5s2 12 12 2 0 6s(s + 3) = = 0 kv = lim sGo (s) = lim 3 s0 s0 s + 5s2 12 12 0 6s2 (s + 3) ka = lim s2 Go (s) = lim 3 = = 0 s0 s0 s + 5s2 12 12 1 1 = 2 U (s) = 1 1+kp = 1 3 s 2 1 1 ess = = U ( s ) = 2 k s v 1 1 = U ( s ) = ka s3 kp = lim Go (s) = lim
s0

6.2. STEADY-STATE ERRORS It is important to note that steady-state errors can also be calculated directly, as shown below. Gc (s) = = Y (s) s(s+2) = 1 U (s) 1 + s(s6 +2) s+3 6s + 18 6(s + 3) = 3 s(s + 2)(s + 3) + 6 s + 5s2 + 6s + 6 s3 6s + 18 U (s) + 5s2 + 6s + 6
6

35

E (s) = U (s) Y (s) = U (s) Gc (s)U (s) = [1 Gc (s)]U (s) = 1 s3 + 5s2 12 s3 + 5s2 + 6s + 6 6s 18 U (s) = 3 U (s) 3 2 s + 5s + 6s + 6 s + 5s2 + 6s + 6 = lim sE (s) s0 s3 +5s2 12 U (s) = 1 s2 +6s+6) s lims0 s s(s3 +5 3 2 s +5s 12 = lims0 s s2 (s U (s) = s1 3 +5s2 +6s+6) 2 s3 +5s2 12 1 lims0 s s3 (s3 +5s2 +6s+6) U (s) = s3 12 1 U (s) = s 6 = 2 12 = = U (s) = s1 2 0 12 U (s) = s1 3 0 = =

ess

6.2.3

Steady-State Errors for Systems with Disturbances

The direct method is used to calculate steady-state errors for systems with disturbances as shown in the gure below.

To this end, the output in s-domain is computed rst. Y (s) = G2 (s)[Ud (s) + X1 (s)] = G2 (s)[Ud (s) + G1 (s)X2 (s)] = G2 (s){Ud (s) + G1 (s)[Ui (s) X3 (s)]} = G2 (s){Ud (s) + G1 (s)[Ui (s) H (s)Y (s)]} = G2 (s)Ud (s) + G2 (s)G1 (s)Ui (s) G2 (s)G1 (s)H (s)Y (s) from which one gets Y (s) = The error in s-domain is given by E (s) = Ui (s) Y (s) = Ui (s) G2 (s)G1 (s) G2 (s) Ud (s) + Ui (s) 1 + G2 (s)G1 (s)H (s) 1 + G2 (s)G1 (s)H (s) G2 (s) 1 + G2 (s)G1 (s)H (s) G2 (s)G1 (s) Ui (s) Ud (s) = 1 + G2 (s)G1 (s)H (s) 1 + G2 (s)G1 (s)H (s) G2 (s)G1 (s) G2 (s) Ud (s) + Ui (s) 1 + G2 (s)G1 (s)H (s) 1 + G2 (s)G1 (s)H (s)

The steady-state error is ess = lims0 sE (s).

36

CHAPTER 6. STEADY-STATE ERRORS


1 s

Example In the armature controlled dc motor as shown in the gure below, Va (s) = ess |Va =0 , ess . Solution: First let G1 (s) =
50 0.1s+1 ,

and L (s) = 5 s . Find ess |L =0 ,

G2 (s) =

1 s+1 ,

and H (s) = 0.2. Then we have

1 50 0.2 s + 1 0.1s + 1 (0.1s + 1)(s + 1) + 10 0.1s2 + 1.1s + 11 = = (0.1s + 1)(s + 1) (0.1s + 1)(s + 1) 2 1 0.1s + 1.1s + 11 50 1 + G2 (s)G1 (s)H (s) G2 (s)G1 (s) = (0.1s + 1)(s + 1) s + 1 0.1s + 1 0.1s2 + 1.1s 39 = (0.1s + 1)(s + 1) 1 + G2 (s)G1 (s)H (s) = 1 + 1 + G2 (s)G1 (s)H (s) G2 (s)G1 (s) = 1 + G2 (s)G1 (s)H (s) = G2 (s) = 1 + G2 (s)G1 (s)H (s) = E (s) = = E (s) |L =0 = = ess |L =0 = E (s) |Va =0 = = ess |Va =0 = E (s) = =
0.1s2 +1.1s39 (0.1s+1)(s+1) 0.1s2 +1.1s+11 (0.1s+1)(s+1) 2

0.1s + 1.1s 39 0.1s2 + 1.1s + 11


1 s+1 0.1s2 +1.1s+11 (0.1s+1)(s+1)

0.1s + 1 0.1s2 + 1.1s + 11 1 + G2 (s)G1 (s)H (s) G2 (s)G1 (s) G2 (s) Va (s) [L (s)] 1 + G2 (s)G1 (s)H (s) 1 + G2 (s)G1 (s)H (s) 1 + G2 (s)G1 (s)H (s) G2 (s)G1 (s) G2 (s) Va (s) + L (s) 1 + G2 (s)G1 (s)H (s) 1 + G2 (s)G1 (s)H (s) 1 + G2 (s)G1 (s)H (s) G2 (s)G1 (s) Va (s) 1 + G2 (s)G1 (s)H (s) 0.1s2 + 1.1s 39 s(0.1s2 + 1.1s + 11) 39 0.1s2 + 1.1s 39 = lim sE (s) |L =0 = lim s0 s0 0.1s2 + 1.1s + 11 11 G2 (s) L (s) 1 + G2 (s)G1 (s)H (s) 5(0.1s + 1) s(0.1s2 + 1.1s + 11) 5 5(0.1s + 1) = lim sE (s) |Va =0 = lim s0 s0 0.1s2 + 1.1s + 11 11 1 + G2 (s)G1 (s)H (s) G2 (s)G1 (s) G2 (s) Va (s) + L (s) 1 + G2 (s)G1 (s)H (s) 1 + G2 (s)G1 (s)H (s) E (s) |L =0 +E (s) |Va =0

6.2. STEADY-STATE ERRORS Therefore, we have ess = lim sE (s) = lim sE (s) |L =0 + lim sE (s) |Va =0 = ess |L =0 +ess |Va =0 =
s0 s0 s0

37

5 34 39 + = 11 11 11

38

CHAPTER 6. STEADY-STATE ERRORS

Chapter 7

The Routh Stability Criterion


7.1 Poles and Zeros
K (sm + bm1 sm1 + + b1 s + b0 ) sn + bn1 sn1 + + a1 s + a0

In general, the transfer function G(s) of a system can be represented by G(s) = where K is the gain of the system. Now assume that z1 , z2 , , zm are roots of the numerator, and p1 , p2 , , pn are roots of the denominator. Then, z1 , z2 , , zm are called zeros of the system, and p1 , p2 , , pn are referred to as poles of the system. In addition, the transfer function G(s) can be written as K (s z1 )(s z2 ) (s zm ) G(s) = (s p1 )(s p2 ) (s pn ) We have the following observations: 1. The zeros are the values of s for which the transfer function becomes zero and the poles are the values of s for which the transfer function is innite. 2. The transfer function can be specied by the values of zeros, poles, and gain. The poles and zeros of a transfer function are complex numbers, so can be represented by points on the complex plane, which results in a pole-zero plot. In a pole-zero plot, a pole is marked with a cross and a zero is marked with a circle .

7.2

Stability

A system is called to be stable if the output dies away as t ; unstable if the output tends to innity as t ; critically stable if the output does not die away or increase to innity but tends to some nite but non-zero values when subject to an impulse input. Example Check the stability of the systems described by G1 (s) = 1 s+2 1 , s+2 G2 (s) = 1 s2 1 s2

Solution: Let input be a unit impulse function, that is, U (s) = 1. Then the output in s-domain is Y1 (s) = G1 (s)U (s) = Taking the inverse Laplace transform gives y1 (t) = e2t 0, y2 (t) = e2t , 39 t t Y2 (s) = G2 (s)U (s) =

40 So, G1 (s) is stable and G2 (s) unstable. Stability Test:

CHAPTER 7. THE ROUTH STABILITY CRITERION

1. A system is stable if all the poles are in the open left-hand side of the s-plane, that is, all the poles have negative real parts. 2. A system is unstable if one or more poles are in the open right-hand side of the s-plane, that is, one or more poles have positive real parts. 3. A system is critically stable if one or more poles are on the imaginary axis and the rest are in the open left-hand side of the s-plane, that is one or more poles have zero parts and the rest have negative real parts. Example 1 Consider the following systems (a) s2 s1 4s + 4 (b) 2(s + 1) (s + 1)(s + 2)(s 3) (c) (s + 3)(s 1) s(s + 2)(s + 3)(s + 4) (d) s2 s+4 +s+3 (e) s2 1 +s+1

Find poles and zeros for the systems, plot them in s-plane, and check the stability. Solution (a)
s1 s2 4s+4

s1 (s2)2 .

p1 = 2, p2 = 2, z1 = 1. It is unstable.

(b) p1 = 1, p2 = 2, p3 = 3, z1 = 1. It is unstable. (c) p1 = 0, p2 = 2, p3 = 3, p4 = 4, z1 = 3, z2 = 1. It is stable. +4 1 1 1 1 s+4 (d) s2s +s+3 = [s( 1 +j 1 11)][s( 1 j 1 11)] . p1 = 2 + j 2 11, p2 = 2 j 2 11, z1 = 4. It is stable. 2 2 2 2 1 1 1 1 1 (e) s2 +1 = = + j 3, p = j 3. It is stable. . p 1 2 1 1 1 1 s+1 2 2 2 2 [s( 2 +j 2 3)][s( 2 j 2 3)] Example 2 Find transfer functions and check stabilities for the systems (a) poles: -1, -2; zeros: no; gain: 2; (b) poles: 1, -2; zeros: 0; gain: 10; (c) poles: -2+j1, -2-j1; zeros: 1; gain: -5; (d) poles: 1+j2, 1-j2; zeros: -1; gain: 7. Solution: (a) (b) (c) (d)
2 (s+1)(s+2) 10s (s1)(s+2)

is stable. is unstable. = =
5(s1) (s+2)2 +1 7(s+1) (s1)2 +4

5(s1) [s(2+j )][s(2j )] 7(s+1) [s(1+j 2)][s(1j 2)]

= =

5(s1) s2 +4s+5 7(s+1) s2 2s+5

is stable. is unstable.

7.3

The Routh Stability Criterion

We have discussed that the stability of a system can be determined by checking the positions of poles in the s-plane, which means that we need to nd roots of the denominator of a transfer function. In general, it is not a easy thing to nd roots of the polynomial an sn + an1 sn1 + an2 sn2 + + a1 s + a0 with n > 3. The Routh criterion can be used to determine the stability of a high order system without nding roots of its denominator. The procedure is given below. 1. Write the characteristic equation in the form of an sn + an1 sn1 + an2 sn2 + + a1 s + a0 with an > 0

7.3. THE ROUTH STABILITY CRITERION

41

2. If any of the coecients are zero or negative, then there is a root or roots that are imaginary or have positive real parts, that is, the system is either critically stable or unstable. 3. If all coecients are positive, arrange the coecients of the polynomial according to following pattern. sn sn1 sn2 sn3 . . . s2 s1 s0 where b1 = an2 b2 = an4 c1 = an3 c2 = an5 an an1 an an1 an1 b1 an1 b1 an3 an5 b2 b3 an an1 b1 c1 . . . x1 y1 z1 an2 an3 b2 c2 . . . x2 y2 an4 an5 b3 c3 . . . x3

Routh stability criterion states that the number of roots of the characteristic equation with positive real parts is equal to the number of changes in sign of the coecients of the rst column of the Routh array. If all elements in the rst column are positive, then the system is stable. If there are negative elements in the rst column, then the system is unstable. Example 1 Check the stability of G(s) = Solution: 1. All coecients of the characteristic equation are positive. 2. Routh array is given below. s4 s3 s2 s1 s0 1 2 1 =3 2 =4 1 =1
1 2 2 1 1 2 2s+1 s4 +2s3 +3s2 +4s+1 .

3 4 4 1 =1 1 0

1
1 2

All the elements in the rst column are positive, so the system is stable. Example 2 Check the stability of G(s) = Solution: 1. All coecients of the characteristic equation are positive. 2. Routh array is given below. s4 1 s3 1 s2 3 = 1 s1 13 3
0 1 1 4 1 3 1 2s+1 s4 +s3 +s2 +4s+1 .

1 4 1 =1

1
1 1

=4

s 1 =1

3
13 3

The rst column has a negative element, so the system is unstable.

42 Example 3 The system G(s) =


2s+1 s5 4s4 +3s3 +2s2 +5s+2

CHAPTER 7. THE ROUTH STABILITY CRITERION is unstable because there is a negative coecient in the denominator.
10 s+1

Example 4 Find k so that the system with G1 (s) =

and G1 (s) =

1 s(s+4) ,

as shown in the gure below is stable.

Solution: 1. The closed-loop transfer function is computed below. G(s) = = G(s) s+1 s(s+4) = 1 1 + G(s)H (s) 1 + s10 +1 s(s+4) k
10 1

10 10 = (s + 1)s(s + 4) + 10k s(s2 + 5s + 4) + 10k 10 = 3 2 s + 5s + 4s + 10k 2. It follows from Routh-Hurwitz criterion that 10k > 0, that is k > 0. 3. Routh array is given below. s3 1 s2 5 s1 4 2k = 4 s 10k = 10k
0

4 10k
1 5

10k 0

5 42k

It follows from Routh-Hurwitz criterion that 4 2k > 0, that is, k < 2 and 10k > 0, that is k > 0. So 0 < k < 2

Chapter 8

Root Locus Analysis


8.1 Denition

Consider a closed-loop system described by the following block diagram.

The open-loop transfer function for the system is Go (s) =

k s+1 k

with pole s = 1. The closed-loop transfer function is

G(s) =

Go (s) k = s+1k = 1 + Go (s) s + 1 +k 1 + s+1

with pole (1 + k ). It is evident that the closed-loop pole changes as k changes. For instance, the closed-loop pole is -1, which is the same as the open-loop pole, when k = 0, -2 for k = 1, -3 for k = 2, and so on. A curve of the closed-loop pole versus k for k > 0 can be plotted in s-plane. Such a curve is called the root locus, which is shown below.

Now consider a second-order system with the open-loop transfer function Go (s) = and 2 3. Its closed-loop transfer function is computed below.
k

k s2 +4s+1

with open-loop poles 2 + 3

G(s) =

Go (s) k 2 = s +4s+1 = 2 k 1 + Go (s) s + 4 s +1+k 1 + s2 +4s+1 43

44

CHAPTER 8. ROOT LOCUS ANALYSIS

The closed-loop poles, that is, roots of the characteristic equation s2 + 4s + 1 + k = 0, are p= 4 16 4(1 + k ) = 2 2 4 (1 + k ) = 2 3k

3 and 2 3, which are the open-loop poles. The system is overdamped. As 0 < k < 3, the closed-loop poles are 2 + 3 k and 2 3 k. The system is overdamped. As k = 0, the closed-loop poles are 2 + As k = 3, the closed-loop poles are 2 and 2. The system is critically damped. As k > 3, the closed-loop poles are 2 + j k 3 and 2 j k 3. The system is underdamped. The root locus plot for this system looks like the graph shown above. From these two example, we can make the following observations. 1. The root locus is a locus of the closed-loop poles in s-plane as the gain increases from 0. 2. The root locus starts at the open-loop poles.

8.2

Construction

Now consider a closed-loop system with unity feedback. Assume that the open-loop transfer function is given by Go (s) = k (s z1 )(s z2 ) (s zm ) (s p1 )(s p2 ) (s pn )

with open-loop gain k , open-loop zeros z1 , z2 , , zm , and open-loop poles p1 , p2 , , pn . Its closed-loop transfer function is given by Go (s) G(s) = 1 + Go (s) The closed-loop characteristic equation is 1 + Go (s) = 1 + that is, k (s z1 )(s z2 ) (s zm ) = 1 = 1(odd multiple of ) (s p1 )(s p2 ) (s pn ) which implies that the phase condition [(s z1 ) + (s z2 ) + + (s zm )] [(s p1 ) + (s p2 ) + + (s pn )] = odd multiple of and magnitude condition | (s z1 ) || (s z2 ) | | (s zm ) | =1 | (s p1 ) || (s p2 ) | | (s pn ) | must be satised. Construction of Root Loci 1. The number of root loci is equal to the degree n of the open-loop characteristic equation or the order of the closed-loop transfer function. 2. The root loci start at the open-loop poles and end at the open-loop zeros. If there are more poles than zeros, then m loci end at the open-loop zeros and the remaining (n-m) loci end at innity. 3. The root loci are symmetrical with respect to the real axis. 4. Portions of the real axis are sections of root loci if the number of poles and zeros lying on the axis to the right of the portion is odd. k (s z1 )(s z2 ) (s zm ) =0 (s p1 )(s p2 ) (s pn )

8.2. CONSTRUCTION 5. Those loci terminating at innity tend towards asymptotes at angles to the positive real axis of 3 5 [2(n m) 1] , , , , nm nm nm nm

45

6. The asymptotes intersect the real axis at a point, called the center of gravity or centroid of the asymptotes, given by (p1 + p2 + + pn ) (z1 + z2 + + zn ) nm 7. The intersection of root loci with the imaginary axis can be found by calculating those values of k which result in the existence of imaginary roots, that is, solutions to the closed-loop characteristic equation with s = j . 8. The term breakaway point is used for the case that two or more loci meet at a point and then subsequently break away from that point along separate paths. The breakaway point can be found by solving the closed-loop characteristic equation for k and solving dk =0 ds for s. 9. The angle of departure of a locus at k = 0 from a complex pole and the angle of arrival of a locus at k = at a complex zero can be determined by using the phase condition. Example 1 Draw root loci for the unity feedback system with open-loop transfer function Go (s) = Solution: 1. Find the closed-loop characteristic equation: G(s) = Go (s) k (s + 1) (s+2+j 3)(s+2j 3) = = (s+1) 1 + Go (s) (s + 2 + j 3)(s + 2 j 3) + k (s + 1) 1 + (s+2+k j 3)(s+2j 3)
k(s+1)

k (s + 1) (s + 2 + j 3)(s + 2 j 3)

which means the closed-loop characteristic equation is (s + 2 + j 3)(s + 2 j 3) + k (s + 1) = 0 2. Since Go (s) is of second order, there are two loci. 3. Open-loop poles are 2 + j 3 and 2 j 3 and zeros are -1. 4. The portion of the root loci on the real axis is from -1 to because to its right there is only one zero. 5. The angle of the asymptote is
nm

21

= = 180 , which implies that the asymptote is the real axis.

6. Since the asymptote is the real axis, the intersection with the real axis has no signicance. 7. The intersection of loci with the imaginary axis can be determined by solving the characteristic equation with s = j for k and , that is (j + 2 + j 3)(j + 2 j 3) + k (j + 1) = 0 (j + 2)2 (j 3)2 + jk + k = 0 (j )2 + 4j + 4 + 9 + jk + k = 2 + j (4 + k ) + 13 + k = 0 which means that (4 + k ) = 0 2 + 13 + k = 0

46

CHAPTER 8. ROOT LOCUS ANALYSIS Solving these equations for k and gives k = 4 and = 13 + k = 13 4 = 3. In this course, the root loci are restricted to the case with positive k . So a negative k means there are no intersections between the root loci and the imaginary axis, that is, the root loci does not cross the imaginary axis.

8. The arrival point is determined by solving (s + 2 + j 3)(s + 2 j 3) + k (s + 1) = 0 for k , which is k= and letting
dk ds

(s + 2 + j 3)(s + 2 j 3) s2 + 4s + 13 = s+1 s+1 dk (2s + 4)(s + 1) (s2 + 4s + 13) = ds (s + 1)2

= 0, that is, 0=

This is equivalent to (2s + 4)(s + 1) (s2 + 4s + 13) = 2s2 + 6s + 4 s2 4s 13 = s2 + 2s 9 = 0 Solutions to this equation are s= Only s = 4.1623 is on the root loci. 9. There is one pair of complex poles and no complex zeros. The angle of departure of the locus at k = 0 from the complex pole s = 2 + j 3 is determined by using the phase condition (s z1 ) [(s p1 ) + (s p2 )] = odd multiple of 180 2 2 4 + 36 = 1 10 = 4.1623, 2.1623

8.2. CONSTRUCTION with s being a point on the root locus very close to s = 2 + j 3. (s z1 ) = 180 tan1 (s p2 ) = 90 Thus, 108.4 90 (s p1 ) = 180 3 1 = 108.4

47

Solving this equation gives (s p1 ) = 180 108.4 + 90 = 198.4, 161.6. These two angles are actually the same because 198.4 + 161.6 = 360. Example 2 Given a closed-loop system with unity feedback, which has an open-loop transfer function with poles -1, -2, -3, no zero and gain k . Draw root loci for this system and nd the ranges of k for the closed-loop system to be stable, critically stable and unstable. Solution: 1. Find the open-loop transfer function Go (s) = 2. Find the closed-loop characteristic equation: G(s) = Go (s) k (s+1)(s+2)(s+3) = = k 1 + Go (s) ( s + 1)( s + 2)( s + 3) + k 1 + (s+1)(s+2)(s+3)
k

k (s + 1)(s + 2)(s + 3)

which means the closed-loop characteristic equation is (s + 1)(s + 2)(s + 3) + k = 0 3. Since Go (s) is of third order, there are three loci. 4. Open-loop poles are 1, 2, 3 and zeros are none. 5. The portion of the root loci on the real axis is from -1 to 2 because to its right there is one pole and from 3 to because to its right there is three poles. 6. The angles of the asymptotes are
nm

30

and

3 nm

30

= .

7. The intersection with the real axis is

p1 + p2 + p3 1 2 3 = = 2 nm 30

8. The intersection of loci with the imaginary axis can be determined by solving the characteristic equation with s = j for k and , that is (j + 1)(j + 2)(j + 3) + k = 0 ( 2 + j 3 + 2)(j + 3) + k = 0 j 3 3 2 + j 2 3 2 + j 9 + 6 + k = 0 6 + k 6 2 + j (11 3 ) = 0 which means that 6 + k 6 2 = 0 11 3 = 0 Solving these equations for k and gives = 11 and k = 6 2 6 = 66 6 = 60.

48 9. The breakaway point is determined by solving (s + 1)(s + 2)(s + 3) + k = 0 for k , which is k = (s + 1)(s + 2)(s + 3) and letting 0=
dk ds

CHAPTER 8. ROOT LOCUS ANALYSIS

= 0, that is,

dk = [(s + 2)(s + 3) + (s + 1)(s + 3) + (s + 1)(s + 2)] = [s2 + 5s + 6 + s2 + 4s + 3 + s2 + 3s + 2] = [3s2 + 12s + 11] ds 3s2 + 12s + 11 = 0

This is equivalent to Solutions to this equation are s= Only s = 1.42 is on the root loci. 12

144 132 = 1.42, 2.58 6

10. There is no complex poles and zeros, so there is no need to determine the departure or arrival angles. 11. When k = 60, the system is critically stable because the closed-loop poles are on the imaginary axis. When 0 < k < 60, the system is stable because all closed-loop poles are in the open left-hand side of s-plane. When k > 60, the system is unstable because two closed-loop poles are in the open right-hand side of s-plane.

Chapter 9

PID Controllers
Proportional Controller: In t-domain, y (t) = KP e(t); in s-domain Y (s) = Kp E (s) I Integral Controller: In t-domain, y (t) = KI e(t)dt; in s-domain Y (s) = K s E (s) ( t) Derivative Controller: In t-domain, y (t) = KD de dt ; in s-domain Y (s) = KD sE (s) ( t) PID Controller: In t-domain, y (t) = KP e(t) + KI e(t)dt + KD de dt ; KI I . In s-domain Y (s) = Kp E (s) + K s E (s) + KD sE (s) = (Kp + s + KD s)E (s). The block diagrams for these controllers are shown below.

49

50 These controllers can be implemented by using op-amps, as shown below.

CHAPTER 9. PID CONTROLLERS

Example Consider a system with a transfer function of Gp (s) = 1. Check the stability of the system.

1 s(s+1) .

Answer the following questions.

2. Calculate the steady-state error with a unit step input and unit ramp input. 3. Design a proportional controller to stabilize the system and achieve the steady-state error with a ramp input of 10% and nd 5% settling time. 4. Can you nd an integral controller to stabilize the system? 5. Design a PI controller to stabilize the system and to reduce the steady-state error with a ramp input to 0. 6. Design a PID controller with KI = 0.5KP and KD = 0.5KP so that the overshoot is less than 25%. Solution: 1. The system is critically stable. 2. The error in s-domain is E (s) = U (s) Y (s) = U (s) The steady-state error is ess = lim sE (s) =
s0 s1 1 lims0 s ss(+ s+1) s = s1 1 lims0 s ss(+ s+1) s2 =
2 2

1 1 U (s) = 1 s(s + 1) s(s + 1)

U (s) =

s2 + s 1 U (s) s(s + 1)

U (s) = U (s) =

1 s 1 s2

51 3. The closed-loop system with a proportional controller is shown below.

It is clearly seen that the open-loop transfer function is Go (s) = KP Gp (s) = 1 E (s) = 1+G U (s). So with U (s) = s1 2 and ess = 0.1, we have o (s) 0.1 lim sE (s) = lim
s0

KP s(s+1)

and the error in s-domain is

s0

1 1 s 1 1 = = = lim s0 s + sGo (s) 1 + Go (s) s2 lims0 sGo (s) lims0

KP s+1

1 KP

which implies that KP 10. So, choose KP = 10. The closed-loop transfer function is Gc (s) = Go (s) KP s(s+1) = = 2 P 1 + Go (s) s + s + KP 1 + s(K s+1)
KP

Comparing this with the standard form for a second-order system gives 2 = KP n = KP = 10 n 1 1 2n = 1 = 2 = 2 n 10 The 5% settling time is ts = 3 3 = 0.15s = n 2 10 10

4. The closed-loop system with an integral controller is shown below.

The closed-loop transfer function is Gc (s) = Routh array is given as follows: s3 1 s2 1 s1 KI = 0 1 1 KI s0 KI = KI


1 KI 0 KI 1 s s(s+1) 1 I +K s s(s+1)

KI KI = 3 s2 (s + 1) + KI s + s2 + KI

0 KI

The system is stable only if KI > 0 and KI > 0. It is impossible. So, there is no solution to the problem. 5. The closed-loop system with a PI controller is shown below.

52 The open-loop transfer function is Go (s) = The error in s-domain is E (s) = The steady-state error is ess = lim sE (s)
s0

CHAPTER 9. PID CONTROLLERS

KP +

KI s

1 KP s + KI = 2 s(s + 1) s (s + 1)

1 U (s) 1 + Go (s)

1 1 = lims0 s 1+G o (s) s 1 1 lims0 s 1+Go (s) s2 = 1 1+lims0 Go (s) = 0 1 lims0 sGo (s) = 0

U (s) = U (s) =
1 s 1 s2

1 s 1 s2

U (s) = U (s) =

So the PI controller with any KP and KI can reduce errors to zero for both step and ramp input. The closed-loop transfer function is Gc (s) = Routh array is given as follows: s3 s2 s1 s0 1 KP 1 KI KP 1 K = K K I P I 1 K I KP 1 K I 0 = K I
KP

Go (s) KP s + KI s2 (s+1) = = 3 P s+KI 1 + Go (s) s + s2 + KP s + KI 1+ K s2 (s+1)

KP s+KI

The system is stable only if KP >, KP KI > 0 and KI > 0, that is KP > KI and KI > 0. 6. The closed-loop system with a PID controller is shown below.

The closed-loop transfer function is Gc (s) = = = = KP + 1+ s2 (s s2 (s


0.5KP + 0.5KP s s(s1 s +1) KP KP + 0.5s + 0.5KP s s(s1 +1) 2 0.5KP s + KP s + 0.5KP + 1) + 0.5KP s2 + KP s + 0.5KP 0.5KP (s + 1)2 + 1) + 0.5KP (s + 1)2

0.5KP (s + 1) s2 + 0.5KP s + 0.5KP

Comparing this with the standard form for a second-order system gives
2 = 0.5KP n 2 2n = 0.5KP = n

n = 0.5KP 2 = n

53 It follows from the requirement on overshoot that e



1 2

0.25 ln 0.25 ln 0.25 = ln 1 = ln 4 0.25

1 2 1 2

ln 4 1 2 2 2 (ln 4)2 (1 2 ) = (ln 4)2 (ln 4)2 2 2 + (ln 4)


2

2 (ln 4) 2

2 2

(ln 4)

2 + (ln 4)2 ln 4 2 + (ln 4)


2

= 0.4037

2 Choose = 0.5. Then n = 2 = 1, so 0.5KP = n = 1, that is, KP = 2.

54

CHAPTER 9. PID CONTROLLERS

Chapter 10

Frequency Response
10.1 Steady-State Response

Frequency response is the output of a system when subject to a sinusoidal input. The steady-state response of a system to a sinusoidal input u(t) = U sin(t) is also a sinusoidal function yss (t) = Y sin(t + ) with Y = U | G(j ) | and = [G(j )]. Here G(j ) is called frequency response function. This will be illustrated by the following example. Example 1 Find the output of a system G(s) =
1 s+2

with a sinusoidal input u(t) = a sin(t).


a s2 + 2

Solution: The Laplace transform of the input is U (s) = Y (s) = G(s)U (s) = Performing the partial fraction expansion gives Y (s) = As a result, we have

and the output in s-domain is

1 a a = 2 2 s+2s + (s + 2)(s2 + 2 )

A Bs + C A(s2 + 2 ) + (Bs + C )(s + 2) + 2 = s + 2 s + 2 (s + 2)(s2 + 2 ) a = A(s2 + 2 ) + (Bs + C )(s + 2)

Let s = 2. Then, a = A(4 + 2 ), that is, A =

a 4+ 2 .

Let s = 0. Then, a = A 2 + 2C , that is,


3

C=

a a 4+ a A 2 4a 2a 2 = = = 2 2 2(4 + 2 ) 4 + 2

Let s = 2. Then, a = A(4 + 2 ) + 4(2B + C ), that is, 0 = 4(2B + C ). As a result, we have B= Therefore, the output is Y (s) =
a 4+ 2

C a = 2 4 + 2

s+2

a 4+ 2 s +

s2 +

2a 4+ 2 2

a a 2a 1 s + 4 + 2 s + 2 4 + 2 s2 + 2 4 + 2 s2 + 2

Taking the inverse Laplace transform gives y (t) = a 2t a 2a e cos(t) + sin(t) 4 + 2 4 + 2 4 + 2 55

56 Now let cos = expressed as


2 . 4+ 2 Then, sin = 4+ and tan = 2 sin cos

CHAPTER 10. FREQUENCY RESPONSE


1 = 2 , that is, = tan 2 . The output can be

y (t) =

a a 2t a a 2t e + [sin cos(t) + cos sin(t)] = e + sin(t + ) 4 + 2 4 + 2 4 + 2 4 + 2

When t goes to innity, the rst term will die away. Therefore, the steady-state response is given by yss (t) = Now let us look at G(j ) =
1 j +2 .

a sin(t + ) 4 + 2

Its magnitude and angle are given by | G(j ) | = 1 4 + 2 2 = tan1 2

[G(j )] = tan1 So, the steady-state output can be written as

yss (t) = a | G(j ) | sin(t + [G(j )]) As a matter of fact, the steady-state response of any linear system G(s) to a sinusoidal input u(t) = a sin(t) is given by yss (t) = a | G(j ) | sin(t + [G(j )]) Example What will be the steady-state response of a second order system d2 y (t) dy (t) + 10y (t) = 5u(t) +3 dt2 dt when subject to the input u(t) = 2 sin(2t + 70 ). Solution: By taking Laplace transform on both sides of the dierential equation, we get s2 Y (s) + 3sY (s) + 10Y (s) = 5U (s) Thus, the transfer function is G(s) = The frequency response function is G(j ) = 2 5 5 = + j 3 + 10 10 2 + j 3 5 s2 + 3s + 10

Its magnitude and phase angle at = 2 are given as follows: 5 5 = 6 2 [(10 22 )2 + 9 22 ] 6 = tan1 (1) = 45 [G(j )] = tan1 10 4 | G(j ) | = Therefore, the solution to the problem is 5 yss (t) = sin(2t + 25 ) 3 2

10.2

Bode Plots

Bode plot consists of two graphs, one of magnitude plotted against the frequency and one of the phase angle plotted against the frequency. The magnitude and phase angle are plotted using logarithmic scales.

10.2. BODE PLOTS It is common practice to express the magnitude in units of decibel (dB). Magnitude in dB = 20 lg | G(j ) | Note that if G(j ) = G1 (j )G2 (j ) Gn (j ), then | G(j ) |=| G1 (j ) |) | G2 (j ) | | Gn (j ) | Taking logarithm to base 10 gives 20 lg | G(j ) |= 20 lg | G1 (j ) | +20 lg | G2 (j ) | + + 20 lg | Gn (j ) | In addition, the phase angle satises [G(j )] = [G1 (j )] + [G2 (j )] + + [Gn (j )]

57

Bode Plot for Constant Gain: G(s) = K , G(j ) = K , | G(j ) |= K , 20 lg | G(j ) |= 20 lg K , and [G(j )] = 0. The Bode plot is given below.

Bode Plot for

1 s:

G(s) = 1 s , G(j ) =

1 j ,

| G(j ) |=

1 ,

20 lg | G(j ) |= 20 lg , and [G(j )] = 90.

= 0.1rad/s = 1rad/s = 10rad/s The Bode plot is given below.

20 lg | G(j ) |= 20 lg 0.1 = 20dB 20 lg | G(j ) |= 20 lg 1 = 0dB 20 lg | G(j ) |= 20 lg 10 = 20dB

58

CHAPTER 10. FREQUENCY RESPONSE Bode Plot for s: G(s) = s, G(j ) = j , | G(j ) |= , 20 lg | G(j ) |= 20 lg , and [G(j )] = 90 . = 0.1rad/s = 1rad/s = 10rad/s 20 lg | G(j ) |= 20 lg 0.1 = 20dB 20 lg | G(j ) |= 20 lg 1 = 0dB 20 lg | G(j ) |= 20 lg 10 = 20dB

The Bode plot is given below.

Bode Plot for s1 +1 : G(s) = 1 [G(j )] = tan .

1 s+1 ,

G(j ) =

1 1+j ,

| G(j ) |=

1 , 1+ 2 2

20 lg | G(j ) |= 20 lg 1 + 2 2 , and

1 = 0.1 rad/s

rad/s

1 = 10 rad/s

20 lg | G(j ) |= 20 lg 1 + 0.01 20 lg 1 = 0dB [G(j )] = tan1 0.1 0 20 lg | G(j ) |= 20 lg 1 + 1 = 20 lg 2 = 3dB 0dB [G(j )] = tan1 1 = 45 20 lg | G(j ) |= 20 lg 1 + 10 20 lg 10 = 20dB [G(j )] = tan1 10 90

The point =

is called break-point. The Bode plot is given below.

Bode Plot for s + 1: G(s) = s + 1, G(j ) = 1 + j , | G(j ) |=

1 + 2 2 , 20 lg | G(j ) |= 20 lg 1 + 2 2 , and

10.2. BODE PLOTS [G(j )] = tan1 .


1 = 0.1 rad/s

59

rad/s

1 = 10 rad/s

20 lg | G(j ) |= 20 lg 1 + 0.01 20 lg 1 = 0dB [G(j )] = tan1 0.1 0 20 lg | G(j ) |= 20 lg 1 + 1 = 20 lg 2 = 3dB 0dB [G(j )] = tan1 1 = 45 20 lg | G(j ) |= 20 lg 1 + 10 20 lg 10 = 20dB [G(j )] = tan1 10 90

The point =

is called break-point. The Bode plot is given below.

Example Draw asymptotes of the Bode diagram for a system G(s) =

10 2s+1 .

Solution: G(s) = 10 2s1 +1 = G1 (s)G2 (s). The Bode plot is shown below.

60

CHAPTER 10. FREQUENCY RESPONSE

Chapter 11

Control of Discrete Processes and PLC


11.1 Introduction

As a simple illustration of what is meant by discrete process control, consider a dc motor starting process. Because of a large starting current, we need to insert some resistors into the armature circuit of a dc motor. In order to keep the starting current under a certain level, we need to design a circuit to implement the following operations:

1. When the start button is pushed, the motors armature circuit is connected to its power supply and the machine starts with all resistors R1 , R2 , and R3 . 2. R1 is cut out from the armature circuit 10s later. 3. R2 is cut out 10s after R1 is cut out. 61

62 4. R3 is cut out 10s after R2 is cut out.

CHAPTER 11. CONTROL OF DISCRETE PROCESSES AND PLC

5. The motor will stop whenever the stop button is pushed. This starting process can be implemented by a circuit composed of switches and relays. The normally open button BO will be closed when pushed, whereas the normally closed button BC will be open when pushed. A relay contains a coil and some contacts, either normally open contacts or normally closed contacts, or both. Normally open contacts will be closed when the coil is energized and open when de-energized, whereas normally closed contacts will be open when energized and closed when de-energized. Time-delay relays are a kind of relays. Normally open contacts will be closed after a certain delay when the coil is energized and open immediately when de-energized, whereas normally closed contacts will be open after a certain delay when energized and closed immediately when de-energized. The starting process can also be implemented by using a Programmable Logic Controller (PLC). A PLC is a microprocessor-based controller that uses a programmable memory to store instructions and implement functions such as logic, sequencing, timing, counting, and arithmetic.

11.2. PLC PROGRAMMING

63

11.2

PLC Programming

A PLC can be programmed by using a simple form of language, ladder diagram. Writing a program is equivalent to drawing a switching circuit. A ladder diagram looks like a ladder. It consists of two vertical lines, representing the power rails, and several horizontal lines, which are rungs of the ladder. In drawing a ladder diagram, the following conventions are adopted: 1. Vertical lines represent power rails between which circuits are connected. 2. Each rung (horizontal line) on the ladder denes one operation in the control process. 3. Each rung must start with an input or inputs and must end with at least one output. 4. A ladder diagram is read from top to bottom. The rung is read from left to right. When a PLC is in its run mode, it goes through the entire ladder program to the end, and then promptly resumes at the start. This procedure of going through all the rungs of the program is termed a cycle.

11.3

Internal Relays

In PLCs there are elements that are used to hold data and behave like relays, being able to be switched on or o or switch other devices on or o. These elements are termed as internal relays. Such internal relays do not exist as real-world switching devices, but are merely bits in the storage memory that behave the same way as an external relay. Consider the dc motor starting circuit, a latch circuit is needed to start and stop the motor. Such a latch circuit can be implemented by an internal relay, as shown below.

64

CHAPTER 11. CONTROL OF DISCRETE PROCESSES AND PLC

11.4

Timers

PLCs have timers as built-in devices. Timers count fractions of a second or seconds using the internal cpu clock. Timers behave like time-delay relays. When they are energized, their contacts change state after a preset time and resume their normal state when de-energized. Consider the dc motor starting circuit. 3 timers are needed to control the dc motor starting process, as shown below.

11.5

Counters

Counters are also built-in devices in PLCs, which count occurrences of input signals. A counter is set to some preset number value and when this value of input pulses has been received, it will operate its contacts. Thus normally open contacts would be closed and normally closed contacts open. There are two types of counters, down-counters and up-counters. The counter will be reset when there is a pulse to its reset input (RST). The counter count pulses to its input (CTD for down-counters or CDU for up-counters). Thepreset value is indicated by CV . Down-counters count down from the preset value to zero, that is, events are subtracted from the preset value. When the counters reach the zero value, their contacts change state. Up-counters count from zero up to the preset

11.5. COUNTERS

65

value, that is, events are added until the number reaches the preset value. When the counters reach the preset value, their contacts change state. As an example, let us analyze the ladder diagram shown below.

1. The counter is reset and ready for counting when there is a pulse to RST. 2. Start counting pulses to CTD. 3. When the counter reaches its preset value, stop counting and its normally open contact changes state becomes closed. The timing diagram for this ladder diagram is given below.

Potrebbero piacerti anche