Control Systems
Lecture (4)
Constantinos Siettos
Feedback Control Systems
Control of a System’s Response
Transient Steady State
Why Feedback?
Steady-State Error
E(s) R(s) 1 K
E(s) R(s) 1 K s
e(t) 1 1 K
e(t) e
K tY(s) Y(s)
For
R(s)=1/s For R(s)=1/s
lim
t lim
s 0
f f t sF s
The difference between input and output for a predetermined input for
t
Steady-State Error- Proportional Control
Control Gc(s)
system G
p(s)
feedback H(s)=1 reference input, R(s)
error, E(s) output, Y(s)
+ -
error, u(s)
1
p c
c p
G s G s T s Y s
R s G s G s
1
c pE s R s
G s G s
0
lim lim
ss t s
e e t sE s
Steady-State Error with Proportional Controller - Step Input
1
c pE s R s
G s G s
0 0
0
0
1
1 1
lim lim lim
lim lim
ss t s s
c p
s c p s c p
A
e e t sE s s s
G s G s
A A
G s G s G s G s
Constant of steady state error
Α
Steady-State Error with Proportional Controller-Ramp Input
1
c pE s R s
G s G s
2
0 0
0
lim lim lim
lim
ss t s s
c p
s c p
A
e e t sE s s s
s sG s G s A
sG s G s
Constant of velocity error
Α
Steady-State Error with Proportional Controller
1
p c
c p
G s k T s Y s
R s k G s
E.g. for a 1st order process
( )
p
G s K
s a
c
R s s a E s s a k K
c cY s Kk
T s R s s a k K
Control Gc(s)=kc
system G
p(s)
feedback H(s)=1 reference input, R(s)
error, E(s) output, Y(s)
+ -
error, u(s)
Steady-State Error, Use of Matlab
clear all Kc=1;
K=1;
a=0.5;
sys1=tf(1,1);
sys2=tf(K,[1 a]);
sysh=tf(1,1);
sys3=series(sys1,sys2);
sys4=feedback(sys3,sysh) step(sys4)
T=0:0.01:4
U=ones(length(T),1);
LSIM(sys4,U,T) U=0.35*T;
LSIM(sys4,U,T)
Steady-State Error-
Simple Design Example
1
pE s R s
KG s
Find Κ so that the steady-state error is 10%
1. For R(s) step ?
0 0
1
1 0
5 5
1 1
6 7 8 6 7 8
lim lim
s s
e t s s
s s
K K
s s s s s s s s
1
pE s R s
KG s
1. For R(s) ramp ?
2
0 0
1
1
5 5
1 6 7 8 6 7 8
1 336
5 5 0 1 6 7 8
lim lim
.
s s
e t s s
s s
K s K
s s s s s s s
K K
So Κ=672
Steady-State Error-
Simple Design Example
Find Κ so that the steady-state error is 10%
Control System of the Direction of Automotive Robot
1
p
G s K
s
1 2c
G s K K
s
1
c pE s R s
G s G s
1. For R(s) step and Κ
2=0:
0 01 1 1
1 1 1
1 1
lim lim
s s
A
A A
e t s s
K K K K
K K
s s
2. For R(s) step and Κ
2>0:
0 01 2
2 1
0 1 1
1 1
lim lim
s s
A s A
e t s
K s K K
K K
K s s s s
y
1
p
G s K
s
1 2c
G s K K
s
1
c pE s R s
G s G s
3. For R(s) ramp and Κ
2>0:
2
0 0
2 2
1 2
1
11 1
lim lim
s s
A
A A
e t s s
K K s K s K K K K
K s s s
y
Control System of the Direction of
Automotive Robot
1
p
G s K
s
1 2c
G s K K
s
1
c pE s R s
G s G s
3. For R(s) ramp and Κ
2>0:
2
0 0
2 2
1 2
1
11 1
lim lim
s s
A
A A
e t s s
K K s K s K K K K
K s s s
y
Control System of the Direction of
Automotive Robot
1
p
G s K
s
1 2c
G s K K
s
2
e t A
K K
clear all K1=1;
K2=0.5;
Tau=0.1
sys1=tf([Κ1 Κ2],[1 0]);
sys2=tf(K,[tau 1]);
sysh=tf(1,1);
sys3=series(sys1,sys2);
sys4=feedback(sys3,sysh) T=0:0.01:10
U=sin(T);
LSIM(sys4,U,T)
0 1 2 3 4 5 6 7 8 9 10
-1 -0.8 -0.6 -0.4 -0.2 0 0.2 0.4 0.6 0.8
1 Linear Simulation Results
Time (sec)
Amplitude
Control System of the Direction of
Automotive Robot-Use of Matlab
0 05
4 3
3
:
n sT.
s
n s
s
n
T e
T T
1
2
n
T
p
P.O. 100e
1 2
M
pt1 e
1 2
Percent Overshoot is defined as:
P.O. = [(Mpt – fv) / fv] * 100%
Mpt = The peak value of the time response fv = Final value of the response
) 1 sin(
1 )
(
e
t
t
y
nt n1
2 cos
1
Performance of Feedback System in Time
Field
Performance of Feedback System in Time Field
) 1 sin(
1 )
(
e
t
t
y
nt n1
2 cos
1
Oscillation Period:
2
2
n
1
T
Time that the output takes the maximum value :
2
2
2
2
2
1 1 1 0
1
, 0, 1, 2, ...
1
( )
n ntsin
n n ntcos
nn
dy t e t e t
dt
t n n
The first time that the edge appears for n=1:
1
2
n
T
p
2 2 2
2
n
n n
Y s R s
s s
clear all
t=[0:0.1:12];
Num=1;
For zeta=[0.1 0.2 0.5 0.9 1 2];
Den1=[1 2*zeta 1];
Sys=tf(num,den);
[y,tout]=step(sys,t);
plot(tout,y);
Pause(1) hold on;
end
0 2 4 6 8 10 12
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8
ζ
Performance of Feedback System in Time
Field-MATLAB
An example: Reading the Hard-Disc
H(s)=1 R(s)
Κ Y(s),
Rotation Velocity + -
-
5 +
D(s)
1 20
s s
Design: the maximum overshoot <5%, Τs<250, Overshoot in step disturbance <5x10-3
5
25
2 2 2
20 5 20 5 2
n
n n
K K
Y s R s R s R s
s s K s s K s s
1 2
1 1 005 .
M
pte
3 250
s
n
T
1 2
100 e 5
2
n20 10
n
maple( 'solve(100*exp(-10*pi/
(sqrt(5*x))/sqrt(1-100/(5*x)))<5),x' )
An example: Reading the Hard-Disc
H(s)=1
R(s) Κ Y(s),
Rotation Velocity + -
-
5 +
D(s)
120
s s
Design: the maximum overshoot <5%, Τs<250, Overshoot in step disturbance <5x10-3
clear all
t=[0:0.01:1];
K=25;
Num=[5*K];
Den1=[1 20 5*K];
Sys=tf(num,den);
[y,tout]=step(sys,t);
plot(tout,y),grid;
Pause(1) hold on;
end
25
20 5
Y s K R s
s s K
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
0 0.2 0.4 0.6 0.8 1 1.2 1.4
time
y(t)
H(s)=1
R(s) Κ Y(s),
Rotation Velocity + -
-
5 +
D(s)
120
s s
Design: the maximum overshoot <5%, Τs<250, Overshoot in step disturbance <5x10-3
An example: Reading the Hard-Disc
Control of the Insouline injection
2
1 2
2 1 2
1 1
K s
s s K s
Y s R s R s
s s s K s
K s s
What is the value of Κ so that the maximum value of response in a unit step disturbance do not exceed 5x10-3,
Time period of settling 250ms
Pump
Κ Body
H(s)=1
R(s) E(s) Y(s)
Sugar concentration
+ -
insouline
2
p
1 G s s
s s
2
1 2
Y s K s R s
s s K s
What is the value of Κ so that the maximum value of response in unit step disturbance does not exceed 2%, settling time 4ms
clear all
t=[0:0.1:12];
Num=[K 2K];
Den1=[1 (1+K) 2*K];
Sys=tf(num,den);
[y,tout]=step(sys,t);
plot(tout,y);
2
2 2 2
n
n n
a s a
Y s R s
s s
Control of the Insouline injection
Pump
Κ Body
H(s)=1
R(s) E(s) Y(s)
Sugar concentration + -
insouline
2
p 1 G s s
s s
Integral Indices of Performance – Optimal Design
1. Integral of the absolute value of the error (IAE)
0
IAE e t dt
e(t) denotes the difference between set point and output
• Criteria that optimize the closed loop response of set-point changes or disturbances.
• The optimal values of the control parameters minimize the integral criteria
• The 3 most used criteria are the following:
2. Integral of the squared error (ISE)
20
ISE e t dt
3. Integral of the time-weighted absolute error (ITAE)
0
ITAE t e t dt
Integral Indices of Performance – Optimal Design
• Criteria that optimize the closed loop response of set-point changes or disturbances.
• The optimal values of the control parameters minimize the integral criteria
• The 3 most used criteria are the following:
H(s)=1 R(s)
Κ Y(s), bank angle
+ -
s 1010 s s 12 2
Activation of the Wind Slope (BANK)
Plane Dynamics
Gyroscope Gain
Integral Indices of Performance –
Optimal Design-Matlab
Aim: Optimization of the closed loop response in a step change with IAE criterion
clear all kiter=0;
for K=0.1:0.001:2;
sys1=tf(K,1);
sys2=tf(10,[1 10]);
sys3=tf(12, [1 2 0]);
sys12=series(sys1,sys2);
sysopen=series(sys12,sys3);
sysclosed=feedback(sysopen,1);
%H=get(sysclosed);
y=step(sysclosed);
kiter=kiter+1;
Ksave(kiter)=K;
e(kiter)=sum(abs(y-1));
[K e(kiter)]
end
plot(Ksave,e)
Integral Indices of Performance – Optimal Design-Matlab
H(s)=1
R(s) Κ Y(s), bank angle
+ -
12 2 s s
s1010
Activation of the Wind Slope
Plane Dynamics
Gyroscope Gain
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8 2 0
100 200 300 400 500 600
0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1
10 11 12 13 14 15 16 17 18 19 20
0 1 2 3 4 5 6 7
0 0.2 0.4 0.6 0.8 1 1.2
1.4 Step Response
Time (sec)
Amplitude
0 10 20 30 40 50 60 70 80 90 100
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8
2 Step Response
Time (sec)
Amplitude
0 50 100 150 200 250
0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8
2 Step Response
Time (sec)
Amplitude
Integral Indices of Performance – Optimal Design-Matlab
Aim: Optimization of the closed loop response in a step change with IAE criterion
Y s(s)
C(s) U(s)
Y sp (s)
G c(s) Y(s)
D(s)
G a(s) G p(s)
G s(s)
G d (s)
+ -
E(s)+ +
Feedback Control loop
1 )
( )
( )
( )
(
) ( )
( )
( )
( ) (
s G
s G
s G
s G
s G
s G
s G
s Y
s Y
s c
a p
c a
p sp
1 )
( )
( )
( )
(
) ( )
( ) (
s G
s G
s G
s G
s G
s D
s Y
s c
a p
d
Characteristic Equation
1 0 ( ) ( ) ( ) ( )
p a c s
G s G s G s G s
The transient response of the system is determined from the place of poles which are the roots of the characteristic equation
A state of a system is stable if bounded inputs result to bounded outputs
The complex s-plane seperates in two regions: one stable whchcorresponds to the left semi-plane and the unstable region which corresponds to the right semi-plane
s-plane
stable unstable
x x
x
x x
x
x
j
x x
Poles and Stability
Re Im
Time
y
Re Im
Time
y
Re Im
Time
y