APP下载

Tuning Method of PID Controller Parameter Based on Immune Principle

2013-06-02BIBo

机床与液压 2013年18期

BI Bo

International School,Chongqing Jiaotong University,Chongqing 400074,China

1.Introduction

With the development of modern technology,a lot of advanced control algorithms have been proposed.However,up to now the most common method of practical applications is still the conventional PID control algorithm in the process industrial control.Owing to the complexity of production field situation,if it is unsuitable in control parameter tuning,then it is a certainty to result in poor control effect produced by controller,and even it might lead to collapse of the system[1-2].In view of that the control parameter tuning is directly related to the control quality of control system,the tuning of controller parameters is the core research content of control system design as before[3-4].Inspired by biological immune system,this paper proposed a sort of PID control parameter tuning method based on the immune principle,and by means of the tuned control parameter it can construct the PID controller so as to actualize the optimizing control for controlled object.

2.Conformation of objective function

The closed feedback control system is shown as in Fig.1.In which,Gp(S)is the controlled object model,Gc(S)is the controller,ris the set value input,eis the error signal,uis the controller output,andyis the system output.

Fig.1 Closed feedback control system

The symbolic technical specifications of measuring the control system quality are accuracy,rapidity and stability.The accuracy reflects the steady control precision of system,and the rapidity shows the dynamic response characteristic of system.The stability is inherent characteristics of system,and it is the prerequisite to run the control system.In order to obtain the excellent control quality,it should make the coordination of the relationship among technical specifications in the control process so as to ensure the optimization of overall performance of system.Therefore,the technical specifications,such as controlled variable,error and risetime and so on,should be decided under a certain constraint conditions,and the optimal control parameter is that the controller parameter suppose satisfy a certain constraint conditions.In the process of controller optimization design,there are some puzzles,i.e.,how to select the performance index,and how to choose the optimization method.In terms of performance index,the shorter the risetime,the better the system quality is,and the faster the system response is,and the rapidity shows the dynamic response characteristic of system.If it seeks only the better dynamic characteristic then the obtained control parameter is very possible to make the control signal be too large.In the actual application,it probably results in system being unstable due to the inherent characteristics of the saturated system.In order to obtain better control effect,the constraint conditions must be the control variable,error and risetime.In the control process based on immune principle,the fitness function is related to the objective function,after determining the objective function,it can be as the fitness function to make the optimized parameters.The optimal control parameter is that under satisfying precondition of constraint condition it makesf(x)be as the maximum,xis the parameter of corresponding controller.

In order to obtain satisfactory dynamic characteristics of transient process,it adopts the integral of time-weighted absolute error performance index as the least objective function of parameter selection.To prevent the control energy too large,it introduces a quadratic term of control input in the objective function.The optimal index of parameter selection is chose as follows.

Where,e(t)is the system error,u(t)is the controller output,tuis the rise time,andw1,w2,w3is the weight.In order to avoid to the phenomena of system overshoot,the punitive function is adopted.Namely,once the overshoot is produced,the overshoot would be as a term of optimal index.And at this time,the optimal index would become as follows.

Where,w1,w2,w3,w4are the weighting factors,respectively,andw4>>w1.

3.Method of parameter tuning

The method of controller parameter tuning is similar with the body immune system,and the corresponding relationship between the proposed method and body immune system is shown as in Tab.1.

Ta b.1 Comparisons between immune and proposed parameter tuning method

In the candidate solutions produced by random,it selects the superiority antibody by means of affinity computation of antigen and antibody.In the clone process,they retain the protogene and it makes the mutation for them,and lots of new antibodies are produced.Then,it makes reappraise for new antibody,and the newly produced antibody updates ceaselessly the antibody set.The update mechanism of antibody is that the newly produced antibody which owns higher affinity eliminates the lower affinity antibody in the antibody set.The antibody in the antibody set ranks according to the affinity ascending order.Through the specified evolutionary generation,it extracts the optimal antibody,and thereby the optimal resolution is obtained.As shown in Tab.1,the optimal resolution of problem is abstracted as antigen,the feasible resolution of problem is abstracted as antibody,and an antibody represents a candidate solution.Therefore,the antigen means the optimized objective function.The antibody means the candidate resolution of objective function,and in the real coding,the antibody usually is a vectorX=(X1,X2,…,Xn).Therefore,each antibody represents a point in n-dim space.The affinity of antigen-antibody is a value after the antibody is substituted into the antigen to be computed.

3.1.Clone selection algorithm

In the body immune system,if the antigen invades,then the immune system would produce lots of antibody to match the antigen,and the antibody concentration that the affinity is large to the antigen would increase so as to be propitious to eliminate the antigen.When the antigen is withered away the production of the antibody would be inhibited.At the same time,the concentration of antibody would be reduced,and the immune system keeps the immune balance all the time.In the antibody set,the superiority antibody that the affinity is large to the antigen is activated,and makes lots of clone so as to further eliminate the antigen.The code of clone selection process is as follows:

The new produced cell through clone selection process is merged into the antibody set,and the concentration of antibody is increased.It shows that the number of approximate resolution is also increased.But if the antibody concentration is overtopped then it is difficult to keep the antibody diversity,and therefore the antibody with better evolutionary potential would be missed so as to fall into the local optimal.The number of memory cell clone in the clonal selection process must be limited,and the expression of the relationship is shown as below.

