Compensation of Dominant and Variable Delay in Process Systems

A technique is proposed for compensating dominant and variable delay in process systems. The basic structure of ... View: PDF | PDF w/ Links | Full Te...
0 downloads 0 Views 205KB Size
982

Ind. Eng. Chem. Res. 1998, 37, 982-986

Compensation of Dominant and Variable Delay in Process Systems Yu-Chu Tian† and Furong Gao* Department of Chemical Engineering, The Hong Kong University of Science and Technology, Clear Water Bay, Kowloon, Hong Kong

A technique is proposed for compensating dominant and variable delay in process systems. The basic structure of the Smith predictor is adopted, while the delay parameter in the process model is continuously tuned on-line by minimizing a performance index function. The average magnitude difference function, the expectation of the absolute difference between process output and process model output, is shown to be a good performance index function. The effectiveness of the proposed method is demonstrated through applications to two typical processes. 1. Introduction Time delay, resulting from material and energy transportation lag, measurement delay, etc., is a common phenomenon in many industrial processes. Many design techniques and conventional control algorithms such as PID cannot be directly applied to processes with dominant time delay. Smith (1957) proposed an effective method to control a process with known and fixed delay. Figure 1 gives the basic structure of the Smith predictor. In this figure, the symbols R and L are setpoint and load, respectively. Gp(s) ) G(s)e-ds, where d is time delay and G(s) is the delay-free part of Gp(s). y and yˆ are process output and process model output, respectively. G*(s) denotes the delay-free part of the process model; d* is an estimation of the time delay. For an integrator process with dominant delay, it has been found that the standard Smith predictor cannot be directly applied due to its poor load rejection performance. A constant load disturbance will result in a steady-state error. Modifications to the standard Smith predictor have been proposed to overcome this problem (Watanabe and Ito, 1981; Astrom et al., 1994; Matausek and Micic, 1996; Zhang and Sun, 1996). An example of such modifications, proposed by Matausek and Micic (1996), is shown in Figure 2. This modified Smith predictor has a simple structure and good system performance. Only three parameters, Kp, Tr, and d*, are required to be determined. The determination of the parameters is also relatively easy. From Kp, Tr, and d*, all the parameters in Figure 2 can be obtained. Both the standard Smith predictor (Figure 1) and the modified Smith predictor by Matausek and Micic (Figure 2) are based on the assumption of a good process model. An inherent drawback of the Smith predictor is that its control performance is sensitive to the process model, especially to time delay. If a process model deviates from the process dynamics, i.e., G*(s) and d* are inaccurate, the system performance deteriorates. Applications of the Smith predictor are, therefore, limited in industrial processes. To alleviate this limitation, it is necessary to find a mechanism to compensate * To whom correspondence should be addressed. Telephone: +852-2358 7139. Fax: +852-2358 0054. E-mail: kefgao@ uxmail.ust.hk. † On leave from Institute of Industrial Process Control, Zhejiang University, Hangzhou 310027, People’s Republic of China. E-mail: [email protected].

Figure 1. Block diagram of the Smith predictor.

0

Figure 2. Modified Smith predictor by Matausek and Micic.

model errors. There have been a few extensions of the Smith predictor to simplify or robustify the controllers. For example, robust analysis and design techniques have been applied to the Smith predictor (Laughlin et al., 1987; Lee, et al., 1996), and adaptive control methods have also been applied to the Smith predictor via on-line parameter estimation of the predictive model (Hang et al., 1989; Hagglund, 1992; Dumont et al., 1993; Rad et al., 1995). These modifications, however, do not explicitly address the control problem of dominant and variable delay processes. Few algorithms concerning the problem are easy to implement on-line and in realtime. By on-line adjusting the delay parameter in the process model, this paper extends the Smith predictor to a wide range of industrial processes with dominant and variable time delay. The method is applicable to processes with or without an integrator. The basic structure of the Smith predictor or its modified forms is retained, while the time delay parameter in the predictive model is tuned on-line by minimizing the error between the process output and the process model output, as shown in Figures 3 and 4. The average magnitude difference function (AMDF) is employed as

