0% found this document useful (0 votes)
42 views

Practical Process Control

Uploaded by

gad480
Copyright
© © All Rights Reserved
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
42 views

Practical Process Control

Uploaded by

gad480
Copyright
© © All Rights Reserved
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 277

Practical Process Control©

Techniques for Applied Process Control


Practical Process Control

Copyright © 2007 Control Station, Inc. All Rights Reserved 2


Fundamental Principles of Process Control

What We Will Learn in This Section


Introduction & Motivation for Process Control
The Terminology of Process Control
Control Loop Block Diagrams
Everyday Examples to Build Our Terminology
Home Heating System
Cruise Control in a Car
Overall Workshop Goals and Methods

Copyright © 2007 Control Station, Inc. All Rights Reserved 3


Motivation for Automatic Process Control

Safety First:
people, environment, equipment

The Profit Motive:


meeting final product specs
minimizing waste production
minimizing environmental impact
minimizing energy use
maximizing overall production rate

Copyright © 2007 Control Station, Inc. All Rights Reserved 4


“Loose” Control Costs Money

65 operating constraint
PV & SP (%) 60 set point far from
profit constraint
55

SP
more profit

45

Copyright © 2007
40 poor control = large variation in PV by Control Station, Inc.
All Rights Reserved

Time

It takes more processing to remove impurities, so greatest


profit is to operate as close to the maximum impurities
constraint as possible without going over

It takes more material to make a product thicker, so greatest


profit is to operate as close to the minimum thickness
constraint as possible without going under
Copyright © 2007 Control Station, Inc. All Rights Reserved 5
“Tight” Control is More Profitable

65 operating constraint set point near


60 profit constraint
PV & SP (%)
SP

50
more profit

tight control = small variation in PV


45

40
Copyright © 2007 by Control Station, Inc. All Rights Reserved

Time

A well controlled process has less variability in the measured


process variable (PV), so the process can be operated close
to the maximum profit constraint.

Copyright © 2007 Control Station, Inc. All Rights Reserved 6


Terminology for Home Heating Control

Control Objective
Measured Process Variable (PV)
Set Point (SP)
Controller Output (CO)
Manipulated Variable
Disturbances (D) thermostat
controller
set point TC TT
temperature heat loss
sensor/transmitter (disturbance)

control
signal

fuel flow furnace


valve

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Copyright © 2007 Control Station, Inc. All Rights Reserved 7


Home Heating Feedback Control

Measurement → Computation → Action

Is house cooler than set point? (Tsetpoint  Thouse > 0)

Action  open fuel valve

Is house warmer than set point? (Tsetpoint  Thouse < 0)

  Action  close fuel valve

Copyright © 2007 Control Station, Inc. All Rights Reserved 8


Home Heating Control Block Diagram

manipulated
controller output, CO house
controller error fuel flow
signal to furnace valve temperature
e(t) = (SP – PV) to furnace

set point, SP Furnace


Thermostat Home Heating
+- Fuel
(desired temp) Controller Process
Valve

disturbances
measured temperature (heat loss from home)
process variable signal, PV

Temperature
Copyright © 2007 by Control Station, Inc. Sensor/Transmitter
All Rights Reserved

Copyright © 2007 Control Station, Inc. All Rights Reserved 9


General Control Loop Block Diagram

controller error controller output manipulated


e(t) = (SP – PV) signal, CO process variable
variable

set point, SP Final Control


+- Controller Process
Element (FCE)

disturbance, D
measured process variable
signal, PV

Measurement
Copyright © 2007 by Control Station, Inc. Sensor/Transmitter
All Rights Reserved

Copyright © 2007 Control Station, Inc. All Rights Reserved 10


Examples Used in this Workshop

Measurement Sensors:
temperature, pressure, pressure drop, level, flow,
density, concentration

Final Control Element:


solenoid, valve, variable speed pump or compressor,
heater or cooler

Automatic Controllers:
on/off, PID, cascade, feed forward, multivariable,
model-based Smith predictor, sampled data,
parameter scheduled adaptive control

Copyright © 2007 Control Station, Inc. All Rights Reserved 11


Workshop Goals

Learn why modeling the dynamic behavior of a process is


fundamental to controlling it
Practice methods of collecting and analyzing process data to
determine dynamic behavior
Learn what "good" or "best" control performance means for
a particular process
Understand the computational methods behind PID control
and learn when and how to use each form
Learn how controller tuning impacts performance and how
to determine values for these parameters
Understand the limitations and pitfalls of the different
controllers and learn how to turn this to your advantage

Copyright © 2007 Control Station, Inc. All Rights Reserved 12


Thought Experiment: Cruise Control in a Car

Copyright © 2007 Control Station, Inc. All Rights Reserved 13


Thought Experiment: Cruise Control in a Car

Control Objective:
maintain car velocity
Measured Process Variable (PV):
car velocity (“click rate” from transmission rotation)
Manipulated Variable:
pedal angle, flow of gas to engine
Controller Output (CO):
signal to actuator that adjusts gas flow
Set point (SP):
desired car velocity
Disturbances (D):
hills, wind, curves, passing trucks....

Copyright © 2007 Control Station, Inc. All Rights Reserved 14


Cruise Control Block Diagram

manipulated
controller error controller output, CO gas flow rate
e(t) = (SP – PV) signal to gas pedal to car engine car speed

set point, SP Gas Pedal


Cruise Car Speed
+- Control
(desired speed) Controller Process
Element

disturbances
measured “click rate” (hills, wind, etc.)
PV signal

Magnet and Coil Sensor


Copyright © 2007 by Control Station, Inc.
All Rights Reserved

Copyright © 2007 Control Station, Inc. All Rights Reserved 15


Hands-On Case Study: Gravity-Drained Tanks

Process Variable (PV)


Set Point (SP)
Controller Output (CO)
Disturbances (D)
CO

SP
PV

Copyright © 2007 Control Station, Inc. All Rights Reserved 16


Hands-On Case Study: Heat Exchanger

Process Variable (PV)


Set Point (SP)
Controller Output (CO)
Disturbances (D)

CO

PV

SP

Copyright © 2007 Control Station, Inc. All Rights Reserved 17


Understanding Dynamic Process Behavior

What We Will Learn in This Section


Dynamic Process Behavior – What It Is & Why We Care
What a FOPDT Dynamic Model Represents
Analyzing Step Test Plot Data to Determine FOPDT
Dynamic Model Parameters
Process Gain, Time Constant & Dead Time
How To Compute Them From Plot Data
How to Use Them For Controller Design and Tuning
How to Recognize Nonlinear Processes

Copyright © 2007 Control Station, Inc. All Rights Reserved 18


Dynamic Process Behavior and Controller Tuning

Consider cruise control for a car vs a truck


how quickly can each accelerate or decelerate
what is the effect of disturbances (wind, hills, etc.)

Controller (gas flow) manipulations required to maintain


set point velocity in spite of disturbances (wind, hills)
are different for a car and truck because the dynamic
behavior of each "process" is different

Dynamic behavior  how the measured process variable


(PV) responds over time to changes in the controller
output (CO) and disturbances (D)

Copyright © 2007 Control Station, Inc. All Rights Reserved 19


Graphical Modeling of Dynamic Process Data

To learn about the dynamic behavior of a process, we


analyze measured process variable (PV) test data

PV test data can be generated by suddenly changing the


controller output (CO) signal

The CO should be moved far and fast enough so that the


dynamic behavior is clearly revealed as the PV responds

The dynamic behavior of a process is different as operating


level changes (nonlinear behavior), so collect data at
normal operating conditions (design level of operation)

Copyright © 2007 Control Station, Inc. All Rights Reserved 20


Modeling Dynamic Process Behavior

The best way to understand process data is through modeling

Modeling means fitting a first order plus dead time (FOPDT)


dynamic model to the process data:
dPV
p + PV = Kp  CO(t  θp)
dt

where:
PV is the measured process variable
CO is the controller output signal

The FOPDT model is simple (low order and linear) so it only


approximates the behavior of real processes

Copyright © 2007 Control Station, Inc. All Rights Reserved 21


Modeling Dynamic Process Behavior

When a first order plus dead time (FOPDT) model


is fit to dynamic process data

dPV
p + PV = Kp  CO(t  θp)
dt

The important parameters that result are:


Steady State Process Gain, Kp
Overall Process Time Constant,  p
Apparent Dead Time, Өp

Copyright © 2007 Control Station, Inc. All Rights Reserved 22


The FOPDT Model is All Important

FOPDT model parameters (Kp,  p and Өp) are used in


correlations to compute controller tuning values

Sign of Kp indicates the action of the controller


(+ Kp  reverse acting; — Kp  direct acting)

Size of  p indicates the maximum desirable loop sample time


(be sure sample time T  0.1 p )

Ratio of Өp/ p indicates whether model predictive control


such as a Smith predictor would show benefit
(useful if Өp > p )

Model becomes part of the feed forward, Smith Predictor,


decoupling and other model-based controllers

Copyright © 2007 Control Station, Inc. All Rights Reserved 23


Step Test Data and Dynamic Process Modeling
Manual Mode Step Test on Gravity Drained Tanks

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Process starts at steady state in manual mode


Controller output (CO) signal is stepped to new value
Process variable (PV) signal must complete the response

Copyright © 2007 Control Station, Inc. All Rights Reserved 24


Process Gain (Kp) from Step Test Data

Kp describes how far the measured PV travels in


response to a change in the CO
A step test starts and ends at steady state, so Kp can
be computed directly from the plot

Steady State Change in the Process Variable, ΔPV


Kp 
Steady State Change in the Controller Output, ΔCO

where PV and CO are the total change from initial to
final steady state

A large process gain, Kp, means that each CO action will


produce a large PV response

Copyright © 2007 Control Station, Inc. All Rights Reserved 25


Process Gain (Kp) for Gravity-Drained Tanks

PV = (2.9 – 1.9) = 1.0 m

CO = (60 – 50) = 10 %

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Compute PV and CO as “final minus initial”


steady state values

Copyright © 2007 Control Station, Inc. All Rights Reserved 26


Process Gain (Kp) for Gravity-Drained Tanks

PV = 1.0 m

PV 1.0 m m
Kp = –––– = ––––– = 0.1 –––
CO 10% %

CO = 10 %

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Kp has a size (0.1); a sign (+0.1), and units (m/%)

Copyright © 2007 Control Station, Inc. All Rights Reserved 27


Process Time Constant ( p ) from Step Test Data

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Time Constant,  p , describes how fast the measured PV


responds to changes in the CO
More specifically, how long it takes the PV to reach 63.2%
of its total final change (PV), starting from when it first
begins to respond

Copyright © 2007 Control Station, Inc. All Rights Reserved 28


Process Time Constant ( p ) from Step Test Data

Copyright © 2007 by Control Station, Inc. All Rights Reserved

t PVstart

1) Locate t PVstart , the time where the PV starts a


first clear response to the step change in CO

Copyright © 2007 Control Station, Inc. All Rights Reserved 29


Process Time Constant ( p ) from Step Test Data

PV63.2
PV total
63.2% of PV total

Copyright © 2007 by Control Station, Inc. All Rights Reserved

t PVstart

2) Compute 63.2% of the total change in PV as:


PV63.2 = PVinital + 0.632 PV

Copyright © 2007 Control Station, Inc. All Rights Reserved 30


Process Time Constant ( p ) from Step Test Data

PV63.2

P
Copyright © 2007 by Control Station, Inc. All Rights Reserved

t PVstart t 63.2

3) t 63.2 is the time when the PV reaches PV63.2


4) Time Constant,  p , is then: t 63.2 — tPVstart

Copyright © 2007 Control Station, Inc. All Rights Reserved 31


Time Constant ( p ) for Gravity-Drained Tanks

Copyright © 2007 by Control Station, Inc. All Rights Reserved

tPVstart = 4.1

Here, tPVstart = 4.1 min

Copyright © 2007 Control Station, Inc. All Rights Reserved 32


Time Constant ( p ) for Gravity-Drained Tanks

PV63.2 = 2.5
PV = 1.0 m
63.2% of PV total

Copyright © 2007 by Control Station, Inc. All Rights Reserved

4.1

PV63.2 = PVinital + 0.632 PV

= 1.9 + 0.632(1.0) = 2.5 m

Copyright © 2007 Control Station, Inc. All Rights Reserved 33


Time Constant ( p ) for Gravity-Drained Tanks

PV63.2 = 2.5

P P = 5.7 – 4.1 = 1.6 min


Copyright © 2007 by Control Station, Inc. All Rights Reserved

4.1 5.7

Time Constant,  p = t 63.2 — tPVstart = 1.6 min


 p must be positive and have units of time
Copyright © 2007 Control Station, Inc. All Rights Reserved 34
Process Dead-Time (Өp) from Step Test Data
Dead time, Өp, is how much delay occurs from the time when
the CO step is made until when the measured PV shows a first
clear response.

Өp is the sum of these effects:


transportation lag, or the time it takes for material to
travel from one point to another
sample or instrument lag, or the time it takes to collect,
analyze or process a measured PV sample
higher order processes naturally appear slow to respond
and this is treated as dead time

Dead time, Өp, must be positive and have units of time

Copyright © 2007 Control Station, Inc. All Rights Reserved 35


Process Dead-Time (Өp) from Step Test Data

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Өp
tCOstep
t PVstart

Өp = t PVstart — tCOstep

Copyright © 2007 Control Station, Inc. All Rights Reserved 36


Dead-Time (Өp) for Gravity Drained Tanks

Өp = 4.1 – 3.8 = 0.3 min

Copyright © 2007 by Control Station, Inc. All Rights Reserved

tCOstep = 3.8
t PVstart= 4.1

Өp = t PVstart — tCOstep = 0.3 min

Copyright © 2007 Control Station, Inc. All Rights Reserved 37


Dead-Time (Өp) is the Killer of Control

Tight control grows increasingly difficult as Өp becomes large


The process time constant is the clock of the process. Dead
time is large or small relative only to  p
When dead time grows such that Өp >  p , model predictive
control strategies such as a Smith predictor may show benefit
For important PVs, work to select, locate and maintain
instrumentation so as to avoid unnecessary dead time in a loop

Copyright © 2007 Control Station, Inc. All Rights Reserved 38


The FOPDT Model Parameters

In Summary

For a change in CO:

Process Gain, Kp  How Far PV travels

Time Constant,  p  How Fast PV responds

Dead Time, Өp  How Much Delay Before PV Responds

Copyright © 2007 Control Station, Inc. All Rights Reserved 39


Hands-On Workshop

Workshop #1
Exploring Dynamics of Gravity-Drained Tanks

Copyright © 2007 Control Station, Inc. All Rights Reserved 40


Processes have Time Varying Behavior

The CO to PV behavior described by an ideal FOPDT model is


constant, but real processes change every day because:
surfaces foul or corrode
mechanical elements like seals or bearings wear
feedstock quality varies and catalyst activity decays
environmental conditions like heat and humidity change

So the values of Kp,  p and Өp that best describe the dynamic


behavior of a process today may not be best tomorrow

As a result, controller performance can degrade with time and


periodic retuning may be required

Copyright © 2007 Control Station, Inc. All Rights Reserved 41


Processes have Nonlinear Behavior

…cause changing (nonlinear)


response in real processes
equal CO steps…

Copyright © 2007 by Control Station, Inc. All Rights Reserved

The dynamic behavior of most real processes


changes as operating level changes

