160A – Intro to Control Systems
Midterm – 8/29/07 - Solutions
1) (15) Using the Routh test, check for what range of K (real number) these
2 polynomials have RHP roots:
a) s4 +2 s3 +3 s2+K b) s3+4s2+K s +4
a) the term s1 is missing, so NO test to be performed, there are
unstable solutions for any K. If you did the Routh test, no matter
what result you got, I consider it wrong because Routh’s test only
applies to polynomials with all terms having the same sign.
b) This can be tested, and the array looks like this
S3 1 K
S2 4 4
S1 1 K 0
det
− 4 4 = − 4 − 4 K = K − 1
4 K
S0 4 4
det
− K − 1 0 = − − 4(K − 1) = 4
K −1 K −1
First column is 1, 4, K-1, 4 and there is no sign variations if K>1, so the
polynomial is unstable for K≤1
2) (20) Write the differential equations for the following systems, and
transform them to the Laplace domain. What order do you expect this
system to be? WHY?
The time domain diff. eq. can be written using the basic relations of mechanical
systems and the free body diagram for masses m1 and m2. Gravity, being
constant, can be removed from the problem: it gives only a steady state
extension on the springs. u2 is the input force.
General equations for the elements, where x is the linear coordinate, are:
Mass: F = ma = m&x&
Dashpot F = −bx&
Spring F = −kx
On m2 acts the force of the spring k2 (proportional to its length), the force of the
damper, proportional to the speed to which the damper is subject, and to the
input force. Draw the free body diagram to check the force signs,
m2 &y&2 = − k 2 y 2 − b( y& 2 − y&1 ) + u2
Sign check (handwaving proof ☺): y2 points downwards, so the forces pushing
down are positive. If you imagine to increase y2, spring pulls up, so its
contribution is negative. Consider now the dashpot: if y2 is increasing, the
damper brakes the mass, so the y2 dot contribution is negative. If y1 is increasing
(moving down) the dashpot is pushed down, so y1 dot contribution is positive.
External force u1 pushes down, so it gives a positive contribution.
For mass m1 we get a similar equation. Draw the free body diagram for the signs
of the acting forces, and check the signs with the considerations as before:
m1 &y&1 = −k1 y1 − b( y&1 − y& 2 )
Going to Laplace domain, with zero initial conditions requires to express the
derivatives as multiplications by s: we obtain
m2 s 2Y2 ( s ) = −k 2Y2 ( s ) − bs (Y2 ( s ) − Y1 ( s ) ) + U 2 ( s )
m1 s 2Y1 ( s ) = − k1Y1 ( s ) − bs (Y1 ( s ) − Y2 ( s ) )
System (and transfer function between Y1 and U2) is expected to be fourth order,
because there are 4 independent elements storing energy (2 springs and 2
masses). Dashpots don’t store energy, they dissipate it, like resistors.
Extra credit (Only if you have time): find Y1(s)/U2(s).
Obtain Y2 from one equation and substitute it in the other equation. After some
algebraic manipulations, final result is
Y1 (s ) bs
=
U 2 (s ) m1m2 s + b(m1 + m2 )s + (k1m2 + k 2 m1 )s 2 + b(m1 + m2 )s + k1k 2
4 3
4) (25) Find the transfer functions C(s)/R(s) and C(s)/(D(s) of the following
system:
Show all the manipulations you do on the block diagram.
System is linear, with 2 inputs, so one can consider one input only at a time. It is
a major error writing that the G2 input is D+G1 because you cannot add a
transfer function and a signal.
Considering D=0, to find C/R, there are (among many others) two possible
solutions
a) solve the loop G1G2 with feedback H1, and you get for the internal loop
G1G2
The system is so reduced to this one:
1 + G1G2 H 1
R G1G2
G3 C
+ Gc 1 + G1G2 H 1
H2
Applying one more time the closed loop formula, the result is
G1G2
Gc G3
C 1 + G1G2 H 1 GcG1G2G3
= =
G3 H 2 1 + G1G2 H1 + GcG1G2G3 H 2
R 1+ G G1G2
1 + G1G2 H 1
c
Another possible solution is to move the pickup point of H1 after the block G3 and
to inject the output of H1 block before Gc. In doing so, we have to modify the H1
transfer function: moving the measuring point after G3 requires that H1 is modified
as H1/G3. Moving the injection point before Gc requires another change to the H1
block, H1/(GcG3). We obtain this system:
R
+ Gc G2 G3 C
+ G1
- -
H1
Gc G3
H2
Here the two feedback blocks are in “parallel” they have the same input and their
outputs are added, so we can substitute the feedback path with a single block.
On the forward path we can also unify block (I left 2 blocks in the forward path to
exploit the same block diagram for the second input).
R C
+ GcG1 G2G3
-
H1
H2 +
GcG3
The transfer function between C and R is hence (as before):
C Gc G1G2G3 Gc G1G2G3
= =
R H 1 1 + G1G2 H 1 + Gc G1G2G3 H 2
1 + Gc G1G2G3 H 2 +
Gc G3
The advantage of this approach is that the injection point of signal D is preserved,
so when we have to find C/D, we can use the same block diagram with very
minor changes:
D
C
+ GcG1 + G2G3
-
H1
H2 +
GcG3
We still recognize a standard feedback diagrams, with forward gain given by
G2G3 and feedback block given by GcG1 times (H2+H1/(G1G3)). This is a negative
feedback configuration because along the loop there is a negative sign. The
transfer function between C and D is hence
C G2G3 G2 G3
= =
D H 1 1 + G1G2 H 1 + Gc G1G2 G3 H 2
1 + G2G3 Gc G1 H 2 +
G G
c 3
Observe that the denominator is the same as the previous point: changing the
input or the output point in a system has the effect of changing zeroes but poles
stay in the same position.
5) (30) For the following system, find K and kd such that the closed loop
response Y/U to an input step has a maximum overshoot of 5% and a steady
state error of 3%. Show the final closed loop function Y/U and determine the rise
and settling times of the closed loop system for a step input.
In the notes, I suggested you to disregard the spec on the steady state and add
instead a spec on rise time tr < .11s. This implies that the CLOSED LOOP
complex conjugate poles must have omega > 1.8/.11s=16.4 rad/s
U 3 Y
+ + K 1 2
- s + 3s + 4
- 2
kd s
The time domain overshoot spec requires that the closed loop poles have a
damping coefficient ζ=0.7. The steady state error with a step input sets a
constraint on the steady state gain of the loop. The rise time spec sets
omegan=16.3 rad/s
Let first reduce the original block diagram to a standard form. The 2 feedback
branches can be added, and the equivalent H is H=1+s kD. The forward path gain
can be reduced to a standard polynomial with a unity leading term (highest
6K
power). G = 2 . The closed loop gain is given by the usual equation:
s + 6s + 8
6K
Y s + 6s + 8
2 6K ωn2
= = 2 =A 2
U 1 + (1 + sk ) 6K s + 6( Kk D + 1) s + 6 K + 8 s + 2ζωn s + ωn2
s 2 + 6s + 8
D
Observe that I equate my result to the standard second order form with an extra
coefficient to take care of the real gain: the standard form has a unity DC gain.
The damping coefficient ζ depends both on K and kD whereas the steady state
1 1 1 4
error is given by ess = = = = = 0.03
1 + K p 1 + G (0)H (0) 1 + 6 K 1 3K + 4
8
The K constant is hence K=388/9=43.11.
The damping coefficient ζ depends both on K and kD whereas the pole frequency
ωn depends only on K. ωn2=6K+8=(16.3 rad/s)2=> K=43 (almost the same as the
original problem ☺)
This K value, substituted in the closed loop gain expression gives:
776
Y 3 258 .7
= ≈ 2
U 776 800 s + (258 .7 k D + 6 )s + 266 .7
s2 + k D + 6 s +
3 3
As a check, the steady state output value for a step input is given by s going to 0
776
3 97
in the closed loop expression: lim =
s →0 776 800 100
s2 + k D + 6 s +
3 3
that is in steady state the value is 97% of the desired value, with a 3% error, as
required.
The closed loop poles are at ωn=√266.7=16.3 rad/s and the s coefficient can now
be determined. 258.7k D + 6 = 2ζωn = 2 ⋅ 0.7 ⋅ 16.3 so kD=0.0652.
Y 258.7
The closed loop transfer function is = 2
U s + 22.86s + 266.7
Rise time is approximately tr≈1.8/ ωn=1.8/16.3 rad/s=0.11s and the settling time,
4.6 4.6 4.6
at 1% is t s = = = = 0.4s
σ D ζωn 0.7 ⋅ 16.3 rad/s