S0888-5885(97)00507-1 CCC: $15.00 © 1998 American Chemical Society Published on Web 01/24/1998

Ind. Eng. Chem. Res., Vol. 37, No. 3, 1998 983

The basic idea of the methods is to detect the location of the correlation peak of the two received signals, which corresponds to the best estimation of the delay. A measure of direct correlation between the received signals is defined by

RD(τ) ) E{x1(t) x2(t+τ)} ) Rss(τ-d)

Figure 3. On-line tuning of d* in the Smith predictor through minimizing RA(d*).

(2)

where E{ } denotes the mathematical expectation of the quantity within the bracket, and Rss(τ-d) ) E{s(t) s(t+τ)} is the autocorrelation function of s(t). Rss(τ-d) can be transposed to have its maximum value at τ ) d. The computation of RD(τ) requires an integration that is difficult to obtain on-line and in real-time. An estimate of RD(τ) from the sampled time series data of x1(t) and x2(t) is

RD(τ) )

1 N

x1(i∆t) x2(i∆t+τ) ∑N-1 0

(2′)

where N > 0 is the number of sample pairs used. It is required that the total number of sample pairs, representing the observation time, is larger than N. In addition to the above direct correlation function, other criteria may also be used for delay estimation. A simpler criterion requiring less computation is the socalled AMDF, expressed by

RA(τ) ) E{| x1(t) - x2(t+τ) |}

(3)

Similar to RD(τ), RA(τ) can also be estimated from the sampled time series data of x1(t) and x2(t) as Figure 4. On-line tuning of d* in the modified Smith predictor by Matausek and Micic through minimizing RA(d*).

a minimizing criterion. Two typical examples are given to illustrate the effectiveness of the proposed method. 2. Delay Estimation Principle Consider two noisy measurement signals, x1(t) and x2(t), received at two sensors. The two signals are transmitted from the same source labeled by s(t). One of the signals, say x2(t), includes a dominant delay, d, to be estimated from the received signals. This physical problem can be mathematically described as

(1)

or in discrete-time form as

x1(i∆t) ) s(i∆t) + n1(i∆t) x2(i∆t) ) s(i∆t - d) + n2(i∆t)

1 N

|x1(i∆t) - x2(i∆t+τ)| ∑N-1 0

(3′)

A minimum value of RA(τ) takes place at τ ) d, indicating the estimate of delay d. The previous assumptions of stationary, Gaussian, and independent distributions of noises are strict and thus hard to be met in most practical applications. Various window functions (prefilters) can be adopted to improve the performance of the delay estimator. Each technique has its advantages and limitations depending on the nature of signals and noises. 3. Application to Processes with Variable Delay

x1(t) ) s(t) + n1(t) x2(t) ) s(t - d) + n2(t)

RA(τ) )

(1′)

where i is an integer and ∆t is the sampling period. Delay d is assumed to be a multiple of ∆t for simplicity. To make the problem mathematically treatable, it is assumed that the noises, n1(t) and n2(t), are not correlated with each other nor with the source signal s(t). It is further assumed that observation time is large compared to delay d and that all signals and noises are stochastic and stationary with zero-mean Gaussian distributions. A number of methods can be employed to estimate the delay for the problem described above (Carter, 1993).

The delay estimation principle discussed in the last section may be applied to obtain an estimate of the process delay for our modified Smith predictors as shown in Figure 3 or 4, even if the assumptions are not strictly satisfied. For the Smith predictor in Figure 3, we have

Y*(s) ) G*(s) U(s) Y(s) ) G(s) exp(-ds) U(s) Y ˆ (s) ) Y*(s) exp(-d*s) ) G*(s) exp(-d*s) U(s) (4) y*(t), y(t), and d* can be viewed as x1(t), x2(t), and τ, respectively. The estimate d* of d can then be obtained by selecting d* > 0 to maximize the direct correlation function

RD(d*) ) E{y*(t) y(t+d*)} or to minimize the AMDF

(5)

984 Ind. Eng. Chem. Res., Vol. 37, No. 3, 1998

RA(d*) ) E{| y*(t) - y(t+d*) |}

(6)

RD(d*) and RA(d*) can be computed respectively from the sampled time series data of y(t) and y*(t):