Copyright © 2007 Control Station, Inc. All Rights Reserved 42


Processes have Nonlinear Behavior

3) but behavior of real processes


changes with operating level

2) FOPDT model response is


constant as operating level changes
1) with equal CO steps

Copyright © 2007 by Control Station, Inc. All Rights Reserved

A FOPDT model response is constant as operating level changes

Since the FOPDT model is used for controller design and tuning, a
process should be modeled at a specific design level of operation!

Copyright © 2007 Control Station, Inc. All Rights Reserved 43


Process Control Preliminaries

What We Will Learn in This Section

The “Wire In” to “Wire Out” Controller Viewpoint


On/Off Control and Its Limitations
Intermediate Value Control and the PID Algorithm
The Controller Design and Tuning Recipe
P-Only Controller Design, Tuning and Testing

Copyright © 2007 Control Station, Inc. All Rights Reserved 44


Process Control Loop Block Diagram

controller error controller output manipulated


e(t) = (SP – PV) signal, CO process variable
variable

set point, SP Final Control


+- Controller Process
Element (FCE)

disturbance, D
measured process variable
signal, PV

Measurement
Copyright © 2007 by Control Station, Inc. Sensor/Transmitter
All Rights Reserved

The final control element, process and sensor/transmitter


each have their own response gain (how far), time
constant (how fast) and dead time (how much delay)

Copyright © 2007 Control Station, Inc. All Rights Reserved 45


The Controller Only Sees “Wire Out” to “Wire In”
controller output
signal, CO

set point, SP Control Element (Valve)


Controller Process
Sensor, Transmitter…

disturbance, D
measured
process variable
signal, PV

Copyright © 2007 by Control Station, Inc. All Rights Reserved

The controller sends a CO signal out on one wire and receives


the measured PV signal back on another wire
From the controller’s view, the individual gains, time constants
and dead times all lump into one overall process behavior
Going forward, “process dynamics” refers to this combined or
overall “wire out” to “wire in” behavior

Copyright © 2007 Control Station, Inc. All Rights Reserved 46


The Designer’s “Process” Considers Each Instrument

For new installations, the dynamic behavior of the final control


element (e.g. a valve) and sensor should be considered prior
to purchase

A final control element and sensor should start to respond


quickly (add little dead time, Өp) and complete the response
quickly (have a small time constant,  p)

The qualifier “quickly” is relative to the overall time constant


of the process (a Өp of 9 min is large relative to a  p of 10
min but small relative to a  p of 1000 min)

If undesirable behavior (e.g. large dead time or nonlinear


behavior) can be traced to a particular instrument, then
consider relocation, maintenance or replacement

Copyright © 2007 Control Station, Inc. All Rights Reserved 47


On/Off Control - The Simplest Controller
upper dead band limit

lower dead band limit

On -

Off
Copyright © 2007 by Control Station, Inc. All Rights Reserved

The CO is either open/on/maximum or closed/off/minimum

To protect the final control element from wear, a dead band or an upper and
lower set point is used

As long as the measured PV remains between these limits, no changes in


control action are made

Copyright © 2007 Control Station, Inc. All Rights Reserved 48


On/Off Control Has Limited Use

On/off with dead band is useful for home appliances such


as furnaces, air conditioners, ovens & refrigerators

For most industrial applications, on/off is too limiting

Think about riding in a car


that has on/off cruise control

Copyright © 2007 Control Station, Inc. All Rights Reserved 49


Intermediate Value Control and PID

Intermediate value control permits tighter control with


less oscillation in the measured PV

Intermediate value control requires:


a sensor that can transmit a PV signal over a full
range of values
a control algorithm that can receive the PV signals
and compute CO signals across the complete range
between full on/off
a final control element that can assume intermediate
positions between full on/off

Example final control elements include process valves,


variable speed pumps and compressors, and heating and
cooling elements

Copyright © 2007 Control Station, Inc. All Rights Reserved 50


Intermediate Value Control and PID
The most popular intermediate value controller is PID

PID computes a CO signal based on control error:


Kc de(t)
CO= CO + Kc  e(t) +  e(t)dt + Kc  D
bias I dt
Proportional Integral Derivative

where:
CO = controller output signal
CObias = controller bias or null value
PV = measured process variable
SP = set point
e(t) = controller error = SP – PV
Kc = controller gain (a tuning parameter)
I = controller reset time (a tuning parameter)
D = controller derivative time (a tuning parameter)

Copyright © 2007 Control Station, Inc. All Rights Reserved 51


P-Only: The Simplest PID Controller

PV measured at intermediate values

SP

CO signal transmitted
over range of values

Copyright © 2007 by Control Station, Inc. All Rights Reserved

proportional (or P-Only) control is the simplest PID controller

sensor must measure PV over a full range of operation

controller computes CO values ranging from 0–100%

Copyright © 2007 Control Station, Inc. All Rights Reserved 52


The Gravity-Drained Tanks Control Loop
Measurement, computation and control action repeats every loop
sample time, T:

a sensor measures the liquid level process variable (PV)


this PV is subtracted from the set point level (SP) to compute
control error; e(t) = SP – PV

the controller computes a controller output signal (CO) based on


this error, e(t)

the CO is transmitted to the valve, causing it to move

this causes the liquid flow rate into the top tank to change,
which ultimately changes the level in the lower tank

The goal is to make controller error, e(t), equal 0 by keeping the


liquid level at set point (making PV = SP)

Copyright © 2007 Control Station, Inc. All Rights Reserved 53


The P-Only Control Algorithm
Computes an output signal every sample time, T, as:

CO = CObias + Kc  e(t)
where
CO = controller output signal
CObias = controller bias
e(t) = controller error
= SP – PV (or set point – process variable)
Kc = controller gain (a tuning parameter)

Kc  Kp (controller gain  process gain)


A larger Kc means a more active or aggressive controller
Like Kp, controller gain has a size, sign and units

Copyright © 2007 Control Station, Inc. All Rights Reserved 54


Controller Design and Tuning Recipe

1. Establish the design level of operation (DLO), i.e. the normal


or expected values for set point and major disturbances

2. Bump the process and collect controller output (CO) to


process variable (PV) dynamic process data around this DLO
(a step test is one kind of bump test)

3. Approximate the process data behavior with a first order plus


 p model (get values for model
dead time (FOPDT) dynamic
parameters Kp, and Өp)

4. Use the model parameters from step 3 in rules and


correlations to complete the controller design and tuning.

Copyright © 2007 Control Station, Inc. All Rights Reserved 55


1) The Design Level of Operation (DLO)
A controller is designed and tuned for a particular process
behavior (specific values of Kp,  p and Өp)

Real processes are nonlinear and their behavior changes (their


Kp,  p and/or Өp change) as operating level changes

…cause changing (nonlinear)


response in real processes
equal CO steps…

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Thus, a controller should be designed for a specific level of


operation (the DLO)

Copyright © 2007 Control Station, Inc. All Rights Reserved 56


2) Bump Process & Collect Dynamic Process Data
the design level of operation (DLO) for the measured process
variable (PV) is where the set point (SP) will be during normal
operation

the DLO also includes the important disturbance variables. The


major disturbances should be at their normal or typical values
when collecting dynamic process data

Bump the process (perform the dynamic test such as a step


test) as near practical to the DLO when the PV and
disturbances are quiet and steady

A bump test should move the CO far enough and fast enough
such that it generates a clear response in the PV

Copyright © 2007 Control Station, Inc. All Rights Reserved 57


3) Fit a FOPDT Model to the Data

Copyright © 2007 Control Station, Inc. All Rights Reserved 58


4) Controller Gain, Kc, from Correlations
P-Only control has one adjustable (tuning) parameter, Kc
CO = CObias + Kc  e(t)

Kc sets how active the controller is to changes in error, e(t)


if Kc is small, the controller is conservative or sluggish
If Kc is large, the controller is active or aggressive

P-Only control is so limited that there are no great tuning


correlations. One choice is the integral of time-weighted
absolute error (ITAE) correlation:

0.2   p 
1.22
Kc =  
Kp  θp 

Copyright © 2007 Control Station, Inc. All Rights Reserved 59


Understanding Controller Bias, CObias
Thought Experiment for: CO = CObias + Kc  e(t)
Consider a P-Only cruise controller where the CO sets the
flow of gas

Suppose while under cruise control, the measured speed


equals the desired speed equals 70 kph
Since PV = SP, then e(t) = 0 and the P-Only controller is:
CO = CObias + Kc  e(t)
= CObias + 0

If CObias is zero, then CO (the flow of gas to the engine) is


zero even though the car is going 70 kph
If the car is going 70 kph, there must be a baseline flow of
gas

This baseline CO is the bias or null value, CObias

Copyright © 2007 Control Station, Inc. All Rights Reserved 60


Understanding Controller Bias, CObias
For cruise control, the bias is the flow of gas that, in manual
mode, causes the car to travel the design speed of 70 kph when
the disturbances are at their normal or expected values
In general, CObias is the value of CO that, in manual mode,
causes the measured PV to maintain steady state at the design
level of operation (DLO)
The DLO includes the normal SP as well as the normal or
expected values for the major disturbances
Controller bias is not normally adjusted once the controller is
put in automatic (closed loop)

Copyright © 2007 Control Station, Inc. All Rights Reserved 61


Reverse Acting, Direct Acting and Control Action

Controllers provide negative feedback.


feedback Whenever the PV is
moving away from SP, the CO needs take the opposite action to
correct the problem and keep PV = SP (keep e(t) = 0)
If Kp is positive and the PV is too high, the controller must
decrease the CO to correct the error.
If Kp is negative and the PV is too high, the controller must
increase the CO to correct the error.

The control action is the opposite of the PV behavior, so:


When the process is direct acting (Kp positive), the
controller must be reverse acting
When the process is reverse acting (Kp negative), the
controller must be direct acting

Copyright © 2007 Control Station, Inc. All Rights Reserved 62


Reverse Acting, Direct Acting and Control Action

Since Kc always has the same sign as Kp, then


Kp and Kc positive  controller is reverse acting
Kp and Kc negative  controller is direct acting

Many commercial controllers only accept a positive Kc


The sign (or action) of the controller is then indicated by
specifying it as reverse or direct acting

If the wrong control action is entered, the controller will drive


the valve to full open or closed until the entry is corrected
Be aware that some manufactures swap this nomenclature, so
always check your controllers documentation.

Copyright © 2007 Control Station, Inc. All Rights Reserved 63


Offset - The Big Disadvantage of P-Only Control

offset
offset

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Big advantage of P-Only control:


only one tuning parameter (Kc) so it’s easy
to find “best” tuning

Big disadvantage:
the controller permits offset

Copyright © 2007 Control Station, Inc. All Rights Reserved 64


Offset - The Big Disadvantage of P-Only Control

Offset occurs under P-Only control when the set point


and/or disturbances are at values other than that used as
the design level of operation (that used to determine CObias)

CO = CObias + Kc  e(t)

How can the P-Only controller compute a value for CO that


is different from CObias?

The only way is if e(t)  0 (i.e., set point  measured PV)

Copyright © 2007 Control Station, Inc. All Rights Reserved 65


Controller Gain, Kc, Impacts Performance
offset offset

Kc 3Kc 6Kc

CO effort
Copyright © 2007 by Control Station, Inc. All Rights Reserved

As Kc increases:
Control effort increases
Offset decreases
Oscillatory behavior increases

Copyright © 2007 Control Station, Inc. All Rights Reserved 66


Proportional Band

Manufacturers make controller tuning confusing by using


different names and units for the same parameters

A popular alternative to Kc is proportional band, PB.

If CO and PV are in % and the CO signal ranges from a


minimum (COmin) to maximum (COmax) value, then:

PB = (COmax — COmin)/Kc

When CO and PV range from 0% to 100%, the common


conversion between Kc and PB is:

PB = 100/Kc

So if Kc is large, then PB will be small

Copyright © 2007 Control Station, Inc. All Rights Reserved 67


Hands-On Workshop

Workshop #2
P-Only Control of Tank Level

Copyright © 2007 Control Station, Inc. All Rights Reserved 68


Integral Action and PI Control

What We Will Learn in This Section


Essential Elements of the PI Controller
The Function of the Integral Term (Integral Action)
Advantages and Disadvantages to PI Control
Control Tuning From Correlations
Bumpless Transfer to Automatic
Reset Windup and Jacketing Logic

Copyright © 2007 Control Station, Inc. All Rights Reserved 69


The PI Controller
“Ideal” form of the PI Controller
Kc
CO= CO
bias
+ Kc  e(t) +
I  e(t)dt

where:
CO = controller output signal
CObias = controller bias or null value
PV = measured process variable
SP = set point
e(t) = controller error = SP – PV
Kc = controller gain (a tuning parameter)
I = controller reset time (a tuning parameter)

I is in denominator so smaller values provide a larger


weighting to the integral term
 I has units of time, and therefore is always positive
Copyright © 2007 Control Station, Inc. All Rights Reserved 70
Function of the Proportional Term
Proportional term acts on
e(t) = SP – PV

e(25) = 4
e(40) = – 2
PV

SP

Copyright © 2007 by Control Station, Inc. All Rights Reserved

25 40
Time (minutes)

The proportional term, Kc  e(t), immediately impacts CObias


based on the size of e(t) at a particular time t

The past history and current trajectory of the controller error


have no influence on the proportional term computation

Copyright © 2007 Control Station, Inc. All Rights Reserved 71


Control Calculation is Based on Error, e(t)

Proportional term acts on Same data plotted as


e(t) = SP – PV e(t) controller error, e(t)
e(25) = 4
e(40) = – 2
PV

SP
e(40) = –2
0
e(25) = 4

Copyright © 2007 by Control Station, Inc. All Rights Reserved Copyright © 2007 by Control Station, Inc. All Rights Reserved

25 40 25 40
Time (minutes) Time (minutes)

Here is identical data plotted two ways


To the right is a plot of error, where: e(t) = SP – PV

Error e(t) continually changes size and sign with time

Copyright © 2007 Control Station, Inc. All Rights Reserved 72


Function of the Integral Term

The integral term continually sums up error, e(t)

Through constant summing, integral action accumulates


influence based on how long and how far the measured
PV has been from SP over time.

Even a small error, if it persists, will have a sum total


that grows over time and the amount added to CObias will
similarly grow.

The continual summing of integration starts from the


moment the controller is put in automatic

Copyright © 2007 Control Station, Inc. All Rights Reserved 73


Integral Term Continually Sums the Value: SP – PV
Each box has Integral term continually
integral sum of 20 sums e(t) = SP – PV
(2 high x 10 wide)

Integral sum = – 34 Integral sum = 7

Integral sum = 135

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Time (minutes)

The integral is the sum of the area between SP and PV


At t = 32 min, when the PV first reaches the SP, the
integral is: 32min
 e(t)dt = 135
0 min

Copyright © 2007 Control Station, Inc. All Rights Reserved 74


Integral of Error is the Same as Integral of: SP – PV
Integral term continually
sums error, e(t)

Integral sum = 135

Integral sum = 7
Integral sum = – 34

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Time (minutes)

At t = 60 min, the total integral is: 135 – 34 = 101

When the dynamics have ended, e(t) is constant at zero and the
total integral has a final residual value: 135 – 34 + 7 = 108

Copyright © 2007 Control Station, Inc. All Rights Reserved 75


