SlideShare a Scribd company logo
PETROCONTROL
Advanced Control and Optimization
34 East 30th
Street, New York, NY 10016 • Tel: 212-481-6195 • Fax: 212-447-8756
zak@petrocontrol.com
TUNING OF AVERAGING LEVEL CONTROLLER
By
Y. Zak Friedman, PhD
Principal Consultant
Published in Hydrocarbon Processing Journal, December 1994
Averaging level controller tuning, page 2
TUNING OF AVERAGING LEVEL CONTROLLERS.
A friend of mine showed me the latest and greatest in level control technology. Look at
Figure 1, he said, obviously the level movement is an indication of mass imbalance:
Fin - Fout = A * (dL/dt) [1]
Fin = flow of liquid into the vessel
Fout = flow of liquid out of the vessel
A = cross sectional area of the vessel
dt = the time between scans
(dL/dt) = level rate of change.
The level controller operates by manipulating the outlet flow. Every scan it implements
flow changes:
dFo1, dFo2, dFo3, ------------ , dFok
dFo1 = the change in outlet flow after the first scan from now
dFo2 = the change in outlet flow after the second scan from now
'
'
'
dFok = the change in outlet flow after a certain time horizon of
interest: k scans.
We assume that from now on the inlet flow will remain constant. The integral form of
equation 1 then takes the form of:
k
A * (Lk - L0) = A * dL0 * k - ΣΣΣΣ ((k-i+1)*dt*dFoi) [2]
i=1
Lk = the level that will be reached after the time horizon of k scans
L0 = the current level reading
dL0 = the change of level from the previous to the current scan.
It indicates the initial mass imbalance.
We wish to bring the level to its setpoint after the time horizon H, while at the same time
minimize the movement of the manipulated variable Fout. This desire can be
expressed mathematically as:
k
Minimize ΣΣΣΣ (dFoi)**2 [3]
i = 1
Averaging level controller tuning, page 3
Subject to the constraint of equation 2, except we replace Lk by the setpoint LSP, to
express the desire to reach the setpoint after k moves:
k
A * (LSP - L0) = A * dL0 * k - ΣΣΣΣ ((k-i+1)*dt*dFoi) [4]
i=1
LSP = The level controller setpoint
With the help of some textbooks, my friend solved the problem as shown in equation 5,
for the first control action dFo1. We take interest only in dFo1 because each scan the
controller has to only come up with the next move. The solution for dFo1 is:
dFo1 = C1 * dL0 + C2 * dt * (L0-LSP) [5]
C1 = 4 * A / H
C2 = 6 A / (H**2)
H = the time horizon = dt * k
This is nice, I said. Lets compare it to the famous Proportional Integral (PI) algorithm in
its velocity form:
dM = Kc * dL0 + (Kc/TI) * dt * (L0-LSP) [6]
dM = change of the manipulated variable = dFo1
Kc = controller gain
TI = controller reset time.
You have discovered the PI algorithm I told my friend, with settings of:
Kc = 4 * A / H [7]
TI = .67 * H
There was a moment of silence. It turned out that my friend's company offers a
package, which provides the controller of equation 5 on a host computer, not realizing
that any DCS would be quite capable of providing the same, or even better PI controller.
I am writing this not to embarrass the company in question, but rather to show again
here that the PI algorithm is mighty good for level control, and usually no alternatives
are needed. I would also like to suggest a way of tuning for the averaging level
controller based not on some arbitrary time horizon but by relating the tuning constants
to physical characteristics of the vessel in question.
Averaging level controller tuning, page 4
The Averaging Level Control Objective
Figure 2 shows two level applications with entirely different objectives. The objective of
figure 2A is to keep the level always at its setpoint, while moving the manipulated
variable as much as it takes to steady the level quickly. In contrast, the objective of
figure 2B is to minimize the movement of the manipulated variable while keeping the
level within its alarm limits. This second application is called Averaging Level Control,
and it is the subject of this paper.
Before attempting to tune the controller, it would be useful to quantify the control
objective. Say the controller is at steady state and the level is at setpoint. At some
point a disturbance comes in such that the previous inlet flow changes by FD. Equation
1 tells us that the level will then start changing at a rate of:
(dL/dt) = FD / A [8]
The objective is to tune the controller such that it can handle a flow disturbance of
magnitude FD without exceeding the alarm limits. It is assumed that before the
disturbance occurred the vessel was at steady state with its level reading being equal to
the setpoint. After reaching a level peak, which would almost equal the alarm setting,
the objective is to gradually bring the level back to its setpoint.
But how to choose the magnitude of FD? One obvious way is by observing the plant
operation and selecting one of the largest disturbances. Another way, less precise but
often more practical is to set FD as 20% of the typical outlet flow. 20% step change is a
fairly large flow disturbance, and thus the resulting control settings will not often trigger
an alarm.
Setting the Initial Controller Gain
Consider next a proportional only controller. Not that one is recommended, but in the
initial part of the response the integral action plays only a minor role and it can be
ignored. As equation 8 starts working and the level trends upwards, the proportional
action would increase the outlet flow by:
Fout = Fout0 + Kc * (L - LSP) [9]
Fout0 = the initial outlet flow before the disturbance occurred
The manipulated variable Fout will continue to increase as long as the level is rising,
until finally, when the outlet flow equals the inlet flow, the level would stabilize at a new
reading:
Fout = Fout0 + FD = Fout0 + Kc * (L - LSP) [10]
Averaging level controller tuning, page 5
Or:
FD = Kc * (L - LSP) [11]
Our tuning objective specifies that at that time the level will be just equal to the alarm
limit, and that gives us a formula for calculating the controller gain:
Kc = FD / (LIMIT - LSP) [12]
LIMIT = the alarm limit of the controller
From a control point of view it is best to select the setpoint to be at the middle of the
range, i.e., 50% of the level, and have alarm limits at 20% and 80%. Though of course
the setting of level setpoint and limits depends not only on control considerations but
also on vessel geometry and process considerations.
Equation 12 gives the gain in engineering units of say BPD / %. Since most DCS
systems work not in engineering units but in % of range, the gain of equation 12 needs
to be modified to:
Kc% = (FD / Frange) * ((Lrange / (LIMIT - LSP) [13]
Frange = The range of the manipulated variable flow measurement.
Lrange = The range of the level measurement. Normally 100%.
Setting the Initial Reset Time
Once a new steady level is reached after a disturbance, the whole plant has stabilized.
Is there a need to apply a reset action which would disturb the newly accomplished
steady state, only to bring the level back to its setpoint? The answer is "yes", if you
wish to regain the freedom of movement in both directions. But how quickly do we need
to regain that freedom? The simple answer is that the level should be brought back to
its setpoint in time to meet the next major disturbance. However we do not precisely
know when the next disturbance would come.
A reasonable way to address this uncertainty is to relate the reset time to the
disturbance residence time in the vessel. The disturbance residence time is defined as:
RTIME = VS / FD [14]
VS = The surge volume. This is the volume bound between the level
setpoint LSP and the level alarm limit LIMIT. The units of VS
must be such that RTIME is calculated in minutes.
RTIME = Disturbance residence time in minutes
Averaging level controller tuning, page 6
A starting point which is likely to give a good result is a reset time of:
TI = 4 * RTIME [15]
By "good result" it is meant that there would be a reasonable tradeoff between using the
surge volume of the vessel, and between recovering quickly from an upset situation.
Tuning Test
Most level loops will have no dynamic difficulties with the settings of equations 13 and
15. Loops without dead time would certainly perform well. Loops with some dead time
will likely still perform well because averaging level tuning calls for slow, stable
responses. It happens however that due to improper vessel design, interactions with
other loops or excessive dead time, the controller cannot support the initial tuning
objective. The response then becomes oscillatory. This section suggests a set of rules
for tuning averaging level loops which exhibit such oscillatory behavior.
Since averaging level tuning is normally stable, it would be a good idea, in case of
sustained oscillations, to first check whether these oscillations are the result of unstable
level control or just simply an oscillatory disturbance. When in doubt, the level controller
can be turned to Manual. If the oscillations were caused by level instability they would
then die down.
If it has been established that the level controller is responsible for the oscillations, the
presence of these oscillations indicates unusual dynamic problems as stated above. It
is advisable then to have discussions with process engineers and operators to
understand why the loop is oscillatory. Attention should be paid to the heat exchange
system which often provides the mechanism for slow loop to loop interactions.
When there are oscillations, either damped or unstable, the reset time ought to be
considered first. For a satisfactory response the reset time should be at least twice as
long as the oscillation period. The period of oscillation is defined in Figure 3 as twice
the time between the first high and first low peaks of a response.
If TI is sufficiently long and the response is still too oscillatory, it is an indication that this
loop cannot fulfill the objective of handling a disturbance of magnitude FD. There is a
need then to reduce the gain until the loop response is satisfactory. For level control
loops, it would be reasonable to allow no more than three peaks in the response: One
high and one low, followed by another small high or low peak. As shown if Figure 3, the
loop then will have no more than one overshoot and one undershoot.
Once the new gain is set, equation 12 can be rearranged to assess how much of a
disturbance this controller can now handle without sounding an alarm:
FD = Kc * (LIMIT - LSP) [16]
Averaging level controller tuning, page 7
If FD is lower than 10% of the normal outlet flow, the loop will likely remain a problem
loop.
Nonlinear Control Algorithms.
Some DCS systems have the facility of scheduling the controller gain Kc, so that it
would increase with control deviation as follows:
Kc = Kl * (1. + Knl * ABS (L - LSP) / 100) [17]
Kl = The linear control gain
Knl = A nonlinear coefficient
Such a control action provides the ability to reduce the manipulated variable activity at
small disturbances, at the expense of large adjustments when there are large
disturbances.
In the author's opinion, the usefulness of nonlinear level algorithms is overrated. If the
mass imbalance disturbance is large, then a weak initial action will cause the level to
stray further away from setpoint. The level will eventually reach the region of higher
gain and force the strong action required for the disturbance. The changes in the
manipulated variable will then be even more abrupt than those of the linear controller.
As a rule, vessels whose residence time is too short perform better with linear control.
Vessels whose residence time is adequate give a somewhat better performance with
nonlinear control.
For tuning the nonlinear algorithm, it is recommended to first find Kcmax as per
equation 13:
Kcmax = (FD / Frange) * ((Lrange / (LIMIT - LSP) [18]
Then set Kl and Knl so that the control action would double when approaching the level
limit:
Kl = Kcmax / 2 [19]
Knl =100 / ABS (LIMIT - LSP) [20]
Direct Level to Valve Control.
Modern units are likely to have most of their level controllers cascading to flow
controllers. Such cascades are easier to tune because the level - flow process gain
remains constant. The tuning procedure for a level to valve type controller is similar to
that of the cascade, except for the units of the flow disturbance FD. For determining the
controller gain there is a need to define FD not as volume per time, but in terms of how
a flow disturbance of magnitude FD would change the opening of the valve. I.e., FD
must be defined as % valve position change. Frange of equation 13 is then 100%.
Averaging level controller tuning, page 8
Once that is done, equation 13 can be used. However, for calculating the reset time
according to equation 14 and 15, FD must be defined again in terms of volume per unit
time, or % level per unit time, so that the reset time is in minutes.
Level Reading Correction With Irregular Shape of the Vessel.
Many DCS systems have the ability to correct the level reading so that it represents real
volume, rather than height. To determine whether the additional complication of
correcting that reading is worth it, there is a need to discriminate between two cases.
First consider the special, but common case of a horizontal vessel, where the level
setpoint is at the middle of the vessel, and the high and low limits are at 20% and 80%
of the vessel diameter respectively. Second consider a more general case of irregular
vessels.
To begin with the special case of the level setpoint being at the middle of a horizontal
vessel, the Pythagorean theorem shows that at 80% or 20% level reading, the cross
sectional area is reduced to 80% of the area in the middle of the cylinder. The effect of
that reading error would be similar to the nonlinear controller of equation 17, with the
control gain being 25% stronger at high deviations (1/0.8 = 1.25). Hence we conclude
that it is in fact desirable to have such an error and no level linearization is required.
About the same conclusion can be reached for a spherical vessel, except there the area
at the limits is 64% of the area in the middle, and the nonlinear effect is then so that the
gain at the limits is 56% stronger than in the middle. This increase is perfectly
acceptable, as evidenced by the recommendation of equations 18 through 20.
For the general case of irregular shape, or even for cylinders where the setpoint is not in
the middle, it is recommended that level correction be performed, if that is possible.
Otherwise the controller becomes difficult to tune and the tuning objective looses its
meaning.
Conclusions
The PI algorithm is an excellent device for controlling level. To this date no better
alternatives have been established.
The control objective calls for a weak reset action, often resulting in reset times in the
order of one hour.
The method proposed here for tuning the PI level controller has been widely applied
and is known to work well. It makes maximum use of the surge capacity of a vessel,
and in so doing it tends to stabilize the whole plant.
Nonlinear level control can be counter-productive when the vessel is too small. When
the vessel size is adequate nonlinear level control has a small advantage over linear
control.
Averaging level controller tuning, page 9
FIGURE 1.
A SIMPLE LEVEL CONTROL CASCADE
Fin
LC
FC
Fout
Averaging level controller tuning, page 10
FIGURE 2.
LEVEL CONTROL RESPONSE TO A MASS BALANCE DISTURBANCE
2A. TIGHT LEVEL OBJECTIVE
FLOW
LEVEL
2B. AVERAGING LEVEL OBJECTIVE
FLOW
LEVEL
Averaging level controller tuning, page 11
FIGURE 3.
OSCILLATORY LEVEL TUNING
P/2
SETPOINT
PERTURBATION
LEVEL
FLOW

More Related Content

What's hot

Sensor Fusion Study - Ch10. Additional topics in kalman filter [Stella Seoyeo...
Sensor Fusion Study - Ch10. Additional topics in kalman filter [Stella Seoyeo...Sensor Fusion Study - Ch10. Additional topics in kalman filter [Stella Seoyeo...
Sensor Fusion Study - Ch10. Additional topics in kalman filter [Stella Seoyeo...
AI Robotics KR
 
10.1.1.193.2962
10.1.1.193.296210.1.1.193.2962
10.1.1.193.2962
aboma2hawi
 
The extended kalman filter
The extended kalman filterThe extended kalman filter
The extended kalman filter
Mudit Parnami
 
Cascade control
Cascade controlCascade control
Cascade control
Ashvani Shukla
 
Kalman Equations
Kalman EquationsKalman Equations
Kalman Equations
Tim Mazumdar
 
Aifcraft pitch
Aifcraft pitchAifcraft pitch
Aifcraft pitch
mbilal2792
 
Report kalman filtering
Report kalman filteringReport kalman filtering
Report kalman filtering
Irfan Anjum
 

What's hot (7)

Sensor Fusion Study - Ch10. Additional topics in kalman filter [Stella Seoyeo...
Sensor Fusion Study - Ch10. Additional topics in kalman filter [Stella Seoyeo...Sensor Fusion Study - Ch10. Additional topics in kalman filter [Stella Seoyeo...
Sensor Fusion Study - Ch10. Additional topics in kalman filter [Stella Seoyeo...
 
10.1.1.193.2962
10.1.1.193.296210.1.1.193.2962
10.1.1.193.2962
 
The extended kalman filter
The extended kalman filterThe extended kalman filter
The extended kalman filter
 
Cascade control
Cascade controlCascade control
Cascade control
 
Kalman Equations
Kalman EquationsKalman Equations
Kalman Equations
 
Aifcraft pitch
Aifcraft pitchAifcraft pitch
Aifcraft pitch
 
Report kalman filtering
Report kalman filteringReport kalman filtering
Report kalman filtering
 

Similar to Level tuning. by zakpdf

Control
ControlControl
Chapter 10-pid-1
Chapter 10-pid-1Chapter 10-pid-1
Chapter 10-pid-1
mohamed maghraby
 
Lead-lag controller
Lead-lag controllerLead-lag controller
Lead-lag controller
Chiramathe Nami
 
Servo Fundamentals
Servo FundamentalsServo Fundamentals
Servo Fundamentals
purnima saha
 
B010411016
B010411016B010411016
B010411016
IOSR Journals
 
air craft Pitch
air craft Pitchair craft Pitch
air craft Pitch
Faizan Shabbir
 
In layperson's terms: this, is droop control - 2015-06-12.r03.4
In layperson's terms: this, is droop control - 2015-06-12.r03.4In layperson's terms: this, is droop control - 2015-06-12.r03.4
In layperson's terms: this, is droop control - 2015-06-12.r03.4
Abel Rochwarger
 
Voltage Regulation of Boost Converter using Observer based Sliding Mode Contr...
Voltage Regulation of Boost Converter using Observer based Sliding Mode Contr...Voltage Regulation of Boost Converter using Observer based Sliding Mode Contr...
Voltage Regulation of Boost Converter using Observer based Sliding Mode Contr...
TELKOMNIKA JOURNAL
 
PID controller
PID controllerPID controller
PID controller
Tsuyoshi Horigome
 
Model Predictive Control For Integrating Processes
Model Predictive Control For Integrating ProcessesModel Predictive Control For Integrating Processes
Model Predictive Control For Integrating Processes
Emerson Exchange
 
Bt0064 logic design2
Bt0064 logic design2Bt0064 logic design2
Bt0064 logic design2
Techglyphs
 
179529572-ROOT-LOCUS-Control-system-Design-ppt.ppt
179529572-ROOT-LOCUS-Control-system-Design-ppt.ppt179529572-ROOT-LOCUS-Control-system-Design-ppt.ppt
179529572-ROOT-LOCUS-Control-system-Design-ppt.ppt
TaraGonzales5
 
Implementation of closed loop control technique for improving the performance...
Implementation of closed loop control technique for improving the performance...Implementation of closed loop control technique for improving the performance...
Implementation of closed loop control technique for improving the performance...
IJERA Editor
 
A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP PID TUNNING TECHNIQUE FOR A LIQ...
A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP PID TUNNING TECHNIQUE FOR A LIQ...A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP PID TUNNING TECHNIQUE FOR A LIQ...
A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP PID TUNNING TECHNIQUE FOR A LIQ...
IJITCA Journal
 
A Study on Performance of Different Open Loop PID Tunning Technique for a Liq...
A Study on Performance of Different Open Loop PID Tunning Technique for a Liq...A Study on Performance of Different Open Loop PID Tunning Technique for a Liq...
A Study on Performance of Different Open Loop PID Tunning Technique for a Liq...
IJITCA Journal
 
A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP PID TUNNING TECHNIQUE FOR A LI...
A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP  PID TUNNING TECHNIQUE FOR A LI...A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP  PID TUNNING TECHNIQUE FOR A LI...
A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP PID TUNNING TECHNIQUE FOR A LI...
IJITCA Journal
 
Inno2019_EMT4203_CONTROL_II_Chap1_Control Actions.pdf
Inno2019_EMT4203_CONTROL_II_Chap1_Control Actions.pdfInno2019_EMT4203_CONTROL_II_Chap1_Control Actions.pdf
Inno2019_EMT4203_CONTROL_II_Chap1_Control Actions.pdf
kabuej3
 
Control tutorials for matlab and simulink introduction pid controller desig...
Control tutorials for matlab and simulink   introduction pid controller desig...Control tutorials for matlab and simulink   introduction pid controller desig...
Control tutorials for matlab and simulink introduction pid controller desig...
ssuser27c61e
 
TOCbw I&ECPDD Oct67
TOCbw I&ECPDD Oct67TOCbw I&ECPDD Oct67
TOCbw I&ECPDD Oct67
Pierre Latour
 
Comprehensive Approach Towards Modelling and Simulation of Single Area Power...
Comprehensive Approach Towards Modelling and Simulation of  Single Area Power...Comprehensive Approach Towards Modelling and Simulation of  Single Area Power...
Comprehensive Approach Towards Modelling and Simulation of Single Area Power...
IRJET Journal
 

Similar to Level tuning. by zakpdf (20)

Control
ControlControl
Control
 
Chapter 10-pid-1
Chapter 10-pid-1Chapter 10-pid-1
Chapter 10-pid-1
 
Lead-lag controller
Lead-lag controllerLead-lag controller
Lead-lag controller
 
Servo Fundamentals
Servo FundamentalsServo Fundamentals
Servo Fundamentals
 
B010411016
B010411016B010411016
B010411016
 
air craft Pitch
air craft Pitchair craft Pitch
air craft Pitch
 
In layperson's terms: this, is droop control - 2015-06-12.r03.4
In layperson's terms: this, is droop control - 2015-06-12.r03.4In layperson's terms: this, is droop control - 2015-06-12.r03.4
In layperson's terms: this, is droop control - 2015-06-12.r03.4
 
Voltage Regulation of Boost Converter using Observer based Sliding Mode Contr...
Voltage Regulation of Boost Converter using Observer based Sliding Mode Contr...Voltage Regulation of Boost Converter using Observer based Sliding Mode Contr...
Voltage Regulation of Boost Converter using Observer based Sliding Mode Contr...
 
PID controller
PID controllerPID controller
PID controller
 
Model Predictive Control For Integrating Processes
Model Predictive Control For Integrating ProcessesModel Predictive Control For Integrating Processes
Model Predictive Control For Integrating Processes
 
Bt0064 logic design2
Bt0064 logic design2Bt0064 logic design2
Bt0064 logic design2
 
179529572-ROOT-LOCUS-Control-system-Design-ppt.ppt
179529572-ROOT-LOCUS-Control-system-Design-ppt.ppt179529572-ROOT-LOCUS-Control-system-Design-ppt.ppt
179529572-ROOT-LOCUS-Control-system-Design-ppt.ppt
 
Implementation of closed loop control technique for improving the performance...
Implementation of closed loop control technique for improving the performance...Implementation of closed loop control technique for improving the performance...
Implementation of closed loop control technique for improving the performance...
 
A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP PID TUNNING TECHNIQUE FOR A LIQ...
A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP PID TUNNING TECHNIQUE FOR A LIQ...A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP PID TUNNING TECHNIQUE FOR A LIQ...
A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP PID TUNNING TECHNIQUE FOR A LIQ...
 
A Study on Performance of Different Open Loop PID Tunning Technique for a Liq...
A Study on Performance of Different Open Loop PID Tunning Technique for a Liq...A Study on Performance of Different Open Loop PID Tunning Technique for a Liq...
A Study on Performance of Different Open Loop PID Tunning Technique for a Liq...
 
A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP PID TUNNING TECHNIQUE FOR A LI...
A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP  PID TUNNING TECHNIQUE FOR A LI...A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP  PID TUNNING TECHNIQUE FOR A LI...
A STUDY ON PERFORMANCE OF DIFFERENT OPEN LOOP PID TUNNING TECHNIQUE FOR A LI...
 
Inno2019_EMT4203_CONTROL_II_Chap1_Control Actions.pdf
Inno2019_EMT4203_CONTROL_II_Chap1_Control Actions.pdfInno2019_EMT4203_CONTROL_II_Chap1_Control Actions.pdf
Inno2019_EMT4203_CONTROL_II_Chap1_Control Actions.pdf
 
Control tutorials for matlab and simulink introduction pid controller desig...
Control tutorials for matlab and simulink   introduction pid controller desig...Control tutorials for matlab and simulink   introduction pid controller desig...
Control tutorials for matlab and simulink introduction pid controller desig...
 
TOCbw I&ECPDD Oct67
TOCbw I&ECPDD Oct67TOCbw I&ECPDD Oct67
TOCbw I&ECPDD Oct67
 
Comprehensive Approach Towards Modelling and Simulation of Single Area Power...
Comprehensive Approach Towards Modelling and Simulation of  Single Area Power...Comprehensive Approach Towards Modelling and Simulation of  Single Area Power...
Comprehensive Approach Towards Modelling and Simulation of Single Area Power...
 

Recently uploaded

FULL STACK PROGRAMMING - Both Front End and Back End
FULL STACK PROGRAMMING - Both Front End and Back EndFULL STACK PROGRAMMING - Both Front End and Back End
FULL STACK PROGRAMMING - Both Front End and Back End
PreethaV16
 
一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理
一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理
一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理
upoux
 
Introduction to Computer Networks & OSI MODEL.ppt
Introduction to Computer Networks & OSI MODEL.pptIntroduction to Computer Networks & OSI MODEL.ppt
Introduction to Computer Networks & OSI MODEL.ppt
Dwarkadas J Sanghvi College of Engineering
 
Null Bangalore | Pentesters Approach to AWS IAM
Null Bangalore | Pentesters Approach to AWS IAMNull Bangalore | Pentesters Approach to AWS IAM
Null Bangalore | Pentesters Approach to AWS IAM
Divyanshu
 
Determination of Equivalent Circuit parameters and performance characteristic...
Determination of Equivalent Circuit parameters and performance characteristic...Determination of Equivalent Circuit parameters and performance characteristic...
Determination of Equivalent Circuit parameters and performance characteristic...
pvpriya2
 
Call For Paper -3rd International Conference on Artificial Intelligence Advan...
Call For Paper -3rd International Conference on Artificial Intelligence Advan...Call For Paper -3rd International Conference on Artificial Intelligence Advan...
Call For Paper -3rd International Conference on Artificial Intelligence Advan...
ijseajournal
 
Supermarket Management System Project Report.pdf
Supermarket Management System Project Report.pdfSupermarket Management System Project Report.pdf
Supermarket Management System Project Report.pdf
Kamal Acharya
 
Transformers design and coooling methods
Transformers design and coooling methodsTransformers design and coooling methods
Transformers design and coooling methods
Roger Rozario
 
P5 Working Drawings.pdf floor plan, civil
P5 Working Drawings.pdf floor plan, civilP5 Working Drawings.pdf floor plan, civil
P5 Working Drawings.pdf floor plan, civil
AnasAhmadNoor
 
openshift technical overview - Flow of openshift containerisatoin
openshift technical overview - Flow of openshift containerisatoinopenshift technical overview - Flow of openshift containerisatoin
openshift technical overview - Flow of openshift containerisatoin
snaprevwdev
 
OOPS_Lab_Manual - programs using C++ programming language
OOPS_Lab_Manual - programs using C++ programming languageOOPS_Lab_Manual - programs using C++ programming language
OOPS_Lab_Manual - programs using C++ programming language
PreethaV16
 
Levelised Cost of Hydrogen (LCOH) Calculator Manual
Levelised Cost of Hydrogen  (LCOH) Calculator ManualLevelised Cost of Hydrogen  (LCOH) Calculator Manual
Levelised Cost of Hydrogen (LCOH) Calculator Manual
Massimo Talia
 
1FIDIC-CONSTRUCTION-CONTRACT-2ND-ED-2017-RED-BOOK.pdf
1FIDIC-CONSTRUCTION-CONTRACT-2ND-ED-2017-RED-BOOK.pdf1FIDIC-CONSTRUCTION-CONTRACT-2ND-ED-2017-RED-BOOK.pdf
1FIDIC-CONSTRUCTION-CONTRACT-2ND-ED-2017-RED-BOOK.pdf
MadhavJungKarki
 
Applications of artificial Intelligence in Mechanical Engineering.pdf
Applications of artificial Intelligence in Mechanical Engineering.pdfApplications of artificial Intelligence in Mechanical Engineering.pdf
Applications of artificial Intelligence in Mechanical Engineering.pdf
Atif Razi
 
Power Electronics- AC -AC Converters.pptx
Power Electronics- AC -AC Converters.pptxPower Electronics- AC -AC Converters.pptx
Power Electronics- AC -AC Converters.pptx
Poornima D
 
一比一原版(CalArts毕业证)加利福尼亚艺术学院毕业证如何办理
一比一原版(CalArts毕业证)加利福尼亚艺术学院毕业证如何办理一比一原版(CalArts毕业证)加利福尼亚艺术学院毕业证如何办理
一比一原版(CalArts毕业证)加利福尼亚艺术学院毕业证如何办理
ecqow
 
This study Examines the Effectiveness of Talent Procurement through the Imple...
This study Examines the Effectiveness of Talent Procurement through the Imple...This study Examines the Effectiveness of Talent Procurement through the Imple...
This study Examines the Effectiveness of Talent Procurement through the Imple...
DharmaBanothu
 
A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...
A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...
A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...
DharmaBanothu
 
SCALING OF MOS CIRCUITS m .pptx
SCALING OF MOS CIRCUITS m                 .pptxSCALING OF MOS CIRCUITS m                 .pptx
SCALING OF MOS CIRCUITS m .pptx
harshapolam10
 
Zener Diode and its V-I Characteristics and Applications
Zener Diode and its V-I Characteristics and ApplicationsZener Diode and its V-I Characteristics and Applications
Zener Diode and its V-I Characteristics and Applications
Shiny Christobel
 

Recently uploaded (20)

FULL STACK PROGRAMMING - Both Front End and Back End
FULL STACK PROGRAMMING - Both Front End and Back EndFULL STACK PROGRAMMING - Both Front End and Back End
FULL STACK PROGRAMMING - Both Front End and Back End
 
一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理
一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理
一比一原版(osu毕业证书)美国俄勒冈州立大学毕业证如何办理
 
Introduction to Computer Networks & OSI MODEL.ppt
Introduction to Computer Networks & OSI MODEL.pptIntroduction to Computer Networks & OSI MODEL.ppt
Introduction to Computer Networks & OSI MODEL.ppt
 
Null Bangalore | Pentesters Approach to AWS IAM
Null Bangalore | Pentesters Approach to AWS IAMNull Bangalore | Pentesters Approach to AWS IAM
Null Bangalore | Pentesters Approach to AWS IAM
 
Determination of Equivalent Circuit parameters and performance characteristic...
Determination of Equivalent Circuit parameters and performance characteristic...Determination of Equivalent Circuit parameters and performance characteristic...
Determination of Equivalent Circuit parameters and performance characteristic...
 
Call For Paper -3rd International Conference on Artificial Intelligence Advan...
Call For Paper -3rd International Conference on Artificial Intelligence Advan...Call For Paper -3rd International Conference on Artificial Intelligence Advan...
Call For Paper -3rd International Conference on Artificial Intelligence Advan...
 
Supermarket Management System Project Report.pdf
Supermarket Management System Project Report.pdfSupermarket Management System Project Report.pdf
Supermarket Management System Project Report.pdf
 
Transformers design and coooling methods
Transformers design and coooling methodsTransformers design and coooling methods
Transformers design and coooling methods
 
P5 Working Drawings.pdf floor plan, civil
P5 Working Drawings.pdf floor plan, civilP5 Working Drawings.pdf floor plan, civil
P5 Working Drawings.pdf floor plan, civil
 
openshift technical overview - Flow of openshift containerisatoin
openshift technical overview - Flow of openshift containerisatoinopenshift technical overview - Flow of openshift containerisatoin
openshift technical overview - Flow of openshift containerisatoin
 
OOPS_Lab_Manual - programs using C++ programming language
OOPS_Lab_Manual - programs using C++ programming languageOOPS_Lab_Manual - programs using C++ programming language
OOPS_Lab_Manual - programs using C++ programming language
 
Levelised Cost of Hydrogen (LCOH) Calculator Manual
Levelised Cost of Hydrogen  (LCOH) Calculator ManualLevelised Cost of Hydrogen  (LCOH) Calculator Manual
Levelised Cost of Hydrogen (LCOH) Calculator Manual
 
1FIDIC-CONSTRUCTION-CONTRACT-2ND-ED-2017-RED-BOOK.pdf
1FIDIC-CONSTRUCTION-CONTRACT-2ND-ED-2017-RED-BOOK.pdf1FIDIC-CONSTRUCTION-CONTRACT-2ND-ED-2017-RED-BOOK.pdf
1FIDIC-CONSTRUCTION-CONTRACT-2ND-ED-2017-RED-BOOK.pdf
 
Applications of artificial Intelligence in Mechanical Engineering.pdf
Applications of artificial Intelligence in Mechanical Engineering.pdfApplications of artificial Intelligence in Mechanical Engineering.pdf
Applications of artificial Intelligence in Mechanical Engineering.pdf
 
Power Electronics- AC -AC Converters.pptx
Power Electronics- AC -AC Converters.pptxPower Electronics- AC -AC Converters.pptx
Power Electronics- AC -AC Converters.pptx
 
一比一原版(CalArts毕业证)加利福尼亚艺术学院毕业证如何办理
一比一原版(CalArts毕业证)加利福尼亚艺术学院毕业证如何办理一比一原版(CalArts毕业证)加利福尼亚艺术学院毕业证如何办理
一比一原版(CalArts毕业证)加利福尼亚艺术学院毕业证如何办理
 
This study Examines the Effectiveness of Talent Procurement through the Imple...
This study Examines the Effectiveness of Talent Procurement through the Imple...This study Examines the Effectiveness of Talent Procurement through the Imple...
This study Examines the Effectiveness of Talent Procurement through the Imple...
 
A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...
A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...
A high-Speed Communication System is based on the Design of a Bi-NoC Router, ...
 
SCALING OF MOS CIRCUITS m .pptx
SCALING OF MOS CIRCUITS m                 .pptxSCALING OF MOS CIRCUITS m                 .pptx
SCALING OF MOS CIRCUITS m .pptx
 
Zener Diode and its V-I Characteristics and Applications
Zener Diode and its V-I Characteristics and ApplicationsZener Diode and its V-I Characteristics and Applications
Zener Diode and its V-I Characteristics and Applications
 

Level tuning. by zakpdf

  • 1. PETROCONTROL Advanced Control and Optimization 34 East 30th Street, New York, NY 10016 • Tel: 212-481-6195 • Fax: 212-447-8756 zak@petrocontrol.com TUNING OF AVERAGING LEVEL CONTROLLER By Y. Zak Friedman, PhD Principal Consultant Published in Hydrocarbon Processing Journal, December 1994
  • 2. Averaging level controller tuning, page 2 TUNING OF AVERAGING LEVEL CONTROLLERS. A friend of mine showed me the latest and greatest in level control technology. Look at Figure 1, he said, obviously the level movement is an indication of mass imbalance: Fin - Fout = A * (dL/dt) [1] Fin = flow of liquid into the vessel Fout = flow of liquid out of the vessel A = cross sectional area of the vessel dt = the time between scans (dL/dt) = level rate of change. The level controller operates by manipulating the outlet flow. Every scan it implements flow changes: dFo1, dFo2, dFo3, ------------ , dFok dFo1 = the change in outlet flow after the first scan from now dFo2 = the change in outlet flow after the second scan from now ' ' ' dFok = the change in outlet flow after a certain time horizon of interest: k scans. We assume that from now on the inlet flow will remain constant. The integral form of equation 1 then takes the form of: k A * (Lk - L0) = A * dL0 * k - ΣΣΣΣ ((k-i+1)*dt*dFoi) [2] i=1 Lk = the level that will be reached after the time horizon of k scans L0 = the current level reading dL0 = the change of level from the previous to the current scan. It indicates the initial mass imbalance. We wish to bring the level to its setpoint after the time horizon H, while at the same time minimize the movement of the manipulated variable Fout. This desire can be expressed mathematically as: k Minimize ΣΣΣΣ (dFoi)**2 [3] i = 1
  • 3. Averaging level controller tuning, page 3 Subject to the constraint of equation 2, except we replace Lk by the setpoint LSP, to express the desire to reach the setpoint after k moves: k A * (LSP - L0) = A * dL0 * k - ΣΣΣΣ ((k-i+1)*dt*dFoi) [4] i=1 LSP = The level controller setpoint With the help of some textbooks, my friend solved the problem as shown in equation 5, for the first control action dFo1. We take interest only in dFo1 because each scan the controller has to only come up with the next move. The solution for dFo1 is: dFo1 = C1 * dL0 + C2 * dt * (L0-LSP) [5] C1 = 4 * A / H C2 = 6 A / (H**2) H = the time horizon = dt * k This is nice, I said. Lets compare it to the famous Proportional Integral (PI) algorithm in its velocity form: dM = Kc * dL0 + (Kc/TI) * dt * (L0-LSP) [6] dM = change of the manipulated variable = dFo1 Kc = controller gain TI = controller reset time. You have discovered the PI algorithm I told my friend, with settings of: Kc = 4 * A / H [7] TI = .67 * H There was a moment of silence. It turned out that my friend's company offers a package, which provides the controller of equation 5 on a host computer, not realizing that any DCS would be quite capable of providing the same, or even better PI controller. I am writing this not to embarrass the company in question, but rather to show again here that the PI algorithm is mighty good for level control, and usually no alternatives are needed. I would also like to suggest a way of tuning for the averaging level controller based not on some arbitrary time horizon but by relating the tuning constants to physical characteristics of the vessel in question.
  • 4. Averaging level controller tuning, page 4 The Averaging Level Control Objective Figure 2 shows two level applications with entirely different objectives. The objective of figure 2A is to keep the level always at its setpoint, while moving the manipulated variable as much as it takes to steady the level quickly. In contrast, the objective of figure 2B is to minimize the movement of the manipulated variable while keeping the level within its alarm limits. This second application is called Averaging Level Control, and it is the subject of this paper. Before attempting to tune the controller, it would be useful to quantify the control objective. Say the controller is at steady state and the level is at setpoint. At some point a disturbance comes in such that the previous inlet flow changes by FD. Equation 1 tells us that the level will then start changing at a rate of: (dL/dt) = FD / A [8] The objective is to tune the controller such that it can handle a flow disturbance of magnitude FD without exceeding the alarm limits. It is assumed that before the disturbance occurred the vessel was at steady state with its level reading being equal to the setpoint. After reaching a level peak, which would almost equal the alarm setting, the objective is to gradually bring the level back to its setpoint. But how to choose the magnitude of FD? One obvious way is by observing the plant operation and selecting one of the largest disturbances. Another way, less precise but often more practical is to set FD as 20% of the typical outlet flow. 20% step change is a fairly large flow disturbance, and thus the resulting control settings will not often trigger an alarm. Setting the Initial Controller Gain Consider next a proportional only controller. Not that one is recommended, but in the initial part of the response the integral action plays only a minor role and it can be ignored. As equation 8 starts working and the level trends upwards, the proportional action would increase the outlet flow by: Fout = Fout0 + Kc * (L - LSP) [9] Fout0 = the initial outlet flow before the disturbance occurred The manipulated variable Fout will continue to increase as long as the level is rising, until finally, when the outlet flow equals the inlet flow, the level would stabilize at a new reading: Fout = Fout0 + FD = Fout0 + Kc * (L - LSP) [10]
  • 5. Averaging level controller tuning, page 5 Or: FD = Kc * (L - LSP) [11] Our tuning objective specifies that at that time the level will be just equal to the alarm limit, and that gives us a formula for calculating the controller gain: Kc = FD / (LIMIT - LSP) [12] LIMIT = the alarm limit of the controller From a control point of view it is best to select the setpoint to be at the middle of the range, i.e., 50% of the level, and have alarm limits at 20% and 80%. Though of course the setting of level setpoint and limits depends not only on control considerations but also on vessel geometry and process considerations. Equation 12 gives the gain in engineering units of say BPD / %. Since most DCS systems work not in engineering units but in % of range, the gain of equation 12 needs to be modified to: Kc% = (FD / Frange) * ((Lrange / (LIMIT - LSP) [13] Frange = The range of the manipulated variable flow measurement. Lrange = The range of the level measurement. Normally 100%. Setting the Initial Reset Time Once a new steady level is reached after a disturbance, the whole plant has stabilized. Is there a need to apply a reset action which would disturb the newly accomplished steady state, only to bring the level back to its setpoint? The answer is "yes", if you wish to regain the freedom of movement in both directions. But how quickly do we need to regain that freedom? The simple answer is that the level should be brought back to its setpoint in time to meet the next major disturbance. However we do not precisely know when the next disturbance would come. A reasonable way to address this uncertainty is to relate the reset time to the disturbance residence time in the vessel. The disturbance residence time is defined as: RTIME = VS / FD [14] VS = The surge volume. This is the volume bound between the level setpoint LSP and the level alarm limit LIMIT. The units of VS must be such that RTIME is calculated in minutes. RTIME = Disturbance residence time in minutes
  • 6. Averaging level controller tuning, page 6 A starting point which is likely to give a good result is a reset time of: TI = 4 * RTIME [15] By "good result" it is meant that there would be a reasonable tradeoff between using the surge volume of the vessel, and between recovering quickly from an upset situation. Tuning Test Most level loops will have no dynamic difficulties with the settings of equations 13 and 15. Loops without dead time would certainly perform well. Loops with some dead time will likely still perform well because averaging level tuning calls for slow, stable responses. It happens however that due to improper vessel design, interactions with other loops or excessive dead time, the controller cannot support the initial tuning objective. The response then becomes oscillatory. This section suggests a set of rules for tuning averaging level loops which exhibit such oscillatory behavior. Since averaging level tuning is normally stable, it would be a good idea, in case of sustained oscillations, to first check whether these oscillations are the result of unstable level control or just simply an oscillatory disturbance. When in doubt, the level controller can be turned to Manual. If the oscillations were caused by level instability they would then die down. If it has been established that the level controller is responsible for the oscillations, the presence of these oscillations indicates unusual dynamic problems as stated above. It is advisable then to have discussions with process engineers and operators to understand why the loop is oscillatory. Attention should be paid to the heat exchange system which often provides the mechanism for slow loop to loop interactions. When there are oscillations, either damped or unstable, the reset time ought to be considered first. For a satisfactory response the reset time should be at least twice as long as the oscillation period. The period of oscillation is defined in Figure 3 as twice the time between the first high and first low peaks of a response. If TI is sufficiently long and the response is still too oscillatory, it is an indication that this loop cannot fulfill the objective of handling a disturbance of magnitude FD. There is a need then to reduce the gain until the loop response is satisfactory. For level control loops, it would be reasonable to allow no more than three peaks in the response: One high and one low, followed by another small high or low peak. As shown if Figure 3, the loop then will have no more than one overshoot and one undershoot. Once the new gain is set, equation 12 can be rearranged to assess how much of a disturbance this controller can now handle without sounding an alarm: FD = Kc * (LIMIT - LSP) [16]
  • 7. Averaging level controller tuning, page 7 If FD is lower than 10% of the normal outlet flow, the loop will likely remain a problem loop. Nonlinear Control Algorithms. Some DCS systems have the facility of scheduling the controller gain Kc, so that it would increase with control deviation as follows: Kc = Kl * (1. + Knl * ABS (L - LSP) / 100) [17] Kl = The linear control gain Knl = A nonlinear coefficient Such a control action provides the ability to reduce the manipulated variable activity at small disturbances, at the expense of large adjustments when there are large disturbances. In the author's opinion, the usefulness of nonlinear level algorithms is overrated. If the mass imbalance disturbance is large, then a weak initial action will cause the level to stray further away from setpoint. The level will eventually reach the region of higher gain and force the strong action required for the disturbance. The changes in the manipulated variable will then be even more abrupt than those of the linear controller. As a rule, vessels whose residence time is too short perform better with linear control. Vessels whose residence time is adequate give a somewhat better performance with nonlinear control. For tuning the nonlinear algorithm, it is recommended to first find Kcmax as per equation 13: Kcmax = (FD / Frange) * ((Lrange / (LIMIT - LSP) [18] Then set Kl and Knl so that the control action would double when approaching the level limit: Kl = Kcmax / 2 [19] Knl =100 / ABS (LIMIT - LSP) [20] Direct Level to Valve Control. Modern units are likely to have most of their level controllers cascading to flow controllers. Such cascades are easier to tune because the level - flow process gain remains constant. The tuning procedure for a level to valve type controller is similar to that of the cascade, except for the units of the flow disturbance FD. For determining the controller gain there is a need to define FD not as volume per time, but in terms of how a flow disturbance of magnitude FD would change the opening of the valve. I.e., FD must be defined as % valve position change. Frange of equation 13 is then 100%.
  • 8. Averaging level controller tuning, page 8 Once that is done, equation 13 can be used. However, for calculating the reset time according to equation 14 and 15, FD must be defined again in terms of volume per unit time, or % level per unit time, so that the reset time is in minutes. Level Reading Correction With Irregular Shape of the Vessel. Many DCS systems have the ability to correct the level reading so that it represents real volume, rather than height. To determine whether the additional complication of correcting that reading is worth it, there is a need to discriminate between two cases. First consider the special, but common case of a horizontal vessel, where the level setpoint is at the middle of the vessel, and the high and low limits are at 20% and 80% of the vessel diameter respectively. Second consider a more general case of irregular vessels. To begin with the special case of the level setpoint being at the middle of a horizontal vessel, the Pythagorean theorem shows that at 80% or 20% level reading, the cross sectional area is reduced to 80% of the area in the middle of the cylinder. The effect of that reading error would be similar to the nonlinear controller of equation 17, with the control gain being 25% stronger at high deviations (1/0.8 = 1.25). Hence we conclude that it is in fact desirable to have such an error and no level linearization is required. About the same conclusion can be reached for a spherical vessel, except there the area at the limits is 64% of the area in the middle, and the nonlinear effect is then so that the gain at the limits is 56% stronger than in the middle. This increase is perfectly acceptable, as evidenced by the recommendation of equations 18 through 20. For the general case of irregular shape, or even for cylinders where the setpoint is not in the middle, it is recommended that level correction be performed, if that is possible. Otherwise the controller becomes difficult to tune and the tuning objective looses its meaning. Conclusions The PI algorithm is an excellent device for controlling level. To this date no better alternatives have been established. The control objective calls for a weak reset action, often resulting in reset times in the order of one hour. The method proposed here for tuning the PI level controller has been widely applied and is known to work well. It makes maximum use of the surge capacity of a vessel, and in so doing it tends to stabilize the whole plant. Nonlinear level control can be counter-productive when the vessel is too small. When the vessel size is adequate nonlinear level control has a small advantage over linear control.
  • 9. Averaging level controller tuning, page 9 FIGURE 1. A SIMPLE LEVEL CONTROL CASCADE Fin LC FC Fout
  • 10. Averaging level controller tuning, page 10 FIGURE 2. LEVEL CONTROL RESPONSE TO A MASS BALANCE DISTURBANCE 2A. TIGHT LEVEL OBJECTIVE FLOW LEVEL 2B. AVERAGING LEVEL OBJECTIVE FLOW LEVEL
  • 11. Averaging level controller tuning, page 11 FIGURE 3. OSCILLATORY LEVEL TUNING P/2 SETPOINT PERTURBATION LEVEL FLOW