RD(d*) )

∑II y*(i∆t) y(i∆t+d*) 1

0

∑II |y*(i∆t) - y(i∆t+d*)| ∑II |y˜ (i∆t+d*)|

1 N 1 ) N

RA(d*) )

1 N

(5′)

1

0

1

0

(6′)

where I1 ) (t - d*)/∆t, I0 ) I1 - N + 1, y˜ (i∆t) ) y(i∆t+d*) - y*(i∆t). It is apparent that I0 has to be greater than 0. This implies that t g (N - 1)∆t + d* has to be met for any selected N, or N e (t - d*)/∆t + 1 for any given observation time t. By shifting the time variable, eqs 5′ and 6′ can be transformed into

RD(d*) )

1 N

t/∆t y*(i∆t-d*) y(i∆t) ) ∑t/∆t-N+1 1 t/∆t yˆ (i∆t) y(i∆t) N ∑t/∆t-N+1

(5′′)

t/∆t |y*(i∆t-d*) - y(i∆t)| ) ∑t/∆t-N+1 1 1 t/∆t t/∆t |yˆ (i∆t) - y(i∆t)| ) ∑t/∆t-N+1 |y˜ (i∆t)| N ∑t/∆t-N+1 N

RA(d*) )

1 N

(6′′) where t/∆t - N + 1 g 0 is required for the selections of t and N. For our Smith predictor of Figure 4, we have the following formulas different from the relations of eq 4:

Y*(s) ) G*(s) Ur(s) Y(s) ) G(s) exp(-ds) {Ur(s) - U0(s)}, U0(s) ) K0Y ˜ (s) Y ˆ (s) ) Y*(s) exp(-d*s) ) G*(s) exp(-d*s) Ur(s) (7) RD(d*) and RA(d*) can then be computed using relations similar to those for our modified Smith predictor of Figure 3. Maximizing RD(d*) or minimizing RA(d*) will give an on-line tuning of d*. In comparison to maximizing the direct correlation measure RD(d), minimizing the AMDF RA(d*) is a more flexible criterion for the problem considered. In addition to giving a correlation measure between y and y*, RA(d*) also gives a degree of error between y and y*. This clear physical interpretation is consistent with the design objective: tuning model parameters by minimizing the error between the process output and the process model output. The minimization of RA(d*) is, therefore, chosen as the performance index function for compensating the dominant and variable process delay. 4. Simulation Examples 4.1. First-Order Plus Delay Process. Consider a widely used first-order plus delay process with the following transfer function:

Gp(s) )

Kp e-ds Tps + 1

Figure 5. Response of the Smith predictor to square-wave setpoint changes.

(8)

where Kp ) 1, Tp ) 0.5, and d ) 5. The standard Smith

Figure 6. Response of the Smith predictor with a variable process delay.

predictor can be implemented for the system with G*(s) ) K*/(T*s + 1) and delay e-d*s, as shown in Figure 1. In an ideal situation, K* ) Kp, T* ) Tp, and d* ) d. Suppose that the desired closed-loop transfer function of the controlled system is also a first-order plus delay process [Y(s)/R(s)]d ) [1/(s + 1)]e-ds. This indicates that the open-loop process response to a step change in setpoint is retained in the corresponding closed-loop system. Solving for Gc gives a standard PI controller Gc ) Kc(1 + 1/Tis) with Kc ) 0.5 and Ti ) 0.5. The resulting Smith predictor works well if the dynamic model matches the process behaviors. Figure 5 shows the response of the Smith predictor to square-wave setpoint changes. Throughout the simulations, the sampling time step is set to be 0.075. Matlab/Simulink software is used as the simulation tool. As stated previously, the Smith predictor is sensitive to the process model, particularly to delay time variations. Inevitable mismatch between the process model and the actual process results in a poor control performance, in some cases even an unstable response. Deviation of the process model to process dynamics is introduced to evaluate the effectiveness of the proposed method. For simplicity, the process model and consequently controller settings are kept unchanged, while the process dynamics are varied to simulate model mismatch. As it is relatively easy to have a good estimation of process gain, its variation is not considered to reduce the paper length. An unknown variable delay is first introduced to the process to demonstrate its effect on system performance. Both gradual and sudden changes in d are considered, as shown in Figure 6. When t g 50, d is a square wave, while when t < 50, d is a sinusoidal wave with the form of