Advantage of PI Control – No Offset
The PI controller stops computing changes in CO when e(t)
equals zero for a sustained period
Kc
I 
CO= CO + Kc  e(t) + e(t)dt
bias

At that point, the proportional term equals zero, and the integral
term may have a residual value

Kc
CO = CObias + 0 + (108)
 I   
Integral acts as
“moving bias” term

This residual value, when added to CObias, essentially creates an


overall “moving bias” that tracks changes in operating level

This moving bias eliminates offset, making PI control the most


widely used industry algorithm
Copyright © 2007 Control Station, Inc. All Rights Reserved 76
Disadvantages of PI Control - Interaction

Integral action tends to increase the oscillatory or


rolling behavior of the PV

There are two tuning parameters (Kc and  I ) and


they interact with each other

Kc
CO= CO
bias
+ Kc  e(t) +
I  e(t)dt

This interaction can make it challenging to arrive at


“best” tuning values

Copyright © 2007 Control Station, Inc. All Rights Reserved 77


Disadvantages of PI Control - Interaction

2 Kc

Base Case Performance

Kc

Kc/2

Copyright © 2007 by Control Station, Inc. All Rights Reserved.

 I /2 I 2 I

Copyright © 2007 Control Station, Inc. All Rights Reserved 78


Bumpless Transfer to Automatic

Modern controller’s use a “bumpless transfer” when


switching to automatic

Bumpless transfer achieves a smooth transition to closed


loop by automatically:
setting CObias equal to the current CO value
setting the SP equal to the current PV value

So at switchover to automatic, there is no controller error


and the bias is properly set to produce no offset

As a result, no immediate control action is necessary that


would “bump” the measured PV

Copyright © 2007 Control Station, Inc. All Rights Reserved 79


Hands-On Workshop

Workshop #4
The Hazard of Tuning PI Controllers by Trial and Error

Copyright © 2007 Control Station, Inc. All Rights Reserved 80


Solution to “Guess and Test” Tuning

Best Practice – Always Follow the Design and Tuning Recipe:

1. Establish the design level of operation (DLO), i.e. the normal


or expected values for set point and major disturbances

2. Bump the process and collect controller output (CO) to


process variable (PV) dynamic process data around this DLO

3. Approximate the process response data with a first order plus


 p dynamic model (get values for model
dead time (FOPDT)
parameters Kp, and Өp)

4. Use the model parameters from step 3 in rules and


correlations to complete the controller design and tuning.

Copyright © 2007 Control Station, Inc. All Rights Reserved 81


Recipe Step 4 - Tuning from Correlations
LOOP-PRO uses Internal Model Control (IMC) Relations

First compute,  c , the closed loop time constant


(a small  c provides an aggressive or quick response)

Choose your performance using these rules:

aggressive:  c is the larger of 0.1  p or 0.8 Өp


moderate:
 c is the larger of 1 p or 8 Өp
conservative:
 c is the larger of 10  p or 80 Өp

PI tuning correlations use this


c and the FOPDT model values:

Kc =
1 p and  I = p
Kp (θp + c)

Copyright © 2007 Control Station, Inc. All Rights Reserved 82


Expected PI Controller Response Performance

Conservative Moderate Aggressive

Copyright © 2007 by Control Station, Inc. All Rights Reserved.

Set point tracking (servo) response as c changes

Copyright © 2007 Control Station, Inc. All Rights Reserved 83


Reset Time vs Reset Rate
Manufacturers confuse tuning and implementation by using
different names and units for the same controller parameter:

Some use proportional band (PB) instead of controller gain (Kc)


Some use reset rate ( R ) instead of reset time ( I ),
where: 1
R =
I

Reset rate (
 R ) has units of 1/time or sometimes repeats/minute

Know your manufacturer


before we start tuning a controller

Copyright © 2007 Control Station, Inc. All Rights Reserved 84


Integral Action and Reset Windup
The math makes if possible for the error sum (the integral) to
grow very large.
Kc
I 
CO= CO + Kc  e(t) + e(t)dt
bias
integral
The integral term can grow so large that the total CO signal stops
making sense (it can be signaling for a valve to be open 120% or
negative 15%)

“Windup” is when the CO grows to exceed the valve limits


because the integral has reached a huge positive/negative value

It is associated with the integral term, so it is called reset windup

The controller can’t regulate the process until the error changes
sign and the integral term shrinks sufficiently so that the CO
value again makes sense (moves between 0 – 100%).

Copyright © 2007 Control Station, Inc. All Rights Reserved 85


Reset Windup and Jacketing Logic

Industrial controllers employ jacketing logic to halt integration


when the CO reaches a maximum or minimum value
Beware if you program your own controller because reset
windup is a trap that novices fall into time and again
If two controllers trade off regulation of a single PV (e.g.
select control; override control), jacketing logic must instruct
the inactive controller to stop integrating. Otherwise, that
controller’s integral term can wind up.

Copyright © 2007 Control Station, Inc. All Rights Reserved 86


Dynamic (Bump) Tests for Controller Tuning

What We Will Learn in This Section


Bump Test Forms – Step, Pulse, Doublet, PRBS
Dynamic data must reveal CO to PV cause-and-effect
relationship
Using Loop Pro Design Tools for FOPDT model fitting
FOPDT modeling of set point driven closed loop data
Do not model disturbance driven data!

Copyright © 2007 Control Station, Inc. All Rights Reserved 87


Recipe Step 2: Generate Dynamic Bump Test Data
“Wire Out”
CO Signal

set point, SP Control Element (Valve)


Controller Process
Sensor, Transmitter…

disturbance, D
“Wire In”
PV Signal

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Controller’s should be designed using process data that shows


a clear PV response to a distinct CO change
This means that bump test (dynamic) data must be collected
using the signals exiting and entering our controller at the wire
termination interface
Major disturbances should be quiet during the bump test

Copyright © 2007 Control Station, Inc. All Rights Reserved 88


Steps for Generating Dynamic Bump Test Data

Process should start at steady state (CO, PV and major D’s)

Start recording CO and PV data before making the bump

Make a sudden CO change that forces a clear PV response

Make sure the PV response dominates the process noise

The disturbances should be quiet during the bump test

Copyright © 2007 Control Station, Inc. All Rights Reserved 89


Bump Must Dominate PV Noise Band

 NB brackets the PV noise (3) when is CO constant.


 Here NB = 1%

CO constant
Copyright © 2007 by Control Station, Inc. All Rights Reserved

A bump test must generate a response that clearly dominates


the random (noisy) PV behavior
A noise band (NB) is one way to gauge noise levels

Copyright © 2007 Control Station, Inc. All Rights Reserved 90


Data Should Show Dynamic “Cause and Effect”

NB = 1% PV = 4%

CO bump
Copyright © 2007 by Control Station, Inc. All Rights Reserved

The CO bump must force a clear and dominating PV response


Here the PV moves about 4 times the noise band, a good value
If you can see it, LOOP-PRO software can model it
Unmeasured disturbances can corrupt the PV data, so larger CO
bumps are generally better (10NB is the “pre-software” guideline)

Copyright © 2007 Control Station, Inc. All Rights Reserved 91


Open Loop Bumps Tests

Open loop tests require that a loop be put in manual; this


can be a problem in some plants.
Popular bump tests include: step, pulse, doublet, PRBS

Step Doublet
66 DLO 66 DLO DLO

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Pulse PRBS
66 DLO 66 DLO

Copyright © 2007 by Control Station, Inc. All Rights Reserved


Copyright © 2007 by Control Station, Inc. All Rights Reserved

Copyright © 2007 Control Station, Inc. All Rights Reserved 92


Step Test

66 DLO

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Desirable: can be analyzed by hand using a graphical analysis


Undesirable: moves the process for an extended period, causing
off-spec production and perhaps safety concerns
Undesirable: generates data on only one side of initial steady
state, which likely is the design level of operation (DLO)

Copyright © 2007 Control Station, Inc. All Rights Reserved 93


Pulse Test

66 DLO

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Pulse test is two step tests performed in rapid succession


Desirable: starts from and returns to an initial steady state
Undesirable: data is generated on only one side of the steady
state, which presumably is the design level of operation (DLO)

Copyright © 2007 Control Station, Inc. All Rights Reserved 94


Remember That Processes are Nonlinear

…cause changing (nonlinear)


response in real processes
equal CO steps…

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Most all processes show a changing (nonlinear) behavior as


operating level changes
Thus, it is good to collect data above and below the design level
of operation (DLO) to get a data set that describes the changing
behavior “on average”
Copyright © 2007 Control Station, Inc. All Rights Reserved 95
Doublet Test

66 DLO DLO

A doublet is two small pulses made in opposite directions:


starts from and returns quickly to the design level of operation
(DLO) with relatively small deviations
produces data that “averages out” nonlinear effects
Thus, doublet test is preferred by many practitioners

Copyright © 2007 Control Station, Inc. All Rights Reserved 96


Pseudo-Random Binary Sequence (PRBS) Test

66 DLO

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Pseudo-random binary sequence (PRBS) tests are a


sequence of controller output pulses that are
uniform in amplitude
alternating in direction
random in duration

Copyright © 2007 Control Station, Inc. All Rights Reserved 97


Pseudo-Random Binary Sequence (PRBS) Test

Desirable aspects:
stays very close to the design level of operation (DLO)
gives smallest maximum deviations of all open loop tests

A proper PRBS design requires specifying:


CO initial value (is associated with the DLO)
CO pulse amplitude
average duration of each pulse
randomized change in pulse duration around this average
length of the experiment itself

If multiple experiments are required to find a “best” test, all


benefit is lost - stick with the doublet test

Copyright © 2007 Control Station, Inc. All Rights Reserved 98


Recipe Step 3: Fit Model to Dynamic Data

Loop-Pro Design Tools module fits dynamic models to process


data with just a few mouse clicks
Data can be in variety of formats (e.g. text files, Excel files)
They must have at least three columns of data:
a time stamp
manipulated variable data (usually CO)
measured PV data

Copyright © 2007 Control Station, Inc. All Rights Reserved 99


For All Bump Test Data Sets

Process should start at steady state (CO, PV and major D’s)


when data collection begins
Start recording data before making the bump
First data point in the file should represent the true initial
steady state of the process

Copyright © 2007 Control Station, Inc. All Rights Reserved 100


Best Practice - View Data To Confirm Dynamic Content

Be sure to zoom on the bump test so that the modeling will


provide the most meaningful result.

Copyright © 2007 Control Station, Inc. All Rights Reserved 101


Fitting a First Order Plus Dead Time (FOPDT) Model

N
2
SSE =  [Measured Datai  Model Datai ]
i=1

Loop-Pro systematically searches for the Kp,  pand Өp that


minimizes the sum of squared errors (SSE) between the
measured data and the approximating model fit

The smaller the SSE for a given data set, the better the
model describes the data
R2 (also computed by LOOP-PRO) is essentially an SSE
normalized for the number of data points and magnitude of
the data, making it a general “goodness of fit” criterion. The
closer it is to 1, the better the model describes the data.

Copyright © 2007 Control Station, Inc. All Rights Reserved 102


Controller Design Using Automatic Mode Data

Set Point (SP) Driven Bump Tests Can Provide Useful Data:

Operations personnel may not willing or able to switch to


manual for a bump test. If so, proceed in automatic mode
(also called closed-loop)

For closed loop studies, dynamic data is generated by


stepping, pulsing or otherwise bumping the set point (SP)

The controller tuning must be aggressive enough such that


the SP bump causes a clear CO change, which in turn forces
a PV response that dominates the noise.

Copyright © 2007 Control Station, Inc. All Rights Reserved 103


Controller Must Force a Sharp CO Change
Manual Mode Automatic Mode
SP
PV (%)
CO (%)

sharp CO
movement

Kp=1.0  p =12.0 Өp=5.0 Kp=1.0  p =12.2 Өp=4.8

Open and closed loop FOPDT model fits are (essentially) the
same if the controller is tuned to force a sharp CO change
If CO change is very sluggish, or so overly active it produces
sustained PV oscillations, the model fit may not be as good

Copyright © 2007 Control Station, Inc. All Rights Reserved 104


Do Not Model Disturbance Driven Data
(for controller tuning)

A controller uses the FOPDT model to understand how its


“wire out” CO signal affects the “wire in” PV measurement

Bump test data must contain reasonably pure CO to PV


information so the FOPDT model will accurately describe the
cause-and-effect relationship

Disturbance events that occur during data collection will


degrade accuracy, and thus the value, of the FOPDT model

Copyright © 2007 Control Station, Inc. All Rights Reserved 105


Example: Here is P-Only Set Point Driven Data

FOPDT model (yellow)


PV

SP
PV data

sharp CO
Copyright © 2007 by Control Station, Inc. All Rights Reserved
movement

Controller SP step produces a clear CO response


FOPDT model fit visually describes the PV data
Therefore, this model is good for controller tuning

Copyright © 2007 Control Station, Inc. All Rights Reserved 106


Example (continued): And Disturbance Driven Data

SP constant PV data
PV

FOPDT model (yellow)

D steps

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Set Point is constant; all dynamics are disturbance driven


FOPDT model visually describes the data, but the model
is not describing CO to PV cause-and-effect behavior

Copyright © 2007 Control Station, Inc. All Rights Reserved 107


Result: Disturbance Driven Data Bad for Tuning

--- closed loop tests ---


Open Loop Set Point Disturbance
Step Driven Driven
Process gain, Kp (m/%) 0.09 0.09 -0.06
Time constant, Tp (min) 1.4 1.4 0.01
Dead time, Өp (min) 0.5 0.4 0.0

Set point driven FOPDT model matches open loop test data
Disturbance driven model is way off; Kp even has wrong sign
If a disturbance has corrupted a data set, run the test again

Copyright © 2007 Control Station, Inc. All Rights Reserved 108


Hands-On Workshop

Workshop #5
PI Control of Heat Exchanger Temperature

Copyright © 2007 Control Station, Inc. All Rights Reserved 109


Measuring and Monitoring Controller Performance

What We Will Learn in This Section


Evaluating Controller Performance
Classical Performance Criteria
Diagnostic Measures
Performance Monitoring Indexes

Copyright © 2007 Control Station, Inc. All Rights Reserved 110


Evaluating Controller Performance
Bioreactors can’t tolerate sudden operating changes because the
fragile living cell cultures could die.
» “good” control means PV moves slowly

Packaging/filling stations can be unreliable. Upstream process


must ramp back quickly if a container filling station goes down.
» “good” control means PV moves quickly

The operator or engineer defines what is good or best control


performance based on their knowledge of:
goals of production
capabilities of the process
impact on down stream units
desires of management

Copyright © 2007 Control Station, Inc. All Rights Reserved 111


Many Performance Analysis Methods

Classical “PV Response to Set Point Step” Analysis


Rise Time
Settling Time
Peak Overshoot Ratio
Diagnostic Measures
Auto and Cross Correlation
Power Spectrum (Spectral Density)

Performance Monitoring Indexes (Use Moving Window)


Moving Average Window
Relative Variance and Standard Deviation

Copyright © 2007 Control Station, Inc. All Rights Reserved 112


Classical Analysis - Peak Related Criteria

A B C

Copyright © 2007 by Control Station, Inc.. All Rights Reserved.

Peak Overshoot Ratio (POR) = B/A


Decay Ratio = C/B

Copyright © 2007 Control Station, Inc. All Rights Reserved 113


Classical Analysis - Peak Related Criteria

