Tuning of Multiloop Proportional−Integral−Derivative Controllers

Apr 15, 1997 - An analytical method of tuning multiloop proportional-integral-derivative controllers based on gain and phase margin specifications is ...
0 downloads 0 Views 189KB Size
Ind. Eng. Chem. Res. 1997, 36, 2231-2238

2231

Tuning of Multiloop Proportional-Integral-Derivative Controllers Based on Gain and Phase Margin Specifications Weng K. Ho,* Tong H. Lee, and Oon P. Gan Centre for Intelligent Control, c/o Department of Electrical Engineering, National University of Singapore, 10 Kent Ridge Crescent, Singapore 119260, Singapore

An analytical method of tuning multiloop proportional-integral-derivative controllers based on gain and phase margin specifications is presented in this paper. The proposed design method can tune the multiloop controllers on-line and in real-time to meet specified system robustness and performance. The design method can be easily combined with existing process identification techniques to implement self-tuning multiloop controllers. 1. Introduction According to a survey (Yamamoto and Hashimoto, 1991) of the state of process control systems in 1989 conducted by the Japan Electric Measuring Instrument Manufacturer’s Association, more than 90% of the control loops were of the proportional-integral-derivative (PID) type. A paper by Bialkowski (1993) also indicates that a typical paper mill in Canada has more than 2000 control loops and that 97% use PI control. Despite the fact that the use of PID control is well established in process industries, many control loops are still found to perform poorly. Bialkowski (1993) reported that only 20% of the control loops were found to work well. Of those that do not perform well, 30% were due to poor tuning. Ender (1993) also claimed that 30% of installed process controllers operate in manual and 20% of the loops use “factory tuning”, i.e., default parameters set by the manufacturer. In view of the fact that PID controllers are widely used but poorly tuned in the industry, we have attempted to give some practical and easily implementable designs and solutions for industrial use (Hang et al., 1991, 1993; Åstro¨m et al., 1992, 1993). This paper, we hope, is another small step in this direction. One well-known method for the tuning of the multiloop PID controllers is the biggest log modulus tuning (BLT) method (Luyben, 1986). This method is viewed in the same light as the classical SISO Ziegler-Nichols method (Ziegler and Nichols, 1942). It gives rough tuning only and needs to be supplemented by fine tuning. Another multiloop design method is the internal model control (IMC) multiloop design (Economou and Morari, 1986). However, it is known that the IMC design gives poor load disturbance response for a process with a small dead-time to time-constant ratio (Ho et al., 1995; Hang et al., 1994; Chien and Fruehauf, 1990). Gain and phase margins have served as important measures of robustness for the single-input singleoutput (SISO) system. It is known from classical control that phase margin is related to the damping of the system and therefore can also serve as a performance measure (Franklin et al., 1986). SISO controller designs * Author to whom all correspondence should be addressed. Email: [email protected]. Telephone: (65)7726286. Fax: (65)7791103. S0888-5885(96)00732-4 CCC: $14.00

by shaping the Nyquist curve to pass through two points given by the gain and phase margins specifications are well accepted in practice and in classical control. However, they are normally solved off-line by numerical methods or trial and error graphically using Bode plots. Such approaches are not suitable for use in self-tuning control. Recently, in the gain and phase margins design method (Ho et al., 1995), simple formulas were derived to tune the SISO PID controllers on-line to meet userspecified gain and phase margins. This paper introduces an extension of this design approach to multiloop control systems. The new multiloop gain and phase margin design method developed in this paper is based on the idea of shaping the Gershgorin bands for closed-loop stability and performance. Conventionally in the direct Nyquist array (DNA) method (Rosenbrock, 1970, 1974; Maciejowski, 1988; Deshpande, 1989), controller designs by shaping of the Gershgorin bands are performed off-line using a trial and error graphical approach. This is often tedious and time consuming and also requires much experience. To solve this problem, this paper introduces the idea of shaping the Gershgorin bands to pass through two user-specified points using a set of analytical formulas, thereby making the design method suitable for on-line and real-time implementation such as in self-tuning control. The new contribution of the paper is to provide an algorithm for the computer to automate the DNA design method. The theoretical motivation and justification for the DNA design method are given in Rosenbrock (1970, 1974) and Maciejowski (1988). Examples of industrial implementation of the DNA design method are given in Desphande (1989).

2. Multiloop Gain and Phase Margin Design Consider an n-inputs and n-outputs open-loop stable multivariable process with the transfer function matrix

[

g11(s) ... g1n(s) G(s) ) l gn1(s) ... gnn(s)

]

