Dissertation Final Report
Dissertation Final Report
Dissertation Final Report
OF A DRUM BOILER
A Thesis Report
Submitted in partial fulfilment of the requirements of the degree of
MASTER OF ENGINEERING
By
DIPANKAR KALITA
(2012H132143P)
Under the supervision of
Dr. HARE KRISHNA MOHANTA
(Assistant Professor)
CERTIFICATE
1
This is to certify that the Dissertation work entitled Modeling, Simulation and
Control of a Drum Boiler by Dipankar Kalita (ID - 2012H132143P) in partial
fulfillment of requirement of BITS G629T Dissertation is a bonafide research work
carried by him under my supervision and guidance.
Date:
Pilani.
Assistant Professor
ACKNOWLEDGEMENTS
I would like to take this opportunity to respectfully acknowledge the guidance and
support given by Dr. Hare Krishna Mohanta throughout this project work. I express my
sincere thanks and deep sense of gratitude for his valuable mentorship and
encouragement at every stage of this Dissertation work. Whenever I have approached him
to discuss ideas for my project or any problem, I have always found an eager listener.
I would like to express my gratitude to Mr. Ajaya Kumar Pani without whom this
project work would not have been completed within the time frame. With his deep insight
and knowledge in the field of process control, he has always been a constant support
throughout this work.
My thanks also goes to all my other batch mates who have made the atmosphere in my
classes lively and interesting. Last, but most importantly, Im grateful to my family for
their love, blessings and support throughout this endeavour.
ABSTRACT
Since boilers are so common there are many modelling efforts. There are complicated
models in the form of large simulation codes which are based on finite element
approximations to partial differential equations. Although such models are important for
plant design, simulators, and commissioning, they are of little interest for control design
because of their complexity.
The objective of this work is to obtain a simplified nonlinear dynamic model for natural
circulation drum-boiler system which can be used for control. The model should describe
the complicated dynamics of the drum, downcomer, and riser components. It is to be
derived from first principles, and is to be characterized by a few physical parameters.
The model should be validated using the available plant data.
This project involves modelling, simulation and control of a drum-boiler system using
MATLAB and SIMULINK. For efficient control of the process various advanced
controllers such as ANN- and Fuzzy Logic based controllers have been used along with
the traditional PID controllers.
TABLE OF CONTENTS
ACKNOWLEDGEMENTS
(i)
ABSTRACT (ii)
1
Introduction 1
2.2
2.3
2.4
2.5
The Model
10
2.6
Summary
13
2.7
13
2.8
The solution14
2.9
Step response..14
Control schemes
3.1
3.2
Tuning methods
19
20
18
3.3
18
PID Controllers
3.1.1
31
PID Controller32
5
23
4.1
4.1.1
Regulatory Problem 32
4.1.1
Servo Problem
35
37
4.1.1
Regulatory Problem 38
4.1.1
Servo Problem
40
Conclusions 42
References
43
44
47
Chapter - 1
Introduction
There are dramatic changes in the power industry because of deregulation. One
consequence of this is that the demands for rapid changes in power generation is
increasing. This leads to more stringent requirements on the control systems for the
processes. It is required to keep the processes operating well for large changes in the
operating conditions. One way to achieve this is to incorporate more process knowledge
into the systems. The goal is to develop moderately complex nonlinear models that
capture the key dynamical properties over a wide operating range. The models are based
on physical principles and have a small number of parameters; most of which are
determined from construction data. Particular attention has been devoted to model drum
level dynamics well. Drum level control is an important problem for nuclear as well as
conventional plants. In Parry, Petetrot and Vivien (1995) it is stated that about 30% of the
emergency shutdowns in French PWR plants are caused by poor level control of the
steam water level. One reason is that the control problem is difficult because of the
complicated shrink and swell dynamics. This creates a nonminimum phase behaviour
which changes significantly with the operating conditions. Since boilers are so common
there are many modelling efforts. There are complicated models in the form of large
simulation codes which are based on finite element approximations to partial differential
equations. Although such models are important for plant design, simulators, and
commissioning, they are of little interest for control design because of their complexity.
The model presented here is adapted from K.J Astrom and R.D. Bell (1998). A nonlinear
dynamic model for natural circulation drum-boilers is adapted. The model describes the
complicated dynamics of the drum, downcomer, and riser components. It is derived from
first principles, and is characterized by a few physical parameters. A strong effort has
been made to strike a balance between fidelity and simplicity. Since the model is derived
from first principles it can describe the system for a wide operating range.
Simulation of the model is done using MATLAB R2010a and results have been verified
with plant data presented in K.J Astrom and R.D. Bell (1998). The conventional PID
controller is applied when the boiler is operating at medium load for both servo and
regulatory problems. Advanced controllers such as Fuzzy logic controllers(FLC) and
Neural Network(NN) predictive controllers have been also tried with satisfactory results.
The details of these controllers are discussed in the report within.
The drum boiler is a simple boiler which consist of a drum, downcomer and riser
components. A simple schematic of the drum boiler have been shown in Figure 1. The
heat Q, supplied to the risers causes boiling. Gravity forces the saturated steam to rise
causing a circulation in the riser-drum-downcomer loop. Feedwater q f , is supplied to the
drum and saturated steam, qs, is taken from the drum to the superheaters and turbine. The
presence of steam below the liquid level in the drum causes the shrink-and-swell
phenomenon which makes level control difficult. In reality the system is much more
complicated than shown in the figure. The system has a complicated geometry and there
are many downcomer and riser tubes. The outflow from the risers passes through a
separator to separate the steam from the water. In spite of the complexity of the system it
turns out that its gross behaviour is well captured by global mass and energy balances.
10
Chapter - 2
Modeling and Simulation
2.1 Global mass and energy balance equations
The global mass balance equation is
Rate of accumulation of mass in the system = Rate input of mass Rate output of mass.
d
[ V + V ]=q f q s .(1)
dt S st W wt
where
S= density of saturated steam (kg/m3)
Vst= total volume of steam in the boiler system (m3)
W= density of saturated water (kg/m3)
Vwt= total volume of water in the boiler system (m3)
qf= feed flowrate (kg/s)
qs=steam flowrate(kg/s)
The global energy balance is
Rate of accumulation of energy in the system = Rate input of energy Rate output of
energy.
d
[ u V + u V +m C t ]=Q+ qf h f q s h s ..(2)
dt S s st W w wt t p m
us= specific internal energy of steam (J/kg).
uw= specific internal energy of saturated water (J/kg).
mt= total mass of metal tubes and the drum.(kg)
Cp= specific heat of metal (J/kg 0C)
tm= temperature of the metal (oC)
Q= heat supplied to the risers (W)
hf= specific enthalpy of feedwater (J/kg)
hs= specific enthalpy of steam (J/kg)
11
d
p
p
S h s V st S V st + W hw V wt W
V +m C t =Q+ qf h f q s h s
.
dt
S
W wt t p m
d
[ h V + h V pV wt pV st +mt C p t m ]=Q+q f h f qs h s .
dt S s st W w wt
d
[ h V + h V pV t +mt C p t m ]=Q+q f h f qs h s .(3)
dt S s st W w wt
The total volume of the drum, downcomer and riser is
V t =V st +V wt .(4)
Equation (1), (3) and (4) combined with saturated steam tables yields a simple boiler
model. We will however make manipulations of the model to obtain a state model. There
are many possible choices of state variables. Since all parts are in thermal equilibrium it
is natural to choose drum pressure ,p as one state variable. This variable is also easy to
measure. Using saturated steam tables, the variables S , W , hS and hW can be expressed
as functions of steam pressure. The second state variable can be chosen as the total
volume of water in the system VWt. Using equation (4) VSt can be eliminated and replaced
by VWt.
Equation (1) can be written as
d
[ V + V ]=q f q s .
dt S st W wt
d
d (V V wt )
d
W V wt ]+V st S + s
=q f q s .
[
dt
dt
dt
d V wt
d
d
d
V wt ]s
+V wt w +V st S =q f q s .
[
dt
dt
dt
dt
12
d w
d dp
d
( W s ) [ V wt ] +(V wt
+V st S ) =q f q s .
dt
dp
dp dt
e 11
d
dp
V wt ] +e 12 =q f q s .
[
dt
dt
d
d
d
d
d
d
d
d
V wt S h s V wt +h s V st S+ V st S hs +h w V wt W +V wt W h w p V t + mt C p t s =Q+
dt
dt
dt
dt
dt
dt
dt
dt
h
( s V st
d
d
d
d
d
S +V st S
hs +h w V wt
W +V wt W
hw V t + mt C p t s ) dp =Q+ qf h f q s h s
dp
dp
dp
dp
dp dt
d V wt
( W hw S h s)
+
dt
.
e 21
d V wt
dp
+e 22 =Q+q f h f q s hs .
dt
dt
So
e 11
d
dp
[ V ] +e 12 dt =q f q s .
dt wt
(5)
e 21
d V wt
dp
+e 22 =Q+q f h f q s hs .
dt
dt
Where
13
( W s ) .
e11 =
e 12
d w
d S
= (V wt dp + V st dp )
(6)
W
h
(
w S h s)
.
e 21=
e 22=hs V st
d
d
d
d
d
S +V st S hs + hw V wt
W +V wt W
hw V t +mt C p t s .
dp
dp
dp
dp
dp
and
hs
hw
d S
d w
d
h
,
,
dp s
dp
dp
d
t
dp s . The results are based on approximations of steam tables
14
s
=7.673+0.36 ( p10 ) .
p
w
=18.6720.0603 ( p10 ) .
p
ts
=8.5230.33 ( p10 ) .
p
The condensation flow rate is given by a simple energy balance done within the system
q ct hc + ( h f hw ) q f = s V st
where
hc =hshw
dh s
dh
dt
dp
+ w V wt w + mt C p s V t
dt
dt
dt
dt .
s V st
dhs
dh
dt
+ w V wt w +mt C p s
dt
dt
dt
accounts for the thermal energy change within the system and the term
Vt
dp
dt
accounts
for the pressure energy change within the system. The negative sign appears before
Vt
dp
dt since condensation is taking place.
The term on the right hand side accounts for the physical changes taking place within the
system due to total change in stored energy within the system.
So it can be rewritten as
s V st
dhs
dh
dt
dp
+ w V wt w +mt C p s V t
dt
dt
dt
dt
)..(8)
1
1
qct = ( hw h f ) q f +
hc
hc
tube, V the volume, h the specific enthalpy, and Q the heat supplied to the tube. All
quantities are distributed in time, t and space, z. Assume for simplicity that all quantities
are same in a cross-section of the tube.
The mass balance for heated section of tube can be derived from the mass continuity
equation. The continuity equation can be stated as
u v w
+
+
+ =0 .
x y
z t
u,v and z are velocity in x,y and z directions respectively. Since mass is only entering and
leaving in z- direction. So we have
w
+ =0 .
z t
( Aw)
+ =0 .
A z
t
q
+A
=0 .(9)
z
t
The energy balance can be derived as follows. Let us consider a infinitesimally small
block of cube through which the fluid is flowing. The cube is a control volume. We will
do the energy balance around this cube. The cube has three coordinates x, y and z. So
Energy flow into the cube- Energy flow out of the cube= Rate of change of energy
Energy flow into the cube=
16
dh
dxd
dt
dh
.
dt
( x +dx ux +dx h/dx )( y+dy u y+dy h/dy )
( x u x h/dx )+( y u y h/dy)+( z u z h/dz )+(Q/dxdydz )
( z+ dz u z +dz h /dz )=
uh vh wh Q h
+ =
x
y
z
V
t .
wh h Q
=
z
t V .
wh h Q
+
=
z
t V .
qh h Q
+
=
A z t V (10)
The specific internal energy of mixture of steam and water is
h= m h s+ ( 1 m ) hw =hw + m hc .(11)
Where
denotes the mass fraction of steam in the flow i.e. the quality of the mixture.
qh
QA
=q hc m =
z
z
V ..from (10) and (11).
So
m=
QA
z
.
q hc V
m ( )= r
f ( m)
The volume and mass fraction of steam are related through
where
v =
m
s
f ( m ) =
m
1 m
+
s
w
( )(
f ( m ) =
w m
s +( w s ) m . .(13)
To model drum level it is essential to describe the total amount of steam in the risers. This
is governed by the average volume fraction in the risers.
1
w
s
( ws ) r
1
V = V ( ) d= f ( m ) d=
(1
ln 1+
)
r 0
w s
s
( w s ) r
0
..(14)
2.3 Mass and energy balance for the riser section
The global mass balance for riser section is
1
( V )V r
S V V r + w =qdc q r (15)
d
dt
Where Vr = volume of the riser(m3).
qdc =flow rate in the downcomer section(kg/s)
qr=flow rate in the riser section(kg/s).
The global energy balance for the riser section is
18
( V )V r + mr C p t s
S u s V V r + w uw =Q+ qdc hw ( 1 r ) qr h w r qr h s .
d
dt
1
(V ) V r +m r C p t s
S u s V V r + w uw =Q+ qdc hw q r hw + r q r hw r q r hs .
d
dt
( V ) V r +mr C p t s
S u s V V r + w uw =Q+ qdc hw ( r hc + hw )q r .
d
dt
u=h
p
.
1
p
( V )V r + m r C p t s
s
( V )V r =Q+ q dc hw ( r hc + hw )q r .
p
S h s V V r s V r + w hw
s V
d
dt
s
( V )V r p V r +mr C p t s
S u s V V r + w uw =Q+ qdc hw ( r hc + hw )q r .(16)
d
dt
Circulation flow
The momentum balance for the downcomer riser loop is
19
2
d q dc
k qdc
( Lr + Ldc ) dt =( ws ) v V r g 2 A .
w
dc
Where Lr and Ldc are the length of riser and downcomer respectively, k is a dimensionless
friction coefficient and Adc is the area of the downcomer.
This is a first order system with time constant
T=
2 w Adc ( Lr + Ldc )
.
k qdc
With typical numerical values we find that the time constant is about a second. This is
short in comparison with the sampling period of the experimental data and we will
therefore use steady state relation.
1 2
k q = A ( ) g v V r .
2 dc w dc w s
q dc= 2 w A dc ( w s ) g v V r /k .(17)
2.4 Distribution of steam in the drum
Vsd volume of steam under liquid level
Vwd volume of water under liquid level
qsd steam flowrate under the liquid surface
qcd - condensation of steam below the liquid level
The mass balance for steam under the liquid level is
d
( V ) = r qr q sdq cd .(18)
dt s sd
qcd can be given by (8)
q cd =
dh
dh
dt
1
1
dp
hw hf ) q f + ( s V st s + w V wt w +md C p s (V sd +V wd ) )
(
hc
hc
dt
dt
dt
dt
..(19)
Flow qsd is driven by the density differences of water and steam, and momentum of flow
entering the drum.
Good fit to the experimental data have been obtained with the following empirical model.
20
q sd=
s
( V V sd 0 )+ r qdc + r (q dc qr ) .(20)
T d sd
Here Vsd0 denotes volume of steam in the drum in the hypothetical situation where there is
no condensation of steam in the drum and Td is the residence time of steam in the drum.
Drum level
The volume of water in the drum is
V wd =V wt V dc (1 v )V r .(21)
The deviation of the drum level l from normal operating level is
l=
V wd + V sd
=l w +l s (22)
Ad
The term lw represents level variations due to change in water in the drum and ls
represents level variations caused by steam in the drum.
2.5 The Model
Selection of state variables
The accumulation of water is represented by the total water volume Vwt. The total energy
is represented by drum pressure p and the distribution of steam and water is captured by
the steam mass fraction in the risers r and the steam volume in the drum Vsd.
Pressure and water dynamics.
These equations are represented by equation (5).
Riser dynamics
Eliminating the flow rate out of the risers, q r , by multiplying eq(13) by (h w + rhc) and
adding to eq (14) gives
( hw + r hc )
d
d
d
d
d
d
s V V r ) ( h w + r h c ) ( w ( 1 V ) V r ) + ( s h s V V r ) + ( w h w ( 1 V ) V r ) p V r +
(
dt
dt
dt
dt
dt
d
( hw + r hc )
d
d
d
d
d
d
s V V r ) ( h w + r h c ) ( w ( 1 V ) V r ) + ( s h s V V r ) + ( w h w ( 1 V ) V r ) p V r +
(
dt
dt
dt
dt
dt
d
21
( hw + r hc )
d
d
d
d
d
d
s V V r ) ( h w + r h c ) ( w ( 1 V ) V r ) + ( s h s V V r ) + ( w h w ( 1 V ) V r ) p V r +
(
dt
dt
dt
dt
dt
d
.
d
d
d
d
d
( h V ) ( hw + r hc ) dt ( s V V r )+ dt ( w hw ( 1 V ) V r ) ( h w+ r h c ) dt ( w ( 1 V ) V r )V r dt p+mr
dt s s V r
.
hc ( 1 r )
dh
dh
d
d
dp
d
s v V r ) + w ( 1 v ) V r w r h c ( w ( 1 V ) V r ) + s V V r s V r +mr C p t s=Q+
(
dt
dt
dt
dt
dt
dt
[(
hw
h
V
d
r hc w ( 1 V ) V r + ( 1 r ) hc s + s s V V r + ( s+ ( w s ) r ) hc V r
V t +mr C p
p
p
p
p
p
d
.
e 32
dr
dp
+ e33
=Q+q dc hc r .(23)
dt
dt
Where
[(
e 32= w
hw
h
r hc w ( 1 V ) V r + ( 1 r ) hc s + s s V V r + ( s + ( w s ) r ) hc V r V V t + mr
p
p
p
p
p
.
e 33=( ( 1 r ) s + r w ) hc V r
V
r .
If the state variables p and r are known the riser flow rate q r can be computed from
eq(13).
1
( V )V r
S V V r + w .
d
qr =q dc
dt
22
1
( V )
S V + w
.
d
q r=q dc V r
dt
1
( V )
S V + w
.
d
q r=q dc V r
dt
q r=q dc V r
d
( ( ))
dt w V w S .
1
( V )
d r
dp
+ V r ( w S ) V
dt
r dt ..(24)
q r=qdc V r
S V + w
Drum Dynamics
The dynamics for the steam in the drum is obtained from the mass balance (18).
Introducing (24) for qr , (19) for qcd and (20) for qsd we get
1
( V )
d r
dp
+V r ( w S ) V
dt
r dt
dh
dh
d
1
1
q dcV r
() s ( V sd V sd 0 ) + r q dc + r (q dcqr ) ( hw h f ) q f + (s V st s + w V wt w +md C p
p
Td
hc
hc
dt
dt
d
d
( V )= r
dt s sd
S V + w
23
( V )+ S V
s
h h
V sd V sd 0 )+ f w q f
(
Td
hc
dh
dh
dt
d
d
1
1
dp
s ( V sd ) +V sd ( s ) + ( hw hf ) qf +
s V st s + w V wt w + md C p s ( V sd +V wd )
+ r ( 1+ ) V r
dt
dt
hc
hc
dt
dt
dt
dt
w =
.
1
w
+( sw ) V
p
p
dh
dh
dt
s
d
1
1
dp
V sd ( s ) + ( hw h f ) q f +
s V st s + w V wt w +md C p s ( V sd +V wd ) + r ( 1+ ) V r V
+
dt
hc
hc
dp
dp
dp
p
dt
( V )
.
e 42
h h w
dp
d
+e 43 r +e 44 ( V sd ) = s ( V sdV sd 0 ) + f
q f (25)
dt
dt
dt
Td
hc
Where
1
w
+( s w ) V
p
p
dh
dh
dt
s
d
1
1
V sd ( s ) + ( hw h f ) q f +
s V st s + w V wt w +md C p s ( V sd +V wd ) + r ( 1+ ) V r V
+
dt
hc
hc
dp
dp
dp
p
e 42=
( V )
e 43= r ( 1+ ) (s w V r)
V
r
e 44= s .
2.6 Summary
The model can be written as
e 11
d
dp
V wt ] +e 12 =q f q s .
[
dt
dt
24
e 21
d V wt
dp
+e 22 =Q+q f h f q s hs .
dt
dt
e 32
dr
dp
+ e33
=Q+q dc hc r .
dt
dt
e 42
h h w
dp
d
+e 43 r +e 44 ( V sd ) = s ( V sdV sd 0 ) + f
qf .
dt
dt
dt
Td
hc
where
( W s ) .
e11 =
e 12
d w
d S
= (V wt dp + V st dp )
W
h
(
w S h s)
.
e 21=
e 22=hs V st
[(
e 32= w
d
d
d
d
d
+V
h +h V
+V wt W
h V t +mt C p t s .
dp S st S dp s w wt dp W
dp w
dp
hw
h
r hc w ( 1 V ) V r + ( 1 r ) hc s + s s V V r + ( s + ( w s ) r ) hc V r V V t + mr
p
p
p
p
p
.
e 33=( ( 1 r ) s + r w ) hc V r
V
r .
1
w
+( s w ) V
p
p
dh
dh
dt
s
d
1
1
V sd ( s ) + ( hw h f ) q f +
s V st s + w V wt w +md C p s ( V sd +V wd ) + r ( 1+ ) V r V
+
dt
hc
hc
dp
dp
dp
p
e 42=
( V )
25
e 43= r ( 1+ ) (s w V r)
V
r
e 44= s .
2.7 Steady state solution of the model
q f =qs .
Q=q s hs q f hf .
Q=q dc h c r .
h
T d ( f hw )
qf .
hc s
V sd =V sd 0
Where qdc is given by equation (15) i.e.
q dc= 2 w A dc ( w s ) g v V r /k .
A convenient way to find the initial values is to first specify steam flow rate q s and steam
pressure p. The feedwater flowrate qf and input power Q are given by the first two
equations and the steam volume in the drum is given by the last equation. The steam
quality is obtained by solving the nonlinear equations.
Q= r hc 2 w Adc ( w s ) g v V r /k .
V =
w
s
( w s ) r
(1
ln 1+
) .
w s
s
( w s ) r
dx
=b (26)
dt
26
Where
e 11
e
E= 21
0
0
e12
0 0
0 0
e22
e 32 e33 0
e 42 e43 e 44
q f q s
Q+q f h f qs h s
b=
Q+q dc hc r
.
s
hf h w
( V V sd 0 ) + h q f
T d sd
c
d V wt
dt
dp
dx
dt
=
dt d r .
dt
d V sd
dt
This is an ordinary differential equation which can be solved by MATLAB using the ODE
function. Basically we use ODE 45 since it is nonstiff differential equations. The ODE 45
implements the fourth or fifth order Runge-Kutta method.
2.9 Step Responses
Fuel Flow changes at medium load
A step change increase of 10 MW is given to the fuel flow rate and the results are
discussed below
As the steam flow out from the drum is constant ,this in turn keeps the pressure of the
drum constantly increasing at the same rate.The constantly increasing pressure in the
drum causes condensation to take place inside the drum which is the reason for an
increase in the water volume, Vwt within the drum.Initially the steam quality at riser
outlet shows a rapid increase and then as time value increases,the quality of steam tends
to become more stable with gradual increase. The volume of steam inside the drum
initially shows an increases by a small volume and eventually decreases as time value
27
increases. As seen from Figure 2 we note a sharp initial increase in the steam volume and
then a steep fall in the curve, the sharp increases could be atrributed with the increasing
steam flowrate in the riser whereas the steep fall occurs due to the increase in pressure
within the drum causing condensation to take place.
At the onset of the step there is a rapid increase in the outlet flow rate of the steam from
the risers as the flowrate of steam from the outlet of the riser needs to match the
downcomer flowrate we observe a decrease in the outlet steam flow rate .These flow rates
equalize almost after 30 seconds. The condensation flow changes in an almost step like
manner. A combination of water and steam dynamics are responsible for the response in
drum level indication and is somewhat complicated .The initial increase in the water level
is due to the rapid initial response of steam. The response in level is a combination of two
competing mechanisms. The water volume in the drum increases due to increased
condensation caused by increasing pressure. The volume of steam in the drum first
increases a little and then it decreases because of the increasing pressure.
28
system causes an increase in the steam volume .There is very rapid increase of
flow out of steam from the riser as a reason of high pressure drop within the
system. After this initial transient response of the riser flow rate it decreases to
match the downcomer flow rate.The decreased steam pressure causes both the
downcomer as well as riser flow rates to increase. The constant decrease in the
pressure happens to create an almost step like decrease in the condensation flow
rate response.
The shrink and swell effect is clearly visible. The contributions from the volumes
of steam and water have initially the same sign. There would however be a
decrease in the water volume because of steam flow rate alterations.
Fig 2: Response due to step change in steam flow rate at medium load.
30
Chapter 3
Control Schemes
The feedback control scheme will be implemented to control the water level with
the conventional PID controller and advanced controller fuzzy logic
controller(FLC). However we will try only feedwater flow rate as the
manipulated variable and both servo and regulatory testing will be done.
The feedback control scheme
3.1 PID controllers
The control implemented by the PID controller can be given as
u ( t ) =K C e ( t ) +
KC t
de(t )
e (t)+ K C D
(27)
I 0
dt
31
Advantages
Disadvantages
Manual Tuning
Requires experienced
personnel.
Zeigler-Nichols
Software tools
Cohen-Coon
for improved response. First of all set KI and KD values to zero. Increase KP until
the loop starts to oscillate. For a quarter amplitude decay type response the KP
value should be set as half of the value at which the response starts to oscillate.
Next we have to increase KI until the offset is eliminated in sufficient time of the
process and at last increase KD, if required until loop is quick to reach its reference
after a load disturbance. But, too much increase in KD can cause excessive
response and overshoot. A fast PID loop usually overshoots a little bit to reach its
response reference point more quickly; however in some system overshoot is not
acceptable, in which case we require an overdamped response.
Parameter
Rise time
Overshoot
Settling
time
Steady-state Stability
error
Kp
Decrease
Increase
Small
change
Decrease
Degrade
KI
Decrease
Increase
Increase
Eliminate
Degrade
KD
Minor
change
Decrease
Decrease
No effect in
theory
Improve in
Kd small
33
Fig 5: Simulink model to control the level in feedback control scheme using the
PID controller.
control. There are two categories of membership functions. One is continuous and
the other discrete
35
NB
NS
ZO
PS
PB
NB
PB
PB
PM
PS
ZO
NS
PB
PB
PS
ZO
NS
ZO
PB
PS
ZO
NS
NB
PS
PM
ZO
NS
NB
NB
PB
ZO
NS
NB
NB
NB
36
Traditional optimization
Genetic Algorithm
Region I
Converges to 1
Converges to 2
Region II
Converges to 2
Converges to 2
Region III
Converges to 3
Converges to 2
In our case the objective function is to minimize the integral of square error(ISE)
and the variables are k1, k2 and k3. k1 , k2 , k3 are the values which need to be
multiplied with the ranges of the functions E, E and W. The optimum values of
k1,k2 and k3 are obtained by using GA inthe optimization toolbox in MATLAB.
38
The scalar input p is multiplied by the scalar weight w to form wp , one of the
terms that is sent to the summer. The other input,1 , is multiplied by a bias b and then
passed to the summer. The summer input often referred to as net input , goes into a
transfer function, f which produces the scalar neuron output a.
1
1+en ..(29)
39
Typically a neuron has more than one input . A multiple input neuron is shown in figure
12.
The neuron has a bias b, which is summed with the weighted inputs to form the net input
n.
n=w1,1 p1 +w1,2 p2 ++ w1, R p R +b .
which can be written in matrix form as
n=+b ..(30)
Where the matrix W from the single neuron case has only one row.
40
41
42
^ y p ( k ) , , y p ( kn+1 ) ,u ( k ) , , u ( km+1 ) ; x ]
y m ( k +1 )= h[
.(32)
^
where h[. , x ] is a function implemented by the neural network, and x is a vector
'
'
2
u ( k + j1 )u (k + j2)
..(33)
N2
J=
j =N 1
where N1 , N2 and Nu define the horizons over which the tracking error and the control
increments are evaluated. The u variable is the tentative control signal , yr is the desired
response and ym is the network model response. The value determines the contribution
that the sum of the squares of the control increments has on the performance index..
The following block diagram illustrates the model predictive control process. The
controller consists of the neural network plant model and the optimization block. The
optimization block determines the values of u that minimize J and then the optimal u is
the output to the plant.
43
Fig 20: The Simulink model for neural network predictive control.
44
Chapter 4
Results and Discussions
4.1 PID controller
4.1.1 Regulatory Problem
In the first regulatory problem we are giving a step change in fuel flow as 10 MW.
The PID parameters obtained by manual tuning are
KC = 500
I = 1 , D = 1.
The response of the system can be seen as follows
46
47
48
49
Fig 25 : Changes in feed water flow rate to control the level.(servo problem)
The changes in the feed water flow rate at the beginning rises to almost 180 kg/s
and then drops to almost 15 kg/s and after about 150 s it settles to a constant
value of 50 kg/s.
4.2 Fuzzy Logic Controller
4.2.1 Regulatory Problem
The membership function of the fuzzy logic controller before optimization are shown
below
50
Fig 27: membership function for input variable E. Range [-0.1 0.1]
Fig 28: membership function for output variable W . Range [-20 20]
The responses before and after optimization of the membership functions are compared
below. As can be seen from the figure that the integral of square error (ISE) before and
after optimization have a difference of almost 26. The three values k1,k2 and k3 which
are multiplied with the membership functions of E,E and W respectively to minimize
ISE are 0.109,0.814 and 0.302 respectively.
51
Fig 28: results after optimization of membership functions (change in fuel flow)
ISE=122.0842
As we see from the response that in fuzzy control the response obtained is more
steady as obtained in PID controller. The response rises a peak of about 0.1 m
above set point and then eventually decreases to the set point. The response
obtained after 90 seconds.
52
Fig 29: response of FLC due to step change in fuel flow rate.
Fig 30: changes in feedwater flow rate to control the level for FLC for a step in fuel flow.
As we can see from figure 20 that the changes in feedwater flow rate can be limited
within a range ,in or case it is +- 20 kg/s but in PID controller it is not possible if the
disturbance by somehow increases to a great extent.
53
The membership function of the fuzzy logic controller before optimization are shown
below
Fig 32: membership function for input variable E. Range [-0.1 0.1]
54
Fig 33: membership function for output variable W . Range [-20 20]
The responses before and after optimization of the membership functions are compared
below. As can be seen from the figure that the integral of square error (ISE) before and
after optimization have a difference of almost 0.3 which is low but the response time
decreases by an extent of almost 5 s. The three values k1,k2 and k3 which are multiplied
with the membership functions of E,E and W respectively to minimize ISE are
1.981,1.593 and 1.34 respectively.
Fig 34: response before optimization of membership functions (change in set point )
ISE=156.6541
Fig 35: response after optimization of membership functions (change in set point )
ISE=156.333
55
Again we can change from the response that it is more smooth than the response obtained
by PID controller and nonoscillatory. The response time is about 105 seconds.
56
57
58
in
time
time
response
response
Fuel flow
147.57
122.08
100 s
90 s
Oscillatory
Smooth
Steam
147.55
-------110 s
-------Oscillatory
60
Smooth
Flow
Set Point
160.95
156.33
90 s
105 s
Oscillatory
Smooth
Chapter 5
Conclusion
After analyzing the results we can conclude as:
The model obtained clearly takes the shrink and swell effect in the drum
The water level contribution(lw) to the water level(l) actually is the water
in the drum and hence we can distinguish it from the model.
Both servo and regulatory problems are taken into account to control the
water level.
The feed water flow rate is very efficient in controlling the level of water.
PID gives an oscillatory response whereas FLC gives a smooth response.
We can restrict the manipulated variable, in our case the feed water flow
rate to a certain range in FLC but it is not possible in PID controllers.
61
References:
1) K.J.Astrom, R.D.Bell, Drum-boiler dynamics, Automatica,2000,vol 36,pg 363378.
2) A.Parry, J.F. Petotrot and W.J.Vivier. Recent progress in sg level control in
French pwr plants. In Proc. Int. Conf on Boiler Dynamics and Control in
Nuclear Powerstations, pg 81-88. British Nuclear Energy Society ,1995
3) H.H. Hacene Habbi, M.Zelmat, B.O. Bouamama,A dynamic fuzzy model for
drum boiler turbine system,Automatica,2002,vol 39,pg 1213-1219.
62
63
Appendix A
MATLAB CODE
function[sys,x0,str,ts]=sfd302_sfcn(t,x,u,flag,x_init)
%sfd302 S-function version of the four state model
%compatible with simulink block diagrams.
global qr qdc qct;
%plant parameters------------------------------mt=300000;mr=100000;md=20000;Cp=650;
Cfw=4.18;Ad=23;Vd=37;Vr=37;Vdc=11;
Vt=Vd+Vr+Vdc;
ke=200;Vsd0=8;beta=0.3;
%properties of steam and water in saturated table
a01=2.7254E6;a11=-1.8992E4;a21=-1160.0;
a02=53.1402;a12=7.673;a22=0.36;
a03=1.4035E6;a13=4.9339E4;a23=-880.0;
a04=691.35;a14=-18.672;a24=-0.0603;
a05=310.6;a15=8.523;a25=-0.33;
%------------------------------------------------if abs(flag) ==1, %compute state derivatives
%state initial conditions
Vwt=x(1);
p=x(2);
64
ar=x(3);
Vsd=x(4);
%controls or inputs
Q=u(1)*1e6; %conversion to watts
qf=u(2);
tf=u(3);
qs=u(4)+4.8*(p-8.5); %correction for steam transducer
% properties of steam and water in saturated state
hs=a01+(a11+a21*(p-10))*(p-10);
dhsdp=a11+2*a21*(p-10);
rs=a02+(a12+a22*(p-10))*(p-10);
drsdp=a12+2*a22*(p-10);
hw=a03+(a13+a23*(p-10))*(p-10);
dhwdp=a13+2*a23*(p-10);
rw=a04+(a14+a24*(p-10))*(p-10);
drwdp=a14+2*a24*(p-10);
ts=a05+(a15+a25*(p-10))*(p-10);
dtsdp=a15+2*a25*(p-10);
%properties of water in subcritical state
hf=(Cfw*tf+p*1e3/rw)*1e3;
%the model equations-------------------hc=hs-hw;
hr=ar*hs+(1-ar)*hw;
%average steam quality volume rati and partial derivatives
z=ar*(rw-rs)/rs;
av=rw/(rw-rs)*(1-(1/z)*log(1+z));
davdar=rw/rs*((1/z)*log(1+z)-1/(z+1))/z;
zp=(rs*drwdp-rw*drsdp)*ar/rs/rs;
z1=(rw*drsdp-rs*drwdp)/(rw-rs)/(rw-rs);
z2=rw/(rw-rs)*((1/z)*log(1+z)-1/(1+z))/z*zp;
davdp=z1*(1-(1/z)*log(1+z))+z2;
%circulation flow
s1=ke*(rw-rs)*Vr*av;
qdc=sqrt(s1);
%equations for coefficents of derivatives of state variables
Td=600/qs;
Vst=Vt-Vwt;
Vwd=Vwt-Vdc-(1-av)*Vr;
e11=rw-rs;
e12=Vst*drsdp+Vwt*drwdp;
e21=hw*rw-hs*rs;
e22x=-Vt*1e6+mt*Cp*dtsdp;
e22=Vst*(hs*drsdp+rs*dhsdp)+Vwt*(hw*drwdp+rw*dhwdp)+e22x;
e3w=(rw*dhwdp-ar*hc*drwdp)*(1-av)*Vr;
e3x=(rs+(rw-rs)*ar)*hc*Vr*davdp-Vr*1e6+mr*Cp*dtsdp;
e32=((1-ar)*hc*drsdp+rs*dhsdp)*av*Vr+e3w+e3x;
e33=(rs+(rw-rs)*ar)*hc*Vr*davdar;
e42y=(1+beta)*ar*Vr;
e42x=e42y*((1-av)*drwdp+av*drsdp+(rs-rw)*davdp)+Vsd*drsdp;
e42=(rs*Vsd*dhsdp+rw*Vwd*dhwdp-Vsd*1e6+md*Cp*dtsdp)/hc+e42x;
65
e43=(1+beta)*(ar*Vr*(rs-rw)*davdar);
e44=rs;
e=[e11,e12,0,0
e21,e22,0,0
0,e32,e33,0
0,e42,e43,e44];
%the right hand side of state equations
b4=(hf-hw)*qf/hc+rs*(Vsd0-Vsd)/Td;
b=[qf-qs; Q+qf*hf-qs*hs; Q-qdc*ar*hc; b4];
%solve linear equation for derivatives
dx=e\b;
qx=(rw-rs)*Vr*davdp*dx(2)+(rw-rs)*Vr*davdar*dx(3);
%two important flows for understanding behaviour
qr=qdc-(av*drsdp+(1-av)*drwdp)*Vr*dx(2)+qx;
qctx=rs*Vst*dhsdp+rw*Vwt*dhwdp-Vt*1e6+mt*Cp*dtsdp;
qct=((hw-hf)*qf+qctx*dx(2))/hc;
%step the derivatives, dx is a 4X1 vector
sys = [dx];
%------------------------------------------------------------elseif flag==3, %Compute outputs
%extract state variables
Vwt=x(1);
p=x(2);
ar=x(3);
Vsd=x(4);
%drum level
rs=a02+(a12+a22*(p-10))*(p-10);
rw=a04+(a14+a24*(p-10))*(p-10);
z=ar*(rw-rs)/rs;
av=rw/(rw-rs)*(1-(1/z)*log(1+z));
Vwd=Vwt-Vdc-(1-av)*Vr;
ls=Vsd/Ad;
lw=Vwd/Ad;
l=lw+ls;
sys=[l,p,lw,ls,qr,av,qdc,ar,Vwt,Vsd,qct];
%-------------------------------------------------------------elseif flag==0, %INITIALIZATIONS
str=[];
sizes(1)=4; %4 continious states
sizes(2)=0; %0 discrete states
sizes(3)=11; % 11 outputs
sizes(4)=4; %4 inputs
sizes(5)=0; % no discontinious roots
sizes(6)=0; % no direct term
sizes(7)=1; ts=[0,0]; %efficency fix(see[1])
sys=sizes';
x0(1)=x_init(1);
x0(2)=x_init(2);
66
x0(3)=x_init(3);
x0(4)=x_init(4);
else
sys=[]; %flags 2 or 4 , not considered since we have no discrete states.
end;
% Also flag 5 is of no interest.
Appendix B
Optimization Code
11711
12711
13611
14511
15411
21711
22711
23511
24411
25311
31711
32511
33411
34311
35111
41611
42411
43311
44111
45111
68
51411
52311
53111
54111
5 5 1 1 1]; d=addrule(d,ruleList);
mt=300000;mr=100000;md=20000;Cp=650;
Cfw=4.18;Ad=23;Vd=37;Vr=37;Vdc=11;
Vt=Vd+Vr+Vdc;
ke=200;Vsd0=8;beta=0.3;
dt=1;
69
l=zeros(1,200);lw=zeros(1,200);ls=zeros(1,200);Q=zeros(1,200);qs=zeros(1,200); for
i=1:200
Vwt(1)=57.2;
p(1)=8.5;
ar(1)=0.0511;
Q(51:200)=96.813*1e6;
qf(1)=50;
hc=hs-hw; hr=ar(i)*hs+(1-ar(i))*hw;
av=rw/(rw-rs)*(1-(1/z)*log(1+z)); davdar=rw/rs*((1/z)*log(1+z)-1/(z+1))/z;
zp=(rs*drwdp-rw*drsdp)*ar(i)/rs/rs; z1=(rw*drsdp-rs*drwdp)/(rw-rs)/(rw-rs); z2=rw/(rwrs)*((1/z)*log(1+z)-1/(1+z))/z*zp; davdp=z1*(1-(1/z)*log(1+z))+z2; %circulation flow
s1=ke*(rw-rs)*Vr*av; qdc=sqrt(s1);
e42y=(1+beta)*ar(i)*Vr; e42x=e42y*((1-av)*drwdp+av*drsdp+(rs-rw)*davdp)
+Vsd(i)*drsdp; e42=(rs*Vsd(i)*dhsdp+rw*Vwd*dhwdpVsd(i)*1e6+md*Cp*dtsdp)/hc+e42x; e43=(1+beta)*(ar(i)*Vr*(rs-rw)*davdar);
e44=rs;
e=[e11,e12,0,0
e21,e22,0,0
71
0,e32,e33,0
0,e42,e43,e44];
dx=e\b; qx=(rw-rs)*Vr*davdp*dx(2)+(rw-rs)*Vr*davdar*dx(3);
%two important flows for understanding behaviour qr=qdc-(av*drsdp+(1av)*drwdp)*Vr*dx(2)+qx; qctx=rs*Vst*dhsdp+rw*Vwt(i)*dhwdpVt*1e6+mt*Cp*dtsdp; qct=((hw-hf)*qf(i)+qctx*dx(2))/hc; Vwt(i+1)=(Vwt(i)+dx(1)*dt);
p(i+1)=(p(i)+dx(2)*dt);
ar(i+1)=ar(i)+dx(3)*dt;
Vsd(i+1)=Vsd(i)+dx(4)*dt;
ls(i)=Vsd(i)/Ad;
lw(i)=Vwd/Ad;
l(i)=lw(i)+ls(i);
lwsp(1:50)=0.859;
%lwsp(51:200)=0.909; err(i)=lw(i)-lwsp(i);
ise(i)=err(i)*(err(i)); else
ise(i)=ise(i-1)+err(i)*(err(i)); end
72
end
if i==1 dele=0;
else dele=err(i)-err(i-1);
end
end iseplot=ise(200);
k2=par(2);
k3=par(3);
fuzzyboils;
drumboilerdynamics; end
73
74