A = (30 – 20)
= 10%

B = (34.5 – 30)
= 4.5%

C = (31 – 30) A B C
= 1%

Copyright © 2007 by Control Station, Inc.. All Rights Reserved.

Here:
POR = 4.5/10 = 0.45 or 45%
Decay ratio = 1/4.5 = 0.22 or 22%

Copyright © 2007 Control Station, Inc. All Rights Reserved 114


Classical Analysis - Time Related Criteria

±5% of PV

PV

Copyright © 2007 by
Control Station, Inc..
All Rights Reserved.

peak time settling time


rise time

The clock for time related events begins


when the SP is stepped

Copyright © 2007 Control Station, Inc. All Rights Reserved 115


Classical Analysis - Time Related Criteria

±5% of PV

PV

Copyright © 2007 by
Control Station, Inc..
All Rights Reserved.

peak time settling time


rise time

trise = 43 – 30 = 13 min
tpeak = 51 – 30 = 13 min
tsettle = 100 – 30 = 70 min

Copyright © 2007 Control Station, Inc. All Rights Reserved 116


Classical Analysis Note
The classical criteria are not independent:
if decay ratio is large, then likely will have a long settling
time
if rise time is long, then likely will have a long peak time

±5% of PV

PV
A B C

Copyright © 2007 by
Control Station, Inc..
All Rights Reserved.
Copyright © 2007 by Control Station, Inc.. All Rights Reserved.

peak time settling time


rise time

Copyright © 2007 Control Station, Inc. All Rights Reserved 117


Classical Analysis – What If No Peaks?

SP

PV

Copyright © 2007 by
Control Station, Inc.
All Rights Reserved.

Old rule-of-thumb is to design for a 10% POR and/or a 25%


decay ratio (called a quarter decay)

Yet many modern operations want no PV overshoot at all,


making B = C = 0

With no peaks, the classical criteria are of limited value

Copyright © 2007 Control Station, Inc. All Rights Reserved 118


Settling Time Doesn’t Use Peaks – But is Noise Specific

±5% of PV ±20% of PV

Copyright © 2007 by
Control Station, Inc.
All Rights Reserved. Copyright © 2007 by
Control Station, Inc.
All Rights Reserved.

settling time
settling time

Settling time is the time it takes for the PV to enter and


remain within a band of operation - no peaks required
A process with more noise must have a wider settling band

Copyright © 2007 Control Station, Inc. All Rights Reserved 119


Advanced Diagnostic Measures

Auto Correlation
Measures how a signal matches a time-shifted version of itself
Good for separating a signal from noise, detecting trends, and
identifying repeating event patterns within a signal
Potential for monitoring controller performance (research in
progress)

Cross Correlation
Measure of relationship between two different signals, even
when the signals contain noise
Does a CO or disturbance impact several PVs? Compute cross
correlation to determine how strongly signal pairs are related

Copyright © 2007 Control Station, Inc. All Rights Reserved 120


Advanced Diagnostic Measures

Power Spectrum (Spectral Density)


Measures frequency and magnitude of change in a signal
Especially good for identifying oscillating behavior
Different signals may have something in common if
spectrum peaks coincide
Process Under PI Control

disturbance (D) oscillates at a


frequency of 17 minutes.

Copyright © 2007 Control Station, Inc. All Rights Reserved 121


Diagnostic Measures – Power Spectrum
Impact of disturbance (D) on PV is not obvious

Process Under PI Control

disturbance (D) oscillates at a


frequency of 17 minutes.

Copyright © 2007 Control Station, Inc. All Rights Reserved 122


Diagnostic Measures – Power Spectrum

Power Spectrum (Spectral Density) Clearly Connects


Disturbance (D) to PV Behavior
1.0
D
normalized power

0.8
PV
0.6

0.4

0.2

0
5 10 15 20 25 30 35
17
period of oscillation (min)

Copyright © 2007 Control Station, Inc. All Rights Reserved 123


Advanced Performance Monitoring Measures

Moving Average
A crude filtering of noisy data to make trends more visible

Moving Variance and Moving Standard Deviation


reveals trends in spread of data, even if data has noise
Useful for identifying changing process/controller performance

e.g., Relative Standard Deviation,  (note: variance = 2)

PV = process variable
n 1
 (PV(i  k  n)  SP) 2 SP = set point
i 0
PV(k) = average PV for window k
 (k )  n 1  100% i, k = indexes
PV(k ) n = window length

Copyright © 2007 Control Station, Inc. All Rights Reserved 124


Advanced Performance Monitoring Measures

Often applied to a “moving window” of data


PV

Time

Copyright © 2007 Control Station, Inc. All Rights Reserved 125


Advanced Performance Monitoring Measures
Must specify window width. Different widths reveal different
features in the data
Shorter windows useful for detecting sudden changes
longer windows useful for tracking process trends

Finding best window width can be challenging (some trial


and error involved)
PV

Time

Copyright © 2007 Control Station, Inc. All Rights Reserved 126


Performance Monitoring – Moving Standard Deviation

Here are many hours of PV data. Can you see when


loop performance changed?
PV

Time

Copyright © 2007 Control Station, Inc. All Rights Reserved 127


Controller Performance Has Clearly Changed

PV

Time

While noisy PV does not reveal obvious change in character, SP


tracking performance clearly shows differences

Copyright © 2007 Control Station, Inc. All Rights Reserved 128


Performance Monitoring – Moving Standard Deviation

Relative Standard Deviation offers a visual


Moving Standard Deviation performance monitoring measure

Time
window size = 500 time units

Copyright © 2007 Control Station, Inc. All Rights Reserved 129


Derivative Action and PID Control

What We Will Learn in This Section


Essential Elements of the PID Controller
The Chaos of Commercial PID Control
Derivative on Measurement is Used in Practice
Tuning PID Controllers Follows the Recipe
PV Noise Degrades Derivative Action

Copyright © 2007 Control Station, Inc. All Rights Reserved 130


The PID Controller
“Ideal” form of the PID Controller

Kc de(t)
CO= CO + Kc  e(t) +  e(t)dt + Kc  D
bias I dt
where:
CO = controller output signal
CObias = controller bias or null value
PV = measured process variable
SP = set point
e(t) = controller error = SP – PV
Kc = controller gain (a tuning parameter)
I = controller reset time (a tuning parameter)
D = controller derivative time (a tuning parameter)

Copyright © 2007 Control Station, Inc. All Rights Reserved 131


The PID Controller

Ideal PID Controller

Kc de(t)
CO= CO + Kc  e(t) +  e(t)dt + Kc  D
bias  I dt

A derivative is a slope or rate of change


 D provides a separate weight to the derivative (or rate of
change) of error, e(t) = SP – PV, as it changes over time
D has units of time so it is always positive
Larger values of  D increase influence of the derivative term

Copyright © 2007 Control Station, Inc. All Rights Reserved 132


Function of the Derivative Term

Proportional term considers how far PV is from SP at any


instant in time and adds or subtracts from CObias accordingly
(recall e(t) = SP – PV)
Integral term addresses how long and how far PV has been
from SP by continually summing e(t) over time
Derivative term considers how fast e(t) is changing at any
instant using the rate of change or slope of the error curve

rapidly changing e(t) = large derivative = large impact on CO

Derivative doesn’t consider if e(t) is positive, negative or how


much time has passed, just how fast e(t) is changing

Copyright © 2007 Control Station, Inc. All Rights Reserved 133


Many Different PID Forms – For Example:

Dependent Ideal Non-Interacting


Kc de(t)
e(t)dt + Kc  D
I 
CO= CO + Kc  e(t) +
bias dt

Dependent Interacting Series


  D Kc
e(t)dt + Kc   D
de(t)
CO= CO
bias
+ Kc  1+  e(t) +
  I I  dt

Independent
de(t)
CO= CO
bias
+ Kc  e(t) + Ki e(t)dt + Kd
dt

Copyright © 2007 Control Station, Inc. All Rights Reserved 134


Each PID Form
Has Several Options

Copyright © 2007 Control Station, Inc. All Rights Reserved 135


Order in the Chaos - All Are Equally Capable

All of the PID forms are identical in capability as long as


they are tuned with their proper matching correlations
(step 4 of the design and tuning recipe)

Different vendors use different terminology for the


same equations and/or parameters

Tuning software is beneficial for keeping track of the


dozens of possible combinations

Copyright © 2007 Control Station, Inc. All Rights Reserved 136


Different Terminology – Same Performance

Know Your
Manufacturer!

Copyright © 2007 Control Station, Inc. All Rights Reserved 137


Problem with Derivative on Error
Error
Data plotted as SP & PV Same data plotted as
SP controller error, e(t)

error, e(t) = SP  PV
PV & SP

=  when SP changes
de(t)
PV dt

0
Copyright © 2007
by Control Station, Inc.
All Rights Reserved

Time Time

A change in SP causes a sudden vertical spike in e(t)


de(t)/dt (the slope) of a vertical spike is infinity

If D is large enough to provide weight to the derivative term,
the result is a large and sudden manipulation in CO
This is called derivative kick and is undesirable

Copyright © 2007 Control Station, Inc. All Rights Reserved 138


So Derivative on Measurement is Used in Practice
Measurement
Data plotted as SP & PV Same data plotted as
SP controller error, e(t)

error, e(t) = SP  PV
PV & SP

=  when SP changes
de(t)
PV dt

0
Copyright © 2007
by Control Station, Inc.
All Rights Reserved

Time Time

Measurement (PV) trace is mirror image of error trace

Derivative (or slope or rate of change) of PV is opposite-but-equal


to derivative of e(t) everywhere except when SP changes

Copyright © 2007 Control Station, Inc. All Rights Reserved 139


Derivative on Measurement is the Solution
SP

PV & SP PV changes in a smooth


and continuous fashion

Copyright © 2007 by Control Station, Inc. All Rights Reserved.

Time

The PV’s of real processes change in a smooth and continuous fashion


(and their data trace will show this as long as T  0.1 p )
So "deriv on error = deriv on PV" everywhere except when SP changes,
and when SP changes, deriv on e(t) causes undesirable behavior
Solution  use PID with deriv on measurement (PV)

Copyright © 2007 Control Station, Inc. All Rights Reserved 140


Math Supports “Opposite but Equal” if SP Constant

Consider that if the set point (SP) is constant, then:


0
de(t) d  SP  PV  dPV
 =
dt dt dt

That is, as long as SP is constant, then:


deriv on error = – deriv on measurement

Copyright © 2007 Control Station, Inc. All Rights Reserved 141


Derivative on PV Does Not "Kick"

PID (deriv on error) PID (deriv on PV)

CO “kick”

Copyright © 2007 by Control Station, Inc. All Rights Reserved.

Heat Exchanger under PID control shows CO kick with derivative on e(t)
Impact of CO kick on PV performance depends on sample time (T) relative
to  p (fast/small sample time gives little chance for impact)
But potential for wear on mechanical FCE (e.g., valve) is always a concern

Copyright © 2007 Control Station, Inc. All Rights Reserved 142


PID with Derivative on Measurement
Dependent Ideal Non-Interacting
Kc dPV
 Kc  D
I 
CO= CO + Kc  e(t) + e(t)dt
bias dt

Dependent Interacting Series


  D Kc
 Kc  D
dPV
CO= CO
bias
+ Kc  1+  e(t) +
 I  I  e(t)dt
dt

Independent
dPV
CO= CO
bias
+ Kc  e(t) + Ki e(t)dt   Kd
dt

Because it does not “kick” when the SP changes:

PID with derivative on measurement


is preferred in practical applications

Copyright © 2007 Control Station, Inc. All Rights Reserved 143


Understanding Derivative Action
dPV dPV
is zero is negative
dt dt

PV & SP

dPV is large and positive


dt

PV slope changes
during response
Copyright © 2006 by Control Station, Inc. All Rights Reserved

Time

Assuming Kc and  D are positive and appropriate size:


when dPV/dt (the slope) is positive, the derivative contribution
works to decrease CO from its current value
when dPV/dt is negative, derivative contribution increases CO

Copyright © 2007 Control Station, Inc. All Rights Reserved 144


PID Controllers Work in Harmony

Proportional term provides a rapid response to controller error

Integral term eliminates offset but increases the oscillatory or


rolling behavior of the PV

Derivative term works to decrease oscillations in the PV


because its largest influence is when PV is rapidly changing

Copyright © 2007 Control Station, Inc. All Rights Reserved 145


Step 4 - Controller Tuning from Correlations
Choose performance with,  c , the closed loop time constant
aggressive:  c is the larger of 0.1 p or 0.8 Өp
moderate:  c is the larger of 1  p or 8 Өp
conservative:  c is the larger of 10  p or 80 Өp

The Internal Model Control (IMC) tuning correlations are:

Kc I D
1   p +0.5 θp   p +0.5 θp
 p θp
Ideal 
 
Kp  c +0.5 θp  2 p + θp

1  p 
p 0.5 θp
Interacting 
Kp   
c +0.5 θp 

Independent algorithm tunings can be computed directly


from above Kc,  I and D 
Copyright © 2007 Control Station, Inc. All Rights Reserved 146
Step 4 - Controller Tuning from Correlations

Other Design Issues from FOPDT Model:

Sign of Kp indicates the action of the controller


(+ Kp  reverse acting; – Kp  direct acting)

Size of  p indicates the maximum desirable loop sample


time (be sure sample time T  0.1 p )

Ratio of Өp/ p indicates if dead time compensation (e.g.,


Smith predictor) would show benefit (useful if Өp >  p )

The FOPDT model becomes part of the feed forward, Smith


Predictor, decoupling and other model-based controllers

Copyright © 2007 Control Station, Inc. All Rights Reserved 147


PID Set Point Tracking
PID shows decreased oscillations compared to PI performance

Heat Exchanger – Aggressive Tuning


SP

PID has somewhat:


shorter rise time
faster settling
PI PID time
smaller overshoot

Copyright © 2007 by Control Station, Inc. All Rights Reserved.

Copyright © 2007 Control Station, Inc. All Rights Reserved 148


PID Set Point Tracking
Each PID algorithm performs the same – as long as each
is tuned with its proper correlation

Heat Exchanger – Moderate Tuning


SP

PID Ideal PID Interacting

Copyright © 2007 by Control Station, Inc. All Rights Reserved.

Copyright © 2007 Control Station, Inc. All Rights Reserved 149


Focus on Derivative Action
For all three response plots below, Kc and I are constant
Measurement (PV) noise is set to zero to eliminate its
influence on the CO signal
This isolates the impact of  D as a tuning parameter
Increasing Derivative Action
PV & SP

0.5 D D 2 D
Copyright © 2007 by Control Station, Inc. All Rights Reserved.

Time

Copyright © 2007 Control Station, Inc. All Rights Reserved 150


Focus on Derivative Action
Increasing Derivative Action

PV & SP

0.5 D D 2 D
Copyright © 2007 by Control Station, Inc. All Rights Reserved.

Time

If middle plot is base case design performance:



If D is too small, the oscillating nature of the process
increases

If D is too large, derivative action inhibits rapid
movement in PV

Copyright © 2007 Control Station, Inc. All Rights Reserved 151


Disadvantages of Derivative
Parameter Interaction: PID has three tuning parameters which interact and must be balanced to
achieve desired performance

2 Kc

Base Case Performance

Increasing Derivative Action Kc


PV & SP