where gij(s) is the commonly used second-order plus dead-time process model: © 1997 American Chemical Society

2232 Ind. Eng. Chem. Res., Vol. 36, No. 6, 1997

gij(s) )

Kije-sLij

,

(sτij + 1)(sτ′ij + 1)

τ′ij e τij

(1)

It is assumed that G(s) has been arranged such that the pairings of the inputs and outputs in the multiloop feedback system correspond to the diagonal elements of G(s). Relative gain array (Bristol, 1966; Shinskey, 1979, 1981; McAvoy, 1983) may be used to carry out interaction analysis and to select the proper pairings. To control the multivariable process G(s), n multiloop diagonal PID controllers are used. The controller transfer function matrix Gc(s) is therefore diagonal

Gc(s) ) diag[gc1(s), gc2(s), ..., gcn(s)]

Figure 1. Typical Nyquist diagram with the Gershgorin circle at the gain crossover frequency wg.

where gci(s) is the PID controller transfer function

(

gci(s) ) KCi 1 +

)

1 (1 + sTDi) sTIi

i ) 1, ..., n

The loop transfer function matrix of the closed-loop system is given by

[

q11(s) ... q1n(s) Q(s) ) G(s) Gc(s) ) l qn1(s) ... qnn(s)

]

Closed-loop stability of the multivariable feedback system can be determined from Rosenbrock’s DNA stability theorem. DNA Stability Theorem (Rosenbrock, 1970, 1974; Maciejowski, 1989). Let the Gershgorin bands centered on the diagonal elements qii(s) of Q(s) exclude the point (-1 + i0). Let the ith Gershgorin band encircle the point (-1 + i0) Ni times counterclockwise. Then, n the closed-loop system is stable if, and only if, ∑i)1 Ni ) p0 where p0 is the number of unstable poles of Q(s). Since we are dealing with open-loop stable processes and most industrial processes are stable, we have assumed that p0 ) 0 in this paper. Figures 1 and 2 show a typical Nyquist curve of a diagonal element qii(iω) and the Gershgorin circle at the gain crossover frequency, wg, and phase crossover frequency, wp, respectively. The Gershgorin band consists of a band of Gershgorin circles each of center qii(iω) and radius ∑j,j*i|qji(iω)| (Maciejowski, 1989) (see Figure 3). Conventionally in the DNA method (Rosenbrock, 1970, 1974; Maciejowski, 1988; Deshpande, 1989), controller designs by shaping of the Gershgorin bands are performed off-line using a trial and error graphical approach. This is often tedious and time consuming and also requires much experience. To solve this problem, the idea of shaping the Gershgorin band to pass through two user-specified points using a set of analytical formulas is given as follows. The two points for shaping the Gershgorin bands are defined in the same spirit as the gain and phase margins. At the gain crossover frequency, ωg, of qii(s), the Gershgorin circle (solid line) intersects the unit circle (dotted line) at B (see Figure 1). Define φm ) arg(B) + π. At the phase crossover frequency, ωp, of qii(s), the Gershgorin circle intersects the negative real

Figure 2. Typical Nyquist diagram with the Gershgorin circle at the phase crossover frequency wp.

Figure 3. Nyquist array and Gershgorin bands of G1(s) Gc1(s) for A′m ) 2 and φ′m ) 20°.

axis at C (see Figure 2). Define A′m ) 1/|C|. For an open-loop stable process, if A′m > 1 and φ′m > 0°, then according to the DNA stability theorem, the closed-loop system is stable.

Ind. Eng. Chem. Res., Vol. 36, No. 6, 1997 2233

Figure 4. Setpoint responses of G1(s) Gc1(s) (solid line: A′m ) 2 and φ′m ) 20°) and G1(s) Gc2(s) (dashed line: A′m ) 3 and φ′m ) 30°).

According to the DNA stability theorem, to obtain stability, the Gershgorin band can thus be shaped based on user-specified A′m and φ′m such that it excludes and does not encircle the point (-1 + i0). This approach can be compared with the classical control technique of shaping the Nyquist curve of a SISO system to meet gain and phase margin specifications. Theoretically, A′m and φ′m or the gain and phase margins in SISO systems only define two points and cannot gaurantee that all parts of the curve do not encircle the point (-1 + i0). However, the gain and phase margin design technique is well accepted in practice and in classical control. A rule of thumb for the choice of A′m and φ′m for multiloop systems is 2 e A′m e 5 and 20° e φ′m e 60°, respectively. From Figure 1, using simple geometry, the phase margin, φm, of qii(s) can be expressed in terms of φ′m as