d ) 5 + A sin(ωt + φ)

for t ∈ [0, 50)

(9)

where the amplitude A ) 3, frequency ω ) 2π/40, and phase φ ) π/2. With d* remaining as 5, Figure 6

Ind. Eng. Chem. Res., Vol. 37, No. 3, 1998 985

Figure 7. Response of our Smith predictor of Figure 3 to squarewave set-point changes.

Figure 9. Effect of a noise disturbance on system performance.

Figure 10. Effect of N on system performance. Figure 8. Effects of time constant variations on system performance.

illustrates the response of the Smith predictor to squarewave setpoint changes with the variable process delay. Clearly, y is oscillatory and the Smith predictor fails to work in this case. The proposed method as shown in Figure 3 is applied to tune d* on-line with an initial value of d* ) 5. N, the number of samples for computing the performance index function RA(d*) is set to be 10. As shown in Figure 7, the output, y, of the closed-loop system tracks the square-wave setpoint changes very well, indicating the effectiveness of the proposed method. The process delay is not estimated during the beginning period of t ) 0 to t ) d. The delay estimation starts to work only when process output becomes available. Once it starts, the delay estimate d* converges to the process delay d quickly and then tracks it, resulting in good control performance. The deviation of the process time constant from its normal value of 0.5 is also considered. Suppose Tp changes 20% to 0.6. With our modified Smith predictor of Figure 3, the control result is shown in Figure 8 together with the on-line estimation of the variable delay. A comparison of Figures 7 and 8 indicates that the model mismatch does not introduce any significant deterioration in control performance with our on-line algorithm, despite the fact that the estimate d* is slightly poorer in the presence of time constant uncertainty. This again indicates the effectiveness of the proposed method. Like any closed-loop identification methods, the proposed scheme cannot be expected to give a good delay estimation when process output tracks setpoint without any error as there lacks an excitement to the estimation algorithm. In this particular situation, a deviation of d* from d has no effect on control performance. In this sense, the proposed method may be viewed as a dynamic compensation to variable process delay rather than a

delay estimation. In practice, there always exists inevitable noise disturbance that can excite the proposed delay compensation algorithm. Suppose a band-limited Gaussian white noise L is imposed onto the process as a load disturbance, as shown in Figure 3. This noise is produced by a standard Matlab/Simulink block implemented using Gaussian white noise into a zero-order holder. The mean and power of the noise is 0 and 1.875 × 10-4, respectively. Figure 9 shows the corresponding response of our modified Smith predictor of Figure 3 to square-wave setpoint changes with a variable delay. Good control performance is obtained in the presence of the load disturbance. In computing the performance index function RA(d*), the number of sampled data pairs, N, is an important design parameter. Small N implies that RA(d*) has a fast response to process delay changes. Small N, however, makes RA(d*) sensitive to noise disturbance. N, therefore, should not be too small. In contrast, large N results in a RA(d*) insensitive to noise disturbance but slow in response to process delay changes. A compromise of N should be considered in practical applications. Figure 10 shows the response of our modified Smith predictor of Figure 3 with N ) 20, twice that in Figure 7. The delay tuning in Figure 10 is clearly more sluggish than that in Figure 7. 4.2. High-Order Integrator Process with Dominant Delay. Now consider a high-order integrator process with a dominant delay described by

Gp(s) ) G(s) e-ds ) 1 e-5s (10) s(s + 1)(0.5s + 1)(0.2s + 1)(0.1s + 1) This process was studied by Matausek and Micic (1996). The standard Smith predictor is not applicable to an integrator process such as model eq 10, as it cannot reject load disturbance. As shown in Figure 2, the

986 Ind. Eng. Chem. Res., Vol. 37, No. 3, 1998

Figure 11. Response of the modified Smith predictor by Matausek and Micic.

Figure 12. Response of our modified Smith predictor of Figure 4.

