Simple, model-based process control
Nonlinear control techniques can be used for more efficient process operation
- Nonlinearity is the primary problem for single-input-single-output (SISO) chemical process control.
- Practicable techniques for nonlinear control can ease design constraints and permit the operation of more competitive processes.
- An engineer's process knowledge expressed as a dynamic nonlinear model can be used to improve control effectiveness
This article is extracted from the tutorial session at the ISA 2012 Automation Week conference and is an extended version of the article that appears in the March/April 2013 issue of InTech.
By R. Russell Rhinehart
Often, nonlinearity is the primary problem for single-input-single-output (SISO) chemical process control. One solution is to design the process for PID control success - for linear responses, or with large inventories to reduce interaction and temper upsets. However, design is an act of balancing multiple objectives; other desirable issues, such as capital cost, flexibility, resource use, energy integration, and sustainability are usually sacrificed to accommodate process control. Practicable techniques for nonlinear control can ease design constraints and permit the operation of more competitive processes.
For nonlinear processes, gain scheduling is a conventional solution to accommodate nonlinearity. In gain scheduling, the controller coefficients are changed to reflect the operating region; the engineer uses process knowledge to create tuning values, which are either placed in a look-up table or expressed in equations.
However, if the engineer's process knowledge is expressed as a dynamic nonlinear model, it is almost as easy to implement a process model-based controller (PMBC) as it is gain scheduling. Several process model-based control approaches have found success in industrial applications. There are several commercial products for relatively simple nonlinear process model-based controllers, engineers have implemented versions in-house, and control integrators and service providers have been implementing model-based controllers for decades.
Process-model based control (PMBC) has several advantages over either classic PID or gain-scheduled PID, even with ratio and feedforward enhancements of advanced regulatory control (ARC). PMBC has a single-tuning parameter, has nonlinear compensation throughout the entire operating range, preserves process knowledge, and provides continuous monitoring of the process - for health, predictive maintenance, and constraint recognition, and economic optimization of setpoints.
PMBC can also be used within a horizon-predictive, constraint-handling framework. And, for multi-input-multi-output (MIMO) processes, PMBC can additionally decouple nonlinear interaction, balance deviations from setpoints when manipulated variable (MV) constraints are hit, and determine economic optimum MV values when there are extra degrees of freedom.
However, this article addresses only the multi-input-single-output (MISO), single step-ahead control approach. This approach can solve many problems and can be implemented by a process engineer.
The references describe PMBC applications on commercial-scale, pilot-scale, and lab-scale processes. The references cite SISO and MISO applications for control of fluid flow rate, heat exchanger temperature, distillation bottoms composition, plasma reactor pressure, and pH. MIMO applications include distillation dual-end composition control and fluidized bed gasification.
PMBC starts with the engineer's process model. Such models are often developed from first-principles (elementary mechanistic models), but models may also contain empirical features, or they may be purely empirical. These are the same models that a process engineer would use in design, optimization, or analysis. Here are two examples chosen to reveal the attributes that can be handled by PMBC:
Example 1: Flow rate
Undergraduate fluid dynamics or process control texts use pressure drop through pipes, valves, and fittings to derive the steady-state incompressible fluid flow rate response to valve stem position:
Where Q is the volumetric flow rate, ∆P is the static pressure driving force over the entire pipe section, a represents the piping system friction loss coefficients, G is the fluid specific gravity, Cv is the valve coefficient of discharge, x is the valve stem position, and f(x) is the inherent valve characteristic.
Characteristically for in-plant piping lengths, the dynamics of fluid acceleration in response to a valve stem position are much faster than the valve position response to the actuator. Accordingly, the dynamics that dominate the fluid flow rate response to the controller output is often that from valve stem position, and it is reasonable to describe valve stem position as a first-order response to controller output:
where τ is the time-constant for the valve actuator, and u is the controller output in %. The 0.01 value converts % into valve stem position as a fraction.
This set of equations represents linear dynamics of Equation  followed by a nonlinear characterization of Equation  and is often termed a Weiner model. Coefficients in Equation  can be evaluated by engineering analysis of the process. The time-constant for Equation  can be revealed by the observed flow rate transient response to a simple controller output step test.
Example 2: Mixing
Consider two streams of concentrations, c1 and c2, entering a tank at a stationary liquid level. Perhaps F1 and c1 represent wild flow properties, and F2 is the controlled flow. The net inflow concentration is:
Note that cin is a nonlinear response to both F1 and F2. Then, the well-mixed description of the tank contents defines the outflow concentration as:
where c is the in-tank concentration, V is the tank volume, and F represents the total flow rate (=F1+ F2). The ratio V/F has the units of a time-constant.
This represents a static nonlinearity of Equation  followed by linear dynamics of Equation , which is often termed a Hammerstein model. Equations  and  can be combined to represent one nonlinear model:
While developed here as separate equations, and then combined, the same result, Equation , could be derived from a transient material component balance on the tank.
Generic format for model equations
This paper will represent the generic dynamic model as:
where y is the process response (the controlled variable, CV), u is the manipulated variable (MV) from the controller, d represents measureable disturbances, and p represents model parameters. PMBC will be derived from the generic Equation .
Equation  is easily placed in that form by subtracting c from both sides and dividing by tau (τ). This is a MISO system with u and d representing the multiple inputs and y the single output. As described, c is the CV; F2 is the MV; and c1, c2, and F2 would be measureable disturbances.
A Weiner model, such as that in Equations  and , can also be placed in the same generic structure. Consider this SISO Weiner model, in which the function symbol g() represents a steady-state (SS) relationship.
Take the time derivative of Equation  using the chain rule.
Then substitute dx/dt from Equation  and x from the inverse of Equation  into Equation .
Now Equation  has the same form as Equation .
To implement PMBC, you will need to derive a dynamic model in the form of Equation  to represent your process.
These, and similar process models, do not pretend to be rigorous; fortunately for control, the model perfection is not needed. Consider that the controller decides a control action that is only 75 percent perfect, leaving 25 percent error. In simplistic qualitative reasoning, at the next control action the controller will correct the 25 percent error by 75 percent. With a rule of thumb that there should be 30 control actions within a process settling time, the continual "steering" by the controller will have the process at the setpoint, with only a 0.2530 (vanishingly small) error. Balancing precision with sufficiency, a model that would represent a homework grade of "B-" or "C+" is fully adequate for control.
This robustness to model imprecision has several advantages. It lessens the burden on the control engineer to achieve model perfection. And it permits the controller to remain functional as a process continually changes because of fouling, reactivity, yield, filter/screen accumulation, or piping modifications, or such change in time.
Further, simple process models, such as those expressed in Equations  through , often represent desirable computational features of execution simplicity and low computational complexity and storage.
Additionally, such simple models often represent the engineer's understanding of the process, and reflect methods already in use for process analysis, device sizing, and analytical trouble-shooting. The process engineer can develop such models, and imbedding them in controllers promulgates process knowledge.
These models do not exactly match the process. There is uncertainty in coefficients (e.g., heat transfer fouling, catalyst reactivity, tray efficiency, friction losses in pipes and fittings, concentration of non-key components, amount of non-condensable gases, etc.). Accordingly, when used for control, there needs to be a feedback correction.
MISO process-model-based control
Simple MISO process-model-based control
There are three functions within model-based control - predict, correct, and act. The structure can be represented by the operations in Figure 1.
This article describes the application to processes that are MISO, with first-order-ish dynamics. The method can be extended to MIMO, constrained processes with complicated dynamics. The method can also be extended to horizon predictive, constraint avoidance control.
The first PMBC function is to use the model to predict or mimic what the process output was expected to do. This updates the past model value with past disturbance and control action, to update the modeled output. With conventional practice of 30 control samplings in an open loop transient (or 10 samplings within a time-constant), the control interval, ∆t, is usually small enough to permit Euler's explicit finite difference method to solve the model numerically. Using Equation  to represent the SISO dynamic model, this model prediction calculation becomes
where i is the time increment counter, representing the present value, and i-1 the immediate past value. The subscript m refers to the modeled value, not the measured process value. However, urefers to the actually implemented MV value, after any overrides change what the controller initially desired (similar to external reset feedback). The symbol d refers to measured disturbances or feedforward variables, and p represents parameter values in the model.
Since computers use assignment statements, the subscript is not necessary. The newly modeledy-value is based on the old conditions. Here the symbol ":=" will indicate a computer assignment statement.
The second function within model-based control is a correction for process-model mismatch. The modeled value will not exactly match the process value for a variety of reasons, including model error (due to either simplification or an inexact parameter value) or unmeasured disturbances. A simple correction approach is to bias the setpoint with the process model mismatch as follows:
The logic is, "If you aim at the target, but hit 3 cm low, then next time aim 3 cm above the target." The box labeled "correct" in the lower left of the figure could provide other functions, but in this correction approach, it simply is a pass-through of the pmm value.
The third model-based control function is to calculate the control action. This starts with a user-defined, desired performance objective for the controller. A simple desire is to calculate a u-value that would make the controller push the model toward the biased setpoint at a rate proportional to the deviation from biased setpoint. Mathematically, this desire is:
The tuning parameter, the controller aggressiveness factor, is τwant. To make the controller push the process at a faster rate, choose a small value for τwant; alternately, for a gentle control action, choose a larger value. Note that Equation  specifies a first-order path, or reference trajectory to the setpoint. This approach to tuning controller aggressiveness is termed CV damping, and τwantdefines the path toward the setpoint. The process engineer or operator who has some familiarity with the process should be able to say what its natural settling time is, and since the time-constant is roughly 1/4th of the settling time (ST), it should be easy to choose the value of τwant. For example, if you want the controller to push the process to the setpoint in 80 percent of the process open-loop settling time, then set τwant = 0.8*ST/4.
Then, match the desired rate to the modeled rate,
And solve for the value of u:
The symbol, f-1(), in Equation  represents the inverse. Normally, the model Equation  is used to calculate the rate of change of the process response, dy/dt, given process influences and state. However, in Equation  the solution (mathematical operation) needs to determine the value of the MV, u, which would cause a desired rate of change, the inverse of the normal modeling solution procedure.
Each of the three functions (predict, correct, act) could be specified with a variety of options or could be executed with a variety of techniques. The multitude of choices has led to a variety of nonlinear controller algorithms and associated acronyms. I like this embodiment for its balance of simplicity and effectiveness.
If the model is linear and first-order, the method described by Equations , , and  is equivalent to an internal reset feedback version of a standard PI controller with the integral-time equal to the process time-constant. It is comforting that idealizations lead to a familiar solution, confirming the correctness of the control steps.
For the case of the mixing tank example, the calculations in the AUTO mode would be (Box #1):
Notably, as an issue for nonlinear control, the set of operations could lead to execution errors. For example, if the value of V in Equation  is zero, or if c2=cmodel in Equation  a divide-by-zero error prevention logic must override the calculation. However, the override options should be clear to the process engineer. It is not a case of "Well, now what do I do?" If V=0, for example, then there is no mixing lag in Equation , and the value of cmodel should be the steady-state value predicted by Equation . If V=0, then replace Equation  with Equation . And, if the modeled tank concentration, cmodel, is equal to the inlet concentration, c2, then either c1 is equal to c2, or F2 had been excessive (or F1 had been zero-ish). In either case, F2 cannot be used to change cmodel; and, as a result, F2 should be zero.
Equation  should also be used in the MAN mode to update the model so that the model is appropriately initialized for bumpless transfer when switched to the AUTO mode. In the MAN mode, I also like setpoint tracking, and recommend updating the setpoint with the measurement.
With these features, the simple MISO PMBC algorithm is noted in Box #2.
Necessarily, some variables need to be explicitly initialized. So, in any code there should be a statement such as (Box #3):
MISO Process-Model Based Control (with parameter adjustment)
Often there are process features or attributes that change with time, and which are indicative of process health. These include catalyst reactivity coefficient, impurity concentration, heat exchanger fouling factor, friction losses in fluid piping, ambient heat losses, active ingredient in raw material, viable cell growth factor, reaction yield, average tray efficiency, etc. Coefficient values in a model, indicated by p in Equation , represent those attributes. As the process changes, the model parameter values will change. Process owners often monitor the model coefficient values that reflect such factors to inferentially observe process condition, performance, or health, and use that information to trigger events, schedule maintenance, predict operating constraints and bottleneck capacity, etc.
Dynamic models can be adjusted online to provide information for the process owner. This also will improve control by keeping the model locally and temporally true to the process, but it is not necessary for control.
There are many ways to adapt models in real time, which lead to a variety of adaptive control methods. A simple and effective approach to adjustment of a first-principles model is to desire that the model parameter be adjusted so that pmm approaches zero in a first-order manner. The mathematical statement of the desire is:
Combining Equations  and 
Substituting into Equation  using the chain rule of differentiation
which, rearranged and using the finite difference approximation for dp/dt:
Equation  is recognizable as Newton's method of incremental, recursive parameter updating (root finding), with as a tempering factor, which prevents excessive changes in the model parameter value and reduces measurement noise effects. In computer assignment statements the subscripts are unnecessary, because the past values are used to assign the new value.
The value of should be large compared to model dynamics (so that the dynamics of model adjustment do not interact with control calculations), but the value of should be small compared to the time period over which the process attribute changes (for rapid tracking of the process).
The choice of which model parameter is to be adjusted should be compatible with the following three principles:
- The model parameter represents a process feature of uncertain value. (If the value could be known directly, the adjustment method would not be needed.)
- The process feature changes in time. (If it did not change in time, adaptation would be unnecessary.)
- The model parameter value has a significant impact on the modeled u-y relation. (If it has an inconsequential impact, there is no justification to adjust it.)
As a specific example, again using the mixing tank model, assume that c1 is not measureable, that it changes in time, and is chosen as the model parameter to be incrementally updated. Then the Equation  rule for adjusting the c1 value becomes:
This incremental model parameter adjustment should be included in both the MAN and AUTO control modes. But the reader should also recognize that if F1 is zero the calculation cannot be executed. Should F1 be zero, there is no information that can be used to adjust c1 by the process output. Accordingly, there is no justification to attempt to use the method to update the model parameter, c1. The added line to the computer code becomes:
IF F1 >0 then c1 :=c1+pmm*V/tauwpmm/F1
The author provides the following observations to help those implementing PMBC:
- In tuning PMBC, tau-want should be a bit less (80 percent, perhaps) than the dominant process-model time-constant. This makes the controller push the process slightly faster than the process would normally respond.
- When adjusting model parameter values, tau-pmm, the time-constant for the model parameter adjustment should be about 10 times the dominant model time-constant. This tempers noise and reduces any interaction that might arise between controller and model adaptation.
- Model parameter adjustment can provide insight on the process behavior for maintenance, health, condition, future constraints, etc. This secondary benefit from a control viewpoint might actually be the primary reason from a maintenance or operations viewpoint.
- Model parameter adjustment is not necessary for control. The feedback mechanism for control is to bias the setpoint with the process-model mismatch.
- Supervisory optimizers use steady state process models to determine economic best operating regions. The optimizer needs to understand constraint possibilities and the temporal state of the process. If the controller models are adjusted in real-time to reflect the temporal process conditions, then integrating the controller models (and model parameter values) within the plant-wide optimizer will provide better setpoint values and constraint recognition.
- Use of process models in the controllers preserves and propagates process knowledge among the operational staff. This enhances process understanding, rational troubleshooting, and process improvement, and provides another secondary benefit.
- The case-by-case model development and controller design is a disadvantage. Each case introduces unique challenges in structuring and implementing the equations to present execution errors and to guarantee a solution. This is often easy, but it takes engineering attention.
- Although my experience finds that local or temporal linearizing these controllers always reveals that they are stable, nonlinearity means an inability to globally guarantee convergence, stability, etc. Some will object to the absence of a universal proof of stability.
- The inverse, Equation , might not provide an explicit solution. Use optimization (as opposed to root finding) when either the controller has multiple MVs or the solution for MV value cannot be from an explicit rearrangement. Optimization is the best way to handle the DoF>0 and DoF<0 situations.
- You can use model parameter tracking independent of process control.
- Nonlinear control ability relieves a constraint on process design, permitting design to focus on more competitive outcomes.
- Implement the controller in stages. Be sure that each stage works before letting it reveal its control decisions. Start with exploring the model offline to test it for compliance to the process. Then simulate the controller offline to ensure all execution errors are compensated in MAN to AUTO switches, startup, etc. Then model operating in MAN mode, shadowing the process. If the model needs fixing, do it. Fix the model before it is used to suggest control action. Do not let a bad model lead to control action that creates a bad reputation for the project. After there is confidence in the model, have the controller operate in AUTO mode and suggest control action. You will need to use the actually implemented MV values, not the controller-suggested output, as controller model inputs. After there is confidence in the controller, place it online.
- The model for the controller must be developed and validated. This takes more time than retuning a controller. But it may save many retuning instances and much cumulative re-tuning time in the long run.
- If the process changes significantly (reconfiguration, product type) then the model may have to be changed.
- Implementation and diagnosis of such controllers requires a process engineer with several years of control experience.
- If the control problem is related to process faults (dropped signals, sticktion, analyzer delay, undersized pumps, ill-sized orifices, etc.) then nonlinear control is not the solution.
- Since the actual MV is used to calculate the modeled value (the overridden MV value in safety or select control, not the previously calculated MV), there is no windup on a constraint.
- Nonlinear or non-stationary - A candidate process could be recognized if tuning the controller is a continual problem because the process gain and/or time-constant and/or interactions change with operating region, and/or they change in time due to process reconfigurations, product type, flow rate, or input material properties.
- Condition monitoring - Use the simple models with model parameter adjustment. This provides information related to process condition and constraints.
- Simple dynamics - This one-step-ahead control action is not appropriate for processes with ill-behaved dynamics (inverse action or significant deadtime) or for processes in which action now could lead to a future constraint violation. However, the approach can be extended to horizon-predictive constraint avoidance control.
- MISO - this approach was developed for a single CV and MV with, possibly, measured disturbances. However, it can be applied within a MIMO situation.
Q: How does his PMBC technique differ from other model-based control techniques that readers may already be familiar with (e.g., Model Reference Adaptive Control, Smith Predictors, etc.)?
A: It seems, in the '70s and '80s, many people realized the potential for computers to do more than PID and independently conceived "hundreds" of model-based control approaches. Basic concept elements were independently conceived, but with many nuances for each stage in the control algorithm function. In my experience, with the right limiting assumptions, one controller becomes another. GMC with a Steady State nonlinear model is the same as output characterization from a PI controller. With a linear model, is it simply PI. Internal Model Control (IMC) with a second-order model and a desire that it track a first-order response to a setpoint change leads to a PID Controller. If the process were linear, first-order, with a fixed delay, then PMBC would reduce to a Smith Predictor, as does IMC. The functions within Advanced Process Control (APC) or the academic community term for it, Model Predictive Control (MPC), can be expressed as Figure 1, and, in a limiting case of MISO single step ahead, reduce to IMC. Classically, the Smith Predictor uses a FOPDT model of the process to account for the deadtime, and the process-model mismatch to bias the setpoint for a PI controller. PMBC, IMC, and other model-based controllers would have a similar structure, but the "Act" function in Figure 1 would be the model inverse, not PI. I have not done much with MRAC; I've been more interested in the use of nonlinear models in control, and all my touches on MRAC showed people using linear models. But I suspect ,with the right choices, one can be converted to another.
Q: The examples in the article focus on non-linear processes, where the non-linearity is in the process itself. Would PMBC also be used for situations where the process itself is linear and only the control valve is nonlinear, or are simpler methods OK for this situation?
A: I do promote the use of the best tool for the situation. Best could mean simplest, most convenient, standard, conventional, least expensive, etc. PMBC preserves process knowledge and has only one tuning coefficient. But if PMBC is low on the learning curve, and gain scheduling or output characterization is expedient, or understood, then those would be the best choices. A nonlinear valve could be handled by either gain scheduling or output characterization. So could many nonlinear processes.
Q: Suppose deadtime is the problem. Will PMBC work?
A: Yes, PMBC will work. But if the process is linear, either IMC or a Smith Predictor may work as well and might have the familiarity comfort that would make them preferred. As with those methods, if the process transport delays vary, and the controller deadtime is fixed, then control can go "bad." With a process-based model, the PMBC approach would have the delay based on the process conditions. The ill-behaved dynamics of delay, inverse action, and very high-order were not addressed in the article. If a process has deadtime, then it is not feasible to expect to be able to move it instantaneously. The appropriate controller desire would be to start the process moving at the desired rate after the delay.
Q: Can PMBC be used in a cascade, ratio, or override situations?
A: Yes. The PMBC approach shown here is meant to replace SISO PID controllers that need to be continually retuned because of process nonlinearity. PMBC could be used as primary or secondary controllers, either as both or mixed with PID. I recommend keeping a stage-by-stage design of simple controllers, each with the same Figure 1 form, rather than trying to generate a single code that does it all-in-one. The signal to the model in PMBC needs to be the actual selected, or overridden, value - kin to external reset feedback used to prevent windup when PID is in an override or select situation.
Most nonlinear MISO processes are low order and stable and can use the technique above. However, the PMBC approach can be extended to use process models that are high order, open loop unstable, integrating, or with deadtime. It can be extended to MIMO processes and to horizon-predictive constraint-handling applications. Real-time model adaptation can be included. The extrapolation of the technique is straightforward but beyond the page constraints of this work. Feel free to contact the author for examples and publications.
Reference and Bibliography
- Raul, P. R., H. Srinivasan, S. Kulkarni, M. Shokrian, G. Shrivastava, and R. R. Rhinehart, "Comparison of Model-Based and Conventional Controllers on a Pilot-Scale Heat Exchanger" ISA Transactions, in press 2013, DOI: 10.1016/j.isatra.2012.12.002.
- Skach, A., P. Raul, and R. R. Rhinehart, "Process-Model Based Differential Pressure Control on a Packed Tower Absorber", Submission 0040-000221, Proceedings of the ISA Automation Week Conference, Mobile, AL, October 17-20, 2011.
- Joshi, N. V., P. Murugan, and R. R. Rhinehart, "Experimental Comparison of Control Strategies," Control Engineering Practice, Vol. 5, No. 7, 1997, pp. 885-896.
- Subawalla, H., V. P. Paruchurri, A. Gupta, H. G. Pandit and R. R. Rhinehart, "Comparison of Model-Based and Conventional Control: A Summary of Experimental Results," Industrial and Engineering Chemistry Research, Vol. 35, No. 10, October, 1996, pp. 3547-3559.
- Mahuli, S. K., and R. R. Rhinehart, and J. B. Riggs, "Nonlinear Model-Based In-Line Control of Wastewater pH: A Laboratory Study," ISA Transactions, Vol. 32, 1993, pp. 241-245.
- Mahuli, S. K., R. R. Rhinehart, and J. B. Riggs, "Experimental Demonstration of Nonlinear Model-Based In-Line Control of pH," Journal of Process Control, Vol. 2, No. 3, 1992, pp. 145-153.
- Dutta, P., and R. R., Rhinehart, "Experimental Comparison of a Novel, Simple, Neural Network Controller and Linear Model Based Controllers," Proceedings of the 1995 American Control Conference, June 21-23, 1995, Seattle, WA, paper TA10-3.
- Gupta, A., and R. R. Rhinehart, "Experimental Comparison of Advanced Control Techniques on a Lab-Scale Distillation Column," Proceedings of the 1995 American Control Conference, June 21-23, 1995, Seattle, WA, paper FA10-4.
- Pandit, H. G., and R. R. Rhinehart, "Experimental Demonstration of Constrained Process-Model-Based Control of a Nonideal Distillation Column," Proceedings of the American Control Conference, ACC92, Chicago, IL, June, 1992, pp. 630-631.
ABOUT THE AUTHOR
R. Russell Rhinehart, Ph.D. (email@example.com), is a professor in the School of Chemical Engineering at Oklahoma State University. He holds the Amoco Endowed Chair and has experience in both industry (13 years) and academe (26 years). He was head of the school from 1997 to 2008 and interim head from 2011 to 2012). Rhinehart is president of the American Automatic Control Council, a Fellow of ISA (2001), a CONTROL Automation Hall of Fame inductee, and received the 2009 ISA Distinguished Service Award. He was editor-in-chief of ISA Transactions from 1998-2011. His 1968 B.S. in chemical engineering and subsequent M.S. in nuclear engineering are both from the University of Maryland. His 1985 Ph.D. in chemical engineering is from North Carolina State University. Rhinehart is the faculty advisor to the OSU ISA Student Section, which has about 70 members. Students working with Dr. Rhinehart implement the techniques in computer-controlled pilot-scale unit operations. He believes that practical demonstration is the key to preparing students for practice careers.