(∑

φm ) φ′m + 2 arcsin

) (∑

j,j*i|qji(iωg)|

2|qii(iωg)|

φ′m + 2 arcsin

)

)

j,j*i|gji(iωg)|

2|gii(iωg)|

(2)

From Figure 2, using simple geometry, the gain margin, Am, of qii(s) can be expressed in terms of A′m as

(

Am ) A′m 1 +

)

∑j,j*i|qji(iωp)| |qii(iωp)|

)

(

A′m 1 +

)

∑j,j*i|gji(iωp)| |gii(iωp)|

(3)

In the proposed design method, A′m and φ′m are specified

2234 Ind. Eng. Chem. Res., Vol. 36, No. 6, 1997

multiloop gain and phase margin design can shape the Gershgorin band on-line, making it suitable for realtime implementation. Like the BLT method (Luyben, 1986) and the multiloop IMC design (Economou and Morari, 1986), the first step of decoupling is not performed in the multiloop gain and phase margin design. 3. Example The multiloop gain and phase margin design method is best illustrated through a simulation example. Consider the methanol-water distillation column of Wood and Berry (1973) (Luyben, 1986):

[

12.8e-s -18.9e-3s + 1 21s + 1 G1(s) ) 16.7s -7s -19.4e-3s 6.6e 10.9s + 1 14.4s + 1

Figure 5. Nyquist array and Gershgorin bands of G1(s) Gc2(s) for A′m ) 3 and φ′m ) 30°.

for each loop. The PID controller gci(s) of each loop can be designed from the phase margin, φm, and gain margin, Am, obtained from eqs 2 and 3 using the gain and phase margin tuning formulas for the SISO system (Ho et al., 1995):

KCi )

(

TIi ) 2ωpi -

ωpiτii AmKii

4ωpi2Lii 1 + π τii

(4)

)

-1

TDi ) τ′ii

(5) (6)

[ (

ωgi )

ωpi Am

(



1 1 , -0.11 1 + 20.70s 12.88s (11)

)

)]

(

(7) π π + Am2 2 2 2 (Am - 1)Lii

Am φm ωpi )

(10)

The inputs and outputs of this multivariable system are paired in correspondence with the diagonal transfer functions. Two multiloop PI controllers are used to control the multivariable process G1(s). A′m ) 2 and φ′m ) π/9 (20°) are specified for both loops. The design steps are as follows: (i) Substitute L11 ) 1 from g11(s) of G1(s) and L22 ) 3 from g22(s) of G1(s) into expression (9) to give respectively ωp ) 1.57 and 0.52. (ii) Substitute ωp ) 1.57, A′m ) 2 and ωp ) 0.52, A′m ) 2 into eq 3 to give respectively Am ) 3.57 and 3.34. (iii) Substitute Am ) 3.57, ωp ) 1.57 and Am ) 3.34, ωp ) 0.52 into eq 7 to give respectively ωg ) 0.44 and 0.15. (iv) Substitute ωg ) 0.44, φ′m ) π/9 (20°) and ωg ) 0.15, φ′m ) π/9 (20°) into eq 2 to give respectively φm ) 1.15 (65.9°) and 1.06 (60.9°). (v) Substitute Am ) 3.57, φm ) 1.15, g11(s) and Am ) 3.34, φm ) 1.06, g22(s) into eqs 4, 5, and 8 to give the 2 PI controllers respectively:

Gc1(s) ) diag 0.57 1 +

where

]

π 2Lii

)

(8)

(9)

The approximation for ωpi in expression (9) can be made for typical gain and phase margin specifications of Am g 3 and π/4 (45°) e φm e π/2 (90°). If the firstorder plus dead-time process model is used for gii(s) of eq 1, then in eq 6 TDi ) τ′ii ) 0 and a PI controller will be designed. The multiloop gain and phase margin design is also related to the DNA design (Rosenbrock, 1970, 1974; Maciejowski, 1989). The DNA design consists of two main steps. In the first step, compensators are used to decouple the system to some extent. The second step consists of designing the diagonal multiloop controllers to shape the Gershgorin bands, off-line graphically for closed-loop stability and performance. In contrast, the

The Nyquist array and the Gershgorin bands of G1(s) Gc1(s) are shown in Figure 3. The closed-loop system is stable because the Gershgorin bands exclude and do not encircle the point (-1 + i0). The setpoint response (solid line) from Matlab simulation is shown in Figure 4. Consider a more robust design of A′m ) 3 and φ′m ) π/6 (30°) for both loops. Using the same approach, the controllers are designed as

[ (

Gc2(s) ) diag 0.38 1 +

1 1 , -0.07 1 + 21.64s 14.80s

)