Where,fnumis the total number of clones of memory cell,theith term represents the number ofith cell,β is a preset parameter factor,θ is the number of superiority cell.

It can be seen from the above expression that the larger the cell affinity is,the more the clone number is,and vise versa.In order to prevent falling into the local optimal,a certain amount of the newly produced antibody produced by random must be introduced in every generation of the evolution process.The antibody cell is dynamically updated during evolution,and each antibody cell is the optimal antibody selected from the current antibody and the new antibody clone.Thereby,it can achieve the dynamic update of antibody cell set,and keep the antibody scale invariant.

3.2.Mutation selection algorithm

The object of mutation is to make the antibody coding of filial generation change so as to get better resolution than the parent generation obtained.Due to the antibody in algorithm adopting the real number coding,the mode of Gauss mutation is adopted,but the mutation does not act on the initial population.In order to focus search around the high affinity antibody and keep the antibody diversity,the paper introduces a sort of adaptive mutation operator,namely the individual component acted by a mutation operator isxi=|xi+Nmi*N(0,1)*xi|,where,N(0,1)is a random number which obeys standard Gauss distribution.The symbol|·|represents calculating the absolute value,andNmiis the mutation rate of corresponding antibody and it is determined as follows:

Obviously,the antibody mutation rate is inversely proportional to the affinity,and the higher the affinity is,the less the mutation rate is.The antibody adaptively adjusts the mutation step according to the affinity in each iteration process,and it makes the focused search around high affinity antibody so as to enhance the convergence rate,and at the same time it keeps the diversity of population.ρ is a mutation coefficient used for adjusting the mutation intensity,and it is related to the size of the search space and population size.

4.Simulation of PID parameter tuning

The transfer function of PID controller algorithm is shown as PID=Kp(1+1/TiS+TdS)=Kp+ki/S+kdS,andki=Kp/Ti,kd=KpTd.Assume the controlled model isGp(S)=e-5s/(1+s)2,and the evolutionary generation is assumed as 100,the population size is 30,the value range of parameterKpis[0,10],the value range ofkiandkdis[0,5],and it takesw1=0.999,w2=0.001,w4=100,w3=2.0,θ=20,β =2.In every generation of evolution,it increases five pieces of antibody randomly so as to strengthen the ability of global optimization.

Here it takes the following tuning methods to make the simulation experiment for the same controlled objectGp(S),and the tuning methods are Magnitude Optimum Multiple Integrations(MOMI),the Ziegler Nichols(ZN),Chien-Hrones-Reswick(CHR),Refined Ziegler Nichols(RZN),Genetic Programming with ZN(GP)and the proposed method,respectively.The control parameter in the experiment comes from reference[5].The tuning parameter is shown as in Tab.2,and Fig.2 is the experimental results of closed loop unit step response for transfer functionGp(S).From the Fig.2,it can be seen that the proposed method,GP and MOMI can obtain better control effect,but the proposed immune principle based method can get less overshoot.

Tab.2 PID control parameter for Gp(s)

Fig.2 Unit step response for controlled object Gp(s)

Based on the above analysis,it can be seen that the proposed method based on immune principle can achieve better control effect than other five methods.Therefore,it is better than other methods.The dominant reason is that the clone mechanism(according to the affinity being high and low)can effectively guide the searching to be focused on better solutions in the neighborhood.The larger the affinity is,the more the number of clone antibody is,and it is more propitious to find the optimal solution.It adopts adaptive mutation strategy,and makes around the antibody with high affinity focus on search,and maintain the diversity of population,therefore it further enhanced the ability to search for the optimal solution.The new antibody joined by random can effectively avoid the algorithm to fall into the local optimal so as to obtain the global optimal solution.

5.Conclusions

Based on the clonal selection algorithm in immune principle,this paper explored the control parameter tuning of PID controller.In the paper,the definition of antigen,antibody and affinity has been given,and also the tuning process of control parameter tuning has been thoroughly discussed.The comparative study among different six sorts of tuning method for simulation of 2-order process with big lag has been confirmed that the proposed method owns better effect of control parameter tuning.The simulation experiment and comparative analysis demonstrates that the proposed parameter tuning method based on the immune principle is effective and reasonable,and it can make PID control system obtain better control performance.

[1]WANG Wei,ZHANG Jingtao,CHAI Tianyou.A SUR-VEY OF ADVANCED PID PARAMETER TUNING METHODS[J].ACTA AUTOMAT ICA SINICA,2000,26(3):343-355.

[2]JIANG Yaping,LI Tao,LIANG Gang,et al.An Immune-based Model for Solving TSP[J].Computer Engineering,2006,32(15):165-167.

[3]de Castro L N,Timmis J I.Artificial immune systems as a novel soft computing paradigm[J].SOFT COMPUTING,2003,7,:526-544.

[4]de Almeida G M,e Silva V V R,.Nepomuceno E G,et al.Application of Genetic Programming for Fine Tuning PID Controller Parameters Designed Through Ziegler-Nichols Technique[J].LECTURE NOTES IN COMPUTER SCIENCE,2005,3612:313.