modified Smith predictor by Matausek and Micic (1996) can be used to control this type of process with good control performance if there is no significant variation in process dynamics. Suppose that the open-loop time constant of the process is retained in the corresponding closed-loop system. According to Matausek and Micic (1996), the process model parameters and the controller settings are respectively designed to be Kp ) 1, d* ) 6.7, Tr ) 1.7, Kr ) 1/(KpTr) ) 1/1.7, and K0 ) 1/(2Kpd*) ) 1/13.4. With these parameter values, good control performance can be obtained. Simulations show that the robustness of the modified Smith predictor by Matausek and Micic (1996) is better than the standard Smith predictor. However, large changes in process parameters still result in poor performance. Again, assume that the process has a dominant and variable delay as in the case of the previous example. The same noise disturbance as in the previous example is also introduced. Figure 11 shows the strongly oscillatory system response, indicating that the modified Smith predictor by Matausek and Micic does not work well in this case. The proposed scheme shown in Figure 4 is applied to compensate the dominant and variable process delay. The initial value of d* is selected to be 6.7 which is subject to on-line tuning. At each sampling, the AMDF RA(d*) is minimized with respect to d* to obtain the current error signal y˜ ) y - y*. N, the number of sampled data pairs for computing the AMDF RA(d*), is set to be 10. As shown in Figure 12 subject to a noise disturbance, y, the output of our modified Smith predictor of Figure 4 tracks the set point very well, indicating the effectiveness of the proposed method. It is noted that d* will not track d in this example as the highorder integrator process dynamics have been approximated by a pure integrator plus delay model.

The tuning criterion is to minimize the AMDF defined by the expectation of the absolute difference between the process output and process model output. The effectiveness of the proposed method has been demonstrated through applications to two typical processes. Acknowledgment This work was supported in part by HKUST under Grant No. RI95/96.EG03. Literature Cited Astrom, K. J.; Hang, C. C.; Lim, B. C. A New Smith Predictor for Controlling a Process with an Integrator and Long Dead-Time. IEEE Trans. Autom. Control 1994, 39, 343. Carter, G. C., Ed. Coherence and Time Delay Estimation; IEEE Press: New York, 1993. Dumont, G. A.; Elnaggar, A.; Elshafei, A. Adaptive Predictive Control of Systems with Varying Time Delay. Int. J. Adapt. Control Signal Process. 1993, 7, 91. Hagglund, T. A Predictive PI Controller for Processes with Long Dead Times. IEEE Control Syst. 1992, 12, 57. Hang, C. C.; Lim, K. W.; Chong, B. W. A Dual-Rate Adaptive Digital Smith Predictor. Automatica 1989, 25, 1. Laughlin, D. L.; Rivera, D. E.; Morari, M. Smith Predictor Design for Robust Performance. Int. J. Control 1987, 46, 477. Lee, T. H.; Wang, Q. G.; Tan, K. K. Robust Smith-Predictor Controller for Uncertain Delay Systems. AIChE J. 1996, 42, 1033. Matausek, M. R.; Micic, A. D. A Modified Smith Predictor for Controlling a Process with an Integrator and Long Dead-Time. IEEE Trans. Autom. Control 1996, 41, 1199. Rad, A. B.; Tsang, K. M.; Lo, W. L. Adaptive Control of Dominant Time Delay Systems via Polynomial Identification. IEE Proc.Control Theory Appl. 1995, 142, 433. Smith, O. J. M. Closer Control of Loops with Dead Time. Chem. Eng. Prog. 1957, 53, 217. Watanabe, K.; Ito, M. A Process-Model Control for Linear Systems with Delay. IEEE Trans. Autom. Control 1981, 26, 1261. Zhang, W. D.; Sun, Y. X. Modified Smith Predictor for Controlling Integrator/Time Delay Processes. Ind. Eng. Chem. Res. 1996, 35, 2769.

5. Conclusion A technique has been proposed to compensate dominant and variable delay in industrial processes. The Smith predictor was adopted as a basic compensator together with an on-line tuning of process model delay.

Received for review July 21, 1997 Revised manuscript received December 2, 1997 Accepted December 3, 1997 IE970507R