CHE-374 · Lesson 9 of 12 · 23 min
Cascade, feedforward, ratio and selector control
Even with its new tuning, tray 13 still drops by more than 2 °C whenever the steam header pressure sags, which happens several times a day when the boilers switch fuel or a large user starts. And when the dilute side streams feeding the recovery column surge by 10 %, the temperature falls by more than 2.5 °C before the loop catches up. Better tuning cannot fix either. A single PI loop must wait for the temperature to move before it acts, and with 2.5 minutes of dead time that is too late. The cure is to change the structure of the control, not its settings. This lesson covers the enhanced single-loop strategies that every chemical plant uses: cascade, feedforward, ratio, split-range and selector control.
Cascade control
In the original loop, the temperature controller moves the steam valve directly. When the header pressure falls, the same valve opening passes less steam, but the controller does not know until the temperature drops minutes later. In a cascade, the temperature controller, the primary or master, sets the set point of a steam flow controller, the secondary or slave, which moves the valve. The flow controller sees the drop in steam flow within seconds and opens the valve to restore it, long before the temperature is affected. The disturbance is corrected in the fast inner loop and never reaches the slow outer one.
Cascade works when three conditions hold. There must be a measurable intermediate variable, here steam flow, on the path from the manipulated variable to the controlled variable. The disturbance to be rejected must act on the inner loop, which the header pressure does. And the inner loop must be much faster than the outer, at least three to five times, so that the outer loop sees it as nearly instantaneous. Steam flow responds in fractions of a minute; tray 13 in several minutes. The inner loop is tuned first, usually as a fairly aggressive PI, and put in automatic; the outer loop is then tuned on the combination.
# Cascade and feedforward on the recovery column: tray temperature, steam flow and feed rate
import math, random
def fopdt_step(K, tau, theta, t):
# response of K e^(-theta s)/(tau s + 1) to a unit step at t = 0
return 0.0 if t < theta else K * (1 - math.exp(-(t - theta) / tau))
class Plant:
# first- or second-order lag with dead time, stepped with Euler at a small dt
def __init__(self, K, tau1, theta, dt, tau2=0.0):
self.K, self.t1, self.t2, self.dt = K, tau1, tau2, dt
self.buf = [0.0] * max(1, int(round(theta / dt)))
self.x1 = 0.0; self.x2 = 0.0
def step(self, u):
self.buf.append(u); ud = self.buf.pop(0)
self.x1 += self.dt * (self.K * ud - self.x1) / self.t1
if self.t2 > 0:
self.x2 += self.dt * (self.x1 - self.x2) / self.t2
return self.x2
return self.x1
def loop(K, tau, theta, Kc, Ti, Td=0.0, tend=60.0, dt=0.01, sp=1.0, load=0.0, t_load=0.0,
umin=-1e9, umax=1e9, antiwindup=True, tau2=0.0):
# PI(D) control of an FOPDT (or SOPDT) plant; derivative acts on the measurement.
# A load enters at the plant input at t_load. Returns lists of t, y, u.
p = Plant(K, tau, theta, dt, tau2)
I, ylast, y = 0.0, 0.0, 0.0
T, Y, U = [], [], []
n = int(tend / dt)
for k in range(n):
t = k * dt
e = sp - y
D = -Kc * Td * (y - ylast) / dt if Td > 0 else 0.0
u_un = Kc * e + I + D
u = min(umax, max(umin, u_un))
if Ti > 0:
if not antiwindup or u == u_un or (u_un > umax and e < 0) or (u_un < umin and e > 0):
I += Kc * dt / Ti * e
d = load if t >= t_load else 0.0
ylast = y
y = p.step(u + d)
T.append(t); Y.append(y); U.append(u)
return T, Y, U
def iae(T, Y, sp, t0=0.0):
dt = T[1] - T[0]
return sum(abs(sp - y) * dt for t, y in zip(T, Y) if t >= t0)
def overshoot(Y, sp):
return max(0.0, (max(Y) - sp) / sp * 100) if sp else 0.0
def settle(T, Y, sp, band=0.05):
last = T[0]
for t, y in zip(T, Y):
if abs(y - sp) > band * abs(sp): last = t
return last
dt, tend = 0.01, 60.0
def run(cascade=False, ff=None, upset='steam'):
# outer: tray temperature (degC) <- steam flow (%), K 0.90, tau 6.5, theta 2.4
# inner: steam flow (%) <- valve (%), K 1.0, tau 0.2, theta 0.05; header pressure upset = -5 % flow
flow = Plant(1.0, 0.2, 0.05, dt); temp = Plant(0.90, 6.5, 2.4, dt)
feedp = Plant(-0.60, 8.0, 3.0, dt) # tray temperature response to feed rate (degC per % feed)
Kc, Ti = 1.44, 6.5 # outer PI (lesson 8, SIMC)
Kf, Tf = 0.5, 0.3 # inner PI on steam flow
I = If = 0.0; y = 0.0; f = 0.0; lag = 0.0; worst = 0.0
for k in range(int(tend / dt)):
t = k * dt
dfeed = 10.0 if (upset == 'feed' and t >= 1) else 0.0
dsteam = -5.0 if (upset == 'steam' and t >= 1) else 0.0
e = 0.0 - y; I += Kc * dt / Ti * e; out = Kc * e + I
if ff == 'static': out += 0.60 / 0.90 * dfeed
if ff == 'leadlag': # (6.5 s + 1)/(8 s + 1) on the static feedforward
lag += dt * (dfeed - lag) / 8.0
out += 0.60 / 0.90 * (lag + 6.5 / 8.0 * (dfeed - lag))
if cascade:
ef = out - f; If += Kf * dt / Tf * ef; valve = Kf * ef + If
else:
valve = out
f = flow.step(valve) + dsteam
y = temp.step(f) + feedp.step(dfeed)
worst = min(worst, y) if abs(min(worst, y)) > abs(max(worst, y)) else max(worst, y)
return worst
print(f"steam header upset (-5 % flow): single loop worst deviation {run(False):+.3f} degC, cascade {run(True):+.3f} degC")
print(f"feed +10 % upset: feedback only {run(True, None, 'feed'):+.3f} degC, + static feedforward {run(True, 'static', 'feed'):+.3f} degC, + lead-lag {run(True, 'leadlag', 'feed'):+.3f} degC")
# Ratio control of the vent scrubber: water ratioed to gas, and the reagent pump ratioed to the water
ratio = 2.8e-3 # m3 water per m3 of vent gas (illustrative design ratio)
for g in (3000.0, 4200.0, 5000.0):
w = ratio * g
print(f"vent gas {g:5.0f} m3/h -> water set point {w:5.2f} m3/h, reagent at 0.8 % of water = {0.008 * w * 1000:5.1f} L/h")steam header upset (-5 % flow): single loop worst deviation -2.081 degC, cascade -0.318 degC feed +10 % upset: feedback only -2.547 degC, + static feedforward +0.337 degC, + lead-lag +0.176 degC vent gas 3000 m3/h -> water set point 8.40 m3/h, reagent at 0.8 % of water = 67.2 L/h vent gas 4200 m3/h -> water set point 11.76 m3/h, reagent at 0.8 % of water = 94.1 L/h vent gas 5000 m3/h -> water set point 14.00 m3/h, reagent at 0.8 % of water = 112.0 L/h
The simulation applies a sudden 5 % loss of steam flow, the header upset, to both structures with the same outer tuning. With the temperature controller moving the valve directly, tray 13 falls 2.08 °C. With cascade, the flow loop restores the steam within about a minute and the temperature falls only 0.32 °C, an improvement of more than six times for a change that costs one flow transmitter and a configuration change in the DCS. Nearly every column reboiler, heat exchanger and reactor jacket at Kingfisher Bioenergy has a flow or temperature inner loop for exactly this reason.
Cascade has its own pitfalls. If the inner loop is put in manual, the outer loop's output goes nowhere, and its integral can wind up; DCS blocks track the inner set point to prevent this. If the inner loop saturates, for example with the steam valve wide open, the outer controller must be told that its output is not being delivered, or it too winds up. And an inner loop that is slow or oscillatory makes the outer loop worse, not better.
Feedforward control
The feed surge is a different kind of disturbance. It does not pass through the steam flow, so cascade does not help. But the feed rate is measured. If the steam needed to keep tray 13 steady can be predicted from the feed rate, it can be changed at once, before the temperature moves. That is feedforward. Its simplest form is static: from the step-test models, a 1 % rise in feed lowers the tray temperature by 0.60 °C at steady state, and a 1 % rise in steam raises it by 0.90 °C, so the steam should rise by \(0.60/0.90 = 0.67\) % for each percent of feed.
Static feedforward alone would be perfect only if the feed and the steam affected the temperature with the same dynamics. They do not: the feed takes about 8 minutes to work through the column, with 3 minutes of dead time, while the steam's effect has a 6.5 minute lag and 2.5 minutes of dead time. A dynamic compensator corrects for this. The ideal feedforward is \(G_{ff} = -G_d/G_p\), the ratio of the disturbance path to the process path. For two FOPDT models it is a gain, a lead-lag \((\tau_p s + 1)/(\tau_d s + 1)\), and a delay of \(\theta_d - \theta_p\) if that is positive. Here the lead-lag is \((6.5s + 1)/(8s + 1)\), and the half-minute delay is small enough to ignore.
The code applies a 10 % feed step with the cascade in place. With feedback alone the temperature falls 2.55 °C. Static feedforward, which raises the steam too early relative to the feed's slower effect, overcorrects slightly, pushing the temperature up 0.34 °C. Adding the lead-lag brings the worst deviation down to 0.18 °C. Feedforward does not replace feedback: models are never exact, and only feedback can correct for the error. The two are always combined, the feedforward signal added to the feedback controller's output, so that the feedback trims whatever the feedforward misses.
Worked problem
Designing a static feedforward gain
In the ester column, a 1 % rise in feed lowers the control tray temperature by 0.50 °C at steady state, and a 1 % rise in steam raises it by 0.78 °C. What feedforward gain should the steam receive?
Show solution
- Steady-state cancellation needs \(K_{ff}K_p + K_d = 0\).
- \(K_{ff} = -K_d/K_p = 0.50/0.78 = 0.64\) % steam per % feed.
Answer: Add 0.64 % steam for each 1 % of feed, then add a lead-lag if the dynamics differ.
Ratio control
Many process relationships are naturally ratios. The vent scrubber of CHE-314 needs about 2.8 liters of water for every cubic meter of vent gas to hold its recovery; its reagent pump must deliver about 0.8 % of the water flow. Rather than calculating a ratio from two measurements and controlling it, which behaves badly at low flows, the usual method multiplies the measured wild flow, the one that cannot be manipulated, by the desired ratio to form the set point of the controlled flow. At 4,200 m³/h of gas, the water set point becomes 11.76 m³/h and the reagent set point 94 L/h; at 3,000 m³/h they fall automatically to 8.4 m³/h and 67 L/h. Ratio control is a form of feedforward, and its ratio is often trimmed by a feedback controller: an outlet ethanol analyzer on the scrubber adjusts the water-to-gas ratio slowly to hold the emission target in the permit.
Ratio control appears all over the ethanol plant: steam to feed on the beer column, reflux to feed on the recovery column, acid to ethanol on the ester pre-reactor, and air to fuel on the boilers, where the ratio is also a safety matter.
Split-range control
Sometimes one controller must move two valves. The ester column's decanter operates under a slight nitrogen blanket. When the pressure falls, nitrogen must be added; when it rises, vapor must be vented to the vent header. A single pressure controller drives both valves in split range: from 0 to 50 % of its output it opens the vent valve as the output falls, and from 50 to 100 % it opens the nitrogen valve. Near 50 % both are closed. Split range also serves heating and cooling on a reactor jacket, and two valves of different size on a wide-ranging flow. The ranges must be calibrated so that the transition is smooth, and the gains of the two halves are often different, which can make tuning a compromise.
Override and selector control
A process can have more control objectives than manipulated variables. The recovery column's reboiler steam must normally hold tray 13, but it must never let the column's bottom pressure exceed the limit set by its tray hydraulics, or the reboiler tube wall exceed its maximum temperature. An override scheme gives each objective its own controller and passes the lowest of their outputs to the steam flow set point through a low selector. In normal operation the temperature controller's output is lowest and in control. If the pressure rises toward its limit, the pressure controller's output falls below the temperature controller's and takes over, holding the pressure just under the limit while the temperature drifts. When conditions return to normal, the temperature controller recovers control automatically. Both controllers need anti-windup tied to the selected output, so that the one not in control does not wind up.
High and low selectors also pick among redundant measurements: a high selector on three reactor bed thermocouples ensures control on the hottest one, and a median selector on three transmitters rejects a single failed instrument. Overrides are part of the basic control system and help keep the plant within limits, but they are not a safety layer. Lesson 11 explains why a separate, independent system must stand behind them.
Choosing a structure
Malik gives Theo a rule of thumb. Use cascade when a disturbance enters through a measurable fast variable. Use feedforward when a disturbance can be measured before it upsets the process and a model of its effect exists. Use ratio control when two flows must stay in proportion. Use split range when one objective needs two actuators. Use selectors when there are more objectives, or constraints, than actuators. In every case, keep a feedback loop to correct what the structure misses, and draw the strategy so that an operator can understand it at three in the morning.
Common mistakes
MistakeBuilding a cascade with an inner loop that is not much faster than the outer.
InsteadThe inner loop should be at least three to five times faster.
MistakeUsing feedforward without feedback.
InsteadModels are imperfect; combine feedforward with feedback trim.
MistakeControlling a calculated ratio of two flows.
InsteadMultiply the wild flow by the ratio to set the controlled flow.
MistakeTreating an override as a safety function.
InsteadOverrides are part of the basic control system; safety needs an independent layer.
Summary and key terms
- Cascade puts a fast inner loop on an intermediate variable; tray 13's header-upset deviation fell from 2.08 to 0.32 °C.
- Feedforward acts on a measured disturbance; ideal \(G_{ff} = -G_d/G_p\), here a gain of 0.67 with a lead-lag.
- Lead-lag feedforward cut the feed-surge deviation from 2.55 to 0.18 °C.
- Ratio control sets one flow from another measured flow; split range drives two valves from one controller.
- Selectors pass the lowest or highest of several controller outputs to respect constraints.
- Cascade control
- A structure in which an outer controller sets the set point of an inner controller.
- Feedforward control
- Control action calculated from a measured disturbance before it affects the controlled variable.
- Lead-lag
- A dynamic compensator with one zero and one pole, used to match feedforward dynamics.
- Ratio control
- Control that keeps one flow in a set proportion to another.
- Split range
- One controller output driving two or more final control elements over different parts of its range.
- Override control
- A selector scheme that lets a constraint controller take over from the normal controller.
- Wild flow
- A flow that is measured but not manipulated, used as the basis for ratio control.
Practice problems
Work each problem on paper first, then reveal the answer to check.
Why does cascade help with a steam header disturbance but not a feed disturbance?
Show answer
The header upset acts on steam flow, inside the inner loop; the feed acts directly on the column.
Feed gain is \(-0.4\) °C/% and steam gain is \(+0.8\) °C/%. Find the static feedforward gain.
Show answer
0.5 % steam per % feed.
Disturbance lag 12 min, process lag 4 min. Write the lead-lag.
Show answer
\((4s + 1)/(12s + 1)\).
A ratio of 2.8 L per m³ gas is set; gas is 5,000 m³/h. What is the water set point?
Show answer
14.0 m³/h.
In a low-select override, which controller is in control?
Show answer
The one whose output is lowest.
What must the controller not in control have to avoid trouble?
Show answer
Anti-windup referenced to the selected output.
Lesson quiz · 5 questions
Score 60% or more to complete this lesson.
Create a free account to save your progress, take quizzes and earn a certificate.