2016 International Conference on Artificial Intelligence and Computer Science (AICS 2016) ISBN: 978-1-60595-411-0

**Tuning of PID Controller Based on Phase Margin for Stable **

**Processes Via IMC Principles **

### Qi-bing JIN and Zhao-jian TANG

*Institute of Automation, Beijing University of Chemical Technology, China Email: 13161631097@163.com

*_{Corresponding author }

**Keywords:** IMC-PID, Phase margin, Frequency domain.

**Abstract. A novel IMC (internal model control) PID tuning method is proposed for stable processes **
with time delay in the frequency domain. In the paper, the IMC controller is originally transformed
into a classical feedback PID controller without approximating the time delay. The phase margin is
used for an analytical approach of selecting controller parameter which is directly related to the
dynamic performance and robustness of the system in IMC. The resulting analytical IMC-PID
controller achieves almost the same control effect as IMC controller.

**Introduction **

Proportional-Integral-Derivative (PID) controllers are still widely used in industrial systems despite the significant developments in control theory and technology [1] since its easy maintenance and operation for a wide range of operating conditions. Extensive methods for the PID tuning had been explored in [2, 3]. However, it has been noticed that the conventional PID controller may not perform well for the complex processes, such as time-delay systems. Recently, the PID tuning rule based on internal model control (IMC) principle has been widely recognized and applied since it possesses the good quality of IMC controller. And the main advantage of IMC lies in the fact that its construct contains only one tuning parameter, namely the filter time constant, which is directly related to the dynamical performance and robustness of a control system [4]. Kaya [5] designed IMC controller by minimizing a weighted function of Integral square error (ISE). Besides, the robustness of control system is very important because the models are usually imprecise and the parameters of all physical systems may vary with the operating conditions and time. Hence, the robustness against parameters perturbation of the system is an important concern in process control [6, 7]. Phase margin is reflection of system robustness. Many scholars use this criterion to design the controller [8]. The desired margins were employed to determine the controller parameter in classic feedback control structure [9, 10, 11] and IMC strategy [12, 13].

**Proposed IMC-PID Method **

Figure 1. The IMC control strategy.

*K(s)*

*d*

*Gp(s)*

*-r* + *y*

Figure 2. equivalent Single-loop PID control system.

The first step of designing procedure for IMC controller shown in Fig 1 is to factorize the process model as:

G s G s G s (1)

Where G s and G s are the portion of the model inverted and not inverted, respectively. Then, the initial equivalent IMC controller in Fig 1 and equivalent PID in Fig 2 can be expressed as:

Q s _{λ} (2)

K s (3)

According to the definition of the phase margin, we can obtain:

λ 1

w L arctanλ ° γ_{°} π (4)

MATLAB is employed to obtain a series of λ/L with the change of phase margin γ. And then we can get the clear analytical relationship between λ/L and γ showing in Fig 3 by using curve fitting technique:

Figure 3. the relationship between λ/L and phase margin γ.

λ

0.0005939γ 0.1162γ 7.683γ 170.9 (5)

Many studies suggest that γ 65°will usually be a good choice. In other words, we will use λ⁄L 0.6257 , w 0.6288 L⁄ throughout the paper.

The next step is to cast the K(s) into practical PID realization. First of all, we assume that the model matches process perfectly and there is no disturbance in system. The in K s is already a PI or PID controller, so the key point is to transform into a filter H(x) shown in Eq (8). Only in this way can the IMC controller in Eq (3) realize perfectly. Bring s jw, x wL and

0.6257 into the Eq (6), the Eq (7) is obtained.

K s _{λ} (6)

F x _{.} (7)

H x a (8)

The central idea of transformation process is in a frequency perspective: the PID controller is designed by achieving the same magnitude and angle as the IMC controller on the two points (the magnitude cross-over and the phase cross-over frequency of the system). Under the condition of γ

65°and the corresponding gain margin K 2.701, the equation group (9) can be solved by MATLAB.

F x ≡ H x

F x ≡ H x (9)

In Eq (9), x 0.6288x 2.1992. In this paper PID form is given in Eq (10). Therefore, the analytical PID parameters are displayed in Table 1.

K s K 1 K K s (10)

Table 1. the parameters of IMC-PID controller.

**G(s) **

.

- **0.0202L ** **0.3934L **

.

**0.0202L ** **0.3934L **

**Robustness Analysis of the PID Controller **

The robustness analysis of the proposed controller is done using the equivalent classic feedback control system shown in Fig 2. The parameters of PID controller are displayed in Table 1. Here, the paper uses maximum sensitivity which is the index of robustness to prove the robustness of system. The value of Ms (1.2-2.0 [7]) is the reciprocal of the shortest distance from the Nyquist curve of the open loop transfer function to the critical point (-1, j0). So the distance function d can be expressed as following:

d r 1 k (11)

K s G s . _{λ} e (12)

r . . . . .

. . . (13)
k . . _{.} _{.}. ._{.} . (14)

Owing to that the nyquist curve is symmetric, so it only needs to consider the domain x 0. Although seems very complex, the function d only related to the size of the x. The minimum value of

d 0.6205 is obtained through the derivative of x. Therefore, the maximum sensitivity is Ms 1.6115.

When there is uncertainty in processes, which can be given by

G s G s 1 ∆ (15)

According to the standard M ∆ structure for robustness analysis, the perturbed closed-loop structure with the process uncertainty holds robust stability if and only if [14]

