Professional Documents
Culture Documents
Introduction
Summary
Control
Open-loop control
Simple
Need to know EVERYTHING ACCURATELY to work right
Cruise-control car: friction(t), ramp_angle(t)
E-commerce server: Workload (request arrival rate? resource
consumption?); system (service time? failures?)
We don
dont know everything
We make errors in estimation/modeling
Things change
Controlled System
Controller
control
function
control
input
error
+ reference
manipulated
variable
Actuator
Monitor
sample
controlled
variable
We don
dont know everything
We make errors in estimation/modeling
Things change
E-business server
Queuing theory
Outline
Introduction
Summary
Controller
Design
Modeling
analytical
system IDs
Dynamic model
Root-Locus
PI Control
Control algorithm
Satisfy
Requirement
Analysis
Performance Specifications
System Models
Dynamic Model
a2 y (t ) + a1 y (t ) + a0 y (t ) = b1 u (t ) + b0u (t )
Transfer functions (frequency domain)
Y(s) = G(s)U(s)
b1s + b0
c1
c2
G (s) =
=
+
a2 s 2 + a1s + a0 s ! p1 s ! p2
C(s)
G(s)
Y(s)
Example
Utilization control in a video server
Completion rate:
rate: Rc(t)= ({kc}
u[m])/t, where {m} is the set of terminated video
kc}u[m])/
streams during [t, t+
t+t]
Unknown
Admission rate:
rate: Ra(t)= ({ka}u[j])/
u[j])/t, where {j} is the set of admitted streams during [t,
t+
t+t]
Model
Differential equation
Error: E(t)=Us-U(t)
t
U (t ) =
! ( R (# ) " R (# ))d#
a
# =0
C?
Us
Ra(t)
U(t)
CPU
Rc(t)
A Diversion to Math
System representations
u(t)
g(t)
y(t)
y (t ) = g (t ) * u (t ) = ! g (t " # )u (# )d#
0
G(s)
Y(s)
Y ( s ) = G ( s )U ( s )
A Diversion to Math
Laplace transform
"
F ( s ) = L[ f (t )] =
! f (t )e
# st
dt
0#
a2 y (t ) + a1 y (t ) + a0 y (t ) = b1 u (t ) + b0u (t )
! Y (s) =
b1s + b0
U ( s )
2
a2 s + a1s + a0
A Diversion to Math
Laplace transform
Basic translations
Impulse function
f(t)=
f(t)=(t) F(s)=1
Step signal f(t)=a
f(t)=a1(t) F(s)=1/s
Ramp signal
f(t)=a
f(t)=at F(s)=a/s2
Exp signal f(t)=eat F(s)=1/(s-a)
Sinusoid signal
f(t)=sin(at) F(s)=a/(s2+a2)
Composition rules
Linearity
L[af(t)+bg(t)]
[af(t)+bg(t)] = aL[f(t)]+bL
[f(t)]+bL[g(t)]
[g(t)]
Differentiation
L[df(t)/dt]
[df(t)/dt] = sF(s)
sF(s) f(0-)
Integration L[tf(
f()d
)d] = F(s)/s
A Diversion to Math
Transfer function
U(s)
G(s)
Y(s)
A Diversion to Math
Poles and Zeros
# f (t ) = ! Ci e pi t
i =1
{pi} are poles of the function and decide the system behavior
A Diversion to Math
Time response vs. pole location
Stable
Unstable
A Diversion to Math
Block diagram
R(s)
R(s)
C(s)
Gc(s)
Go(s)
Y(s)
Y(s)
C ( s )Go ( s )
Gc =
1 + C ( s )Go ( s )
Y ( s ) = Gc ( s ) R ( s )
Back to
Our utilization control example
Error: E(t)=Us-U(t)
t
U (t ) =
! ( R (# ) " R (# ))d#
a
# =0
C?
Us
Ra(t)
U(t)
CPU
Rc(t)
Model
Transfer func. & block diag.
CPU is modeled as an integrator
t
Ra ( s ) " Ra ( s )
1
U (t ) = # ( Ra ($ ) " Rc ($ ))d$ ! U ( s ) =
! Go ( s ) =
s
s
$ =0
Us(s) as input:
Rc(s)
(s) as input:
G1(s) = C(s)Go(s)/(1+C(s)Go(s))
G2(s) = Go(s)/(1+C(s)Go(s))
Output: U(s)=G1(s)Us/s+G2(s)Rc(s)
Rc(s)
Us/s
C(s)
Ra(s)
Go
U(s)
Controller
Design
Modeling
analytical
system IDs
Dynamic model
Root-Locus
PI Control
Control algorithm
Satisfy
Requirement
Analysis
Performance Specifications
Design Goals
Performance Specifications
Stability
Transient response
Steady-state error
Robustness
Disturbance rejection
Sensitivity
A LTI system is BIBO stable if all poles of its transfer function are in the LHP (
(pi,
Re[pi]<0).
&im=1 ( s % zi )
Cn
C1
C2
Y ( s ) = G ( s )U ( s ) = K n
=
+
+ ... +
&i =1 ( s % pi ) s % p1 s % p2
s % pn
n
$ y (t ) = ' Ci e pi t
i =1
t #!
Note : Ci e pi t ""
"# !
if
Re[ pi ] > 0
Performance Specs
Stability
Stable
Unstable
Performance specifications
Controlled
variable
Overshoot
Reference
Transient State
Settling time
Steady State
Time
Response
(queue length)
Good
Control
Bad
(MaxUsers)
Slow
Useless
Performance Specs
Steady-state error
t #"
lim f (t ) = lim sF ( s)
t !"
s !0
s !0
Performance Specs
Steady-state error
ess=-20%
Performance Specs
Robustness
Can a system track the reference input despite of variations in the system?
Increased task execution times
Device failures
Performance Specs
Goal of Feedback Control
Guarantee stability
Disturbance rejection
Low sensitivity
Controller
Design
Modeling
analytical
system IDs
Dynamic model
Root-Locus
PID Control
Control algorithm
Satisfy
Requirement
Analysis
Performance Specifications
Controller Design
PID control
Proportional Control
x(t ) = Ke(t )
C (s) = K
Integral control
Derivative control
C (s) =
x(t ) = KK d e (t ) !
KK i
s
C ( s ) = KK d s
R(s)
E(s)
X(s)
C(s)
Go(s)
-
Y(s)
Controller Design
CPU Utilization Control
CPU is modeled as an integrator
t
Ra ( s ) " Ra ( s )
1
U (t ) = # ( Ra ($ ) " Rc ($ ))d$ ! U ( s ) =
! Go ( s ) =
s
s
$ =0
Us(s) as input:
Rc(s)
(s) as input:
G1(s) = C(s)Go(s)/(1+C(s)Go(s))
G2(s) = Go(s)/(1+C(s)Go(s))
Rc(s)
Us/s
C(s)
Ra(s)
Go
U(s)
Proportional Control
Stability
Proportional Controller
Transfer functions
ra(t)=
Ke(t);
); C(s) = K
(t)=Ke(t
Us/s as input:
Rc(s)
(s) as input:
G1(s) = K/(s+K)
G2(s) = 1/(s+K)
Stability
Rc(s)
Us/s
C(s)
Ra(s)
Go
U(s)
Proportional Control
Steady-state error
Assume completion rate Rc(t) keeps constant for a time period longer than
the settling time: Rc(s)=Rc/s
System response is
U s G1 ( s ) Rc G2 ( s ) KU s ! Rc
U (s) =
+
=
s
s
s(s + K )
Rc
" ess = !
<0
K
CPU Utilization
Proportional Control
U(t)
Us
ess=-20%
Proportional-Integral Control
Stability
Proportional Controller
C(s) = K(1+Ki/s)
Transfer functions
ra(t)=
K(e(t)+Kite(
(t)=K(e(t)+K
e()d
)d)
Us/s as input:
Rc(s)
(s) as input:
G1(s) = (Ks+KKi)/(s2+Ks+KKi)
G2(s) = s/(s2+Ks+KKi)
Stability
Rc(s)
Us/s
C(s)
Ra(s)
Go
U(s)
Proportional Control
Steady-state error
Assume completion rate Rc(t) keeps constant for a time period longer than
the settling time: Rc(s)=Rc/s
System response is
U s G1 ( s ) Rc G2 ( s ) ( KU s + Rc ) s + KK iU s
U (s) =
+
=
s
s
s ( s 2 + Ks + KK i )
! ess = 0
CPU Utilization
Proportional-Integral Control
U(t)
Us
Mp =
0
ts tr tp
ess=0
Controller Design
Summary & pointers
Root-locus design
Frequency-response design
State-space design
G. F. Franklin et. al., Feedback control of dynamic systems
Discrete Control
denoted k instead of t
"
Z[ f (k )] = F ( z ) = ! f (k ) z # k
k =0
Discrete Modeling
Difference equation
V(m) = a1V(m-1) + a2V(m-2) + b1U(m-1) + b2U(m-2)
z domain: V(z) = a1z-1V(z) + a2z-2V(z) + b1z-1U(z) + b2z-2U(z)
Transfer function G(z) = (b1z + b2)/(z2-a1z - a2)
V(m): output in mth sampling window
U(m): input in mth sampling window
Order n: #sampling-periods in history affects current performance
SP = 30 sec, and n = 2 Current system performance depends on
previous 60 sec
Higher-frequency
response
Re(s)
Stable
Unstable
Intuition : z = e Ts
|z|=1
Robust Control
Adaptive Control
Optimal Control
Stochastic Control
MIMO Control
Nonlinear systems
Neuro-fuzzy
Neuro-fuzzy control
Challenging to derive analytic results
ControlWare paper