Kc/2
0.5D D 2 D
Copyright © 2007 by Control Station, Inc. All Rights Reserved.
Copyright © 2007 by Control Station, Inc. All Rights Reserved.

Time
 I /2 I 2 I
For every D… …there is a new grid of Kc and  I patterns

Copyright © 2007 Control Station, Inc. All Rights Reserved 152


Disadvantages of Derivative
There are so many possible response patterns that “guess and
test” tuning becomes problematic
wastes valuable human and capital resources
consumes feed material and operating utilities
result is lost productivity and reduced revenue

Best Practice – follow the Design and Tuning Recipe:


1. Establish the design level of operation (DLO), i.e. the normal or
expected values for set point and major disturbances

2. Bump the process and collect controller output (CO) to process


variable (PV) dynamic process data around this DLO
3. Approximate the process data behavior with a first order plus dead
p
time (FOPDT) dynamic model (get values for model parameters
Kp, and Өp)

4. Use the model parameters from step 3 in rules and correlations to


complete the controller design and tuning

Copyright © 2007 Control Station, Inc. All Rights Reserved 153


Disadvantages of Derivative

Measurement Noise is a Problem:


Derivative action loses its benefits when there is random
error (noise) in the measured PV – a common occurrence
The derivative action causes PV measurement noise to be
amplified and reflected in the CO signal
This is because a noisy PV signal has changing derivatives
as the slope switches direction at every sample

Copyright © 2007 Control Station, Inc. All Rights Reserved 154


Noise Degrades Derivative Action

SP

slope rapidly
decreasing
PV & SP

slope rapidly
increasing
PV

Copyright © 2007 by Control Station, Inc. All Rights Reserved.

Time
Slope (derivative) switches direction every sample
This produces alternating CO actions (called “chatter”) from
the PID algorithm
The CO chatter is amplified based on the size of D
Copyright © 2007 Control Station, Inc. All Rights Reserved 155
Noise Degrades Derivative Action
PV & SP Increasing Noise in PV

PV performance
degrades

Copyright © 2007 by
Control Station, Inc.
All Rights Reserved. Because
CO repeatedly
CO

hits low constraint

As noise level increases, its impact on CO chatter is apparent


If CO hits a constraint, lack of “symmetry in randomness” can
impact PV

Copyright © 2007 Control Station, Inc. All Rights Reserved 156


Hands-On Workshop

Workshop #7
PID Control of Heat Exchanger Temperature

Copyright © 2007 Control Station, Inc. All Rights Reserved 157


Using Signal Filters In Our PID Loop

What We Will Learn in This Section


Sources of Random PV Signal Error (Noise)
The Basics of Filtering
Internal and External Filters
The PID with Controller Output (CO) Filter Algorithm
PID with CO Filter Design, Tuning and Performance

Copyright © 2007 Control Station, Inc. All Rights Reserved 158


Sources of Random PV Measurement Noise
Noise  random variations in a signal

Signal Noise tends to be higher in frequency


Often is electrical interference (e.g. a pump kicks on, sending
an electrical upset throughout the plant circuitry)
Can also arise from poor hardware (e.g. imprecise sample
time stamps; low quality or improperly specified instruments)

Process Noise tends to be lower in frequency


Requires process knowledge to know what is a disturbance to
be controlled vs noise to be filtered
Bubbles and splashing that corrupts a level measurement is
process noise that might benefit from filtering
A poorly-mixed vessel that displays slow random variations in
bulk temperature is not a likely candidate for signal filtering

Copyright © 2007 Control Station, Inc. All Rights Reserved 159


Signal Filtering

Filtering  smoothing a noisy signal with math manipulations

raw PV
PV

filtered PV
CO

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Time

Copyright © 2007 Control Station, Inc. All Rights Reserved 160


Filtering Cautions and Concerns
Before working to “filter away” signal noise, first try and fix
the problem with normal maintenance practices

PV
raw PV

filtered PV
CO

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Time

Filtered signals lag behind the raw signal (add dead time and
increase time constant)
As filtering increases and the signal becomes smoother, added
dead time decreases best possible control performance
Copyright © 2007 Control Station, Inc. All Rights Reserved 161
External Filters in Control
External filters are individual and separate hardware
or software items in the control loop

SP SP CO CO
+ PID FCE Process
Filter Filter
Final Control
Element

Copyright © 2007 by
Control Station, Inc.
All Rights Reserved PV PV Sensor &
Filter Transmitter

Common filters that are independent from the controller


Set point (SP) filter
Controller output (CO) filter
measured process variable (PV) filter

Copyright © 2007 Control Station, Inc. All Rights Reserved 162


External Filters in Control
SP SP CO SP
+ PID

SP & filtered SP
Filter

filtered SP
Copyright © 2007 by
Control Station, Inc.
All Rights Reserved
PV

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Time
Set Point Filters
Not used to address PV noise but included for completeness
SP filters smooth out sudden set point changes so they are
fed gradually to the controller
Thus can use an aggressive tuning for disturbance rejection.
Filtered SP changes are fed gradually to the controller, so SP
response performance remains moderate (or conservative
depending on degree of SP filtering)
Disturbance rejection and SP tracking performance can be
different – but must design & implement a SP filter to do this

Copyright © 2007 Control Station, Inc. All Rights Reserved 163


External Filters in Control

SP SP CO CO
+ PID FCE Process
Filter Filter
Final Control
Element

Copyright © 2007 by
Control Station, Inc.
All Rights Reserved PV PV Sensor &
Filter Transmitter

Process Variable (PV) Filters


Often PV filters are in-line devices designed specifically to
minimize high frequency electrical interference
If filter is added only for improving control, then consider
other options.
Noise only has modest impact on proportional action and no
impact on integral action. Why add filter delay to these
controller terms if there is no benefit?

Copyright © 2007 Control Station, Inc. All Rights Reserved 164


External Filters in Control

SP SP CO CO
+ PID FCE Process
Filter Filter
Final Control
Element

Copyright © 2007 by
Control Station, Inc.
All Rights Reserved PV PV Sensor &
Filter Transmitter

Controller Output (CO) Filters


While PV filters smooth the signal feeding the controller,
CO filters smooth the noise or “chatter” in the CO signal
sent to the final control element (FCE)
Even if noise does not cause control problems, a filter
that smoothes the CO signal will reduce wear on the FCE

Copyright © 2007 Control Station, Inc. All Rights Reserved 165


Internal Filters in Control
Internal filters are part of the control algorithm

SP CO
+ PI +

PV SP CO
D + PI +
Filter
Copyright © 2007 by
D
Control Station, Inc. PV D
All Rights Reserved Filter
Copyright © 2007 by
Control Station, Inc.
All Rights Reserved
PV

Since noise impacts derivative action, only need to filter


signal feeding D term
P and I terms don’t see any filter delay with this architecture
Makes no difference if filter is put before or after D term;
they are mathematically identical forms

Copyright © 2007 Control Station, Inc. All Rights Reserved 166


The PID with CO Filter Algorithm
An all-in-one PID with Controller Output Filter algorithm can
be tuned following the recipe, thus building on our existing
knowledge and experience
SP CO
+ PID w/ CO Filter

Copyright © 2007 by Control Station, Inc.


PV All Rights Reserved

Dependent Ideal Non-Interacting


CO=CO
bias
+ Kc  e(t) + Kc e(t)dt + Kc 
I   D
de(t)  
dt
 D
dCO
dt

Filter Term
Dependent Interacting Series
  D
e(t)dt + Kc  D de(t)    D dCO
Kc
CO=CO
bias
+Kc 1+  e(t) +
I I  dt  dt

Filter Term

Copyright © 2007 Control Station, Inc. All Rights Reserved 167


Always Follow the Design and Tuning Recipe…

1. Establish the design level of operation (DLO), i.e. the normal


or expected values for set point and major disturbances

2. Bump the process and collect controller output (CO) to


process variable (PV) dynamic process data around this DLO

3. Approximate the process data behavior with a first order


plus dead time (FOPDT) dynamic model (get values for
model parameters Kp,  p and Өp)

4. Use the model parameters from step 3 in rules and


correlations to complete the controller design and tuning

Copyright © 2007 Control Station, Inc. All Rights Reserved 168


Step 4 - Controller Tuning from Correlations
Choose performance with,  c , the closed loop time constant
aggressive:  c is the larger of 0.1 p or 0.8 Өp
moderate:  c is the larger of 1  p or 8 Өp
conservative:  c is the larger of 10  p or 80 Өp

The Internal Model Control (IMC) tuning correlations are:

Kc I D 

1   p +0.5 θp   p +0.5 θp  p θp  c   p + 0.5 θp 


Ideal 
Kp   
c + θp  2 p + θp  p   c + θp 
1  p 
p c
Interacting Kp

  c +

θp 
0.5 θp  c + θp

Copyright © 2007 Control Station, Inc. All Rights Reserved 169


Comparing Controller Performance
Heat Exchanger – Aggressive Tuning

Ideal PI Ideal PID Ideal PID w/ Filter

Copyright © 2007 by Control Station, Inc. All Rights Reserved

IMC tuned ideal algorithm: PI vs PID vs PID w/ CO Filter

Copyright © 2007 Control Station, Inc. All Rights Reserved 170


Comparing Controller Performance
Heat Exchanger – Moderate Tuning

Ideal PID w/ Filter Interacting PID


Interacting PID w/ Filter

Copyright © 2007 by Control Station, Inc. All Rights Reserved

IMC tuned ideal vs interacting algorithm

Copyright © 2007 Control Station, Inc. All Rights Reserved 171


Hands-On Workshop

Workshop #8
PID with CO Filter & Control of the Multi-Tank Process

Copyright © 2007 Control Station, Inc. All Rights Reserved 172


The Variety of PID Control Combinations
Proportional Only (P-Only)
P-Only is very stable and straightforward to tune. Use when simple
control and sustained offset are acceptable.

Proportional + Derivative (PD)


The derivative term allows for stronger proportional action, thus giving
fast response with reduced offset. Derivative action dampens
oscillations. Yet large derivative will amplify noise to produce CO
“chatter.” Use when a rapid initial response is desired, the signal is
noise-free, and some sustained offset is acceptable.

Proportional + Integral (PI)


PI control is by far the most widely used controller in the process
industries. Tuning parameters interact so use a tuning recipe approach
to minimize time and waste.

Proportional + Integral + Derivative (PID)


Full PID is challenging to tune, creates CO chatter when the PV signal is
noisy, and provides only modest performance benefits over PI control.
Unless signal has little noise, consider a PID with CO filter algorithm if
PI alone does not provide desired performance.

Copyright © 2007 Control Station, Inc. All Rights Reserved 173


Feature Controller AB SLC 500 AB PLC 5 AB Honeywell UDC 3000
Term ControlLogix
1 2
Proportional Controller Gain KC = 0.1 to 25.5 Kc = 0 to 32,767 Kc = Floating Point Kc = 0.1 to 9999
2
Proportional Gain Kp = 0 to 32,767 Kp = Floating Point

Proportion Band PB = 0.1% to 999.9%

Integral Repeats 1/Ti, 1/Ti RSET MIN = 0.00 to 50.00


1 2 minutes / repeat
Ti = 0.1 to 25.5 Ti = 0 to 32,767
minutes / repeat minutes / repeat x 100 RSET RPM = 0.00 to 50.00
repeats / minute
3
Integral Gain Ki = 0 to 32,767 0.06 – 60
1/seconds x 1000 0.001 – 1
1 2
Derivative Derivative Time Td = 0.01 to 2.55 Td = 0 to 32767 Td RATE MIN = 0.08 to 10.0
minutes minutes
2
Derivative Rate Kd = 0 to 32767

Derivative Filter Yes/No

Bias Yes Yes Yes MAN RSET = -100 to +100%

Controller Action Reverse Acting E = SP - PV E = SP - PV E = SP - PV

Direct Acting E = PV - SP E = PV - SP E = PV - SP
2
Update Time 0.01 to 10.23 1 to 32,767
seconds seconds x 100

Notes: 1
0 to 3276.7 in SLC 5/03 and higher processors when the RG bit is set.
2
Divided by 100 for calculations
3
Divided by 1000 for calculations

Copyright © 2007 Control Station, Inc. All Rights Reserved 174


Setting Derivative Filter in Allen-Bradley PLCs
In the Allen Bradley PLC, the derivative filter is enabled by
selecting “derivative smoothing” on the PID configuration tab
Allen Bradley automatically determines the value of  as

1
 = Where Kd = derivative gain of
 T  independent algorithm
16   + 1

 Kd  T = loop sample time

Thus, the larger the Kd, the stronger the filter (the greater the
smoothing)

Copyright © 2007 Control Station, Inc. All Rights Reserved 175


Advanced Modeling of Process Behavior

What We Will Learn in This Section


Modeling for Offline Simulation
Modeling for Model-Based Control
Higher Order Model Forms
Which Models to Use and When
How Model Parameters Impact Behavior

Copyright © 2007 Control Station, Inc. All Rights Reserved 176


Advanced Modeling of Process Behavior

All real processes display dynamic behavior that is more


complex than FOPDT (first order plus dead time)
Yet FOPDT models approximate the fundamental behavior of
how a PV responds to changes in CO for most all processes:
the direction
how far
how fast
with how much delay
Thus, a FOPDT model provides the essential information
required for controller tuning

Copyright © 2007 Control Station, Inc. All Rights Reserved 177


Other Reasons to Model
When controller tuning is the goal, always use a FOPDT model of
CO to PV dynamic behavior

(for integrating process, use FOPDT Integrating models)

Models have uses beyond controller tuning:


Offline dynamic simulations of processes
The design and construction of model-based control algorithms

Copyright © 2007 Control Station, Inc. All Rights Reserved 178


Modeling for Offline Simulation
Simulations are useful for investigating different process
behaviors, controller algorithms, loop architectures, and
tuning values
Simulations allow fast and safe “what if” studies without
consuming raw materials or utilities, generating waste,
disrupting production schedules...
If derived from first principals, sophisticated models can
take years to develop
The more studies that use a simulation instead of the
actual process, the greater the savings in time and money

 The value of conclusions drawn from a simulation


depends on how well the model describes the process

Copyright © 2007 Control Station, Inc. All Rights Reserved 179


Model Based Control
Controller capability can be improved if a dynamic model
is incorporated as part of the control algorithm.
These models essentially “predict the future” and begin
corrective action based on an estimate of future behavior
Popular model-based architectures including feed forward,
Smith predictor, multivariable decouplers, and model
predictive controllers
Such controllers require significantly more effort to
properly design, tune, validate and maintain.
The controller model must reasonably predict the actual
dynamic behavior of a process for improved performance

Copyright © 2007 Control Station, Inc. All Rights Reserved 180


Overdamped Process Model Forms

This workshop focuses on processes with streams comprised


of gases, liquids, powders, slurries and melts
The measured PVs tend to be temperature, pressure, level,
flow, density, concentration, and the like
These are overdamped processes because there is no
natural tendency to oscillate
They tend to be self regulating processes because they seek
a steady operating level if all variables are held constant

Copyright © 2007 Control Station, Inc. All Rights Reserved 181


Self Regulating Overdamped Models

First Order Plus Dead Time (FOPDT)


dPV
P  PV  KP  CO(t  P )
dt

Second Order Plus Dead Time (SOPDT)

d2PV dPV
P1 P2  (P1  P2 )  PV  KP  CO(t  P )
dt2 dt

Second Order Plus Dead Time with Lead Time (SOPDT w/ L)