(

)]

The Nyquist array diagram of G1(s) Gc2(s) is shown in Figure 5. The system is more robust because the Gershgorin bands are further from the point (-1 + i0). The corresponding setpoint response (dashed line) shown in Figure 4 is more sluggish. Therefore, A′m and φ′m can be specified according to the requirements of system robustness and performance. A comparison with the BLT method (Luyben, 1986) is shown in Figure 6 for G1(s) of eq 10. The controllers designed using the multiloop gain and phase margin

Ind. Eng. Chem. Res., Vol. 36, No. 6, 1997 2235

Figure 6. Comparison of performance of G1(s) Gc1(s) based on the multiloop gain and phase margin design method (solid line) and G1(s) Gc3(s) based on the biggest log tuning method (dashed line).

method are given by eq 11. The controllers designed using the BLT method are given as (Luyben, 1986)

[

(

Gc3(s) ) diag 0.375 1 +

1 1 , -0.075 1 + 8.29s 23.6s

)

(

)]

The multiloop gain and phase margin design (solid line) produces better setpoint and load disturbance responses than the BLT method (dashed line) for output y2. The responses for output y1 are about the same. Another multiloop design method is the internal model control (IMC) multiloop design (Economou and Morari, 1986). However, it is known that the IMC design gives good setpoint response but poor load disturbance response for a process with a small deadtime to time-constant ratio (Ho et al., 1995; Hang et al.,

1994; Chien and Fruehauf, 1990). A simple comparison for the IMC design and the gain and phase margin design for the process

Gp(s) )

e-s0.1 s+1

is given in Figure 7. Figure 7 gives the response for the IMC-PI design and the much improved loaddisturbance response of a design with a gain margin of 3 and a phase margin of 45°. 4. Pilot-Plant Experiment The simple analytical formulas in the multiloop gain and phase margin design are well suited for implement-

2236 Ind. Eng. Chem. Res., Vol. 36, No. 6, 1997

Figure 7. Comparison of setpoint responses and load disturbance responses for e-0.1s/(1 + s). Gain margin of 3 and phase margin of 45° (solid line); IMC-PI (dashed line).

ing multiloop self-tuning PID control. A multiloop selftuning PID controller can be implemented by combining an established multivariable process identification technique (Isermann et al., 1992) with the multiloop gain and phase margin design. Four tanks were connected in the same configuration that Gawthrop (1990) had used for testing his multiloop PID controllers (see Figure 8). A discrete time model

[

b11z-1 b12z-1 -7 z-2 z 1 + a1z-1 1 + a1z-1 G(z) ) b21z-1 b22z-1 -2 z-4 z 1 + a2z-1 1 + a2z-1

]

is estimated using recursive least squares (Isermann et al., 1992). The dead times in G(z) were earlier estimated from open-loop step responses. The continuous-time model is then recovered from the discrete-time model using pole-zero mapping. Loop 1 is tuned for A′m ) 4, φ′m ) 2π/9 (40°) and loop 2 for A′m ) 3, φ′m ) π/6 (30°). Two multiloop PI controllers were used for controlling the four-tank system. They were implemented in a microcomputer with data-aquisition hardware and

Figure 8. Four-tank system.

software connected to the coupled tanks. The sampling interval was 20 s. The forgetting factor for the leastsquares estimator was 0.98, and the initial value of the covariance matrix was 1000I. Figure 9 shows that the initial setpoint responses from t ) 0 to 100 min had fairly large overshoots. As self-tuning progressed, the overshoots of the setpoint responses from t ) 110 to 150 min were very much reduced. At t ) 150 min, taps 1 and 2 were fully opened. As a result, the setpoint responses at t ) 190 min for y1

Ind. Eng. Chem. Res., Vol. 36, No. 6, 1997 2237

Figure 9. Performance of the multiloop self-tuning PI controllers.

and t ) 220 min for y2 became sluggish. However, the subsequent setpoint responses improved due to selftuning. The process transfer function matrix estimated at t ) 120 min was

[

4.3e-40s +1 G(s) ) 383s -80s 1.2e 281s + 1

1.8e-140s 383s + 1 2.5e-40s 281s + 1

]

The PI controller designed using eqs 4 and 5 and for the above process was

[ (

Gc1(s) ) diag 0.62 1 +

1 1 , 0.94 1 + 217s 193s

)

(

)]