‖T‖∞ _{‖∆‖}

∞ (16)

In Fig 2, the complementary sensitivity T of the system is

T jw (17)

Either the process is FOPDT or SOPDT, the complementary sensitivity of system shown as following by inserting the Eq (10) into the Eq (17):

T jw _{.} . . _{.} _{.} (18)

The maximum value of ‖T jw ‖∞ is 1 when the wL 0.

When it comes to the IMC structure, the T can be obtained as:

T jw _{.} (19)

The maximum value of ‖T jw ‖∞ is 1 when the wL 0. It is clearly that the proposed PID

method achieves the same robustness degree as the IMC strategy.

**Simulation Results **

Table 2. process and model in examples.

**Process ** **Model **

**Example1** 1

s 1e .

1

s 1e .

**Example2** 1

s 1 0.5s 1 e

1

0.5s 1.5s 1e

**Example3** 1

s 1 s 2 s 3 e

0.1667

[image:5.612.96.521.113.652.2]0.6494s 1.6304s 1e .

Table 3. the controller parameters in examples.

**PID**

**Example1** 0.3129 1.2288 1 1_{s} _{0.0101s}0.1967s _{1}1

**Example2 ** 0.6257 0.9216 1 0.6671

s 0.333s

0.3943s 1

0.0202s 1

**Example3** 6.384 0.589 1 0.61331

s 0.3983s

4.0138s 1

0.2061s 1

Figure 4. the simulation of example1.

Figure 5. the simulation of example 2.

Figure 6. the simulation of example 3.

Table 4 control effect of each method.

**Method ** **Phase margin ** **Ms ** **ISE **

**Example1**

Proposed PID 66.2°(1.27) 1.6253 0.6421 Proposed IMC 65°(1.26) 1.6171 0.6566

Kaya I 60.2°(1.04) 1.6258 0.8288

**Example2**

Proposed PID 66.2°(0.633) 1.6253 1.287 Proposed IMC 65°(0.629) 1.6171 1.1314

Kaya I 60.2°(0.521) 1.6258 1.659

**Example3**

Proposed PID 66.3°(0.062) 1.6251 13.1 Proposed IMC 65°(0.0616) 1.6169 13.4

Kaya I 60.2°(0.051) 1.6256 16.91

**Conclusions **

The proposal IMC-PID controller maintains the same performance and robustness as IMC controller, which is clearly shown in table 4 and figures. In table 4, the desired control effect has been achieved by proposed PID controller.The approximating method by Kaya I provides the slower response with some overshoot under the condition of the same robustness degree. It is well known that the performance and robustness are a pair of contradiction in the single-loop system. The Kaya’s approximating method is also able to provide good tracking performance but the corresponding response process will be very sluggish.

The paper puts forward the method to realize the perfect transformation between IMC and PID controller. The main advantage of the proposed method lies in that the PID both owns the equality of IMC and classic PID. According to the proposal PID form, one can determine the controller parameters as long as the models are known. The figures and Table 4 reveal that the proposed PID can achieve the same control effect as the IMC controller based on the same robustness degree. In other words, the proposal IMC-PID can be seen as a simple form of PID easy to implement.

**Acknowledgement **

This work is supported by the National Natural Science Foundation of China (61673004) and the Fundamental Research Funds for the Central Universities (Grant ZY1619).

**References **

[1] Panda R.C., Cheng-ching Yu and Hsiao-Ping Huang, PID tuning rules for SOPDT systems: Review and some new results. ISA transactions, (2004) 43, 283-295.

[2] Datta A., Ho M.T. and Bhattacharyya S.P., Structure and Synthesis of PID Controllers. Advances in Industrial Control, London (2000).

[3] Astrom K.J. and Hagglund T., PID controllers: Theory, Design and Tuning. Instrument Society of America Research Triangle Park Nc (1995).

[4] Rivera D.E., Morari M. and Skogestad S., Internal Model Control: 4. PID Controller Design. Industrial & Engineering Chemistry Process Design & Development, 25, 2163-2163 (1986).

[6] Wang Y.G. and Shao H.H., PID auto-tuner based on sensitivity specification. Chemical Engineering Research and Design, 78, 312-316 (2000).

[7] Zhao Z.C., Liu Z.Y. and Zhang J.G., IMC-PID tuning method based on sensitivity specification for process with time-delay. Journal of Central South University of Technology, 18, 1153-1160 (2011).

[8] Mikhalevich S.S., Sergey A. Baydali and Flavio Manenti, Development of a tunable method for PID controllers to achieve the desired phase margin. Journal of Process Control, 25, 28-34 (2015). [9] Weng K.H., Chang C.H. and Cao L.S., Tuning of PID controllers based on gain and phase margin specifications. Automatica, 31, 497–502 (1995).

[10] Wang Q.G., Fung H.W. and Zhang Y., PID tuning with exact gain and phase margins. ISA transactions, 38, 243-249 (1999).

[11] Nie Z.Y., Wang Q.G. and Wu M., Combined gain and phase margins. ISA transactions, 48, 428-433 (2009).

[12] Wang Q.G., Hang C.C. and Yang X.P., Single-loop controller design via IMC principles. Automatica, 37, 2041-2048 (2001).

[13] Kaya I., Tuning P.I. controllers for stable processes with specifications on gain and phase margins. ISA transactions, 43, 297-304 (2004).