d2PV dPV  dCO(t  P ) 


P1 P2  (P1  P2 )  PV  KP  CO(t  P )  L 
dt2 dt  dt 

Copyright © 2007 Control Station, Inc. All Rights Reserved 182


Which One to Use?

Higher order models have more adjustable parameters


This makes them better for data interpolation (i.e.,
following the twists and turns within a given data set)
Yet higher order models do not extrapolate well beyond
the bounds of the original data used to fit the model – a
common occurrence

Choose the simplest model that describes your data


because it will provide the “safest” extrapolation

Copyright © 2007 Control Station, Inc. All Rights Reserved 183


s
5 9
Process
Process ResponseShapes
Response Shapes When
WhenForced by Step
Forced by S
5 8 Process
Process
Response ResponseShapes
Response
Shapes Shapes
of 1stWhen
andForced
When 2ndbyOrder
Forced Step Change
by Step Change
Models
First Order Second Or
e

5 7

C oFirst
m pOrder
a r i n g a F i r s t O Cr doSecond
emr pa na Order
rd i nS ge ca o Fn id r s Ot Or d red r e Rr ea sn p d o
c

5 6
P r oProcess
c PV
Process e s s : Response
C u Response
s t o m P r o cWhen
eShapes
ss
Shapes P r oForced
When
When
Forced c eForced
by s sa: Step
C by
u s t oStep
mChange
by P Step
rChange
o c e s s Change C o n tro lle r: M
5 5
o

C o n t ro lle r O u t p u t P ro c e s s V a ria b le
P ro c e s s V a ria b le
60 First Order 60 Second Order
r

5 4
58 58
5 3
56 single arcsingle arc
56 ‘s’ shaped
P

5 2 54 responseresponse
single arc 54 response
‘s’ shaped
5 1 52 response 52 response
50 50
5 0
C o n t r o lle r O u t p u t

4 9
1 7 06 5 1 8 0 2 2 0 6 5 2 3 0
Second order model has an extra derivative with time
0 1 0 2 0 3 0 4 0 5 0 6 0 7 0 8 0 9 0 1 0 0 1 1 0 1 2 0 1 3 0 1 4 0
4 0 1 5 0 1 6 0 1 9 0 2 0 0 2 1 0 2 4 0 2 5 0 2 6 0 2 7 0 2 8 0 2 9 0 3

e ( t im e u n it s ) T im e
1 6 0 constant 1 8 0 that
1 9 0 enables 2a1 0 gradual 2 3“s”
5 0 shaped 6 0 response
40 150 170 200 220 0 240 250 260 270 280 290 3
0 1 0 2 0 3 0 4 0 7 0 8 0 9
e ( t im e u n it s ) 6 0 60

55 55

50 50
Copyright © 2007 Control Station, Inc. All Rights Reserved 184
Response Shapes of 1st and 2nd Order Models Loop-Pro: Design Too
d Time (SOPDT) Model Fit of Gravity
Loop-Pro: Drained
Design Tools Tank Data
Model: First Order Plus Dead Time (FOPDT) File Name: GDT.txt

5 FOPDT SSE = 0.287


R2 = 0.993
4

Pro cess Vari a bl e


3

78
Loop-Pro: Design Tools
Model: Second Order Plus Dead Time (SOPDT) File Name: GDT.txt

72 5
SOPDT SSE = 0.187
66
R2 = 0.996
a bl e p ul a te d Vari a bl e

4
Pro cess VariMani

60

7.6 9.5 11.4 13.3 15.2 17.1 19.0 20.9


3 Time

78 Gain (K) = 0.1213, Time Constant (T1) = 1.55, Dead Time (TD) = 0.6556
Goodness of Fit: R-Squared = 0.9935, SSE = 0.2873

Second order72
model better describes this data set
visually; with
66
lowest SSE; with R-squared closest to 1
Manip ul a te d Vari a bl e

60

7.6 9.5 11.4 13.3 15.2 17.1 19.0 20.9


Time

Copyright © 2007 Control Station, Inc. All Rights Reserved 185


K = 0.1179, T1 = 1.117, T2 = 0.6334, TD = 0.3289
Goodness of Fit: R-Squared = 0.9958, SSE = 0.1875
Impact of Process Gain on Model Behavior
Impact of Kp on Dynamic Model Behavior
Process: Single Loop Custom Process Cont.: Manual Mode
70
P = 10
60 P = 2.5
Process Vari a bl e /S etp oi n t PV

50

40
65
Kp = 1 Kp= 2 Kp = –1
60
Cont r ol lCO
e r Outp ut

55

50

0 150 300 450 600


Time (time units)

Process gain is the “how far” variable


Double Kp and the PV will travel twice as far
for the same CO change

Copyright © 2007 Control Station, Inc. All Rights Reserved 186


Impact of Time Constant on Model Behavior
Process: Single Loop Custom Process
Impact of P on Dynamic
Loop-Pro: Case Studies Model Behavior Cont.: Manual Mode

60 Kp = 1
P = 0
Process Vari a bl e /S et p oi n t PV

55

slower
50 response

P = 10 P = 25
70

65

60
C ont r ol l eCO
r Outp ut

55

50

0 50 100 150 200 250 300 350 400 450


Time (time units)

Time constant is the “how fast” variable


Make first order P two times larger and the PV response
takes twice as long (doubling the two P of a SOPDT model
more than doubles the response time)

Copyright © 2007 Control Station, Inc. All Rights Reserved 187


Impact of Dead Time on Model Behavior
Impact of P on Dynamic Model Behavior
Process: Single Loop Custom Process Cont.: Manual Mode

60
Kp = 1
delayed
P = 10
PV

55
response
Process Vari a bl e

50
70

65 P = 0 P = 25
60
CO
C ontr ol l e r Outp ut

55

50

0 50 100 150 200 250 300 350 400 450


Time (time units)

Dead time is the “with how much delay” variable


Adding P does not changes the shape of a response,
just how much time passes before the response begins

Copyright © 2007 Control Station, Inc. All Rights Reserved 188


Impact of Lead Element on Model Behavior

L weights the rate of change (derivative) of the CO signal


It describes the initial influence that a change in CO has on
the PV response
Lead time:
has units of time
can be either positive or negative

Copyright © 2007 Control Station, Inc. All Rights Reserved 189


Impact of Lead Element on Model Behavior
Process: Single Loop Custom Process
Impact of L on Dynamic Model Behavior Cont.: Manual Mode
70

overshoot
60
Process Vari a bl e PV

50
inverse
40

L = +20
70

65
L = – 20
60
Contr ol l eCO
r Outp ut

55

50

0 50 100 150 200 250 300 350 400 450


Time (time units)

For a step increase in CO (large positive derivative)


if L is positive,
positive the model imparts a brief positive movement
to PV on top of the natural process dynamics
If L is negative,
negative the model imparts a brief negative movement
to PV on top of the natural process dynamics

Copyright © 2007 Control Station, Inc. All Rights Reserved 190


Techniques for Adaptive PID

What We Will Learn in This Section


Why Adaptive PID is Useful
How to Implement Adaptive PID
Using Loop-Pro to Generate PID Parameters
Example of Adaptive PID
Gap Control

Copyright © 2007 Control Station, Inc. All Rights Reserved 191


Heat Exchanger Shows Nonlinear Behavior

equal SP steps

PV response varies with


a fixed-tuning PI controller

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Processes often exhibit changing (or nonlinear)


behavior as operating level changes
As a result, “best” tuning can change if the set point
moves the PV across a range of operation

Copyright © 2007 Control Station, Inc. All Rights Reserved 192


Parameter Scheduled Adaptive Control

If a changing performance is not acceptable, parameter


scheduled adaptive control may be the solution
Developing an adaptive control strategy costs money
It requires additional bump tests
It consumes more engineering time
Be sure that the loop has sufficient impact on
profitability to justify the effort and expense

Copyright © 2007 Control Station, Inc. All Rights Reserved 193


Parameter Scheduled Adaptive Control

The method of approach:


divide the total range of operation into some
number of increments or operating ranges
select a controller algorithm (PI, PID or PID w/ CO
Filter) for the application
apply the controller tuning recipe once for each of
the operating increments
A computer then updates controller tuning “on the fly”
as operating level changes.

Copyright © 2007 Control Station, Inc. All Rights Reserved 194


Recipe Step 1 & 2: Define and Bump Around DLO

Design Levels Of Operation are Midpoints of Each Set Point Step

DLO 3 = 178 oC

DLO 2 = 163 oC

DLO 1

= 147 oC
Copyright © 2007 by Control Station, Inc. All Rights Reserved

Use this previous example as the bump tests around


three design levels of operation (DLOs)
Define the DLOs as the midpoint of each SP step
Thus DLO 1 = 147, DLO 2 = 163, DLO 3 = 178 °C

Copyright © 2007 Control Station, Inc. All Rights Reserved 195


Recipe Step 3: Fit a FOPDT Model to Each Bump
Model Fit of Set Point Step 1: 140 155 oC

PV data
Model Fit of Set Point Step 2: 155 170 oC

FOPDT model (in yellow)


PV data

FOPDT model (in yellow) Model Fit of Set Point Step 3: 170 185 oC

PV data

FOPDT model (in yellow)

Three bump tests require three


FOPDT model fits

Copyright © 2007 Control Station, Inc. All Rights Reserved 196


Step 4: Use Model Parameters to Tune Controller

The three FOPDT models give three different PI


tuning values in this study

Copyright © 2007 Control Station, Inc. All Rights Reserved 197


Table Look-Up
A look-up table makes tuning updates in discrete
jumps. When the PV is in a defined column span, use
the tunings listed

I

But computers can smoothly interpolate values across


a range of operation

Copyright © 2007 Control Station, Inc. All Rights Reserved 198


Note on Operating Level “Pointer” or Basis Value

The SP is not a good operating level pointer because it


shows where we hope the PV will be, but not necessarily
where it actually is
The CO value changes as operating level changes and as
the load disturbance changes. Thus, the relationship
between CO and current operating level is inconsistent
Current PV offers the most reliable indicator of expected
process behavior

Copyright © 2007 Control Station, Inc. All Rights Reserved 199


Linear/Polynomial Regression
Controll Gain as a Function of Process Variable (PV)
Linear Fit Too Simple Quadratic Fit Overly Complex
Controll Gain as a Function of Process Variable (PV)

1.2 1.2

(Kc) Kc
Gain (Kc) Kc

1 1

Gain,
Controller Gain,

0.8 0.8

Controller Gain
0.6 0.6

Controller
Controller

0.4 0.4

0.2 0.2

0 0
120 130 140 150 160 170 180 190 120 130 140 150 160 170 180 190
Process Variable (PV) Process Variable (PV)

PV PV

Using software like Excel to fit an equation through


bump test tuning values requires care
Make sure the fit is not so simple as to lose information
(e.g., linear fit) or so overly complex as to be unrealistic
(note dip in quadratic fit)

Copyright © 2007 Control Station, Inc. All Rights Reserved 200


Continuous “Schedule” Across Operating Range

Best choice is piece-wise linear fit between data


points. It’s easy to implement and provides
reasonable accuracy between tuning values.

Copyright © 2007 Control Station, Inc. All Rights Reserved 201


Continuous “Schedule” Across Operating Range
Interpolate Controller Gain as Operating Level Changes

- 0.18 Moderate
extrapolate Kc PI Tuning
- 0.16
- 0.14
• (147, - 0.15)
Kc ( % / degrees )

- 0.12 limit Kc

- 0.10

- 0.08
(163, - 0.07)

- 0.06
Copyright © 2007 by Control Station, Inc.

(178, - 0.05)
- 0.04 All Rights Reserved

140 150 160 170 180


PV (degrees)

Either choose to extrapolate (usually bad idea) or


limit at the high and low end (better choice)
Apply this same concept to all PID tuning values

Copyright © 2007 Control Station, Inc. All Rights Reserved 202


Parameter Scheduled Control of Heat Exchanger

adaptive PI tuning maintains


a constant performance in spite
of changing process behavior

Copyright © 2007 by Control Station, Inc. Rights Reserved

Use the continuous schedule approach as shown on


the previous slide for PI tuning, and the performance
remains constant across the range of operation

Copyright © 2007 Control Station, Inc. All Rights Reserved 203


Comparing Fixed PI with Adaptive PI

Fixed PI Tuning Parameter Scheduled Tuning

Copyright © 2007 by Control Station, Inc. All Rights Reserved


Copyright © 2007 by Control Station, Inc. Rights Reserved

Again, make sure the loop is economically


important to pay for the extra effort

Copyright © 2007 Control Station, Inc. All Rights Reserved 204


Related Method - Gap Control

Gap control uses moderate or conservative tuning when


the PV is near (within a band or gap of) the SP
If the PV is outside the gap, more aggressive tunings are
used to quickly bring the process back within to the SP

Copyright © 2007 Control Station, Inc. All Rights Reserved 205


Example of Gap Control
Moderate PI Control Gap PI Control

PV inside gap,
use moderate
PV outside gap,
use aggressive

Copyright © 2007 by Control Station, Inc. All Rights Reserved

Disturbance rejection using constant or traditional


PI control (moderate tuning) shown to left
To the right, when the PV moves outside the band
or gap, aggressive tunings “kick in” to bring the PV
quickly back within the band

Copyright © 2007 Control Station, Inc. All Rights Reserved 206


Integrating (Non-Self Regulating) Processes

What We Will Learn in This Section

Non-Self Regulating Behavior


Modeling Non-Self Regulating Behavior
First Order Model plus dead time
Second Order Model plus dead time
Model-Fitting and Visual Identification
Tuning Correlations

Copyright © 2007 Control Station, Inc. All Rights Reserved 207


Integrating (Non-Self Regulating) Processes

An integrating process’s measured process variable is stable


in an open loop configuration only at its balance point.
Making a step change in the controller output of a stable
integrating process will cause the process variable to move
increasingly in one direction.

Example: Liquid Level in a Surge Tank

What Happens if the Discharge Flow is


HIGHER than the Inlet Flow?

Copyright © 2007 Control Station, Inc. All Rights Reserved 208


Integrating (Non-Self Regulating) Processes

At the beginning, the level in the tank is constant, therefore the exit
flow is exactly matching the inlet flow
As the exit flow rate is increased, more liquid is leaving the tank than is
entering, therefore the tank drains.

Copyright © 2007 Control Station, Inc. All Rights Reserved 209


Integrating (Non-Self Regulating) Processes
Closed Loop Performance

As Kc becomes small and as it becomes large, the PV begins


displaying an underdamped (oscillating) response behavior.

Reset time, Ti, is held constant throughout the experiment while controller gain, Kc, is
increased across both plots.

Copyright © 2007 Control Station, Inc. All Rights Reserved 210


Integrating (Non-Self Regulating) Processes
Impact of Tuning Parameters Different for Integrating Processes

2Kc

Kc Base Case
Performance

Kc/2

Ti/2 Ti 2Ti

Copyright © 2007 Control Station, Inc. All Rights Reserved 211


Modeling Non-Self Regulating Dynamics

A different model must be used to describe this type of


process
First Order plus Dead Time Integrating

dPV *
= Kp  CO(t  θp )
dt

*
PV
Kp , Integrator Gain has units of, CO  time
θp ,dead time has units of time

Copyright © 2007 Control Station, Inc. All Rights Reserved 212


