Result of PID parameters and PID-PSO.
In this chapter, we deal with the problem of controlling Takagi-Sugeno (TS) fuzzy model by PID controllers using the particle swarm optimization (PSO). Therefore, a new algorithm is proposed. This algorithm relies on the use of a new objective function taking into account both the performance indices and the error signal. The advantages of this approach are discussed through simulations on a numerical example.
- nonlinear system
- TS fuzzy model
- self-tuning of PID controller
1. T-S fuzzy model
The theory of modeling based on multiple models has evolved greatly. Indeed, several techniques have been developed in the literature. The common feature of all these modeling techniques is the decomposition of the dynamic behavior of the system into a number of operating zones. Each zone is characterized by a local linear model. Fuzzy logic based on the use of linguistic rules, heuristic strategies and the operator’s know-how. Subsequently, it has undergone a major evolution mainly in Japan where it has been applied in several industrial applications. This type of model proposed by Takagi and Sugeno (1985) makes it possible to express a nonlinear system in several locally linear subsystems. The validity of each local model is defined by a weighting function with bounded support.
The TS model is built on a set of rules of type:
: “IF premises THEN consequence”
We consider a class of nonlinear systems defined by:
with the regressor vector is:
where represents the discrete time, and denote, respectively, the number of delayed output and the number of delayed input. The function is approximated by a TS fuzzy model which is charities by consequent rules that are local linear function of the input variables . The fuzzy rules of the TS model take the following general form:
where denotes the IF-THEN rule, is the number of rules, is the fuzzy subset, is the system input variable, is the system output, is the parameter vector of the corresponding local linear model. Let is the normalized membership function of the inferred fuzzy set , where . The final output is calculated as the average of the outputs corresponding to the rules , weighted by the normalized degree of completion (membership), according to the following expression:
The membership values have to satisfy the following conditions:
Once the parameters of the premises are fixed, the parameters of the consequent for each rule can be obtained using the recursive weighted least squares technique, using the values of the membership degrees of the fuzzy partition matrix of the classification process as weights :
The steps of the WRLS method are summarized in the following algorithm:
Initialize: and .
with and .
2. PID control by pole placement
This section is intended to model the digital PID controller in a new form RST. The control structure RST is the establishment of three polynomials , and . According to the first section, the local linear systems can be represented by:
Indeed, the vector takes the following form: . This form is heard when determining PID controller parameters by the method of poles placement. Figure 1 shows the standard form of RST controller.
In this chapter, we consider only two branches and , as shown in Figure 2, that is to say:
The transfer function in a closed loop is given by:
For a characteristic polynomial , the poles of the closed loop transfer function are imposed to arrive at the performances required by the follow-up of the specifications.
This problem boils down to solving the following equation:
From the after Scheme 4, the equation of regulator is written by:
To simplify Eq. (17), we substitute:
from which we obtain the following standard form:
The parameters of the digital PID regulator (, , and ) are chosen according to the desired poles defined by the polynomial .
The characteristic polynomial can be in the following form:
The values of and are chosen from the specifications imposed by the specifications (rise time, damping, overshoot, etc.) defined in general by comparing the behavior of the process to that of continuous system of second order.
where is a damping coefficient and is a pulsation. We wrote:
By identification, we find:
The control law is:
The structure of the corrector is the standard structure discretized by the approximation upper rectangles, and to find the values of the PID parameters will take the following expression:
3. PID controller based on PSO
3.1. PSO algorithm
Particle swarm optimization (PSO) is a stochastic technique based on collective intelligence, inspired by nature. It was developed by Kennedy and Eberhart . The PSO algorithm is inspired by collective behavior in certain social animals such as fish and migratory birds. This algorithm shares many similarities with evolutionary computational techniques such as genetic algorithms. Indeed, the latter are initialized with random solutions and search for optimums by updating generations involved. However, the PSO has no evolutionary operator such as the crossing and the mutation in the image of genetic algorithms.
In the PSO, each individual of the population is called particle, while the population is known as swarm. It should be noted that a particle can benefit from the movements of other particles in the same population to adjust its position and velocity during the optimization process. Each individual uses local information to which he can access the movement of his nearest neighbors to decide his own move. Very simple rules like “staying close to other people,” “going in the same direction” and “going at the same speed” are enough to maintain the cohesion of the whole group. At each displacement, the performance of each particle is measured by its position and velocity by minimizing a performance function called fitness .
The PSO’s basic algorithm works on a population called a swarm of possible solutions, which are called particles. These particles are placed randomly in the search space of the objective function. At each iteration, the particles move, taking into account their best position (selfish displacement) but also the best position of its vicinity. In fact, the new speed is calculated from the following formula :
In this equality,
where is the maximum of iteration in evolution process, and are the minimum and maximum values of , respectively, and is the current value of iteration. The position of the particle can then be determined by the speed that we have just calculated:
We generate and at the beginning of our algorithm. The PSO algorithm stops if one of these convergence criteria is reached:
the maximum number of iterations is reached;
the speed variation tends to zero; and
the fitness function is satisfied.
3.2. Tuning of PID using PSO optimization
The PSO optimization module complete the self-tuning of PID parameters with a microprocessor that achieves the optimum of PID parameters. These parameters are used to retune the PID controller in PID controller module. To seek the optimum parameters and
In most cases, PID controller work with an error signal () that is calculated from the process variable () and setpoint (). The error represents the deviation of the process variable from the setpoint. Then, the error signal is described as:
A PID controller optimized with PSO algorithm was developed for a TS Fuzzy system. It was also called the PSO-PID controller. PSO algorithm is mainly utilized to determine three optimal PID gains.
Adjusting the parameters of a PID controller can be considered as an optimization problem where it is a matter of finding the optimal solution of the gains of the controller in a predefined search space in order to allow the system to have certain desired performances. In this context, the PSO algorithm can be applied to find the optimal combination of the proportional, integral and derivative gains of the PID controller. During the application of the PSO, the initial population will be created randomly with Np individuals containing three decision variables: , and . To evaluate the individuals, we inject these gains into the PID controller and measure the parameters of the corresponding system output using the parameters of the TS model. The choice of the cost function is determined by the objective to be achieved. These objectives are determined by the performance defined in the specifications. Typically, this is static error, rise time, stabilization time and maximum allowed exceedance.
In the literature, we can find a multitude of performance indices. Most of these indices are based on the optimization error. The integrated square error (ISE) is given by:
Another fitness function is integrated time weight square error (ITSE), which is given as follows:
It seems simpler, yet it is hard to get the ideal time response too. Another widely used fitness function is:
where and represent, respectively, the system error and the output of controller, the utilization of this second item is to limited energy (Figure 3).
Since, more than the error signal, the performance indices in the time domain are also the overshoot (), steady-state error () the settling time () and the rise time (). The performance criteria must include all these performances. Therefore, we proposed a new objective function and it is described by the following equation:
The framework of online parameter self-tuning for nonlinear system based on TS Fuzzy model is depicted in Figure 3.
4. Simulation results
This section presents a simulation example to show an application of the proposed control algorithm and its satisfactory performance.
The nonlinear system is characterized by this equation :
with ; ; ; ; and . Here, is the output and is the input which is uniformly bounded in the region .
We choose as inputs variables, and the number of fuzzy rules is four. The setup applied in this work was the following: the population size was 20, the stopping criterion was 30 generations, , and .
We simulated two experimental cases. In case 1, the simulation result of the control pole placement for the nonlinear system is shown in Figure 4.
It can be seen from Figure 4, we note that the output of command has an important overshooting. In case 2, the PSO algorithm is adding to PID control. Figure 5 shows simulation results of the output signal of the control system.
We make a comparative study of PID control by pole placement method and the optimization algorithm of PSO (Table 1).
|Pole placement method||Optimization of PSO|
We note though, the advantage of optimizing the parameters of PID controller by PSO compared with the method of pole placement quality control, we observed that the overshoot decreases and the algorithm converges in minimum time.
We studied the PID control of a nonlinear system of Takagi-Sugeno for a square input signal using pole placement technique. With this method, we obtain results with an important overshooting. To solve this problem, we have compiled the PID control algorithm with PSO optimization algorithm that it has given good results.
Lagrat I, Ouakka H, Boumhidi I. Adaptive control of a class of nonlinear systems based on Takagi-Sugeno fuzzy model. In: Information and Communication Technologies International Symposium (ICTIS’07); Fez, Morocco. 2007. pp. 3-5
Kung CC, Su JY. Affine Takagi-Sugeno fuzzy modelling algorithm by fuzzy cregression models clustering with a novel cluster validity criterion. IET Control Theory Application. 2007; 1(5):1255-1265
Kennedy J, Eberhart RC. Particle swarm optimization. In: Proceedings of IEEE International Conference on Neural Networks; Perth, Australia. 1995. pp. 1942-1948
Clerc M, Kennedy J. The particle swarm: Explosion, stability, and convergence in multi-dimension complex space. IEEE Transactions on Evolutionary Computation. 2002; 16(1):58-73
Aggarwal V, Mao M, O’Reilly U-M. A self-tuning analog proportional-integral-derivative (PID) controller. In: Adaptive Hardware and Systems. 2006. pp. 12-19
Gomm JB, Yu DL, Williams D. A new model structure selection method for non-linear systems in neural modeling. International Conference in Control IEEE Transaction. 1996; 4(27):752-757