EE371 Lecture Notes
EE371 Lecture Notes
Control systems are an integral component of any industrial society and are necessary to provide
useful economic products for society.
Control engineering is based on the foundation of feedback theory and linear system analysis, and
integrates the concepts of network theory and communication theory. Therefore, control
engineering is not limited to any engineering discipline but is equally applicable for aeronautical,
chemical, mechanical, environmental, civil, and electrical engineering. For example, quite often a
control system includes electrical, mechanical, and chemical components. Furthermore, as the
understanding of the dynamics of business, social and economical systems increases, the ability to
control these systems will increase also.
The methods used to accomplish the control objectives can be classified, very generally, as
open-loop controls and closed-loop or feedback controls.
1. 1
Figure 1.1 Hero’s device for opening temple doors
Toaster
Assume that a toaster is set for the desired darkness of the toasted bread. The setting of the
darkness, or timer knob, represents the input quantity, and the degree of darkness of the toast
produced is the output quantity. If the degree of darkness is not satisfactory, because of the
condition of bread or some other reason, this condition in no way automatically alter the length of
time that heat is applied. The heater portion of the toaster, excluding the timer unit, represents the
dynamic part of the overall system.
1. 2
Figure 1.2 Automatic toaster
Automatic washers and dryers
These devices change operating modes and eventually shut themselves off according to a
preprogrammed schedule, which is usually based on elapsed time.
DC Motor
Another example is the dc shunt motor. For a fixed armature voltage, the field rheostat resistance
setting can be increased to produce the desired increase in the motor speed.
1. 3
A functional block diagram, as shown in Figure 1.4, can represent the above examples just cited
symbolically.
Systems in which the output has an effect upon the input quantity are called closed loop control
systems. The feedback action controls the input to the dynamic unit. Closed-loop or feedback
controls operate according to a very simple principle:
1. Measure the variable to be controlled.
2. Compare the measured value with the desired (commanded value) and determine the
difference (error).
3. Use this difference (amplify if necessary) to adjust the controlled variable so as to reduce the
difference (error).
The events of everyday life give evidence of some sophisticated feedback control systems. For
example, we eat when we are hungry, and we stop when we are full. This behavior suggest the
operation of a feedback loop much like the loops used to control the level of fluid in a tank. In
both cases the set point is the desired level of fullness, the process variable is some measure of
actual fullness, and the control variable is the rate of intake.
1. 4
Water level float regulator
The first historical feedback system claimed by the Russian is the water level float regulator
invented by Polson in 1765. The level regulator system is shown in Figure 1.6 (a). The float
detects the water level and controls the valve that covers the water inlet in the boiler.
Figure 1.6 (a) Water level float regulator; (b) Watt fly ball governor
1. 5
Examples of feedback control are numerous: For example in thermostat control of room
temperature a person selects the desired room temperature (command input) and adjusts the
temperature setting on the thermostat. A bimetallic coil in the thermostat is affected by the actual
room temperature (output) and the reference selector setting. If the room temperature is lower than
the desired temperature, the coil strip alters its shape and causes a mercury switch to operate a
relay, which in turn activates the furnace to produce heat in the room. When the room
temperature reaches the desired temperature, the shape of the coil strip is again altered so that the
mercury switch opens. This deactivates the relay and in turn shuts off the furnace. In this example
the bimetallic coil performs the function of a comparator. The switch, the relay, and furnace are
the dynamic elements of this closed loop control system.
1. 6
Other examples of control systems are:
1. 7
The automatic load-frequency control (ALFC) loop regulates the megawatt output and frequency
(speed) of the generator. The ALFC loop shown in Figure 1.10 will maintain control only during
normal (small and slow) changes in load and frequency. When load on the generator is suddenly
increased by a small amount this demand is supplied by the kinetic energy of the rotating system
causing the reduction of the speed. The speed governor senses this reduction of speed; the
governor action after amplification will operate the turbine throttle valve to admit more steam
such that the input is increased to maintain the power balance. The speed and frequency will
maintain their steady-state value according to the governor drooping characteristic. Additional
secondary control loop is required to maintain the fine adjustment of the frequency.
1. 8
Antiaircraft radar tracking control systems
An early example of military application of a feedback control system is the aircraft radar tracking
control system shown in Figure 1.11. The radar antenna detects the position and velocity of the
target airplane, and the computer takes the information and determines the correct firing angle
for the gun. This angle includes the necessary lead angle so that shell reaches the projected
position at the same time as the airplane. The output signal of the computer, a function of the
firing angle, is fed into an amplifier, which provides power for the drive motor. The motor then
aims the gun at the necessary firing angle.
1. 9
Figure 1.12 Temperature control system.
1. 10
Also, there have been many applications of control system theory to biomedical experimentation,
diagnosis, prosthetics, and biological control systems. The control systems under consideration range
from the cellular level to the central nervous system, and include temperature regulation and
neurological, respiratory, and cardiovascular control.
The closed loop system can be designed to provide extreme accuracy in the steady-state; also its
response time can be reduced by appropriate design. Unfortunately, the feedback link introduces
serious problem stability! Feedback systems readily become oscillators; that is, the controlled
variables fluctuate continuously at some periodic rate (frequency) and never reach the desired
steady-state condition. For any specific system, stable operation can be achieved by proper design,
but the design problem is not always an easy one to solve.
1. 11
1.4 The control problem
A control engineer’s first step is the formation of a suitable model of the dynamic system or
process to be controlled. The model may be validated by analyzing its performance for realistic
input conditions and then by comparing with field test data taken from the dynamic system in its
operating environment. Model validation is often achieved with the aid of computer simulation in
which the effects of varying parameters can be determined more easily. Further analysis of the
simulated model is usually necessary to obtain the model response for different feedback
configurations and parameters settings. Once an acceptable controller has been designed and
tested on the model, the feedback control strategy is then applied to the actual system to be
controlled.
When we wish to develop a feedback control system for a specific purpose, the general procedure
may be summarized as follow:
1. Choose a way to adjust the variable to be controlled; e.g., the mechanical load will be
positioned with an electric motor or an electrical resistance heater will control the temperature.
2. Select suitable sensors, power supplies, amplifiers, etc., to complete the loop.
3. Determine what is required for the system to operate with the specified accuracy in
steady-state and for the desired response time.
4. Analyze the resulting system to determine its stability.
5. Modify the system to provide stability and other desired operating conditions by redesigning
the amplifier/controller, or by introducing additional control loops.
The transfer function of a linear, time-invariant, differential equation system is defined as the ratio
of the Laplace transform of the output to the Laplace transform of the input under the assumption
that all initial conditions are zero. Consider the linear time-invariant system defined by the
following differential equation:
d nc d n −1c dc d mr d m −1r dr
an n
+ an −1 n
+" + a1 + a0 c = bn m
+ bn −1 m
+" + b1 + b0 r (1.1)
dt dt dt dt dt dt
Where c is the output, and r is the input of the system. The transfer function is obtained by taking
the Laplace transform of both sides of equation (1.1), under the assumption that all initial
conditions are zero, or
1. 12
L[output]
Transfer function =
L[input] zero initial condition
Note that the denominator polynomial of (1.2) is the coefficient of C(s). This polynomial set equal
to zero is the characteristic equation of the differential equation (1.1). It will become apparent in
the next chapter that the ai coefficients in (1.1) are parameters of the physical system described
by the differential equation. It follows; therefore, that the characteristic equation does indeed
characterizes the system, since its roots are dependent only upon the system parameters.
1. 13
If the variation of x about x0 are small enough, the nonlinear curve can be approximated by its
tangent at a.
The Taylor series expansion about the operating point is
A good approximation to the curve over a small range
df
f ( x) = f ( x0 ) + ( x − x0 )
dx x = x0
or
y − y0 = m( x − x0 ) (1.3)
df
Where m = is the slope at the operating point
dx x = x0
1. 14
Chapter 2
Introduction
The first step in the analysis and design of control systems is mathematical modeling of
the system. The two most common methods are the transfer function representation and
the state equation approach. The state equations can be applied to portray linear as well
as nonlinear system and will be discussed in the next chapter.
All physical systems are nonlinear to some extent; in order to use the transfer function
and linear state equations the system must first be linearized. Thus, the first task of the
control systems engineer is to make proper assumptions and approximations so that a
linear mathematical model can characterize the system.
The dynamic performance of the physical systems is obtained by utilizing the physical
laws of electrical, mechanical, fluid and thermodynamic systems. We generally model
physical systems with linear differential equations with constant coefficients when
possible. Other models can be derived from the differential equation.
Electric systems are often used extensively in a control system to filter or modify a signal
in order to obtain satisfactory performance of the system. The model of electrical systems
is determined by the application of nodal and loop analysis. The Laplace transform of the
resulting integral-differential equation are obtained with zero initial conditions. A
detailed transfer function block diagram can be obtained by denoting the relationship
between variables graphically by means of the block diagrams. Alternatively, the
s-domain equations may be solved for an output/input ratio, which is the desired transfer
function.
Example 2.1
Find the transfer function relating the capacitor voltage Vc ( s ) , to the input voltage, Vi ( s) .
R L
i (t ) +
vi (t ) C vc (t )
-
Figure 2.1 Circuit of Example 2.1
2.1
Applying KVL
di (t )
Ri (t ) + L + vc (t ) = vi (t ) (2.1)
dt
and
dvc (t )
i (t ) = c (2.2)
dt
Taking Laplace transforms with zero initial conditions, we obtain
[ R + Ls ]I ( s ) + Vc ( s ) = Vi ( s ) (2.3)
and
I ( s ) = CsVc ( s ) (2.4)
Substituting from (2.4) into (2.3), the system transfer function is
[ LCs 2 + RCs + 1]Vc ( s ) = Vi ( s )
or
Vc ( s ) 1
=
Vi ( s ) LCs + RCs + 1
2
or
1
G ( s) = LC (2.5)
R 1
s2 + s +
L LC
Vi ( s ) 1/ LC Vc ( s )
R 1
s2 + s +
L LC
2.2 Block Diagrams
The block diagram is a short hand, pictorial representation of the cause and effect
relationship between the input and output of a physical system. It provides a convenient
and useful method for characterizing the functional relationships among the various
components of a control system. The relation V2 ( s ) = G ( s )V1 ( s ) is represented by a
transfer function block as shown:
V1 ( s ) V2 ( s )
Transfer function G( s) V2 ( s ) = G ( s )V1 ( s )
2.2
V1 ( s ) V2 ( s)
Summing point V2 ( s) = V1 ( s) ± F ( s)
±
F ( s)
V1 ( s ) V1 ( s )
Pickoff point V1 ( s ) = V1 ( s) = V1 ( s)
V1 ( s )
From the above block diagram the following three equations may be written
C (s) = G (s) E ( s)
F ( s ) = H ( s )C ( s )
E (s) = R(s) − F (s)
Eliminating E ( s ) and F ( s ) will result in
C ( s) G ( s)
= (2.6)
R( s) 1 + G ( s) H ( s)
A block diagram representation for the electric system of Example 2.1 with Vi ( s ) as
input and Vc ( s) as output is obtained by utilizing Eqs. (2.3) and (2.4), i.e.
1
[Vi ( s ) − Vc ( s )] = I ( s )
R + Ls
and
1
I ( s ) = Vc ( s )
Cs
Applying the above pictorial representations to these equations will result in the
following block diagram.
2.3
Vi ( s ) 1 I ( s) 1 Vc (s)
R + Ls Cs
−
The above feedback system where H ( s ) , is called a unity feedback system. Applying
(2.6) we have
1
V ( s) Cs ( R + Ls ) 1
T ( s) = c = =
(1) LCs + RCs + 1
2
Vi ( s ) 1 + 1
Cs ( R + Ls )
Example 2.2
G3
+
R( s) E1 ( s ) E2 ( s) + C ( s)
G1 G2
− −
H2
H1
2.4
Method 1 Back substitution
C ( s ) = G3 E1 ( s ) + G2 [G1 E1 ( s ) − H 2C ( s )] (2.10)
Finally, substituting (2.7) into (2.10) and simplifying yields the desired transfer function
C ( s) G1G2 + G3
=
R ( s ) 1 + G2 H 2 + G1G2 H1 + G3 H1
E1 + H1C = R ⎡1 0 H1 ⎤ ⎡ E1 ⎤ ⎡1 ⎤
G1 E1 − E2 − H 2C = 0 ⇒ ⎢ G −1 − H ⎥ ⎢ E ⎥ = ⎢0 ⎥ R
⎢ 1 2⎥⎢ 2⎥ ⎢ ⎥
G3 E1 + G2 E2 − C = 0 ⎢⎣G3 G2 −1 ⎥⎦ ⎢⎣ C ⎥⎦ ⎢⎣0 ⎥⎦
Solving for C
1 0 1
G1 −1 0
G3 G2 0 C (s) G1G2 + G3
R( s ) ⇒ =
1 0 H1 R( s ) 1 + G2 H 2 + G1G2 H1 + G3 H1
G1 −1 − H 2
G3 G2 −1
Block diagrams of complicated control systems may be simplified using easily derivable
transformations.
2.5
Block Diagram Transformation Rules
1. Combining R( s) C (s) R( s) C ( s)
cascade blocks G1 G2 ⇒ G1G2
3. Moving a R( s) C (s)
summing point G ⇒ R( s) G
C ( s)
Apply the block diagram transformation rules to example 2.2 to determine the system
transfer function
G3
+
R( s) E1 ( s ) E2 ( s) + C ( s)
G1 G2
− −
H2
H1
1
G3
G2
R( s) C (s)
G1 G2
− −
H2
H1
R( s) G3 G2 C ( s)
G1 +
− G2 1 + G2 H 2
G G + G3
= 1 2
G2
H1
Eliminating the feedback loop
R( s) G1G2 + G3 C ( s)
1 + G2 H 2 + G1G2 H1 + G3 H1
2.7
Example 2.4
Using block diagram transformation Determine C / R for the following systems
H3
− +
R( s)
G1 G2 + G3
C ( s)
− −
H2
H1
R(s) G2G3 C ( s)
G1
1 + G2 G 3 H 3
− −
H2
G3
H1
G3
R(s) G2G3 C ( s)
G1 1 + G2 G3 H 3 + G2 H 2
−
H1
G3
R( s) G1G2G3 C ( s)
1 + G1G2 H1 + G2 H 2 + G2 G3 H 3
2.8
Example 2.5
C ( s)
Determine
R( s)
H3
− C (s)
R(s)
G1 G2 G3 G4
− −
H1 H2
Moving one takeoff beyond G4 and eliminating the feedback loop G3G4 H 2
H3
G4
− G3G4 C (s)
R( s)
G1 G2 M1 =
1 + G3G4 H 2
−
H1
Moving takeoff point beyond block M 1 and eliminating the top feedback loop
R( s) G2 G 4 M 1 C (s)
G1 M2 =
G4 + G 2 H 3 M 1
−
H1
M1
H1 + G3G4 H1 H 2
G3G4
R( s) G1G2G3G4 C ( s)
(1 + G1G2 H1 )(1 + G3G4 H 2 ) + G2G3 H 3
2.9
2.5 Transfer Function (Multivariable System)
The definition of transfer function can be extended to a system with a multiple number of
inputs and outputs (multivariable system). Consider a system with two inputs and two
outputs as shown in Figure 2.5.
R1 ( s ) C1 ( s )
Multivariable
R2 ( s ) system C2 ( s )
Figure 2.5
When dealing with the relationship between one input and one output, it is assumed that
all other inputs are set to zero, e.g.,
C1 ( s) C1 ( s)
G11 = G12 = (2.11)
R1 ( s) R2 = 0 R2 ( s) R1 = 0
C2 ( s) C2 ( s )
G21 = G22 = (2.12)
R1 ( s ) R2 = 0 R2 ( s ) R1 = 0
Since the principle of superposition is valid for linear system, the total effect on any
output variable due to all the inputs acting simultaneously is obtained by adding up the
outputs due to each input acting alone.
C1 ( s ) = G11 R1 ( s ) + G12 R2 ( s )
(2.13)
C2 ( s ) = G21 R1 ( s ) + G22 R2 ( s )
⎡G G12 ⎤
G = ⎢ 11 ⎥
⎣G21 G22 ⎦
2.10
Example 2.6
C ( s)
Determine
R2 ( s )
R2 ( s)
H3
−
R1 ( s) C (s)
G1 G2 G3
− −
H2
H1
Redrawing the block diagram with R1 = 0 and moving the second summing point beyond
block G2
R2 ( s)
G2 H 3
−
C (s)
G3
− −
H2
G1G2 H1
2.11
R2 ( s )
G2 H 3
−
C (s)
G3
−
G1G2 H1 + H 2
1 C (s)
G3
1 + G2 H 3 −
G1G2 H1 + H 2
R2 ( s ) C (s)
G3
−
G1G2 H1 + H 2
1 + G2 H 3
Eliminating the feedback loop
R2 ( s ) G3 (1 + G2 H 3 ) C ( s)
1 + G2 H 3 + G3 H 2 + G1G2G3 H1
2.12
2.7 Signal Flow Graph
Node A Node
X Bracnh Y
Figure 2.6
Variables X and Y are represented by a small dot called node, and the transmission
function A is represented by a line with an arrow, called branch. Signals travel along
branches only in the direction described by the arrows of the branches. The branch
directing from node X to node Y represent the dependence of variable X upon Y , but not
the reverse.
Branch Branches are unidirectional paths that connect the nodes. An arrow is
assigned to indicate the direction of cause and effect.
Loop A loop is a path that starts and ends on the same node with all other nodes
in the loop touched only once.
2.13
Nontouching Nontouching loops are loops that have no common nodes.
loop
Forward path A forward path starts at an input node, ends at an output node, and
touches no node more than once. A forward path may traverse one or
more feedback branches in proceeding from input to output nodes.
Gains Gains for paths and loops are defined as the products of branch gains for
the paths or loops.
1. Addition Rule: - The value of a variable designated by a node is equal to the sum of
all signals entering the node, i.e. equation
Y = a1 X 1 + a2 X 2 + a3 X 3 + a4 X 4
is represented by
X3
X4
X2
a3
a2
a4
X1 a1
Y
Figure 2.7
2. Transmission Rule: - The value of a variable designated by a node is transmitted on
every branch leaving that node. In other words, the equation
Y1 = b1 X , Y2 = b2 X , Y3 = b3 X
is represented by
Y1
b1
b2
X Y2
b3
Y3
Figure 2.8
2.14
3. Parallel Branches: - Parallel branches in the same direction connecting two nodes can
be replaced by a single branch with gain equal to the sum of the gains of the parallel
branches
It is possible to simplify signal flow graph in a manner similar to that of block diagram
reduction. But it is also possible, and much less time-consuming, to write down the input-
output relationship by inspection from the original signal flow graph. This can be
accomplished by the use of general gain formula, known as Mason’s Gain Formula.
C (s) n M k ∆ k
G ( s) = =∑ (2.16)
R ( s ) k =1 ∆
where
r = Input node variable
c = Output node variable
G = Gain between input r and output c
n = Total number of forward paths
M k = Gain of the k th forward path
∆ = 1 - (sum of all individual loop gains) + (sum of gain products of all possible
combinations of two nontouching loops) - (sum of the gain products of all possible
combinations of three nontouching loops) + . . .
∆ k = The ∆ for the part of the signal flow graph which is nontouching with the k th
forward path. If all loops touches path k , ∆ k = 1 .
It must be emphasized that the gain formula can be applied only between an input node
and an output node.
2.15
Example 2.7
Determine the close loop transfer function for the block diagram of example 2.2 by using
Mason's gain formula.
The following signal flow graph is obtained from Example 2.2 block diagram or the
following equations describing the block diagram.
E1 ( s ) = R ( s ) − H1C ( s )
E2 ( s ) = G1 E1 ( s ) − H 2C ( s )
G3
C ( s ) = G3 E1 ( s ) + G2 E2 ( s )
1 G1 G2 1
R( s) C ( s)
E1 ( s ) E2 ( s ) C (s)
−H2
− H1
∆ = 1 − ( L1 + L2 + L3 )
= 1 + G2 H 2 + G1G2 H1 + G3 H1
Both paths have at least one node in common with every single loop. Therefore
∆1 = ∆ 2 = 1 .
C ( s) G1G2 + G3
=
R ( s ) 1 + G2 H 2 + G1G2 H1 + G3 H1
2.16
The above equations describing the system of Example 2.7 can be written in MATLAB
and using the Symbolic Toolbox “solve” function, the transfer function can be obtained
as follows:
The result is
G=
(G3+G2*G1)/(G3*H1+G2*G1*H1+G2*H2+1)
2.17
Example 2.8
For the signal flow graph shown, use the general gain formula to find the transfer
C (s)
function
R( s )
G4
R( s) 1 G1 G2 G3 1 1
C (s)
E2 ( s ) E3 ( s ) E4 ( s ) C (s)
E1 ( s )
− H1 −H2
−H3
Forward paths:
M 1 = G1G2G3
M 2 = G1G4
Loops:
L1 = −G1 H1
L2 = −G3 H 2
L3 = −G1G2G3 H 3
Nontouching loops:
L1 L2 = G1 H1G3 H 2
Therefore ∆ is given by
2.18
syms R E1 E2 E3 E4 C G1 G2 G3 G4 H1 H2 H3
eq1 = E1 + H1*E2 + H3*E4 - R;
eq2 = E2 - G1*E1;
eq3 = E3 - G2*E2 + H2*E4;
eq4 = E4 - G3*E3;
eq5 = C- E4 - G4*E2;
S = solve(eq1, eq2, eq3, eq4, eq5, E1, E2, E3, E4, C);
G=S.C/R % Obtains the transfer function C(s)/R(s)
Results in
G=
G1*(G3*G2+G4+G4*H2*G3)/(1+H2*G3+G1*H1+H1*G1*H2*G3+H3*G3*G2*G1)
2.19
Example 2.9
A system with several feedback loops and forward paths is shown. Using Mason's rule,
find the transfer function of the system
G7 G8
R ( s) 1 G1 G2 G3 G4 G5 G6 1
C (s)
C (s)
−H4
− H1
−H 2
−H3
Loop L5 does not touch loops L4 and L7 . Also L3 does not touch L4 .
∆ = 1 − ( L1 + L2 + L3 + L4 + L5 + L6 + L7 + L8 ) + L5 L4 + L5 L7 + L3 L4
C ( s) M1 + M 2 ∆ 2 + M 3
G ( s) = =
R( s) ∆
Substitute and obtain the transfer function
2.20
2.10 Modeling of Mechanical System
Most feedback control systems contain mechanical as well as electrical components. The
motion of mechanical elements are either translational, rotational, or a combination of
both. The equations governing the motions of mechanical systems are formulated from
Newton’s law of motion.
This is the motion of a rigid body along a straight line. Newton’s Law of motion states
that the algebraic sum of forces acting on a rigid body in a given direction is equal to the
product of the mass of the body and its acceleration in the same direction. i.e.
∑ forces = Ma (2.17)
M f (t )
d 2 x(t ) du (t )
f (t ) = Ma(t ) = M 2
=M (2.18)
dt dt
Spring- A spring is considered to be an element that stores potential energy. It is
analogous to a capacitor in electrical network. Its behavior may be approximated by a
linear relationship.
x2 (t ) x1 (t )
K
f (t ) f (t )
f (t ) = K [ x1 (t ) − x2 (t )] (2.19)
⎡ dx (t ) dx (t ) ⎤
f (t ) = B ⎢ 1 − 2 ⎥ (2.20)
⎣ dt dt ⎦
where B is the viscous frictional coefficient in N-s/m
Example 2.10
Find the transfer function for the system shown in Figure 2.9 (a).
K x(t )
d 2 x(t )
M
dt 2
M f (t ) dx(t ) M f (t )
B
dt
Kx (t )
B (a) (b)
Figure 2.9
We draw the free-body diagram as shown in Figure 2.9 (b). The applied force is directed
to the right. Forces due to the acceleration of mass, friction and spring impede the motion
and act to oppose it. These forces point to the left as shown. Using Newton’s law of
motion we have
d 2 x(t ) dx(t )
f (t ) = M 2
+B + Kx(t )
dt dt
F ( s ) = [ Ms 2 + Bs + K ] X ( s)
Taking the displacement of the mass x(t ) as the output and the applied force f (t ) as the
input, the transfer function is
X ( s) 1
G ( s) = =
F ( s) Ms + Bs + K
2
2.22
Analogous Systems
We can obtain an analogous electrical system for the above mechanical system.
Mechanical System
u (t )
u (t ) x(t ) u (t )
B x(t ) K x(t )
f (t ) M f (t )
f (t )
f = Kx
f = Bx f = Mx
= ∫ Kudt
= Bu = Mu
Electrical System
R i L i C i
di
v = Ri v=L 1
C∫
dt v= idt
Figure 2.10
Figure 2.11
2.23
Example 2.11
X 2 (s)
The system shown is initially at rest. Find the transfer function G ( s ) =
F (s)
u2 (t ) u1 (t )
B x2 (t ) x1 (t )
K
M f (t )
To draw the electric circuit analogy with velocity analogous to current, note that the
spring is moving with velocity (u1 − u2 ) . Clearly, we have two loops and the circuit is as
shown.
M B
+ u1 1 u2
f (t )
− K
f (t ) = K ∫ (u1 − u2 )dt ⇒ f (t ) = K ( x1 − x2 )
⎡ K K ⎤ ⎡ U1 ( s ) ⎤ ⎡1 ⎤
+ K ⎢ s − ⎥⎢ ⎥ ⎢ ⎥
U1 U2 s
F ( s) ⇒ ⎢ ⎥⎢ ⎥ = ⎢ ⎥ F ( s)
− s
⎢− K K⎥⎢ ⎥ ⎢ ⎥
Ms + B +
⎣⎢ s s ⎦⎥ ⎣⎢U 2 ( s ) ⎦⎥ ⎣⎢ 0 ⎦⎥
The transfer function with U 2 ( s) as output and F ( s ) as input can be found by using
Cramer’s rule
2.24
K
1
s
F (s)
K K
− 0
U 2 ( s) = s = s F ( s)
K K K⎛ K ⎞ K2
− ⎜ Ms + B + ⎟ − 2
s s s⎝ s⎠ s
K K
− Ms + B +
s s
X 2 ( s) 1
G ( s) = =
F ( s ) s ( Ms + B)
Example 2.12
The system shown is initially at rest. Draw the electric circuit analogy and write the s-
domain equation describing the mechanical system.
M1 M2 B2
K2 B2
B1
M2 + u1 u2 1
⇒ f (t ) 1
− K2
K1 B1 x2 u2 K1
M1 (b)
f (t )
x1 u1
(a)
To draw the electric circuit analogy with velocity analogous to current, note
that K1 and B1 are moving with velocity (u1 − u2 ) . Clearly, we have two loops and the
circuit is as shown in (b) above.
2.25
Or the s-domain circuit is
M 1s M 2s B2
B1
+ U1 ( s ) U 2 ( s) K2
F ( s)
− K1 s
s
(c)
Writing mesh equations by inspection in matrix form, we get
⎡ K1 ⎛ K ⎞ ⎤ ⎡ U1 ( s ) ⎤ ⎡1 ⎤
⎢ M 1s + B1 + s − ⎜ B1 + 1 ⎟ ⎥⎢ ⎥ ⎢ ⎥
⎢ ⎝ s ⎠ ⎥⎢ ⎥ = ⎢ ⎥ F ( s)
⎢ ⎛ K1 ⎞ K1 K 2 ⎥ ⎢ ⎥ ⎢ ⎥
⎢ − ⎜ B1 + ⎟ M 2 s + B1 + B2 + + ⎥ ⎣⎢U 2 ( s) ⎦⎥ ⎣⎢ 0 ⎦⎥
⎣ ⎝ s ⎠ s s ⎦
Or in terms of displacements, since U1 ( s) = sX 1 ( s) and U 2 ( s ) = sX 2 ( s ) , we have
⎡ M 1s 2 + B1s + K1 − ( B1s + K1 ) ⎤ ⎡ X 1 ( s ) ⎤ ⎡1 ⎤
⎢ ⎥ =
M 2 s + ( B1 + B2 ) s + K1 + K 2 ⎦ ⎢⎣ X 2 ( s ) ⎥⎦ ⎢⎣ 0 ⎥⎦
F (s)
⎣ − ( B1s + K1 )
2
Example 2.13
The system shown is initially at rest. Draw the electric circuit analogy and write the s-
domain equation describing the mechanical system.
u2 u1
x2 x1
M2 M1 f (t )
K2 K1
B2 (a) B1
To draw the electric circuit analogy with velocity analogous to current, note that K1 is
moving with velocity (u1 − u2 ) . Clearly, we have two loops and the s-domain circuit is as
shown in (b).
M 1s B1 M 2s B2
+ U1 ( s ) K1 U 2 (s) K2
F ( s)
− s s
(b)
2.26
⎡ K1 K1 ⎤ ⎡ U1 ( s ) ⎤ ⎡ 1 ⎤
⎢ M 1s + B1 + s s
− ⎥ ⎢ ⎥ ⎢ ⎥
⎢ ⎥⎢ ⎥ = ⎢ ⎥ F ( s)
⎢ M 2 s + B2 + 1 + 2 ⎥ ⎢ ⎥ ⎢ ⎥
K K K
− 1
⎢⎣ s s s ⎥⎦ ⎢⎣U 2 ( s ) ⎥⎦ ⎣⎢ 0 ⎦⎥
⎡ M 1s 2 + B1s + K1 − K1 ⎤ ⎡ X 1 ( s ) ⎤ ⎡1 ⎤
⎢ ⎥⎢ ⎥ = ⎢ ⎥ F (s)
⎣ − K1 M 2 s + B2 s + K1 + K 2 ⎦ ⎣ X 2 ( s) ⎦ ⎣0 ⎦
2
The variables generally used to describe the rotational motion are torque; angular
acceleration, α ; angular velocity, ω ; and angular displacement, θ . The following
elements are usually involved with the rotational motion.
Inertia: - Inertia, J , is considered as an indication of the property of an element, which
stores the kinetic energy of rotational motion. Moment of inertia of a given disk about its
axis is given by
1
J= Mr 2 (2.21)
2
where M is the mass of the disk and r its radius. Torque due to acceleration is
d 2θ dω
T = Jα = J 2 = J (2.22)
dt dt
Torsional spring: - the torque produced by a torsional spring is
K
τ (t ) θ1 (t ) θ 2 (t ) τ (t )
τ (t ) = K [θ1 (t ) − θ 2 (t )] (2.23)
where K is the spring constant in N-m⁄rad.
Friction for rotational motion: - As with the linear case viscous frictional torque for
rotational motion is
2.27
B
τ (t ) θ1 (t ) θ 2 (t ) τ (t )
⎛ dθ1 (t ) dθ 2 (t ) ⎞
τ (t ) = B ⎜ − ⎟ = B[ω1 (t ) − ω 2 (t )] (2.24)
⎝ dt dt ⎠
Example 2.14
The rotational system shown consists of a cylinder of moment of inertia J. The viscous
friction coefficient is B and the spring has stiffness K . A torque is applied to the shaft as
θ ( s)
shown. Write the equations describing the system and obtain the transfer function
T ( s)
K
J
τ (t ) B
θ (t )
Ω( s )
+ K
T ( s)
− s
K
T ( s ) = ( Js + B + )Ω ( s ) or
s
T ( s ) = ( Js 2 + Bs + K )θ ( s )
1
G ( s) =
Js + Bs + K
2
Example 2.15
Write the equations describing the system shown below.
K1 B3 K2
τ (t )
J1 J2
θ1 (t ) θ 2 (t ) B
1 B2 θ 3 (t )
2.28
The s-domain electric circuit analogy is
B1 J1 s J2s B2
+ K1 K2
T ( s) Ω1 ( s ) Ω2 ( s) B3 Ω3 ( s )
− s s
⎡ K1 K1 ⎤⎡ ⎤ ⎡1 ⎤
⎢ s − 0 ⎥ ⎢ Ω1
s ⎥ ⎢ ⎥
⎢ ⎥⎢ ⎥ ⎢ ⎥
⎢ − K1 B1 + B3 + J1s +
K1
− B3 ⎥ ⎢Ω ⎥ = ⎢0 ⎥ T (s)
⎢ s s ⎥⎢ 2 ⎥ ⎢ ⎥
⎢ ⎥
⎢ 0 K ⎢ ⎥ ⎢ ⎥
− B3 B2 + B3 + J 2 s + 2 ⎥ ⎢ Ω ⎥ ⎢0 ⎥
⎢⎣ s ⎥⎦ ⎣ 3 ⎦ ⎣ ⎦
DC Machines
A machines is basically a torque transducer that converts electric energy into mechanical
energy or vise versa. Dc machines depending on the type of excitations are classified as
permanent magnet, separately excited, and self excited machines. Self-excited machines
are either series field excited, shunt field excited or compound excitation.
The emf induced in the armature of a dc machine is proportional to the angular speed of
the armature ω , and the field flux φ . When saturation is neglected, the field current is
proportional to the field flux (φ ∝ I f ) , and the induced emf can be written as
e = K f I fω (2.25)
τ = K f Ia I f (2.26)
DC machines are used in control system as a generator to sense the speed, i.e., as
2.29
tachometer. Also, DC machine are used widely as motor in control systems, for example
to control the position of an antenna. Because of the linear characteristics of the dc motor
compared to the AC motor, DC motors are more suitable for control system applications.
With the development of the Alnico, ceramic and rare-earth permanent magnet, motors
offers very high torque to volume at a reasonable cost. Also, the advancement in the
brush-and-commutator technology has resulted in highly reliable DC motors with very
low inertia and very small time constant. These motors are used widely in computer
peripheral equipment such as tape drives, printers, disk drives, as well as in automation
and machine tool industries. Many other motors such as stepper motor, AC servomotor
(two-phase induction motor), and synchros are also employed in control systems. Below
the transfer function model of a DC motor is developed. Same procedure can be used to
obtain a model for other electromechanical devices.
DC Motor Model
Consider a separately excited (or a permanent magnet) dc motor with constant field
current as shown in Figure 2.12.
Ra La Fixed field
or PM
+
ia (t )
v(t ) ea (t ) M J
B
τ (t ) θ (t )
-
2.30
Ra La B J
+ ia (t ) ω (t )
+
v(t ) ea (t ) M τ (t )
-
- ea (t ) = K mω
τ (t ) = Kτ I a
Figure 2.13
Applying the KVL to the armature circuit and the electric circuit analogy, we have
di (t )
v(t ) = Ri (t ) + L + e(t ) ⇒ V ( s ) = [ R + Ls ]I a ( s ) + Ea ( s ) (2.29)
dt
dω (t )
τ (t ) = Bω (t ) + M ⇒ T( s ) = [ B + Js ]Ω( s ) (2.30)
dt
You may also draw the s-domain equivalent circuit and write the KVL equations directly
in s-domain. From (2.29), (2.28), (2.30), and (2.27), we have the following four s-domain
equations,
1
I a ( s) = [V (s) − Ea ( s)]
Ra + La s
T ( s ) = Kτ I a ( s )
(2.31)
1
Ω( s ) = T ( s)
B + Js
Ea ( s) = K m Ω( s)
dθ
The angular velocity ω = or in s-domain Ω( s ) = sθ ( s ) , therefore the angular position
dt
in s-domain is written as
1
θ ( s ) = Ω( s ) (2.32)
s
From (2.31) and (2.32), the dc motor block diagram is drawn as shown in Figure 2.14
V ( s) 1 I a ( s) T ( s) 1 Ω( s ) 1 θ ( s)
Kτ
Ra + La s B + Js s
−
Ea ( s )
Km
2.31
From the above block diagram, it is clear that the dc motor model has two time constants,
L
one associated with the armature circuit inductance, τ 1 = a , and the other the mechanical
Ra
J
time constant due to the motor inertia constant τ 2 = . In most cases the electrical circuit
B
time constant is much smaller than the mechanical circuit time constant and La may be
neglected.
From the block diagram the dc motor transfer function is
Kτ
θ ( s) s ( Ra + La s)( B + Js) Kτ
= =
V (s) 1 + Kτ K m s[( Ra + La s )( B + Js) + Kτ K m ]
( Ra + La s)( B + Js)
or
θ (s) Kτ
G (s) = = (2.33)
V ( s ) s[ JLa s + ( BLa + JRa ) s + ( BRa + Kτ K m )]
2
Gear Trains
Gear train, lever, or timing belt over a pulley is a mechanical device that transmits energy
from one part of the system to another in such a way that force, torque, speed, and
displacement may be altered. Gear trains in mechanical systems serve the same purpose,
as do transformers in electrical circuits; gear trains are thus mechanical transformers.
First we consider two ideal gears as shown in Figure 2.15. In the idea gear train the
inertia and friction of the gears are neglected. Later on we will consider these external to
the gears.
T1 θ1
r1
ω1 N1 r1 θ1
N2 ω2 θ
r2 2
r2
T2 θ 2
The number of teeth on the surface of gears is proportional to the radius r1 and r2 , i.e.,
N1 r1
= (2.34)
N 2 r2
The arc distance traversed on the surface of gears of the two meshing gears is the same,
i.e.,
r1θ1 = r2θ 2 (2.35)
Assuming no losses, the work done by gear 1 is equal to the work done on gear 2.,
therefore
T1θ1 = T2θ 2 (2.36)
or mechanical power input is equal to the mechanical power output, i.e.,
T1 T2
− −
T1 ω 2 N1
= = =a
T2 ω1 N 2
Figure 2.16
In practice, real gears have inertia and friction between coupled gears, and they are
included external to the ideal turns ratio.
Example 2.16
In the gear train shown J1 and B1 are the inertia and friction of gear 1, J 2 and B2 include
the inertia and friction of gear 2 and the load. A spring with a fixed end is connected to
gear 2. A torque T is applied to the input gear. Obtain a transfer function model with
T as input and θ1 as output.
2.33
T J1
θ1 ω1 B1 N1
T1
N2
B2 K
J2
N1 θ 2 ω2
Figure 2.17
The s-domain electric circuit analogy is drawn as shown. This is analogous to a transformer on load.
J1 s N J2s
B1 a= 1 B2
N2
Ω1 ( s ) Ω2 (s)
+ K ( s)
T (s) T1 ( s ) T2 ( s )
- s
T1 Ω 2 ( s ) N1
= = =a
T2 Ω1 ( s ) N 2
Figure 2.18
N2 ⎛ K⎞N
T1 ( s) = ⎜ B2 + J 2 s + ⎟ 1 Ω1 ( s ) or
N1 ⎝ s ⎠ N2
2
⎛ K ⎞⎛ N ⎞
T1 ( s ) = ⎜ B2 + J 2 s + ⎟ ⎜ 1 ⎟ Ω1 ( s ) (2.40)
⎝ s ⎠ ⎝ N2 ⎠
Applying analogous KVL equation to the primary, we have
T1 ( s ) = [ B1 + J1s + ]Ω1 ( s ) + T1 (2.41)
Substituting for T1 in (2.41) from (2.40), we get
⎛ K⎞ 2
T1 ( s ) = [ B1 + J1s + ]Ω1 ( s ) + ⎜ B2 + J 2 s + ⎟ ( a ) Ω1 ( s ) or
⎝ s⎠
⎛ K⎞
T1 ( s ) = ⎜ B1 + J1s + a 2 B2 + a 2 J 2 s + a 2 ⎟ Ω1 ( s ) (2.42)
⎝ s⎠
2.34
Similar to the transformer equivalent circuit reflecting from gear 2 to gear 1 we can draw
the equivalent circuit as shown in Figure 2.18. Where the secondary parameters are
transferred to the primary with the secondary parameters multiplied by the square of the
turn ratios.
B1 J1 s a 2 B2 a2 J2s
+ Ω1 ( s )
K
T ( s)
- a2
s
Figure 2.19 The equivalent circuit of the gear train referred to the primary
Ω1 ( s ) 1
G(s) = =
T (s) ( J + a 2 J )s + ( B + a 2 B ) + a 2 K
1 2 1 2
s
where Beq = B1 + a 2 B2 is the equivalent friction referred to the primary gear, and
J eq = J1 + a 2 J 2 is the equivalent inertia referred to the primary gear.
2.17 Sensors
Sensing devices are needed to provide measurements of the plant variables for use in the
feedback control circuits. Some of the common sensors are as follow:
Potentiometers
2.35
either linear or rotational.
V
− +
V RW
− + e(t ) = V RW = Kθ
RT
Kθ
e(t ) = V
θ RT
RW RT e(t ) = K Pθ
− e(t ) + − e(t ) +
Linear displacement Angular displacement
potentiometer potentiometer
The mechanical displacement can be either linear or rotational as shown in Figure 2.20,
in either case the potentiometer is represented symbolically as shown in Figure 2.21
+ θ (t )
θ (t ) e (t )
V KP
− e(t )
θ1 (t ) θ 2 (t ) θ1 (t ) e(t )
+ KP
V −
− θ 2 (t )
e(t ) = K P [θ1 (t ) − θ 2 (t )]
e(t )
Figure 2.22 Two potentiometers used to sense the position of two shafts.
Schematic diagram below shows a typical dc motor position control system, using dc
control.
2.36
Amplifier e (t ) M J
a
B Load Servo motor &
DC Motor Load Transfer
e(t ) function
Pot
+ θ r (t ) e(t ) e (t ) θ L (t )
KP GA a Gm
V
Reference θ (t ) − θ L (t ) − Amplifier
r
input
θr
0
t
Figure 2.23 Error, amplified error and the motor step response
2.37
Tachometers
Tachometers convert mechanical energy into electrical energy. DC Tachometers are used
in control system as velocity indicators or for speed control. Figure below shows the
block diagram of a typical velocity control system. The output is a voltage proportional
to speed.
ω Load
r (t ) e(t ) Power
Controller Amplifier M
− DC
Motor
+ ω
vt (t ) T
− Tachometer
Incremental Encoder
A digital encoder is a device that converts motion into a sequence of digital pulses.
Encoders have both linear and rotary configurations, but the most common type is the
rotary incremental encoder. A typical rotary incremental encoder has a light source, a
2.38
rotary disc, and a sensor. An encoder with three tracks is shown in Figure 2.25. An
incremental encoder produces equally spaced pulses from one or more concentric tracks
on the code disk. The pulses are produced when a beam of light passes through
accurately placed holes in the code disk. Each track has its own light beam. The inside
track has only one hole, which is used to locate the home position on the code disk. The
holes in the middle track are offset from the holes in the outside track by one-half the
width of the hole. The purpose of the offset is to provide directional information.
Code disk
Square-wave signal compatible with digital logic are derived from the sensors.
1
Outer track
0
Middle track
Inner track
Time
The incremental encoder has three tracks. The inner track provides a reference signal to
locate the home position. The middle track provides information about the direction of
rotation. In one direction, the middle track lags the outside track; in the other direction,
the middle track leads the outside track.
2.39
Chapter 3
State Variable Modeling
The differential equations of a lumped linear network can be written in the form
x (t ) = Ax (t ) + B u (t ) (3.1)
y (t ) = Cx (t ) + D u (t )
This system of first-order differential equations is known as the state equation of the
system and x (t ) is the state vector and u (t ) is the input vector. The second equation is
referred to as the output equation. A is called the state matrix, B the input matrix, C
the output matrix, and D the direct transition matrix. One advantage of the state-space
method is that the form lends itself easily to the digital and/or analog computer methods
of solution. Further, the state-space method can be easily extended to analysis of
nonlinear systems. State equations may be obtained from an nth-order differential
equation or directly from the system model by identifying appropriate state variables.
To illustrate how we select a set of state variables, consider an nth-order linear plant
model described by the differential equation
dny d n −1 y dy
n
+ an −1 n −1
+ " + a1 + a0 y = u (t ) (3.2)
dt dt dt
where y (t ) is the plant output and u (t ) is the plant input. A state model for this system is
not unique but depends on the choice of a set of state variables. A useful set of state
variables, referred to as phase variables, is defined as
x1 = y, x2 = y , x3 = y, " , xn = y n −1
Taking the derivatives, we have
x1 = x2 , x2 = x3 , x3 = x4 , " , and xn is given by (3.2) (3.3)
xn = −a0 x1 − a1 x2 − " − an −1 xn + u (t )
or in matrix form
x1 0 1 0 " 0 x1 0
x 0 0 1 " 0 x2 0
2
# = # # # # # + # + # u (t ) (3.4)
xn −1 0 0 0 # 1 xn−1 0
xn − a0 −a1 −a2 − an −1 xn 1
y = [1 0 0 " 0] x (3.5)
3.1
Example 3.1
Obtain the state equation in phase variable form for the following differential equation.
d3y d2y dy
2 3 + 4 2 + 6 + 8 y = 10u (t )
dt dt dt
The differential equation is third order, thus there are three state variables as follows
x1 = y, x2 = y , x3 = y
and the derivatives are
x1 = x2 , x2 = x3 , and x3 = −4 x1 − 3x2 − 2 x3 + 5u (t )
Or in matrix form
x1 0 1 0 x1 0
x2 = 0 0 1 x2 + 0 5u (t )
x3 −4 −3 −2 x3 1
x1
y = [1 0 0] x2
x3
ai = [2 4 6 8];
k = 10;
[A, B, C] = ode2phv(ai, k)
The state variables are directly related to the energy-storage elements of a system. It
would seem, therefore, that the number of independent initial conditions is equal to the
number of energy-storing elements. This is true provided that there is no loop containing
only capacitors and voltage sources and there is no cut set containing only inductive and
current sources. In general, if there are nc loops of all capacitors and voltage sources, and
nL cut sets of all inductors and current sources, the number of state variables is
n = eL + eC − nC − nL (3.6)
3.2
where
eL = number of inductors
eC = number of capacitors
nC = number of all capacitive and voltage source loops
nL = number of all inductive and current source cut sets
Example 3.2
Write the state equation for the network shown in Figure 3.1.
vc 0.5 H
+
iL
is (t ) 0.5 Ω 1F 2.5 Ω
Define the state variables as current through the inductor and the voltage across the
capacitor. Write a node equation containing capacitor, and a loop equation containing an
inductor. The state variables are vc , and iL .
Example 3.3
Write the state equation for the network shown in Figure 3.2.
3.3
4Ω 1H vc 2H
+
i1 i2
+
e(t ) 0.5 F 3Ω
−
−
Define the state variables as current through the inductors and the voltage across the
capacitors. Write a node equation containing the capacitor, and two loop equations
containing the inductor. The state variables are i1 , i2 , and vc .
Example 3.4
Write the state equation for the network shown in Figure 3.3.
4 Ω vc1 2H vc 2
iL
+ 0.25 F
vi 0.5 F 1Ω is
-
0
Figure 3.3 Circuit of Example 3.4
Define the state variables as current through the inductor and voltage across the
capacitors. Write two node equations containing capacitors and a loop equation
containing the inductor. The state variables are vc1 , vc2 , and iL .
3.4
Node equations are
dv v −v
0.25 c1 + iL + c1 i = 0 ⇒ vc = −vc1 − 4iL + vi
dt 4
dv v
0.5 c 2 − iL + c 2 − is = 0 ⇒ vc 2 = −2vc1 + 2vc 2 + 2is
dt 1
and the loop equation is
di
2 L + vc 2 − vc1 = 0 ⇒ iL = 0.5vc1 − 0.5vc 2
dt
or
vc1 −1 0 −4 vc1 1 0
v = 0 v
c2 −2 2 vc 2 + 0 2 i
i
iL 0.5 −0.5 0 iL 0 0 s
Equation (3.3) indicates that state variables are determined by integrating the
corresponding state equation. A diagram known as the simulation diagram can be
constructed to model the given differential equations. The basic element of the simulation
diagram is the integrator. The first equation in (3.3) is
x1 = x2
Integrating, we have
x1 = ∫ x2 dx
The above integral is represented by the time-domain diagram shown in Figure 3.4 (a)
similar to the block diagram, or the time-domain diagram shown in Figure 3.4 (b) similar
to the signal flow graph.
x2 (t ) 1 x1 (t ) s −1
x2 (t ) x1 (t )
s
(b)
(a)
Figure 3.4 Simulation diagram for integrator
It is important to know that although the symbol 1/ s is used for integration, the
simulation diagram is a time domain representation. The number of integrators is equal to
the number of state variables. For example, for the state equation in Example 3.1 we have
three integrators in cascade, the three state variables are assigned to the output of each
integrator as shown in Figure 3.5. The last equation in (3.3) is represented via a summing
point and feedback paths. Completing the output equation, the simulation diagram known
as the phase-variable control canonical form is obtained.
3.5
5u (t ) x3 1 x3 1 x2 1 x1 y 1 s −1 s −1 s −1 1
1 5u (t ) x x1 y
- s s s x3 -2 3 x2
- -
2 OR -3
3 -4
4
(a) (b)
Figure 3.5 Simulation diagram for Example 3.1
3.6
The above simulation in block diagram form is suitable for SIMULINK diagram
construction. You may find it easier to construct the simulation diagram similar to the
signal flow graph as shown in Figure 3.8.
b2
b1
1 w s −1 w
s −1 w s −1 w b0 1 y
u (t )
− a2 x3 x2 x1
− a1
− a0
In order to write the state equation, the state variables x1 (t ) , x2 (t ) , and x3 (t ) are assigned
to the output of each integrator from the right to the left. Next an equation is written for
the input of each integrator. The results are
x1 = x2
x2 = x3
x3 = − a0 x1 − a1 x2 − a0 x1 + u (t )
and the output equation is
y = b0 x1 + b1 x2 + b3 x3
or in matrix form
x1 0 1 0 x1 0
x = 0 0 1 x2 + 0 u (t ) (3.9)
2
x3 − a0 − a1 − a2 x3 1
x1
y = [1 0 0] x2
x3
It is important to note that the Mason’s gain formula can be applied to the simulation
diagram in Figure 3.6 to obtain the original transfer function. Indeed ∆ of Mason’s gain
formula is the characteristic equation. Also, the determinant of sI − A matrix in (3.9),
results in the characteristics equation. Keep in mind that there is not a unique state space
representation for a given transfer function.
The Control System Toolbox contains a set of functions for model conversion.
[A, B, C, D] = tf2ss(num, den) converts the system in transfer function from to state-
space phase variable control canonical form.
3.7
Example 3.5
U (s) 1 W (s) 2 Y ( s)
s + 7s + 2
s + 9 s + 26s + 24
3 2
w = −9w
− 26w − 24w + u & y = w + 7 w + 2w
The above time-domain equations yield the following simulation diagram
1
7
1 w s −1 −1 −1
w s w s w 2 1 y
u (t ) x3
−9 x2 x1
−26
−24
To obtain the state equation, the state variables x1 (t ) , x2 (t ) , and x3 (t ) are assigned to the
output of each integrator from the right to the left. Next an equation is written for the
input of each integrator. The results are
x1 = x2
x2 = x3
x3 = −24 x1 − 26 x2 − 9 x1 + u (t )
and the output equation is
y = 2 x1 + 7 x2 + x3
or in matrix form
3.8
x1 0 1 0 x1 0
x = 0 0 1 x2 + 0 u (t )
2
x3 −24 −26 −9 x3 1
x1
y = [ 2 7 1] x2
x3
The result is
A= B= C= D=
-9 -26 -24 1 1 7 2 0
1 0 0 0
0 1 0 0
Note that MATLAB assigns x1 to the output of the first integrator, and x2 , and x3 to the
output of the second and third integrators.
The Control System Toolbox supports four commonly used representations of linear
time-invariant (LTI) systems: tf, zpk, and ss objects. To create an LTI model or object,
use the corresponding constructor tf, zpk, or ss. For example,
sys = tf(1,[1 0]) .
3.9
creates the transfer function H(s) = 1/s. The result sys is a tf object containing the
numerator and denominator data. You can then manipulate the entire model as the single
MATLAB variable sys. For more details and examples on how to specify the various
types of LTI models, type ltimodels followed by tf, zpk, or ss.
The functions tfdata, zpkdata, and ssdata are provided for extracting the parameters of
the tf, zpk and ss objects. For example the command [num, den] = tfdata(T, 'v') returns
the numerator and denominator of the tf object. The argument ‘v’ returns the numerator
and denominator as row vectors rather than cell arrays. The Control System Toolbox
contains seven more functions, which are useful for creating a single model out of its
components.
Example 3.6
Use feedback function to obtain the closed-loop transfer function and the tf2ss function
to obtain the closed-loop state-space model
R( s) 5( s + 1.4) 1 C (s)
s+7 s ( s + 1)( s + 4)
−
Gc ( s ) G p ( s)
H (s)
10
Transfer function:
5s+7
---------------------------------
s^4 + 12 s^3 + 39 s^2 + 78 s + 70
A= B= C= D=
-12 -39 -78 -70 1 [0 0 5 7] 0
1 0 0 0 0
0 1 0 0 0
0 0 1 0 0
3.10
3.4 Solution of State Equation
Before presenting a formal solution for the state-space equation, let us review the solution
of the linear first-order differential equation due to initial condition. Consider
x(t ) = e at x(0)
As with a single first-order differential equation, the state equation has two solutions:
1. Solution due to initial condition (Homogenous solution) or zero-input response
2. Solution due to input in the absence of initial condition, known as the zero-state
response.
s X ( s ) − x (0) = AX ( s )
or
[s I − A ] X ( s ) = x (0)
Thus the s-domain solution is
3.11
X ( s ) = [ sI − A]−1 x (0) or X ( s ) = Φ ( s ) x (0) (3.13)
where
Φ ( s ) = [sI − A]−1 (3.14)
Taking the inverse Laplace transform, the time-domain solution is
x (t ) = φ (t ) x (0) (3.15)
Example 3.7
vc −2 −1 vc
i = 2 −5 i , with initial conditions vc (0) = 1 , and iL (0) = −1
L L
Determine the zero-input response that is, the response due to initial condition in the
absence of the current source.
X ( s ) = [ sI − A]−1 x (0)
s + 5 −1 s + 5 −1
s + 2 1 2 s + 2 2 s + 2
[ SI − A] = ⇒ Φ ( s ) = [ SI − A]−1 = =
−2 s + 5 ( s + 2)( s + 5) + 2 s 2 + 7 s + 12
s + 5 −1 1 s + 6
2
s + 2 −1 −s
−1
X ( s ) = [ sI − A] x(0) = =
s 2 + 7 s + 12 ( s + 3)( s + 4)
or
s+6 3 −2
( s + 3)( s + 4) +
X ( s) = = s + 3 s + 4
−s 3 −4
( s + 3)( s + 4) s + 3 + s + 4
Thus the zero-input response is
3.12
Solution of Non-homogenous State Equation
s X ( s ) − x (0) = AX ( s ) + B U ( s )
[s I − A ] X ( s ) = x (0) + B U ( s )
zero-input response zero-state response
or
X ( s ) = Φ ( s ) x(0) + Φ ( s ) BU ( s )
where
Φ ( s ) = [sI − A]−1
Taking the inverse Laplace transform in (3.16) the zero-input response and the zero-state
response are obtained
We can also express the above equation in terms φ (t ) and the convolution integral.
t
x(t ) = φ (t ) x(0) + ∫ φ (τ ) Bu (t − τ )dτ (3.17)
0
where
You are required to know and be able to find the zero-input response and the zero-state
response using Laplace transform method.
3.13
Example 3.8
Determine the state vector x(t ) for t ≥ 0 , for the system given below.
x1 0 1 x1 0
x = −2 −3 x + 1 r (t )
2 2
s + 3 1 s + 3 1
s −1 −2 s −2 s
[ SI − A] = −1
⇒ Φ ( s ) = [ SI − A] = 2 =
2 s + 3 s + 3s + 2 ( s + 1)( s + 2)
X ( s ) = [ sI − A]−1 x (0)
s + 3 1 1 s+2 1
−2 s −1 −( s + 2
X ( s ) = [ sI − A]−1 x(0) = = = s +1
( s + 1)( s + 2) ( s + 1)( s + 2) −1
s + 1
e−t
xn (t ) = −t
−e
s + 3 1 0 1 1/ 2 −1 1/ 2
−1
−2 s 1
1
s
s + s +1 + s + 2
X ( s ) = [ sI − A] BR ( s ) = = =
( s + 1)( s + 2) s s ( s + 1)( s + 2) 1 −1
+
s + 1 s + 2
1 − t 1 −2t
−e + e
xs (t ) = 2 2
−t −2 t
e −e
3.14
3.5 State-Space to Transfer Function Conversion
x (t ) = Ax (t ) + B u (t )
y = Cx (t ) + D u (t )
sX ( s ) = AX ( s ) + BU ( s ) ⇒ [sI − A] X ( s ) = BU ( s )
Y ( s ) = CX ( s) + DU ( s )
Y ( s ) = C[ SI − A]−1 BU ( s) + DU ( s )
or
Y ( s)
G ( s) = = C[ SI − A]−1 B + D (3.18)
U ( s)
Example 3.9
x1 0 1 x1 0
x = −6 −5 x + 1 u (t )
2 2
x
y = [8 1] 1
x2
Obtain the system transfer function using the formula in (3.18)
s + 5 1
s −1 6 s
[ SI − A] = ⇒ Φ ( s ) = [ SI − A]−1 = 2
6 s + 5 s + 5s + 6
s + 5 1 0 1
6 [8 1]
G ( s ) = C[ SI − A]−1 B = [8 1] 2
s 1
= 2 s = 8 + s
s + 5s + 6 s + 5s + 6 s 2 + 5s + 6
Therefore
s +8
G ( s) = 2
s + 5s + 6
In MATLAB [num, den] = ss2tf(A, B, C, D, i) converts the state equation to a transfer
function for the ith input.
3.15
Example 3.10
A system is described by the following state-space equations
x1 0 1 0 x1 10
x = 0 0 1 x + 0 u (t )
2 2
x3 −1 −2 −3 x3 0
x1
y = [1 0 0] x2
x3
Y ( s)
Find the transfer function, G ( s ) = .
U ( s)
num =
0.0000 10.0000 30.0000 20.0000
den =
1.0000 3.0000 2.0000 1.0000
Transfer function:
10 s^2 + 30 s + 20
---------------------
s^3 + 3 s^2 + 2 s + 1
3.16
Chapter 4
Time-domain Response
The time response of a control system is usually divided into two parts: the transient
response and the steady-state response,
The steady-state response css (t ) is that part of the response, which remains after the
transient, has died out.
Since inertia, mass, inductance and capacitance are part of a physical system and we know
for some variable instantaneous changes cannot occur and we may go through a transient
period. During this period we have deviation between input and output and therefore
dynamic behavior of a system is very important. The steady-state response of a control
system is also very important. If the output does not agree with the steady-state of the input
exactly, the system is said to have a steady-state error. This topic will be discussed in the
next chapter.
4.1
4.1 Time Response of First-order Systems
sC ( s ) − c(0) + a0C ( s) = b0 R( s )
or
c(0) b
C (s) = + 0 R(s) (4.2)
s + a0 s + a0
This equation can be represented in block diagram as shown
R( s) b0
s + a0 + R( s) b0 C (s)
C (s)
s + a0
c(0) 1 +
s + a0
(a ) (b)
Figure 4.1 Block diagram representation of first-order system
The block diagram shown in Fig. 4.1 (b) is for the zero initial condition. It is only sufficient
to obtain the response due to the force function. For example, if the step response is
obtained, from property of linear system the response due to initial condition can be
obtained from the step response as follow
u (t ) ru (t ) Step
d d response
u (t ) ru (t )
dt dt d
c(0) ru (t )
⇓ ⇓ Impulse L [ C (0)] = c (0)δ ( t )
−1
dt
δ (t ) rδ (t ) response
Response due to initial condition
from step response
Figure 4.2 Finding response due to initial condition from the step response.
4.2
Unit Step response
b
C ( s) = 0 R(s)
s + a0
1
If the input is a unit step function r (t ) = u (t ) , i.e., R ( s ) = , the response is
s
b0 b0
b0 1 a0 a
C ( s) = = − 0
( s + a0 ) s s s + a0
Taking the inverse Laplace transform
b
(
c(t ) = 0 1 − e − a0t
a0
)
or
t
−
c(t ) = K (1 − e ) τ
(4.3)
b0
where τ is the time constant and K = . The response is shown in Fig. 4.3
a0
4.4
The steady-state error, i.e. the difference between input and the output is Kτ. We will
discuss the steady-state error in detail in the next chapter.
1
For the unit step response R ( s) = , and the s-domain step response can be written as
s
ω n2 1 1 K1 K2
C ( s) = = + +
( s − s1 )( s − s2 ) s s ( s − s1 ) ( s − s2 )
Thus the inverse Laplace transform is
c(t ) = 1 + K1e s1t + K 2 e s2t = 1 + K1e − t /τ1 + K 2 e− t /τ 2 (4.11)
1
That is, for ζ > 1 the response is overdamped with two time constants τ 1 = − and
s1
1
τ2 = − .
s2
For ζ = 1 , the poles of G ( s) are real and equal, s1 = s2 = −ζω n , and the response is
critically damped
c(t ) = 1 + e −ζωnt ( K1 + K 2t ) = 1 + K1e − t /τ + K 2te− t /τ (4.12)
1
The time constant for critically damped response is τ 1 =
ζω n
The transient response of a practical control system often exhibits damped oscillations
before reaching steady-state. For ζ < 1 , the roots of the characteristic equation are complex
The underdamped response ( ζ < 1 ) to a unit step input, subject to zero initial condition is
given by
ω n2 1 1 K K*
C ( s) = = + +
( s + ζω n − jω d )( s + ζω n + jω d ) s s ( s + ζω n − jω d ) ( s + ζω n + jω d )
1 1 1−ζ 2
K is found to be K = − ∠θ − 90D where θ = tan −1 , therefore
2 1−ζ 2 ζ
1
c(t ) = 1 − e−ζωnt (sin ω d t + θ ) (4.14)
1−ζ 2
Figure 4.5 Step response of the second order system for ζ < 1 .
Roots of the characteristic equations given in (4.11) are marked in the s-plane as shown in
Figure 4.6. s1,2 = −ζω n ± jω n 1 − ζ 2
4.2
s1
jω n 1 − ζ 2
ωn
θ
−ζω n 0
s2
Figure 4.6 Pole locations s-plane
4.3
Locus of roots when ω n is held constant while the damping ratio is varied from −∞ to
+∞ is shown in Fig. 4.7.
jω n
ζ =0
0 > ζ > −1
0 <ζ <1
Unstable Region
∞ ←ζ ζ >1 ζ < −1 ζ → −∞
ζ >1 ζ = −∞ σ
ζ =1 ζ =∞ ζ = −1
ζ =0
Figure 4.7 Locus of roots of the characteristic equation with constant ω n , varying ζ
The step response comparison for various root locations in the s-plane is shown in
Figure 4.8.
4.4
Figure 4.8 Step response comparison for various root locations in the s-domain
jω
0 σ
Overdamped
s-plane
jω
jω
0 σ
jω
0 σ
Underdamped
s-plane
Undamped sinusoid
jω
0 σ
s-plane
jω
0 σ Unstable
s-plane
jω
0 σ
4.5
Unstable
s-plane
4.3 Step response using MATLAB Control System toolbox
Given a transfer function of a closed-loop control system, the function step(num, den)
produces the step response plot with the time vector automatically determined. num, and
den are the coefficients of the numerator and denominator of the closed loop transfer
function in descending order of power. If the above commands are invoked with the left-
hand argument c = step(num, den), the response c is returned. If the time array t is
specified, step(num, den, t) produces the step response plot over the specified time
interval. With the left hand argument c = step(num, den, t) returns the response for c,
over the specified time interval, and we need to use plot function to obtain the plot.
Similarly the functions impulse, initial, and lsim can be used to obtain the impulse
response, response due to initial condition and response to a defied forcing function.
Example 4.1
C (s) ω n2
Obtain the unit step response for the second-order system = G ( s) = 2
R( s) s + 2ζω n s + ω n2
For the following damping ratios ζ : 0.1 0.2 0.4 0.7 1 4 , and ω n = 5 .
We use the following commands
wn=5;
num = wn^2;
zeta =[0.1 0.2 0.4 .7 1 4];
for k=1:6
den = [1 2*zeta(k)*wn wn^2];
step(num, den);
hold on
end
legend('\zeta=0.1', '\zeta=0.2', '\zeta=0.4', '\zeta=0.7', '\zeta=1', '\zeta=4')
4.6
Figure 4.8 Response of a second-order system to a step input for different values of ζ .
The performance criteria that are used to characterize the transient response to a unit step
input include rise time, peak time, overshoot and settling time. The underdamped step
response for a second order system is shown in Figure 4.9. We define the rise time tr as the
time required for the response to rise from 10 % of the final value to 90 % of the final
value. The time to reach the peak value is t p . The swiftness of the response is measured by
tr and t p . The similarity with which the actual response matches the step input is measured
by the percent overshoot and settling time ts . For underdamped systems the percent
overshoot P.O. is defined as
Maximum value - Final value M − Css
P.O. = ×100 = pt ×100 (4.17)
Final value Css
The peak time is obtained by setting the derivative of c(t ) to zero.
π
tp = (4.18)
ωn 1 − ζ 2
4.7
Figure 4.9 Second order system step response for ζ < 1 .
The peak value of the step response occurs at this time and evaluating the response at
t = t p yields
1−ζ 2
c(t p ) = M tp = 1 + e −ζπ / (4.19)
1−ζ 2
P.O. = e −ζπ / × 100 (4.20)
Settling Time: settling time t s is the time required for the step response to reach within 2%
of its final value. These parameters are easy to find graphically once a plot of the response
is obtained. Regardless of the percentage used, the settling time will be directly
proportional to the time constant τ, i.e.
1
ts ≅ 4τ = 4 (4.21)
ζω n
4.8
Example 4.2
0.16s
Sensor
KD
0.2
Figure 4.10
Determine the step response percentage overshoot, P.O. , peak time, t p , and settling time t s .
1 1
τ= = = 0.2777 sec
ζω n (0.6)(6)
ts ≅ 4τ = 4(0.2777) = 1.11 sec
For higher order system the time-domain specifications are obtained from step response
4.9
using MATLAB. A function named timespec is developed in “Computational Aids in
Control Systems Using MATLAB” for finding the time-domain specifications. However,
the new MATLAB Control System Toolbox has powerful ltiview program obtains the
system responses and the time-domain or frequency domain specifications. This is
demonstrated in the following Example 4.3. See Tutorial II MATLAB Functions for
Modeling and Time-domain analysis
Example 4.3
Use the ltiview to obtain the step response time-domain specifications for the system in
Example 4.2. We use the following statements
The mouse right-click is used to obtain the time-domain specifications. From File menu
you can select Print to Figure option to obtain a Figure Window for the LTI Viewer for
editing the graph.
4.10
Example 4.4
1 + es
Figure 4.12
P.O. = e −ζπ / 1 − ζ 2 × 100
e −ζ (π ) / 1 − ζ 2 = 0.4
−ζ (π )
= ln 0.4 = −0.91629
1−ζ 2
ζ 2π 2 0.8396
= 0.8396 ⇒ ζ2 = = 0.0784 ⇒ ζ = 0.28
1−ζ 2 10.709
π π
tp = = 0.8 ⇒ ωn = = 4.0906 Rad/s
ωn 1 − ζ 2 0.8 1 − 0.282
C ( s) 16.733
= 2
R( s ) s + 1.288s + 16.733
We use the following statements to obtain the step response and time-domain
specifications.
4.11
num = 16.733; den =[1 2.29 16.733];
G = tf(num, den) % transfer function G
ltiview('step', G)
4.12
4.5 Frequency Response of systems
The frequency response of a system is defined as the steady- state response of the system
to a sinusoidal input signal. Consider a system with transfer function G ( s) and a
sinusoidal input
r (t ) = A cos ω t (4.22)
Substituting for the Laplace transform of r (t ) , the s-domain response C(s) of the system
output is
As As
C (s) = G(s) = G ( s)
s +ω
2 2
( s − jω )( s + jω )
(4.23)
The partial fraction expansion will result in
K K*
C ( s) = + + ∑ of terms generated by the poles of G ( s )
s − jω s + jω
where
As 1 1
K= G ( s) = AG ( jω ) = A G ( jω ) ∠θ (ω ) (4.23)
( s + jω ) s = jω
2 2
The poles of G ( s ) are the natural frequencies (or natural modes). They govern the
waveform of the transient component of the response. For the linear lumped network, the
terms generated by the poles of G ( s ) will not contribute to the steady-state response c(t ) .
The inverse Laplace transform of the partial fraction for complex poles is given by
−1 K K* −α t
L + = 2 K e cos( β t + θ )
s + α − jβ s + α − jβ
Therefore, the steady-state response is given by the inverse Laplace transform of the first
two terms of C ( s) .
First-Order System
Consider first the frequency response of a first-order system with the following transfer
function
1
G ( s) = (4.25)
τ s +1
The frequency response transfer function is
1 1
G ( jω ) = = ∠θ (ω ), where θ (ω ) = − tan −1 (ωτ ) (4.26)
1 + jωτ [1 + ω 2τ 2 ]
A plot of G ( jω and θ (ω ) is given in Figure (4.14).
The system bandwidth is defined as that value of frequency at which the magnitude of the
1
frequency response is reduced to 2 of its low frequency value. This frequency is denoted
by ω B . For the first-order system the bandwidth is given by
1
ωB = (4.27)
τ
Equation (4.27) is true only for the first-order systems.
ω n2 1
G ( jω ) = =
−ω 2 + j 2ζω nω + ω n2 ω 2
ω
1− + j 2ζ
ωn2
ωn
The frequency response transfer function amplitude is
1
G ( jω ) = 1
(4.29)
ω 2 2
ω
2 2
1 − 2 + 2ζ
ω n ω n
Mpω 1.4
1.2
|G(jω)|
1
0.8
Bandwidth
0.707
0.6
0.4
0.2
0 ωB 7
0 1 2 3 4 ωr 5 6 8 9 ω 10
For a constant ζ , increasing ω n causes the bandwidth to increase by the same factor. This
corresponds to a decrease in the peak time t p and the rise time tr the transient response.
Therefore, to increase the speed of response of a system, it is necessary to increase the
system bandwidth. For a particular system, an approximate relationship is given by
ω Btr = constant . Where this constant has a value in the neighborhood of 2 for the second-
order system, i.e.,
4.15
ω B tr ≈ 2 (4.30)
For ζ < 0.707 , the amplitude exhibits a peak value. The frequency at which the peak
occurs is obtained by setting the derivative of G ( jω ) to zero. This frequency is known as
the resonance frequency. For ζ< 0.707, the resonance frequency ω r is given by
ω r = ω n 1 − 2ζ 2 (4.31)
The maximum value of the magnitude of the step response, denoted by M pω , is
1
M pω = (4.32)
2ζ 1 − ζ 2
The peak in the frequency response is directly related to the amount of overshoot in the
transient response. The greater the peaks, the more overshoot will occur. Thus, in control
system design M pω is usually restricted to a maximum allowable value.
Example 4.5
25
G ( s) =
s + 2s + 25
2
(a) Find the resonant frequency ω r , peak amplitude M pω and the bandwidth ω B of the
system.
(b) Use MATLAB to obtain the frequency response and find ω r , M pω and ω B .
ω n2 = 25 ⇒ ω n = 5 Rad/s
2
2ζω n = 2 ⇒ ζ = = 0.2
(2)(5)
ω r = ω n 1 − 2ζ 2 = 5 1 − 2(0.2) 2 = 4.8 Rad/s
1 1
M pω = = = 2.55 Rad/s ⇒ dB (ω r ) = 8.136
2ζ 1 − ζ 2
2(0.2) 1 − (0.2) 2
4.16
2
1 1
2 2
=
ωB2 ωB 2
1 − ω 2 + 2ζ ω
n n
ωn
or
x = 1 − 2ζ 2 ± 4ζ 4 − 4ζ 2 + 2
2
ω
For ζ = 0.2 , x = 2.2788 = B ⇒ ω B = 7.55 Rad/s
ωn
ζ = 0.5 x = 1.618034 = (
ω B )2 1⇒ ωB = 2.544
ωn
(b) We use the following statements.
num=25;
den=[1 2 25];
bode(num, den), grid
The result is shown in Figure 4.16
4.17
Figure 4.16 The Bode plot for the system of Example 4.5.
To find the peak amplitude right click on the amplitude curve near the peak value, hold and
drag back and forth until you locate the peak value dB(ω r ) = 8.14 , and ω r = 4.8 Rad/s .
The bandwidth is the frequency where the amplitude is 0.707 or –3dB. Right-click on the
amplitude curve near –3 dB point, hold and move until gain is –3 dB. The bandwidth is
found to be 7.55 Rad/s.
4.18
Example 4.6
The closed-loop transfer function of a control system is described by the following third-
order transfer function
C (s) 750
= T (s) = 3 2
R( s) s + 36s + 205s + 750
The time constant of the real pole at s = −30 is τ 1 = 1/ 30 which is negligible compared to
the time constant of τ 2 = 1/ 3 for the dominant poles −3 ± j 4 . Therefore the approximate
reduced model transfer function is
25
T (s) 2
( s + 6 s + 25)
4.20
Figure 4.18 Third-order and reduced-order Bode plot of Example 4.6.
Table 4.1
4.21
1
The frequency response method and the root-locus method are simply two different
ways of applying the same basic principles of analysis. These methods supplement
each other, and in many practical design problems, both techniques are employed.
One advantage of the frequency response method is that the transfer function of
a system can be determined experimentally by frequency response tests. Further-
more, the design of a system in the frequency domain provides the designer with
control over the system bandwidth and over the effect of noise and disturbance on
the system response.
As we have seen the phase and gain margins of a control system are a mea-
sure of the closeness of the polar plot to the (-1, 0) point. Therefore, the open-loop
frequency response gain margin and phase margin may be used in the design crite-
ria.
The gain and phase margins along with ωpc and ωgc are obtained more easily
from the Bode plot. The phase margin may be read directly off the Bode plot at the
frequency which the amplitude curve crosses the 0 dB line, and the gain margin
may be read (in decibels) at the frequency at which the phase angle curve crosses
the −180◦ line. For satisfactory operation the phase margin should be between 30◦
and 60◦ , and the gain margin should be greater than 6 dB.
Additional performance specifications in terms of closed-loop frequency re-
sponse are the closed-loop system bandwidth, ωB , and the closed-loop system res-
onant peak magnitude, Mp . The bandwidth indicates how well the system tracks
an input sinusoid and is a measure of the speed of response. If the bandwidth is
small, only signals of relatively low frequency are passed, and the response is slow;
whereas a large bandwidth corresponds to a faster rise time. Therefore, the rise time
and the bandwidth are inversely proportional to each other.
The frequency at which the peak occurs, the resonant frequency, is denoted
by ωr , and the maximum amplitude, Mp , is called the resonant peak magnitude.
Mp is a measure of the relative stability of the system. A large Mp corresponds
to the presence of a pair of dominant closed-loop poles with small damping ratio,
which results in a large maximum overshoot of the step response in the time do-
main. In general, if Mp is kept between 1.0 and 1.7, the transient response will be
acceptable.
In summary, the frequency response design provides information on the steady-
state response, stability margin, and system bandwidth. The transient response per-
formance can be estimated indirectly in terms of the phase margin, gain margin,
EE-371 H. Saadat
2
and resonant peak magnitude. Percent overshoot is reduced with an increase in the
phase margin, and the speed of response is increased with an increase in the band-
width. Thus, the gain crossover frequency, resonant frequency, and bandwidth give
a rough estimate of the speed of transient response.
A common approach to the frequency response design is to adjust the open-
loop gain so that the requirement on the steady-state accuracy is achieved. This
is called the proportional controller. If the specifications on the phase margin and
gain margin are not satisfied, then it is necessary to reshape the open-loop transfer
function by adding the additional controller Gc (s) to the open-loop transfer func-
tion. Gc (s) must be chosen so that the system has certain specified characteristics.
This can be accomplished by combining proportional with integral action (PI) or
proportional with derivative action (PD).
Proportional Controller
Example 1
A plant has a minimum-phase transfer function
K K
G(s) = = 3
s(s + 2)(s + 8) s + 10s2 + 16s
sketch the polar plot and determine the closed-loop system stability the phase
crossover frequency, and the gain margins for K = 50.6, K = 160, and K = 506
K
G(jω) =
jω(2 + jω)(8 + jω)
−jK
G(jω) =
ω[16 − ω 2 + j10ω]
EE-371 H. Saadat
3
To find the real -axis crossing and the phase crossover frequency, we set the imagi-
nary part of the numerator to zero, resulting in ωpc = ±4 rad/s. Therefore the gain
at ωpc is
−10K −K
G(j4) = 2
=
100(4) 160
The Nyquist function is used to obtain an accurate plot for the three values of K.
Nyquist plot
1
0.5
K = 506
−0.5
K = 160
K = 50.6
−1
−1.5
−4.5 −4 −3.5 −3 −2.5 −2 −1.5 −1 −0.5 0
The results for the specified controller gain are
Example 2
The bode (magnitude and phase angle) plots of the above open-loop transfer func-
tion for k = 50.6, k = 160, and k = 506 are as shown in the next page. From the
plots determine the phase and gain crossover frequencies, the gain margin and the
phase margin for the specified controller gains.
EE-371 H. Saadat
4
10
dB
−10
−20
−30
0.1 0.2 0.4 0.6 0.8 1 2 3 4 5 6 7 8 910
−100
−120
−140
θ, degree
−160
−180
−200
−220
0.1 0.2 0.4 0.6 0.8 1 2 3 4 5 6 7 8 910
ω, rad/s
The results from the bode plots are
EE-371 H. Saadat
5
Example 3
Obtain the Bode plot, gain and phase margins for the feedback control system with
the open-loop transfer function
8 8
G(s) = = 3
s(s + 1)(s + 4) s + 5s2 + 4s
Determine the gain factor KP of a proportional controller such that the steady-
state error due to a ramp input will equal 0.25. Obtain the frequency response of
the compensated system and the new gain and phase margins.
The steady-state error specification requires
1
ess = = 0.25
Kv
or
Kv = 4
8Kp
Kv = lim s = 2Kp = 4
s→0 s(s + 1)(s + 4)
or
Kp = 2
The compensated open loop transfer function to satisfy the steady state error is
2(8) 16
G(s) = = 3
s(s + 1)(s + 4) s + 5s2 + 4s
Using bode function, the open loop frequency response for the compensated and
uncompensated system is obtained as shown.
EE-371 H. Saadat
6
20
10
dB
0
GMc ≈ 2 dB
−10 GMu ≈ 8 dB
−20
−30
0.1 0.2 0.4 0.6 0.8 1 2 3 4 5 6 7 8 910
ωgcU ωgcC
−100
−120
θ, degree
−140
−160
P.M. −156 + 180 ≈ 22° P.M. ≈ 5°
−180
−200
0.1 0.2 0.4 0.6 0.8 1 2 3 4 5 6 7 8 910
ω, rad/s ω
pc
From the frequency response plot, ωpc , ωgc , gain margin and phase margin for the
uncompensated and compensated systems are:
EE-371 H. Saadat
Operational Amplifier
c c
c
+ve power
c c
......
.
.
. ........
.
. ...... .
supply
.
.
.
.
.
.
.
.
.
.
.
.
.................................................................................................
.
.
.
- ........
.
. ......
......
......
+
.
. ......
.
.
. .....
.
. ......
. .................................................................................................
.
. ......
.
. ......
+
.
.
.
. ........
.
. . .....
.
.
+ .
.. .
..
vn
.................................................
. .......
.
. ...... . .
. ..... .
+
.
. .
vo
...........
. .
.
.
. .
.
vp
.
ve power
supply
...................................................................................................................................................................................................................................................................
VCC
.
.
.
.
.
.
.
.
.
.
..
......... ......... ......... ..................................................................................................
.
. ..
.
.
. ...
.
. ..
.
.
. ....
v0
.
. .
..
.
.
. ...
. ..
Slope = A
.
. ..
.
.
. ..
.
.
. ...
.
.
.
. ...
.
. ..
.
. ..
.
.
.
. ...
.
. ..
.
. .
.
. ..
. ....
.
.
. ...
.
.
. .
. ...
.
.
. .. .
.
v vn)
....
.
.
..........................................................................................................................................................................
......................................................................................................................................................................
0 ( p
..
....
.
.
.
.... . .
.
.
... . .
.... . .
.
.
.... . .
.
.. .
.
. .
.
.
..
. .
.
.
.. .
.
.
.. .
.
.
. .
.
..
. .
.
.
.. .
... .
.
.
... .
.
.
... .
.
.
.. .
.
.
VCC
. .
.... .
.
.
...
. .
.
.
... .
.
................................................................................................. ........ ........ .........
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
j j
When vp vn is small the op amp behaves as a linear
device. Outside this linear range the op amp saturates
and behaves as a nonlinear device. For operation in
the linear range the net input voltage is constrained to
the voltage VCC applied to the power terminals. The
op amp output is given by
8
>
< VCC A(vp vn) < VCC
v0 = > A(vp vn) VCC A(vp vn) VCC
: VCC A(vp vn) > VCC
EE-253 H. Saadat
73
For a typical op amp operating on its linear region,
the voltage difference between the two inputs is very
small, less than 2 mV.
vx = vp vn 0
Also the input resistance is very large, and the output
resistance is negligibly small. For example, the com-
10
mon 741 op amp has Aapprox 5 , Rin 2
M ,
and Rout 40
. Because of the high input resis-
tance, negligibly small current flows into the two op
amp inputs, usually on the order of A.
In most practical applications, the circuit analysis can
be simplified with good accuracy by assuming the op
amp to be ideal, i.e.,
A = 1, so that vn = vp
Rin = 1, so that in = ip = 0
Rout = 0
EE-253 H. Saadat
74
Inverting Amplifier
Since the open-loop gain of an op amp is infinitely
high to stabilize the operation a portion of the output
signal is returned to the input inverting terminal, re-
ducing the input voltage applied to this terminal which
in turn reduces the output voltage, and the op amp
operates on its linear region. Figure 4.3 shows the
circuit configuration for an inverting op amp.
R2
b
... ... ... ...
......................................................................................................................................... .
.
.... ... ... ... ...
b
.
.
.
.... .
.
.
... .
.
i-n +VCC
.
.
... .
b
.
.
... .
.
.
.... .
.
.
.
... .
.
R1
b
.
.
... .
.
... .
.
.
.
.... .
.
.
.
.
.
..............
. .
b
... .
.
. .
.
. .
. ... .
. .
.
... .. .. .. .
.
- . .
. ....... . .
.
vx
.......................... ........................................................................................ ....... .
.
. ... .. .. .. ...... .
.
.... ... .
...... .
... .... ...... .
.
...... .
... ... ...............................................
.
...........................................
.... .... .......
.
....
+
... ... ..
...
.. ......
...
+ ..
vi
. .
..
............................................ .......
.. .. ...... .
+ ... ........... .
.
vo
.... .
.
.
.... ..... .
.
.
VCC
... .
- ..
..
.
....
....
... ...
.... ...
... ...
.... ....
... ..
............................................................................................................................................................................................................................................................................................
..
.......................
...........
......
EE-253 H. Saadat
75
Noninverting Amplifier
The circuit configuration for a noninverting op amp is
shown in Figure 4.4
R2
b
.... ... ... ...
............................................................. ........ ........ ........ .............................................................
.
.
bb
.
... .
.
.
.... .
.
.
.
+VCC
.... .
.
.
b
... .
.
.
.
... .
i
.
.... .
.
.
.
.... .
R1 - -
.
n
.
.
.... .
.
... .
.
.
.
. .
... . .
..... . .
.
b
. . .
.... ... .......... . . .
.
R3 vn i-p +
. ...... . .
. .
.. .. .. .. .
. . . .
.
.. . . . . . ....... .
....................................................................................... ........ ........ ........ ....................... .............................................. ...... .
.
.
. ...... .
... ... ...... .
.
... .... ......
......
.
.
.
.
.... ... ...
..
..
..
..
..
..
..
..
...
..
..
.............................................................
... .... .......
.
+
.....
vp
.... ..
. ...
..
... ...... ..... ..... .....
. . . .
. .
.........
...................... .... .... .... .................... ............................................ ......
... ... .. .. .. .. ... .......... . .
vo
.
... ... ............ .
.
.
.
.... .... . .
vi
.
VCC
.
....
...
..
....
+
...
...
...
.
- ....
.... ...
.... ...
....................................................................................................................................................................................................................................................................................................................................................
...
......................
...........
......
b
... ... ... ...
........................................................................................................................................
.
. .
.. .. .. ..
Ra
bb
.
. .
.
.
. .
.
.
. .
.
.
. .
.
i-n +VCC
.
. .
.
. .
b
. .
.
.
.
. .
.
. .
.
. . . . . . . . .
.
. .
.
....................................................................................................................................................................................................................................................... .
.
.
.
. .
.
.
Rb
.
. .. .. .. .. .
. .
. .
.
.
.
. .
. .
. .
.
.
. .
. .
. .
.
. .
. . .
.
.
. .
. .
. . .
.
.
. .
.
. .
.
. . .
.
. .
.
. . .
. . .
b
.
. .
. .
. .......... . .
. . . . . .
.
vn
. . . . ...... . . .
.
.
.
.
.
.
... .... .... ....
. . . .
........................................................................................................................ ..... ..... ..... ...............................
.
.
.
.
.
......................................................................................... -.
.
.
.
.. ...
.
.
.
.......
.
.
.
.
.
Rc
.
. . .. .. . . .. . . ......... .
.
. . . .
.
. ..
. .
.
. .
.
.
...... .
.
.
.
. .
. .
. .
. ...... .
...............................................
va +-
.
.
. .
. .
. .
. . . ...........................................
... .
.
.
.
.
. ..... ....
+
... .
. .
.
. . ....
vp
....
.
.
. .
. . ........
. . . . . . . . .
+. .
vb
. ................................................................................................. . .. .....
. ...
. .
...... ............
. .
. .
. .
. .
. ...
.
...
.......
. .. .. .. .. .
. .
. ......... . .
.
+ .... .
vo
. .
. .
.
. .......... .
.
.... .
.
.
.
.
.. .
.
.
vc
.
VCC
.
. .. .
. .
.
.
.
.
.
.
.
.
.
.
.
.
- .
+ .
.
.
.
.
.
.
.
.
.
. .... .
.
.
.
.
.
.
.
.
.
.
.
....
...
..
- ...
.
.
.
.
.
.
.
.
.
.
.
.
. . .
.
.
. ..
. .
.
.
.
.
.
.
.
. ..
. ..
.
.
.
.
.
........................................................................................................................................................................................................................................................................................................................
................................................................................................................................................................................................
vn va vn vb vn vc vn vo
.. .
.
.
+ + + + in = 0
.
.
......................
...........
......
Ra Rb Rc Rf
vn = vp 0; and in = 0; thus we have
va vb vc vo
Ra Rb Rc Rf
= 0
Rf Rf Rf
vo = ( Ra va + R vb + Rc vc)
b
So the output voltage is an inverted scaled sum of the
three input voltages. If Ra Rb Rc Rs, then = = =
Rf
vo = ( va + vb + vc)
Rs
and if Rf = Rs, we have
vo = (va + vb + vc)
77
Difference amplifier circuit
Rf
b
... ... ... ...
......................................................................................................................................... .
.
.... ... ... ... ...
b
.
.
.
.... .
.
.
... .
.
+VCC
.
.
... .
b
.
.
... .
.
.
i
.... .
.
.
.
... .
b b
.
Ra - -
.
n
... .
.
.
.... .
.
.
.
... .
.
. .
.
.
.... ............. .
.
.
.
.
.
.
..... . .
Rb vn i-p +
. .
. .
. ...... . . .
.
.
.................. .......
............... ......
. .
. ......
...... .....
. ...
. .......
. ..... . ..
..
...
..
..
..
...
..
...... ........ ........ ........ .................................................................
. ....... .
.
.
. ... .... .... .... ..... .
.
. . .. ...... .
.
. . .
.
.
. ...
.
......
....... .
.
.
.
.
. ..
. ................................................
.
...........................................
.
.
. ..
. ...
.....
. .. .....
+
.
.
. .
. ....
. .
.....
.
. ... .... .... .... .. ..
.
va
.
. .
....................... ..... ..... ..... ................................................................ . .......
.....
. .. .. .. .. . .. ...... . .
+ ... .......... .
.
vo
.... .... .
Rc vp VCC
.
.... .... ..... .
.
vb
. ..... .
.
-
.
+ ...........
.......... .
..
....
.
.
. .....
.
.
.
.
.
.
.
.
.
.
- .
..........
......
....
..
.
.
. ..... ....
.
. ... ...
.
.
. . .
...............................................................................................................................................................................................................................................................................................................................................................................
.
. ..
.
......................
...........
......
vn va vn vo
Ra
+ Rf
+ in = 0
Rc
in = 0 = ip = 0; and vn = vp = R + Rc vb; thus
b
vo =
( Ra + R f )
vn
Rf
v
Ra Ra a
Rc(Ra + Rf ) Rf
= Ra(R + Rc) vb Ra va
b
Rf (Ra=Rf + 1) Rf
= Ra(R =Rc + 1) vb Ra va
b
EE-253 H. Saadat
78
The output voltage is equal to the difference between
scaled replica of the two inputs. If Ra=Rf = Rb=Rc,
we get
Rf
v0 = (vb va)
Ra
and if
Rf = Ra
we obtain
vo = vb va
EE-253 H. Saadat
79