Graphical Technique for Model Fitting
The graphical method of fitting a FOPDT Integrating model to
process data requires a data set that includes at least two
constant values of controller output, CO1 and CO2.

Integrating processes
need not start at a
steady value (steady-
state) before a bump is
made to the CO

Copyright © 2007 Control Station, Inc. All Rights Reserved 213


Graphical Technique for Model Fitting
Integrator Gain, Kp*

y(t2 )  y(t1 )
Slope 
t2  t1

Step 1: Calculate Slopes

Copyright © 2007 Control Station, Inc. All Rights Reserved 214


Graphical Technique for Model Fitting
Integrator Gain, Kp*

Slope -Slope
* 2 1
K =
p CO -CO
2 1

*
Step 2: Calculate Integrator Gain, Kp

Copyright © 2007 Control Station, Inc. All Rights Reserved 215


Graphical Technique for Model Fitting
Integrator Gain, Kp*

Dead time is calculated


in similar fashion as
the self-regulation
FOPDT model

Step 3: Calculate Dead Time, θp


θp = 1.0 min

Copyright © 2007 Control Station, Inc. All Rights Reserved 216


Always Follow the Design and Tuning Recipe…

1. Establish the design level of operation (DLO), i.e. the normal


or expected values for set point and major disturbances

2. Bump the process and collect controller output (CO) to


process variable (PV) dynamic process data around this DLO

3. Approximate the process data behavior with a first order plus


dead time integrating(FOPDT Integrating) dynamic model
*
(get values for model parameters and Өp)
Kp

4. Use the model parameters from step 3 in rules and correct


tuning correlations to complete the controller design and
tuning

Copyright © 2007 Control Station, Inc. All Rights Reserved 217


Step 4 - Controller Tuning from Correlations
Choose performance with, c , the closed loop time constant
moderate :  c = 3 * Өp
very conservative:  c = 30 * Өp

PI tuning correlations use this  c and the FOPDT Integrating model


values:

c c
c

Copyright © 2007 Control Station, Inc. All Rights Reserved 218


Hands-On Workshop

Workshop #18
PI Control of the Pump Tank Process

Copyright © 2007 Control Station, Inc. All Rights Reserved 219


Cascade Control

What We Will Learn in This Section


The Cascade Control Architecture
Benefits of a Cascade Strategy
Design and Tuning a Cascade Controller
Application to a Flash Drum Process
Application to a Jacketed Reactor

Copyright © 2007 Control Station, Inc. All Rights Reserved 220


Cascade Control

Architectures for improved disturbance rejection


Feed Forward
Cascade
Both require additional instrumentation and
engineering time in return for a controller better able
to reject disturbances
Neither architecture benefits nor detracts from set
point tracking performance

Copyright © 2007 Control Station, Inc. All Rights Reserved 221


Traditional Feedback Loop is in the Dashed Circle

inner
disturb, D2 Inner
Disturbance

primary secondary secondary secondary primary


(outer) (inner) (inner) (inner) (outer)
SP1 Primary SP2 Secondary CO2 Secondary + PV2 Primary PV1
+ Controller + FCE +
– – Controller Process Process
e.g. valve

inner secondary process variable, PV2

Copyright © 2007
by Control Station, Inc.
All Rights Reserved
outer primary process variable, PV1

A cascade is comprised of two ordinary PID controllers


The inner secondary loop has a traditional feedback structure,
and it is nested inside the outer primary loop

Copyright © 2007 Control Station, Inc. All Rights Reserved 222


Nested Loops Work to Protect Outer Primary PV1
inner
disturb, D2 Inner
cascade works
Disturbance to protect PV1

primary secondary secondary secondary primary


(outer) (inner) (inner) (inner) (outer)
SP1 Primary SP2 Secondary CO2 Secondary + PV2 Primary PV1
+ Controller primary +– FCE +
– Controller Process Process
(outer) e.g. valve
CO1

inner secondary process variable, PV2

Copyright © 2007
by Control Station, Inc.
All Rights Reserved
outer primary process variable, PV1

Cascade architectures seek to improve the disturbance


rejection performance of PV1

Copyright © 2007 Control Station, Inc. All Rights Reserved 223


Early Warning is Basis for Cascade Success
requires an
inner
disturb, D2 Inner
“early warning”
Disturbance variable

primary secondary secondary secondary primary


(outer) (inner) (inner) (inner) (outer)
SP1 Primary SP2 Secondary CO2 Secondary + PV2 Primary PV1
+ Controller primary +– Valve +
– Controller Process Process
(outer)
CO1

inner secondary process variable, PV2

Copyright © 2007
by Control Station, Inc.
All Rights Reserved
outer primary process variable, PV1

Success in a cascade design depends on the measurement


and control of an "early warning" process variable PV2

Copyright © 2007 Control Station, Inc. All Rights Reserved 224


Cascade Design

Characteristics for selecting early warning PV2 include:


it must be measurable with a sensor
the same FCE (e.g., valve) used to manipulate PV1
also manipulates PV2
the same disturbances that are of concern for PV1 also
disrupt PV2
PV2 responds before PV1 to disturbances of concern
and to FCE manipulations

Copyright © 2007 Control Station, Inc. All Rights Reserved 225


Cascade Design
A cascade design requires:
two sensors
two controllers
one final control element (FCE)
The output of the outer primary controller, rather than going to
a valve, becomes the set point of the inner secondary controller
Because of this nested architecture:

Success requires that


the settling time of the inner secondary inner loop
is significantly faster
than that of the outer primary outer loop

Copyright © 2007 Control Station, Inc. All Rights Reserved 226


Example: Flash Drum Process
pressure set
overhead vapor
down stream
(a disturbance)
P

vapor
hot liquid feed
LC Lsetpoint
flash
valve liquid

liquid
drain
valve position manipulated
to control liquid level

Level must never fall so low that vapor is sent down liquid
drain nor rise so high that liquid enters the vapor line

Copyright © 2007 Control Station, Inc. All Rights Reserved 227


Flash Drum – Single Loop Architecture
Design Objective  control liquid level in the drum

Choose valve position as manipulated variable


If level too high, open valve
If level too low, close valve

Concern is that drain flow rate changes as a function of


valve position
hydrostatic head (height of the liquid)
pressure of vapor pushing down on liquid (a disturbance)

Copyright © 2007 Control Station, Inc. All Rights Reserved 228


Flash Drum overhead vapor
pressure set
down stream
(a disturbance)
P

vapor
hot liquid feed
LC Lsetpoint
flash
valve liquid

liquid
drain
valve position manipulated
to control liquid level

If pressure of vapor phase is constant, then as drain valve


opens and closes, the liquid drain flow rate increases and
decreases in predictable fashion
Single loop architecture would then be satisfactory

Copyright © 2007 Control Station, Inc. All Rights Reserved 229


Flash Drum – Single Loop Architecture
Suppose the vapor phase pressure starts decreasing:
This disturbance causes pressure pushing down on the liquid
interface to decrease
If the valve position were to remain constant, the liquid drain
flow rate would similarly decrease
Consider that if a pressure decrease occurs quickly enough,
the controller can be opening the valve yet the liquid drain
flow rate can continue to decrease

This contradictory outcome can confound the controller

Observation  It is liquid drain flow rate, not valve position, that


must be adjusted for high performance disturbance rejection

Copyright © 2007 Control Station, Inc. All Rights Reserved 230


Solution: Flash Drum Cascade Architecture
pressure set
overhead vapor
down stream
(a disturbance)
P

vapor
hot liquid feed
LC Lsetpoint
flash
valve liquid

Fsetpoint

FC
liquid
drain
flow rate manipulated
to control liquid level

Two controllers (level control; drain flow rate control)


Two sensors (measuring liquid level; liquid drain flow rate)
One final control element (valve in the liquid drain stream)

Copyright © 2007 Control Station, Inc. All Rights Reserved 231


A Cascade Control Solution

Liquid level is the outer primary PV1 and controlling it remains


the main objective
For inner secondary PV2 choose liquid drain flow rate:
liquid drain flow rate is measurable with a sensor
the same valve used to manipulate liquid level (PV1) also
manipulates the liquid drain flow rate (PV2)
changes in vapor phase pressure that disturb PV1 also
impact PV2
drain flow rate is inside the liquid level in that it responds
well before liquid level to changes in valve position and
changes in vapor phase pressure

Copyright © 2007 Control Station, Inc. All Rights Reserved 232


Flash Drum Cascade Architecture
vapor phase
pressure Pressure to
Drain Flow
Relationship

primary secondary liquid drain liquid


set point set point Liquid flow rate Drum Level level
Secondary
++
Primary Liquid Drain
+– Controller +– Controller
Drain
Process Process
Lsetpoint Fsetpoint Valve

secondary process variable (liquid drain flow rate)

primary process variable (liquid level)

Liquid level control (main objective) is outer primary loop


Liquid drain flow rate is inner secondary loop
Output of primary controller is set point of secondary controller
Flow control dynamics are much faster than level control
dynamics so this is consistent with design criteria

Copyright © 2007 Control Station, Inc. All Rights Reserved 233


Flash Drum Cascade Architecture

If liquid level is too high, the primary level controller now


calls for an increased liquid drain flow rate rather than
simply an increase in valve opening
The flow controller then decides whether this means
opening or closing the valve and by how much
Thus, a vapor phase pressure disturbance gets addressed
quickly by the secondary flow controller and this improves
disturbance rejection performance

Copyright © 2007 Control Station, Inc. All Rights Reserved 234


Tuning a Cascade Implementation
Cascade loop tuning uses our existing skills:
Begin with both controllers in manual mode
Select P-Only controller for the inner secondary loop (integral
action increases settling time and offset is rarely an issue for
the secondary process variable)
Tune the secondary P-Only controller for set point tracking
and test it to ensure satisfactory performance
Leave secondary controller in automatic; it is now part of the
primary process. Select a PI or PID controller for the primary
loop, tune it for disturbance rejection and test it
With both controllers in automatic, tuning is complete

Copyright © 2007 Control Station, Inc. All Rights Reserved 235


Exploring the Jacketed Reactor Process

Well mixed vessel with exothermic (heat producing) reaction


Residence time is constant so conversion of feed to product can
be inferred from the reactor exit stream temperature
Objective  maintain constant measured reactor exit stream
temperature in spite of jacket inlet temperature disturbances

Copyright © 2007 Control Station, Inc. All Rights Reserved 236


The Jacketed Reactor
To control reactor exit stream temperature, the vessel is
enclosed with a cooling jacket
If the exit stream temperature (and thus conversion) is high,
the controller opens a valve to increase cooling liquid flow rate
This cools the reactor, slowing the heat producing reaction
The disturbance variable of concern is the cooling jacket inlet
temperature

Copyright © 2007 Control Station, Inc. All Rights Reserved 237


Disturbances and the Jacketed Reactor
Consider scenario where the temperature of the cooling liquid
entering the jacket fluctuates, changing the ability of the
cooling jacket to remove heat
If the cooling liquid temperature becomes colder just as the
reactor temperature starts to fall, the controller can lower the
cooling liquid flow rate yet be removing more heat than before
Again, a contradictory result can confound the controller and
impact disturbance rejection performance

Copyright © 2007 Control Station, Inc. All Rights Reserved 238


Cascade Architecture for the Jacketed Reactor

Outer primary variable remains reactor exit stream temperature


Inner secondary variable is cooling jacket outlet temperature

Copyright © 2007 Control Station, Inc. All Rights Reserved 239


The Reactor Cascade Architecture
Cooling jacket outlet temp is a proper secondary variable
it is measurable with a sensor
valve used to manipulate reactor exit stream temperature
(PV1) also manipulates cooling jacket outlet temp (PV2)
changes in cooling jacket inlet temperature that disturb
reactor exit stream temp also disturb the cooling jacket
outlet temp
the cooling jacket outlet temp is inside the reactor exit temp
in that it responds first to changes in valve position and
changes in the cooling jacket inlet temperature

Copyright © 2007 Control Station, Inc. All Rights Reserved 240


The Reactor Cascade Architecture
jacket inlet
temperature Inlet to Outlet
Jacket Temp
Relationship

primary secondary jacket outlet reactor exit


set point set point Secondary Jacket temperature temperature
++
Primary Cooling Jacket Reactor
+– Controller +– Controller
Flow
Process
Tsetpoint Tsetpoint Process
Valve

secondary process variable (cooling jacket outlet temperature)

primary process variable (reactor exit stream temperature)

Outer primary process (PV1) is reactor exit temperature


measured variable is reactor exit stream temperature
controller output is set point of secondary controller
Inner secondary process (PV2) is the cooling jacket
measured variable is the cooling jacket outlet temperature
manipulated variable is the cooling jacket liquid flow rate

Copyright © 2007 Control Station, Inc. All Rights Reserved 241


Disturbance Rejection Comparison

Disturbance Rejection Performance Disturbance Rejection Performance


of Single Loop PI Controller of Cascade Architecture
Process: Single Loop Jacketed Reactor Cont.: PID ( P= DA, I= ARW, D= off, F = off) Process: Cascade Jacketed Reactor Pri: PID ( P= RA, I= ARW, D= off, F = off)
Sec: PID ( P= DA, I= off, D= off, F = off)
88
88
86

constant 86
PV/S et p oi n t

Prim ary PV
set point P-Only
84

reactor exit 84
constant set point
temperature 72
control offset for primary variable
45
Contr ol l e r Outp ut

68

Secondary PV
30
48 48
disturbance disturbance
44
variable steps
44
variable steps
Di s t u rbance

Di s tu rbance
40 40

0 10 20 30 40 0 10 20 30 40
Time (mins) Time (mins)
Tuning: Gain = 1.0, Reset Time = 0.95, Sample Time = 1.0

Tuning: Gain = -3.0, Reset Time = 1.71, Sample Time = 1.0


Tuning: Gain = -5.8, Sample Time = 1.0

Copyright © 2007 Control Station, Inc. All Rights Reserved 242


Set Point Tracking Comparison

Set Point Tracking Performance Set Point Tracking Performance Under


Under PI Control Cascade Control
Process: Single Loop Jacketed Reactor Cont.: PID ( P= DA, I= ARW, D= off, F = off) Process: Cascade Jacketed Reactor Pri: PID ( P= RA, I= ARW, D= off, F = off)
92 Sec: PID ( P= DA, I= off, D= off, F = off)
92

90
90

88
88
PV/ S etp oi n t

Pri m ary PV
86
86

84 84
set point tracking set point tracking
60
performance 60 performance

40 40
C ontr ol l e r Out p ut

Secondary C O
20 20

0 10 20 30 40 50 0 10 20 30 40 50
Time (mins) Time (mins)
Tuning: Gain = 1.0, Reset Time = 0.95, Sample Time = 1.0
Tuning: Gain = -3.0, Reset Time = 1.71, Sample Time = 1.0

Cascade does not provide benefit in tracking set point changes

Copyright © 2007 Control Station, Inc. All Rights Reserved 243


Hands-On Workshop

Workshop #11
Cascade Control of Jacketed Reactor

Copyright © 2007 Control Station, Inc. All Rights Reserved 244


Feed Forward Control

What We Will Learn in This Section


Feed Forward Architecture
Problems with feedback control
Feed Forward with Feedback Trim
Example: Flash Drum
Dead Time Criteria
Feed Forward Theory
Visual Comparison between Feed Forward Control and Single
Loop

Copyright © 2007 Control Station, Inc. All Rights Reserved 245