The corresponding Nyquist array and Gershgorin bands are shown in Figure 10. 5. Conclusions An analytical method of tuning multiloop PID controllers based on gain and phase margin specifications is presented in this paper. This method is developed in the same spirit as the biggest log modulus tuning method to provide a simple and practical design method for multivariable control systems. It is based on the idea of shaping the Gershgorin bands to pass through two user-specified points, for closed-loop stability and performance. The proposed design method tunes the multiloop PID controllers to meet specified system robustness and performance. The design method can

2238 Ind. Eng. Chem. Res., Vol. 36, No. 6, 1997

Figure 10. Nyquist array and Gershgorin bands of the four-tank system.

be easily combined with existing process identification techniques to implement self-tuning multiloop controllers. Literature Cited Åstro¨m, K. J.; Hang, C. C.; Persson, P.; Ho, W. K. Towards Intelligent PID Control. Automatica 1992, 28, 1-9. Åstro¨m, K. J.; Ha¨gglund, T.; Hang, C. C.; Ho, W. K. Automatic Tuning and Adaptation for PID Controllerssa Survey. Control Eng. Practice 1993, 1, 699-714. Bialkowski, W. L. Dreams Versus Reality: A View from Both Sides of the Gap. Pulp Pap. Can. 1993, 94 (11). Bristol, E. H. On a Measure of Interaction for Multivariable Process Control. IEEE Trans. Autom. Control 1966, AC-11, 133-134. Chien, I. L.; Fruehauf, P. S. Consider IMC Tuning to Improve Controller Performance. Chem. Eng. Prog. 1990, 86, 33-41. Deshpande, P. B. Multivariable Process Control; Instrument Society of America: Research Triangle Park, NC, 1989. Economou, C. G.; Morari, M. Internal Model Control 6: Multiloop Design. Ind. Eng. Chem. Proc. Process Des. Dev. 1986, 25, 411419. Ender, D. B. Process Control Performance: Not as Good as You Think. Control Eng. 1993, 40, 180-190.

Franklin, G. F.; Powell, J. D.; Naeini, A. E. Feedback Control of Dynamics Systems; Addison-Wesley: Reading, MA, 1986. Gawthrop, P. J.; Nomikos, P. E. Automatic Tuning of Commercial PID Controllers for Single-loop and Multiloop Applications. IEEE Control Syst. Mag. 1990, 10, 34-42. Hang, C. C.; Åstro¨m, K. J.; Ho, W. K. Refinements of the ZieglerNichols Tuning Formula. IEE Proc.sPart D: Control Theory Appl. 1991, 138, 111-118. Hang, C. C.; Åstro¨m, K. J.; Ho W. K. Relay Auto-tuning in the Presence of Static Load Disturbance. Automatica 1993, 29, 563564. Hang, C. C.; Ho, W. K.; Cao, L. S. A Comparison of Two Design Methods for PID Controllers. ISA Trans. 1994, 33, 147-151. Ho, W. K.; Hang, C. C.; Cao, L. S. Tuning of PID Controllers Based on Gain and Phase Margins Specifications. Automatica 1995, 31, 497-502. Isermann, R.; Lachmann, K. H.; Matko, D. Adaptive Control Systems; Prentice Hall: New York, 1992. Luyben, W. L. Simple Method for Tuning SISO Controllers in Multivariable Systems. Ind. Eng. Chem. Process Des. Dev. 1986, 25, 654-660. Maciejowski, J. M. Multivariable Feedback Design; AddisonWesley: Reading, MA, 1989. McAvoy, T. J. Interaction Analysis: Principles and Applications; Instrument Society of America: Research Triangle Park, NC, 1983. Rosenbrock, H. H. State-Space and Multivariable Theory; Nelson: London, 1970. Rosenbrock, H. H. Computer-Aided Control System Design; Academic Press: London, 1974. Shinskey, F. G. Process Control Systems; McGraw-Hill: New York, 1979. Shinskey, F. G. Controlling Multivariable Processes; Instrument Society of America: Research Triangle Park, NC, 1981. Wood, R. K.; Berry, M. W. Terminal Composition Control of a Binary Distillation Column. Chem. Eng. Sci. 1973, 28, 1707. Yamamoto, S.; Hashimoto, I. Present Status And Future Needs: The View From Japanese Industry. In Chemical Process ControlsCPCIV: Proceedings of the Fourth International Conference on Chemical Process Control; Arkun, Y., Ray, W. H., Eds.; AIChE: New York, 1991. Ziegler, J. G.; Nichols, N. B. Optimum Settings for Automatic Controllers. Trans. ASME 1942, 64, 759-768.

Received for review November 18, 1996 Revised manuscript received February 18, 1997 Accepted February 20, 1997X IE960732T

X Abstract published in Advance ACS Abstracts, April 15, 1997.