Process Identification Using Relay Shifting Method for Auto Tuning of PID Controller

The paper describes the use of a recently introduced relay shifting method for estimation parameters of a second order time delayed model. The aim is to obtain a process model for setting PID control parameters. For this purpose, an algorithm is designed for estimation of model parameters from two frequency response points obtained from a single relay feedback test without any assumptions about a model transfer function. The relay shifting method is slightly modified here by using an integrator to receive the frequency response points in positions more suitable for model fitting. This modification enables to better estimate the static gain even under constant load disturbance. The proposed solution is demonstrated on simulated examples.


Introduction
If we want to control a process, we need to determine its properties and then we can design its control. The Proportional-Integral-Derivative (PID) controllers are the most commonly used controllers in process industries. If done manually, the tuning procedure of the PID controller may become very tedious and time consuming. There are many methods for the PID controller auto tuning. The method using the relay feedback control is one of the most commonly used methods for tuning PID controllers. Åstrom and Hägglund were the first ones who proposed this method [1]. They proposed a relay feedback experiment where a process is under a relay control for finding the critical gain and the critical frequency of the closed loop process. This relay feedback approach enables to calculate the same parameters like the Ziegler-Nichols method [2] but without a priory information about the process, in a shorter time and in a controlled manner. The scheme of the relay feedback experiment is depicted in Fig. 1, where y denotes the controlled variable, w the desired variable, u the manipulated variable, d the disturbance variable and e the control error. The Åstrom-Hägglund method is very simple and practical one for tuning PID controllers. Therefore many methods based on the relay feedback experiment have been developed up to now. These methods can be categorized into three groups for single-input-singleoutput (SISO) systems: Describing function method, curve fitting approach and frequency response estimation for model fitting, see [3,4]. There are several overview publications dedicated to the relay feedback identification, e.g. [3][4][5][6][7]. Most of these methods assume linear low-order models plus time delay which can be effectively used for process identification. The presented method belongs to the frequency response methods where only a few of the published relay methods are able to obtain all model parameters using one relay feedback test without a prior information. Moreover, some relay identification methods do not consider problems caused by the influence from measurement noise, load disturbances and nonzero initial process conditions that are in practical applications often encountered.

Specifications
Consider a stable process which can be described by a time invariant linear dynamic model around its operating point. The process variable y should be kept near the operating point by a controller. The goal is to determine the process model from information obtained from a single relay feedback experiment. This model should be suitable for tuning PID controllers.

Shifting method
The relay shifting method [8] uses an asymmetrical relay with a hysteresis (see Fig. 2 3) and that the process can be described by a linear time invariant SISO model. The method is based on finding two points G(jω 1 ), G(jω 2 ) of the process frequency response G(jω) related to the fundamental frequency ω 1 and the 2 nd harmonic ω 2 of the input/output signals where The integrals are computed numerically. The relationship (4) for determining the point G(jω 2 ) corresponds to the use of the filter with the frequency transfer function The filter filters out all odd harmonic frequencies including the fundamental harmonic frequency ω 1 and amplifies twice the even harmonic frequencies including ω 2 . The block diagram of this filter is shown in Fig. 4 where The newly acquired point G(jω 2 ) determined by the shifting method allows the estimation of two other model parameters from a single relay feedback test. The position of the points G(jω 1 ), G(jω 2 ) in the Nyquist frequency characteristic is shown in Fig. 5. Fig. 5 is the static gain K of a proportional system. The value K is often assumed to be known a priory, e.g. [9] or more relay tests are necessary, e.g. [10]. The static gain can be also determined by the following formula if the asymmetrical relay is used and it is known exactly the working point (u 0 ,y 0 ), see [11].
The three points G(0), G(jω 1 ) and G(jω 2 ) can be used for fitting the model, see [12]. These values were determined without any assumptions about a model structure which is the great advantage of this approach.

Modifications of the shifting method
The position of the point G(jω 2 ) is not very convenient for model fitting. To receive a better position of the point G(jω 2 ) we can slightly modify the block diagram for the relay feedback test slightly by the transport delay D (see [13]), or alternatively by the additional integrator, see G(jω 1 ) This proportional model is very universal and can be used for description of oscillatory or aperiodic systems. Model (10) has four parameters and these ones (including the static gain K) can be estimated from the points G(jω 1 ), G(jω 2 ).

SOTD model fitting
The parameters K, a 2 , a 1 and τ u of model (10) can be determined from knowledge of the values ω 1 , ω 2 , G(jω 1 ) and G(jω 2 ) obtained by the shifting method from a single relay feedback test. For this purpose we can use the following criterion The value of the criterion Kr depends on the values of K, a 2 , a 1 and τ. For more compact notation we introduce the vector 2 1 [ ] T K a a θ τ = (12) containing the unknown values of the parameters K, a 2 , a 1 and τ of the SOTD model (10). For a stable system, the value of the vector θ that minimises the criterion (11) can be determined by ˆa rg min ( ) where D={ (K, a 2 , a 1 , τ): K>0, a 2 >0, a 1 >0, τÎá0,τ m ñ} and τ m see Fig. 3. Denote the real and imaginary part of the complex values G(jω 1 ) and G(jω 2 ) ( ) , for 1, 2 then ( )

Examples
The relay shifting method is demonstrated on a lag dominated process with the transfer function This aperiodic proportional process was taken from [14]. The relay feedback experiment was realised with integrator (see Fig. 6b) and the asymmetrical relay was with a hysteresis having the following parameters (see Fig. 2 (18) The process model M 1 was assumed in form (10). The time courses of the manipulated variable u and the controlled variable y are shown in Fig. 8. The following values were obtained from the time courses of the relay output u and the process output y.
The Nyquist frequency characteristic of the process (14) and its model (21) are shown in Fig. 9. The points G(jω 1 ) and G(jω 2 ) are also highlighted in the figure. The unit step responses h P , h M of the proces P 1 (s) and its model M 1 (s) are depicted in Fig 10.   Fig. 9. The Nyquist frequency characteristics for the frequency transfer functions P 1 (jω) and M 1 (jω). The relay shifting method was also successfully applied for two aperiodic processes taken from [14] (balanced and delay dominated) and one oscillatory process. The transfer functions of these processes and their SOTD models are described in Table 1.

Conclusions
The introduced relay shifting method was successfully tested on simulated examples and on the laboratory apparatus called "Air Aggregate". Matlab/Simulink programming environment and Mosaic -integrated development package for PLC Tecomat were used for the testing. PLC Tecomat Foxtrot was used for relay control of air flow and temperature on the laboratory apparatus "Air Aggregate".