Feed Forward Control
Architectures for Improved Disturbance Rejection
Feed Forward
Cascade
Both require additional instrumentation and engineering time
in return for a controller better able to reject disturbances
Neither architecture benefits nor detracts from set point
tracking performance

Copyright © 2007 Control Station, Inc. All Rights Reserved 246


The Feed Forward Architecture

feed forward can improve


rejection of either disturbance
disturbance
variable II Disturbance
Process II
disturbance
variable I Disturbance
Process I

measured
process
set point Final variable
++
Feedback
++
Secondary Primary
+– Controller
Control
Process Process
Element

measured process variable

Feed forward does not require a secondary process variable

Copyright © 2007 Control Station, Inc. All Rights Reserved 247


Problems with Feedback Control
Traditional feedback control
takes action only after the measured process variable has
been forced from set point
damage to stable operation is in progress before a
traditional feedback controller even begins to respond
Some disturbances originate in another part of the plant and a
measurable series of events occur that cause that “distant”
disturbance to impact your process
From this view, a feedback controller starts too late to be
effective in reducing the impact of a disturbance

Copyright © 2007 Control Station, Inc. All Rights Reserved 248


Feed Forward with Feedback Trim
d(t) Disturbance to
Process Variable
Behavior

sensor “disturbance”

utotal is the feedback controller output


minus the feed forward output signal
Feed Forward Element
Disturbance Model
Process Model
ydisturb
– ufeedforward
ysetpoint Traditional Controller Output to y(t)
+– Feedback ++ Process Variable
yprocess ++
ufeedback utotal Behavior
Controller
“process”

measured process variable

A feed forward controller measures the disturbance while it is still


"distant"
Feed forward element receives the disturbance signal and
computes preemptive control actions which are combined with
traditional feedback control action

Copyright © 2007 Control Station, Inc. All Rights Reserved 249


Feed Forward with Feedback Trim
Feed forward implementation requires:
purchase and installation of a sensor
construction of a feed forward element comprised of a
disturbance and process model
The disturbance model receives disturbance signal, d(t), and
predicts an “impact profile” of when and by how much the
measured process variable, y(t), will change
Given this sequence of disruption, the process model then
predicts a series of control actions, ufeedforward, that will exactly
reproduce this behavior
A negative sign enables “actions opposite to prediction” to be
taken so there is zero net effect on the process variable
Total controller output is: Utotal = Ufeedback  Ufeedforward

Copyright © 2007 Control Station, Inc. All Rights Reserved 250


Feed Forward with Feedback Trim
The models must be programmed into the control computer
Since linear models never exactly describe process behavior,
feed forward will not provide perfect disturbance rejection
Tasks of the feedback trim:
rejects that portion of the measured disturbance that make
it past the feed forward element
works to reject unmeasured disturbances
provides set point tracking capabilities as needed

Copyright © 2007 Control Station, Inc. All Rights Reserved 251


Example: overhead vapor
pressure set

Flash Drum Process down stream


(a disturbance)
P

vapor
hot liquid feed
LC Lsetpoint
flash
valve liquid

liquid
drain
valve position manipulated
to control liquid level

Traditional Feedback Control


If a pressure decrease occurs quickly, the controller can actually
be opening the valve yet the liquid drain flow rate can continue to
decrease
Controller response starts late and cannot effectively minimize
the impact of the disturbance

Copyright © 2007 Control Station, Inc. All Rights Reserved 252


A Feed Forward Solution
overhead vapor pressure set down stream
(a disturbance)

P
Feed Forward Element
Disturbance Model
Process Model
vapor
hot liquid feed Lsetpoint
LC
flash
valve liquid

liquid
drain

Sensor detects disturbance as pressure increases


Disturbance model predicts a tank level impact profile
Process model computes actions to duplicate this profile
Negative sign added so “actions opposite to prediction” occur
Feedback trim accounts for plant-model mismatch

Copyright © 2007 Control Station, Inc. All Rights Reserved 253


Feed Forward Control Design
Feed forward implementation requires:
purchase and installation of a sensor to measure the
disturbance of interest
construction and programming of a feed forward element
comprised of a disturbance and process model
Two design criteria for success are:
The models must reasonably describe the process and
disturbance dynamics
The process dead time (controller output to measured
process variable) must be shorter than the disturbance
dead time (disturbance to measured process variable)

Copyright © 2007 Control Station, Inc. All Rights Reserved 254


About Dead Time Criteria
Suppose:
Plant has disturbance dead time less than process dead time
A disturbance occurs and the feed forward controller instantly
responds
The disturbance will already be disrupting the process before the
first disturbance rejection control actions even arrive

control actions must arrive at the same time as the disturbance


for reasonable disturbance rejection

Copyright © 2007 Control Station, Inc. All Rights Reserved 255


About Dead Time Criteria

manipulated
variable

measured
process variable

disturbance
variable

Because of short dead time between the disturbance and


measured process variable, feed forward provides little benefit to
gravity drained tanks process

Copyright © 2007 Control Station, Inc. All Rights Reserved 256


Feed Forward Theory
The process model:
Perturb the controller output signal, u(t), and record the
measured variable, y(t), as the process responds
Fit a FOPDT form to the data to obtain process model GP(s)
In the Laplace domain we can say:
Y(s) = GP (s)U(s)
This model says that with knowledge of controller output moves,
we can compute the process variable response
Rearrange the model to say that, given a change in the process
variable, the controller output signal moves that would cause that
change can be back-calculated:
U(s) = [1/GP(s)] Y(s)

Copyright © 2007 Control Station, Inc. All Rights Reserved 257


Feed Forward Theory
The disturbance model is created in the same way except it is the
disturbance variable, d(t), that is perturbed
Since disturbance variables are beyond the control of a loop
(that’s why they’re disturbances) it may not be possible to do this
at will
Fit a FOPDT form to the data to obtain disturbance model, GD(s),
where:
Y(s) = GD(s) D(s)
This model says that with knowledge of disturbance changes
(provided by the added sensor) the impact profile on the
measured process variable can be computed

Copyright © 2007 Control Station, Inc. All Rights Reserved 258


Feed Forward Theory
Once online, the disturbance signal is fed through the disturbance
model to compute the impact profile:
Ydisturb(s) = GD(s) D(s)
This predicted sequence of disruption is then fed to the process
model to back calculates a series of preemptive control actions:
Ufeedforward(s) = [1/GP(s)] Ydisturb(s)
The feed forward action is combined with the feedback trim to
yield the total controller output:
U(s)total = U(s)feedback  U(s)feedforward

Copyright © 2007 Control Station, Inc. All Rights Reserved 259


Feed Forward Disturbance Rejection

FF

The cooling jacket inlet temperature (the disturbance) is


measured with a sensor as shown above
The disturbance signal is sent to a feed forward element
comprised
of a process and disturbance dynamic model

Copyright © 2007 Control Station, Inc. All Rights Reserved 260


Disturbance Rejection
Compare Single Loop vs. Feed Forward
Disturbance Rejection Performance of Single Loop PI Controller Disturbance Rejection Performance of PI With Feed Forward
reactor exit constant set
temperature point

constant
set point

rapid control action


from feed forward

disturbance
disturbance variable steps
variable steps

Copyright © 2007 Control Station, Inc. All Rights Reserved 261


Set Point Tracking
Compare Single Loop vs. Feed Forward
Process: Single Loop Jacketed Reactor Cont.: PID ( P= DA, I= ARW, D= off, F = off)
92

90

88
PV/S et p oi n t

86

84 feedback only feed forward with feedback trim

60

40
C ontr ol l e r Out p ut

20

0 10 20 30 40 50 60 70 80 90
Time (mins)

Tuning: Gain = -3.0, Reset Time = 1.71, Sample Time = 1.0

Feed forward does not provide benefit in set point tracking

Copyright © 2007 Control Station, Inc. All Rights Reserved 262


Workshop Exercise:
Feed Forward Control of Jacketed Reactor

Copyright © 2007 Control Station, Inc. All Rights Reserved 263


Multivariable Process Control

What We Will Learn in This Section

How to reduce loop interactions with decouplers


Decouplers as feed forward control
The effects of large dead time on controller performance
The benefits of Model Predictive Controllers
example: The Smith Predictor
calculating error of the controller

Copyright © 2007 Control Station, Inc. All Rights Reserved 264


Multivariable Process Control
Multiple manipulated variables each impact more than one
measured process variable, causing loop interactions
Decouplers are feed forward elements designed to reduce loop
interaction in multivariable processes
The only difference between a feed forward element and a
decoupler is that with a decoupler, the disturbance to be rejected
is the action of another control loop on the process

Copyright © 2007 Control Station, Inc. All Rights Reserved 265


Distillation Column is a 2 x 2 Multivariable Challenge

Copyright © 2007 Control Station, Inc. All Rights Reserved 266


Control Loop Interaction

PROCESS 11
y1setpoint u1 y1
- CONTROL PV1
+ response to +
+
Process 1
CO1

INTERACT 12
PV1
response to
CO2

INTERACT 21
PV2
response to
CO1

PROCESS 22
CONTROL PV2 +
2
ysetpoint +- u2 response to + y2
Process 2 CO2

Copyright © 2007 Control Station, Inc. All Rights Reserved 267


Decouplers are Feed Forward Controllers
A decoupler is comprised of a process model and a cross-loop
disturbance model:
The cross-loop disturbance model receives the cross-loop
controller signal and predicts an “impact profile,” or when and
by how much the process variable will be impacted
Given this predicted sequence of disruption, the process model
then back calculates a series of control actions that exactly
counteract the cross-loop disturbance as it arrives so the
measured process variable remains constant at set point
A new sensor is not needed because the cross-loop controller
signal is readily available for use by the decoupler
Developing and programming the dynamic process and cross-loop
disturbance models is required for implementation

Copyright © 2007 Control Station, Inc. All Rights Reserved 268


Decoupling Structure

PROCESS 11
y1setpoint u1feedback u1total y1
- CONTROL
++
PV1
+ response to +
+
Process 1
CO1

G11( s)

DECOUPLER 12
PV1
INTERACT 12
decoupled from u1decouple PV1
CO2
response to
D12 (s) CO2
G12 ( s)

INTERACT 21
DECOUPLER 21 2
udecouple PV2
PV2
response to
decoupled from
CO1
CO1
G21( s)
D21( s)

PROCESS 22
CONTROL PV2 +
+- +
2
ysetpoint 2
+ response to + y2
Process 2 ufeedback 2 CO2
utotal
G22 ( s)

Copyright © 2007 Control Station, Inc. All Rights Reserved 269


2 x 2 Multivariable Decoupling
Requires 4 dynamic models:
Process 11 (how CO1 impacts PV1)
Interact 12 (how CO2 impacts PV1)
Interact 21 (how CO1 impacts PV2)
Process 22 (how CO2 impacts PV2)
Models must be developed from plant data, validated for
accuracy, and then programmed into control architecture
Decoupling is not widely employed because implementation
requires quite challenging modeling, tuning and maintenance

Copyright © 2007 Control Station, Inc. All Rights Reserved 270


Processes with Large Dead Time

Large Dead Time Impacts Controller Performance


Dead time is "large" only relative to the process time constant 
As θP ≥ P , it is increasingly difficult to achieve a tight
performance with PID control
Suppose a process has θP = P and sample time T = 0.1P
10 full samples (one dead time) must pass after a control
action before the sensor detects any impact 
controller tuning must be sluggish or too much corrective
action can accumulate in the dead time “pipeline” leading to
large oscillations and even unstable operation

Copyright © 2007 Control Station, Inc. All Rights Reserved 271


Large Dead Time Impacts Controller Performance

2. The sensor does not see the result of the control action
cold liquid until the hot liquid travels down the pipe, and this
Fsetpoint dead time makes tight control difficult.
FC

hot liquid

Tsetpoint
TC

1. If the measured temperature is below set point,


the controller calls for more hot liquid.

A hot and cold liquid stream combine at the entrance to a pipe,


travel its length, and spill into a tank
Control objective is to maintain temperature in the tank by
adjusting the flow rate of hot liquid entering the pipe

Copyright © 2007 Control Station, Inc. All Rights Reserved 272


Large Dead Time Impacts Controller Performance
If tank temperature is below set point, the hot liquid valve is
opened and the temperature entering the pipe increases
The sensor does not detect this, however, so the valve is opened
more and more and the pipe fills with ever hotter liquid 
When hot liquid reaches the tank, the temperature rises to set
point and the controller steadies the hot liquid flow rate
But the full pipe continues pouring hot liquid into the tank,
causing tank temperature to continue to rise
Because of the delay, the controller will now fill the pipe with
too-cold liquid resulting in large oscillations in temperature
Solutions  1) detune the controller
2) model predictive control

Copyright © 2007 Control Station, Inc. All Rights Reserved 273


Predictive Models in the Controller Architecture
Model predictive controllers (MPC) incorporate a dynamic process
model as part of the controller architecture
The model describes the controller output to process variable
dynamics (the FOPDT model used for tuning is such a model)
The model predicts a future value of the process variable based
on the current state of the process and recent control actions
If the predicted future  a desired set point, control actions can be
taken now, before the predicted problem occurs

MPC exploits process knowledge contained


in a dynamic model to compute
current control actions based on a predicted future

Copyright © 2007 Control Station, Inc. All Rights Reserved 274


Predictive Models in the Controller Architecture
In theory, a perfect model can eliminate the negative influence of
dead time on controller performance
In practice, MPC can certainly provide a performance benefit
This benefit is not free:
an appropriate dynamic model form must be selected
model parameters are then fit to appropriate process data
the model must be programmed in the control computer
the model predictions must be sequenced with the feed-back
loop to create an integrated MPC architecture

Copyright © 2007 Control Station, Inc. All Rights Reserved 275


Smith Predictor: The Simplest MPC
ysetpoint u(t) Actual y(t)
PID
+– Process
Controller
u (t )
yideal (t )
y process (t ) Predict y(t) Behavior
As If There Were
yideal(t)
+- +
+
No Dead Time yideal(t) – yprocess(t)
y (t ) Process Model
Add Time Delay
to “Ideal” yprocess(t)
Prediction of y(t)
Dead Time Model
Model Internal to
Controller Architecture
( y(t) – yprocess(t)) + yideal(t)

The ideal process model receives u(t) and produces yideal(t), a


prediction of what y(t) will be one dead time into the future
this yideal(t) is store for one P in the dead time model block. At the
same time, a previously stored yprocess(t) is released that is the value
of yideal(t) stored one P ago
yprocess(t) is a prediction of the current value of y(t)

Copyright © 2007 Control Station, Inc. All Rights Reserved 276


The Smith Predictor
The Smith controller error, e*(t), is thus:
e*(t) = ysetpoint(t)  ( y(t)  yprocess(t) + yideal(t))
If the model exactly describes the process dynamics
y(t)  yprocess (t) = 0
so for a perfect model, the e*(t) going to the controller is: 
e*(t) = ysetpoint (t)  yideal(t)
If the model is exact, the Smith error is the set point minus a
prediction of the process variable if there were no dead time
The model will never be exact, but:
the better the model, the greater the benefit
a bad model can make poor performance horrible
e* (t )  ysetpoint (t )   y (t )  y process (t )  yideal (t ) 
y (t )  y process (t )  0
e* (t )  ysetpoint (t )  yideal (t )

Copyright © 2007 Control Station, Inc. All Rights Reserved 277

You might also like