Sunteți pe pagina 1din 55

CHE517

Advanced
Process Control
Prof. Shi-Shang Jang
Chemical Engineering Department
National Tsing-Hua University
Hsin Chu, Taiwan
Course Description
Course: CHE517 Advanced Process Control
Instructor: Professor Shi-Shang Jang
Text: Seborg, D.E., Process Dynamics and
Control, 2nd Ed., Wiley, USA, 2003.
Course Objective: To study the application of
advanced control methods to chemical and
electronic manufacturing processes
Course Policies: One Exam(40%), a final
project (30%) and biweekly homework(30%)
Course Outline
1. Review of Feedback Control System
2. Dynamic Simulation Using MATLAB
and Simu-link
3. Feedforward Control and Cascade
Control
4. Selective Control System
5. Time Delay Compensation
6. Multivariable Control

Course Outline - Continued
7. Computer Process Control
8. Model Predictive Control
9. R2R Process Control


Chapter 1 Review of
Feedback Control Systems
Feedback Control
Terminology
Modeling
Transfer Functions
P, PI, PID Controllers
Block Diagram Analysis
Stability
Frequency Response
Stability in Frequency Domain
Feedback Control
Examples:
Room temperature control
Automatic cruise control
Steering an automobile
Supply and demand of chemical engineers
Controller
Transmitter
Set point
stream
Temp
sensor
Heat loss
condensate
Feedback Control-block
diagram
Terminology:
Set point
Manipulated variable (MV)
Controlled variable (CV)
Disturbance or load (DV)
Process
controller
Controller process
Sensor +
transmitter
+
- Set point
Measured value
error
Manipulated
variable
Controlled variable
disturbance
Instrumentation














Signal Transmission: Pneumatic 3-15psig, safe longer time lags, reliable
Electronic 4-20mA, current, fast, easy to interface with computers, may
be sensitive to magnetic and/or electric fields
Transducers: to transform the signals between two types of signals, I/P:
current to pneumatic, P/I, pneumatic to current
Controller
Transmitter
Set point
stream
Temp
sensor
Heat loss
condensate
Modeling
Rate of accumulation = Input output + generation
consumption


At steady state : let T = T
S
and Q = Q
S
0 = Q
S
UA(T
S
- T
0S
)
Deviation variables : let T = T
S
+T
d
, Q = Q
S
+Q
d
, T0 = T
0s
+T
0d
Then :

If system is at steady state initially T
d
(0) = 0
) ( ) (
0
T T UA Q T MC
dt
d
P
=
Mass M
Cp
T
Q
Q=UA(T-T
0
)
) ( ) (
0d d d d P
T T UA Q T
dt
d
MC =
Transfer Functions
Laplace Transforming:
M C
p
S T
d
(S) = q
d
(S) - U A (T
d
(S) T
od
(S))
Or

( )
( ) ( )
UA SMC
S UAT
UA SMC
S q
S T
p
od
p
d
d
+
+
+
=
UA MsC
UA
p
+
UA MsC
p
+
1

T
d
(S)
+
+
q
d
(S)
T
od
(S)
Non-isothermal CSTR
Total mass balance:

Mass balance :

Energy balance :

Initial conditions : V(t=0) = V
i
, T(t=0) = T
i
, C
A
(t=0) =
C
Ai

Input variables : F
0
, C
A0
, T
0
,F
F F V
dt
d
=
0
) (
condensate
T V C
A
C
B
F
0

0
C
A0
T
0
F


C
A
T

steam
A B
r
A
= - KC
A
mol/ft
3
K = e
-E/RT
V KC C F C F C V
dt
d
A A A A
) ( ) (
0 0
=
) ( ) )( ( ) (
0 0
T Ts UA KC Hr T C F T C F T C V
dt
d
A P P P
+ A + =
Linearization of a Function

X
0
X
0
- X
0
+
- 0
F(X)
X
aX+b
Linearization
( ) ( ) ( )
( ) ( ) ( )
( )
0 0
0 0
0 0
0 0
,
( , )
0
Laplace Transform
( )
1
x x x x
u u u u
d
d d
d d d
d
d
dx f f
f x u x x u u
dt x u
f x u
dx
ax bu
dt
sx s ax s bu s
or
x s b K
u s s a s t
= =
= =
c c
= ~ +
c c
+
= + +
= +
= =
+
Linearization of Non-
isothermal CSTR
12
12
11 0,
,
21 22 , 11 0,
31 32 , 33 31 0, 32 , 33
11 12
, 21 22 , 21 22 23
31 32 33 31 32 3
. .
0 0 0 0
0
d
d d
A d
d A d d d
d
d A d d d A d d
d d
A d A d
d d
dV
b F b F
dt
dC
a V a C b F b F
dt
dT
a V a C a T b F b C b Ts
dt
i e
V V b b
d
C a a C b b b
dt
T a a a T b b b
= +
= + + +
= + + + + +
( ( (
( ( (
= +
( ( (
( ( (

| | | |
( )
{ }
( ) ( ) ( ) ( ) ( )
0,
3 ,
0,
,
,
1
0,
( ) ( )
0 0 1 0 0 0
( ) ( )
( ) '
d
d
s d
d d
A d d
d s d
d
p d L d L d
F
F AX s BU s
T
V F
y C F CX DU
T T
T s C sI A B D U s
G s Ts s G s F s G s F s

(
(
(
(
= +
(
(
(
(


(
(
(
(
= + = +
(
(
(
(


( = +

= + +
Common Transfer Functions
K=Gain; =time constant;
=damping factor; D=delay
First Order System

Second Order System

First Order Plus Time Delay

Second Order Plus Time Delay

( ) 1
) (
+
=
s
K
s MV
s CV
t
( )
Ds
e
s s
K
s MV
s CV

+ +
=
1 2
) (
2 2
t, t
( )
Ds
e
s
K
s MV
s CV

+
=
1
) (
t
( ) 1 2
) (
2 2
+ +
=
s s
K
s MV
s CV
t, t
Transfer Functions of
Controllers
Proportional Control (P)
Proportional Integral Control (PI)
Proportional-Integral-Derivative Control (PID)
m(s) = K
c
[ e(s) ]
e = T
spt
- T
K
c

e(s) m(s)
(

t
+ =
}
t
0
I
c
dt ) t ( e
1
) t ( e K ) t ( m
(

t
+ = ) s ( e
s
1
) s ( e K ) s ( m
I
c
e(s) m(s)
)
s
1
1 ( K
I
c
t
+
e(s) m(s)
) s
s
1
1 ( K
D
I
c
t +
t
+
(

t +
t
+ =
}
t
0
D
I
c
dt
de
dt ) t ( e
1
) t ( e K ) t ( m
| |
(

t +
t
+ = s
s
1
1 ) s ( e K ) s ( m
D
I
c
The Stability of a Linear
System
Given a linear system y(s)/u(s)=
G(s)=N(s)/D(s) where N, D are
polynomials
A linear system is stable if and only if
all the roots of D(s) is at LHS, i.e.,
the real parts of the roots of D(s) are
negative.


Stability in a Complex Plane
Re
Im
Purdy oscillatory
Purdy oscillatory
Fast Decay
Slow Decay
Exponential Decay
Exponential Decay
with oscillatory
Slow growth
Fast Exponential
growth
Exponential growth
with oscillatory
Stable (LHP)
Unstable (RHP)
Partial Proof of the Theory
For example: y(s)/u(s)=K/(s+1)
The root of D(s)=-1/
In time domain: y+y=ku(t)
The solution of this ODE can be
derived by y(t)=e
-t/
[e
1/
ku(t)dt+c]
It is clear that if <0, limt

y .

Transfer functions in parallel
X(S)= G
1
(S)*U
1
(S) + G
2
(S)*U
2
(S)

U
1
(S)
U
2
(S)
G
1
(S)
G
2
(S)
X
1
(S)
X
2
(S)
+
+
X

(S)
X
1
(S) X
2
(S)

Transfer function Block
diagram

Kc
+
-
T
set
control
Q
S
process
1

Measuring device
T
d
UA S MC
P
+
1
UA S MC
K
UA S MC
K
T
T
P
C
P
C
set
d
+
+
+
=
1
1
1
Proportional control
No measurement lags
Block Diagram Analysis
e = X
s
X
m

m = G
c
(S) e(s) = G
c
e
X
1
= G
p
m = G
p
G
c
e
X = G
L
L + X
1
= G
L
L + G
p
G
c
e
X
m
= G
m
X = G
m
G
L
L + G
p
G
c
e
X = G
L
L + G
p
G
c
[X
s
X
m
]
= G
L
L + G
p
G
c
[X
s
] G
p
G
c
[X
m
]
=G
L
L + G
p
G
c
X
s
G
p
G
c
G
m
X
s
m c p
c p
m c p
L
X
G G G 1
G G
L
G G G 1
G
X
+
+
+
=

X(S)
+
+
G
L
(S)
G
P
(S)
G
m
(S)
L(S)
m
G
c
(S)

+
-
X
s
X
m
X
1
e

Stability of a Closed Loop
System
A closed loop system is stable if and
only of the roots of its characteristic
equation :

1+G
c
(s)G
p
(s)G
m
(s)=0

are all in LHP
Level System
( ) ( )
( ) ( )
( )
( ) ( ) 1 1 /
/ 1 1
Laplacing
2
, point reference a Given
.
,
0
, 0 0
0 0
+
=
+
=
+
=
= +
=
c
c
+
c
c
~
= =
s
K
s a A
a
a As s F
s h
or
s F s ah (s) Ash
h
h
k
F h h
h
f
F F
F
f
dt
dh
A
h F
h k F F F
dt
dh
A
d in
d
d in d d
d d in in in
in
d
in
in out in
t
The jacketed CSTR
TRC
FC
T
c

T, C
a

W
Set Point
W
c

2A B
A Nonisothermal Jacketed CSTR
(i) Material balance of species A



(ii) Energy balance of the jacket



(iii) Energy balance for the reactor



(iv) Dependence of the rate constant on
temperature
2
) (
A
A A
A
kC
V
C C W
dt
dC
f

=
|
P
A
P
c
f
C
HkC
V C
T T A
V
T T W
dt
dT
|
A
|
o
|
2
) (
) (

=
c
w c c
P c
c c
M
T T W
C M
T T A
dt
dT ) (
'
) (

=
o
)
273
exp(
0
+
=
T
Q
A k
Linearization of
Nonisothermal CSTR
CV=T(t)
MV=W
c
(t)
It can be shown that

( )
( ) 1
2 3
,
+ + +
=
cs bs as
K
s W
s T
d c
d
A Practical Example Temperature
Control of a CSTR
Method of Reaction Curve


D
Dead time
Maximum slope
C
Process
output
Time constant
time
Ziegler-Nichols Reaction Curve
Tuning Rule
P only PI PID
Kc t/DKp 0.9t/DK
p
1.2t/DK
p
t
I
n.a. D/0.3 D/0.5
t
D
n.a. n.a. 0.5D
C

D
m
D= 1
=13
k = -0.0202
Kc= -579.2079

i
=3.33

setpoint
Ziegler-Nichols Ultimate Gain
Tuning
Find the ultimate gain of the process
Ku. The period of the oscillation is
called ultimate period Pu
P only PI PID
Kc Ku/2 Ku/2.2 Ku/1.7
t
I
n.a. Pu/1.2 Pu/2
t
D
n.a. n.a. Pu/8
Measuring Controller
Performance
( ) ( )
( ) ( ) ( ) ( )
( )
} }
} }
} }



= =
= =
= =
0 0
0
2
0
2
0 0
dt t e t dt y y t ITAE
dt t e dt t y y ISE
dt t e dt t y y IAE
s
s
s
Upper Limit of Designed
Controller Parameters of
PID Controllers
Q: Given a plant with a transfer
function G(s), one implements a PID
controller for closed loop control,
what is the upper limit of its
parameters?
A: The upper limit of a controller
should be bounded at its closed loop
stability.
Approaches
Direct Substitution for Kc
Root Locus method for Kc
Frequency Analysis for all
parameters
An Example
) 3 )( 2 )( 1 (
1
+ + + s s s
K
c




1. Stability Limit by Direct
Substitution
At the stability limit (maximum value of Kc
permissible), roots cross over to the RHP.
Hence when Kc=Ku, there are two roots
on the imaginary axis s=i
(s+1)(s+2)(s+3)+Ku=0, and set s= i,
we have (i+1)(i+2)(i+3)+Ku= 0, i.e.
(6+Ku-6
2
)+i(11-
3
)=0. This can be
true only if both real and imaginary parts
vanishes: 11-
3
=0 =
11
;
6+Ku-611=0 Ku=60

2. Method of Root Locus
Rlocus (sys,k)
k(12) ans =69.6706
3. Frequency Domain
Analysis
Definitions: Given a transfer function
G(s)=y(s)/x(s); Given x(t)=Asint;
we have y(t) Bsin(t+)
We denote Amplitude Ratio=AR()
=B/A; Phase Angle=()
Both AR and are function of
frequency ; we hence define AR
and is the frequency response of
system G(s)


An Example
( )( )( ) 3 2 1
1
+ + + s s s
A sin(et) B = sin(et+|)
Frequency Response of a
first order system
( )
et |
t e
et | | e
t e
t e
e
e
t
1
2 2
1
2 2
2 2
2 2
tan
1
tan ); sin(
1
) (
1
) (
) ( sin ) ( ;
1
) (
) (
) (

=
+
=
= +
+

+ +
=
+
= =
+
= =
K
AR
t
KA
t y
s
K
s
A
s y
s
A
s x t A t x
s
K
s G
s x
s y
Basic Theorem
Given a process with transfer function
G(s);
AR()=G(i)
()= G(i)
Basically, G(i)=a+ib

( ) a b
b a AR
/ tan
1
2 2

=
+ =
|
Example: First Order
System
( )
( )

90 lim
0 lim
that Note
tan tan
1
1
1
) (
1
1
1
) ( 1
1
1
1
1
) (
1 1
2 2
2 2
2 2 2 2 2 2
=
=
=
|
.
|

\
|
=
+
= + =
+ =
+

+
+
=
+

=
+
=
+
=



|
te |
e t
e t
te
e t e t
te
e t
e
t
e
e
AR
a
b
b a AR
ib a i
i
i
i G
s
s G
Corollary
If G(s)=G
1
(s)G
2
(s)G
3
(s)
Then AR(G)=AR(G
1
) AR(G
2
) AR(G
3
)
(G)= (G
1
) + (G
2
)+ (G
3
)

Proof: Omitted

Example
( ) ( )
( ) ( )
( ) ( )
( ) ( )
2
1
1
1
2 1
2
2
2
2
2
2
1
1
2 1
2 1
2
2
1
1
tan tan
1 1
1 1
) (
et et | | |
e t e t
e t e t

= + =
+ +
= =
=
+ +
=
K K
AR AR AR
s G s G
K K
s G
Bode Plot: An example
G(s)=1/(s+1)(s+2)(s+3)
where db=20log
10
(AR)

Nyquist Plot
sys=tf(num,den)
NYQUIST(sys,{wmin,wmax}))

Nyquist Stability Criteria
Given G(i), assume that at a
frequency
u
, such that =-180 and
one has AR(
u
), the sufficient and
necessary condition of the stability of
the closed loop of G(s) is such that:
AR(
u
) 1
The Extension of Nyquist
Stability Criteria
Given plant open loop transfer
function G(s), such that at a
frequency
u
, the phase angle
(
u
)=-180. At that point, the
amplitude ratio AR=G (
u
) , then
the ultimate gain of the closed loop
system is Ku=1/AR, ultimate period
Pu=2/
u
.
Simulink Example
time
R
e
s
p
o
n
s
e

D~1.4 t~3.7-1.4=2.3
s
P
e
s
G
5 . 0
1 5 . 2
165 . 0

+
~
Simulink Example -
Continued
>> sys=tf(1,[1 6 11 6])

Transfer function:
1
----------------------
s^3 + 6 s^2 + 11 s + 6

>> bode(sys)
e
u
=3.5
AR
u
=-38db
=10
-38/20
=0.0162
K
u
=1/AR
u
=80
Simulink Example -
Continued
1. Reaction Curve Approach:
K
C
=1.2t/DKp=1.2*2.5/(0.5*0.165)=36;
t
I
=D/0.5=1;t
D
=D*0.5=0.25
0 1 2 3 4 5 6 7 8 9 10
0
0.2
0.4
0.6
0.8
1
1.2
1.4
1.6
1.8
2
Simulink Example -
Continued
1. Ultimate properties Approach:
Ku/1.7=80/1.7=47;t
I
=Pu/2= 2*t / 2e
U
=0.9;t
D
=Pu/8=0.22

S-ar putea să vă placă și