0% found this document useful (0 votes)
50 views6 pages

Genetic Algorithm-Based Adaptive Tuning Method of PID Controllers

This document describes a genetic algorithm-based method for adaptively tuning PID controllers. The method takes desired specifications for the system response as input, such as rise time and overshoot. A genetic algorithm is then used to find the optimal PID parameters (KP, KI, KD) that satisfy the specifications. If a specification is met, a stricter target is set for the next iteration. This process continues until the specifications can no longer be fully satisfied, leading to a well-tuned PID controller design. The method is presented as an improvement over traditional root locus and Ziegler-Nichols tuning approaches.

Uploaded by

Mona Ghazal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
50 views6 pages

Genetic Algorithm-Based Adaptive Tuning Method of PID Controllers

This document describes a genetic algorithm-based method for adaptively tuning PID controllers. The method takes desired specifications for the system response as input, such as rise time and overshoot. A genetic algorithm is then used to find the optimal PID parameters (KP, KI, KD) that satisfy the specifications. If a specification is met, a stricter target is set for the next iteration. This process continues until the specifications can no longer be fully satisfied, leading to a well-tuned PID controller design. The method is presented as an improvement over traditional root locus and Ziegler-Nichols tuning approaches.

Uploaded by

Mona Ghazal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 6

See discussions, stats, and author profiles for this publication at: https://www.researchgate.

net/publication/271842666

Genetic algorithm-based adaptive tuning method of PID controllers

Conference Paper · January 2009

CITATIONS READS

0 112

4 authors, including:

Zaer Abo-Hammour Prof-Othman Alsmadi


University of Jordan University of Jordan
55 PUBLICATIONS   668 CITATIONS    45 PUBLICATIONS   320 CITATIONS   

SEE PROFILE SEE PROFILE

Hussam Khasawneh
University of Jordan
28 PUBLICATIONS   99 CITATIONS   

SEE PROFILE

Some of the authors of this publication are also working on these related projects:

Flexible Distribution of Energy and Storage Resources View project

Gentle Electromagnetic Pump for Fluids with Stress-Sensitive Microparticles View project

All content following this page was uploaded by Zaer Abo-Hammour on 05 March 2015.

The user has requested enhancement of the downloaded file.


INISTA 2009
International Symposium on INnovations in Intelligent SysTems and Applications, June 29-July 1, 2009, TRABZON, TURKEY

Genetic-Algorithm-Based Adaptive Tuning Method of PID


Controllers

Za'er S. Abo-Hammour, Othman M-K. Alsmadi, Mohammad S. Sarayreh,


Husam J. Khasawneh
Department of Mechatronics Engineering, University of Jordan, Amman, Jordan
Department of Electrical Engineering, University of Jordan, Amman, Jordan
Department of Computer Engineering,Mutah University, Karak, Jordan
Department of Mechatronics Engineering, University of Jordan, Amman, Jordan
[email protected], [email protected], [email protected]
[email protected]

Abstract PID controllers are becoming of more importance to


even appear in biological systems [4].
The use of genetic algorithm (GA) as a tuning Several modifications must be made in order to
technique for optimal PID controller design is obtain a practically useful PID controller. Parameter
presented in this paper. The desired values of the adjustment of PID controllers has been a challenging
system response specifications (rise time, settling problem considered in the field of control system
time, overshoot and peak time) are initially fed by design. Based on the desired specifications of the
the designer. The genetic algorithm is then used to user, the design process might be in time domain or
find the best PID parameters (KP, KI, KD) that satisfy in frequency domain. The time domain
the user demands. In the new technique, the obtained characteristics are generally the rise time, settling
values of the response parameters are always time, overshoot, peak time and steady state error,
compared with the desired specifications and once while the frequency domain characteristics are
any specification is satisfied, a new more strict generally the gain margin and the phase margin. In
specification value is generated. This adaptive order to achieve the desired specifications, a number
process is repeated throughout the evolution process of methods, referred to as tuning methods, have been
of the GA until the new updated values of the developed to achieve this objective [5,6]. However,
response specification are not totally satisfied. This which one gives the optimal solution is usually the
process may lead to a design with more desired main target of any designer trying to select any of
advantages. Simulation results show the efficiency these methods [7].
and superiority of the proposed scheme as compared Two tuning methods of PID controller are often
to the root locus method. considered: the Root locus tuning method and
Ziegler-Nichols (Z-N) tuning method. The Root
locus method is based on one-parameter-at-a-time
1. Introduction design process [5], which leads to weaker design
process when as compared to methods that optimize
In engineering systems, a PID controller is the the three parameters of the controller
most common way of using feedback at both the simultaneously. On the other hand, the (Z-N) tuning
industrial and the laboratory levels. The ability of method is a PID tuning method that is of
PID controllers to show their valuable importance in experimental nature in general. This method is used
most practical industrial process has led to their for third order plants where the increase in the
wide implementation in industrial applications. It proportional element leads to instability of the plant.
has been recorded that 90-95% of control systems In fact, these methods give an initial controller
can be controlled using PID controllers [1]. It has design that needs to be further tuned by trial and
also been stated that in process control applications, error process to produce a desired response [8].
more than 95% of the controllers are of PID type [2]. The limitations of the previously mentioned
As a matter of fact, based on a survey, 97% of methods urges the researchers to search for new
regulatory controllers utilize PID feedback in the more advantageous methods that can optimize the
refining, chemicals, pulp and paper industries [3]. PID controller parameters in a global nature.
Genetic Algorithms are one of the efficient tools for 2. Problem formulation
solving optimization problems [9]. They have arisen
from the desire to model a biological process for the The PID controller consists of three types of
purpose of designing autonomous learning and control actions: proportional action P, integral action
decision-making systems [10]. They are adaptive, I, and derivative action D). The input/output
general purpose generate and test search procedures, relationship of an ideal PID controller in frequency
optimization methods or learning mechanism based and time domains is given respectively by:
on Darwinian principle of biological evolution, that
is “the survival of the fittest” and the genetic KI
Gc ( s ) = K P + + KDs (1)
operators. Genetic algorithms are based on the s
triangle of genetic operations: selection de(t )
(reproduction), crossover (recombination) and ∫
u (t ) = K P e(t ) + K I e(t )dt + K D
dt
(2)
mutation. Although GA is a very simple technique,
it can solve complex system problems that other The desired system response that might include the
techniques might not have the ability to accomplish, rise time (Tr), peak time (Tp), maximum overshoot
because they can find the global near optimal (O.S.), and settling time (Ts) are given by the
solution in a very large solution space without designer. During the evolution process of the
becoming trapped at local minima [11,12]. GA's are genetic algorithm, the step response is obtained of
applied usually in situations where the number of the overall closed loop control system based on the
parameters to be optimized is large, or when other generated values for the controller parameters
classical optimization methods either fail (non- together with the plant dynamical model. The actual
differentiable problems) or cannot lead to values of the specifications are then compared with
satisfactory results (when stuck in local minima). the desired values. If any of the four specification
However, one of GA's major drawbacks is an parameters is achieved, then a new desired value is
inherent handicap of being slow to reach the optimal obtained using the following equation:
solution [13].
Based on the attractive features of genetic Desired new = 0.9 * Desired old (3)
algorithms, many researchers have used GAs to tune This strategy is applied on all of the four parameters
the PID controller parameters [14,15]. Their work ( Tr, Tp, OS,Ts). in this strategy, the stricter values
was motivated by the search for an optimal solution for the four parameters are obtained throughout the
of the PID control parameters based on certain evolution process which means that the best values
desired transient and steady state response of the specification will be obtained at the end of the
specifications. Generally, all time domain run. The new approach is illustrated by the block
specifications are to be minimized. This means that diagram shown in Figure 1. The optimal solution is
the rise time, settling time, overshoot, peak time and obtained when all the specifications are optimized
steady state error of the desired response should be and the fitness function approaches unity. As a
as minimal as possible. The minimization problem result, the PID controller design is formulated as a
is then converted to a maximization problem of the maximization problem of the fitness function. The
fitness function. Their efforts were based on one of fitness function evaluated in the conventional
two scenarios. In the first one, the user will specify genetic-algorithms is given as following:
desired specifications and once the genetic algorithm
obtain those specifications, the algorithm will be fitness= (w _ ts × ratio_ ts) + (w _ tr × ratio_ tr)
(4)
terminated. This scenario has the drawback that the + (w _ tp × ratio_ tp) + (w _ os × ratio_ os)
user might specify somehow lenient specifications
that can be achieved while there are still large where w _ ts ≡ weight of settling time, w _ tr ≡
possibilities of getting better results if the weight of rise time, w _ tp ≡ weight of peak
specifications were stricter than the given ones. In
time, w _ os ≡ weight of maximum overshoot. In
the second scenario, the user does not specify any
desired values for the specifications. The goal is to addition to that, the ratios are defined as:
minimize the response parameters without any desired _ ts desired _ tr
ratio _ ts = , ratio _ tr = ,
reference about his own priorities. This scheme has actual _ ts actual _ tr
the limitation of missing the desired specifications
where the designer priorities are not clearly defined.
desired _ tp desired _ os a mating pool devoted to the creation of new
ratio _ tp = , ratio _ os = . individuals for the next generation such that the
actual _ tp actual _ os
chance of a given individual to be selected to
Based on this, Equation (5) is to be satisfied: mate is proportional to its relative fitness. This
means that best individuals receive more copies
∑ {w _ ts + w _ tr + w _ tp + w _ os } = 1 (5) in subsequent generations so that their desirable
traits may be passed onto their offspring. This
step ensures that the overall quality of the
population increases from one generation to the
Desiredi : Tr, Tp, O.S., and Ts
next.
4. Crossover. Crossover provides the means by
Kp, Ki, and Kd obtained by the GA which valuable information is shared among the
population. It combines the features of two
parent individuals to form two children
Matlab simulations for a step input individuals that may have new patterns
compared to those of their parents and plays a
central role in GAs.
Actuali : Tr, Tp, O.S., and Ts 5. Mutation. Mutation is often introduced to
guard against premature convergence.
Generally, over a period of several generations,
Yes Desired i,new =
Desiredi ≥ Actuali the gene pool tends to become more and more
0.9 *Desired i,old
homogeneous. The purpose of mutation is to
No introduce occasional perturbations to the
parameters to maintain genetic diversity within
Fitness Function
the population.
6. Replacement. After generating the offspring’s
Figure 1. Fitness evaluation scheme population through the application of the
genetic operators to the parents’ population, the
3. Genetic algorithm parents’ population is totally replaced by the
offspring’s population. This is known as non-
GAs are based on principles inspired from the overlapping, generational, replacement. This
genetic and evolution mechanisms observed in completes the “life cycle” of the population.
natural systems. Their basic principle is the 7. Termination. The GA is terminated when some
maintenance of a population of solutions to the convergence criterion is met. Possible
problem that evolves in time. They are based on the convergence criteria are: the fitness of the best
triangle of genetic reproduction, evaluation and individual so far found exceeds a threshold
selection [6]. Genetic reproduction is performed by value, the maximum number of generations is
means of two basic genetic operators: crossover and reached, or the progress limit, the improvement
mutation. Evaluation is performed by means of the in the fitness value of the best member of the
fitness function that depends on the specific population over a specified number of
problem. Selection is the mechanism that selects generations is less than some predefined
parent individuals with probability proportional to threshold, is reached. After terminating the
their relative fitness. The genetic algorithm used in algorithm, the optimal solution of the problem is
this work consists of the following steps: the best individual so far found. The block
1. Initialization. An initial population comprising diagram of the genetic algorithm is given in
of Np individuals is randomly generated in this Figure 1.
phase. An additional operator was introduced to
2. Evaluation. The fitness, a nonnegative measure enhance the performance of the GA, the elitism
of quality used as a measure to reflect the operator. The preservation of the best solution or
degree of goodness of the individual, is solutions, elitism, and moving it to the next
calculated for each individual in the population generation is vital to the effectiveness of the GA [6].
as given in Equation 4. It is utilized to ensure that the fitness of the best
3. Selection. In the selection process, individuals candidate solution in the current population must be
are chosen from the current population to enter larger than or equal to that of the previous
population (i.e., a good solution found should not be weights used in the fitness function on the tuning
lost through some of the genetic operators). In other process will be covered in details to see its effect on
words, it guarantees that the best fitness in the the parameter values of the PID controller and the
population is a monotically non-decreasing function. response parameters.

4. Simulation and results 4.1. Example

The input data to the algorithm is divided into Consider the open loop transfer function is:
two parts; the genetic-algorithms related parameters s +1
and the plants related parameters. The genetic- G(s) =
algorithms related parameters include the population s + 10 s + 32 s 2 + 32 s
4 3

size, Np, the cross over probability, Pc, the mutation Results of the tuning process for the PID controller
probability, Pm, the weights of the fitness function, using the genetic algorithm and the root locus
the initialization method, the selection scheme, the techniques are shown in Table 1 where all weights
replacement method, and finally the termination used in the fitness function have the value of 0.25.
criterion. The plants related parameters include the Results show the superiority of the genetic
coefficients of both numerator and denominator of algorithms in tuning the PID controller over the root
the plant transfer function, the range of searching for locus method. After that, the effects of different
each parameter of controllers (KP, KI, and KD), and values of the weights of fitness function were
the desired values of every response parameter ( Tr, considered. In this process, emphasis is given to
Tp, OS, Ts). one response parameter (a value of 0.7), while the
The initial setting of the genetic-algorithm other three parameters are given less equal weight (a
related parameters are as follows: the population size value of 0.1 for each). This process is repeated four
is set 100 individuals. The crossover probability is times to take all the possibilities. The results are
kept at 0.7, the mutation probability is 0.01. The shown in Table 2 and Figure 2, where it is clear that
rank based selection strategy is used where the rank- for this plant, the weights changes of the settling
based ratio is set to 0.5. Generational replacement time, rise time, and peak time, have a minor impact
scheme is applied where the number of elite parents on the response parameters while the overshoot is
that are passed to the next generation equals one– seriously affected by the weight changes.
tenth of the population size. The searching range for
KP, KI, and KD parameters set to 0-500, 0-100, and
0-20 respectively with accuracy equal to 0.1. The
genetic-algorithm is stopped when one of the
following conditions is met. First, the improvement
in the fitness value of the best individual in the
population over 100 generations is less than 0.001.
Second, a maximum number of 1000 generations is
reached.
Different plants were investigated for the
purpose of tuning the PID controller. However, we
will present only one case, which will present the
overall conclusion of this new technique. Results of
the tuning process using GAs will be compared with Figure 2. Step response for different weights
the results of tuning the controller using the root
locus technique. Furthermore, the effects of the

Table 1. Comparison between PID tuning using GA with equal weights and root locus
Method used PID Parameters Response Parameters
KP KI KD TS Tr TP OS%
Root locus tuning 46.13 1.86 90.46 5.34 0.214 0.308 2.95
Genetic algorithm tuning 88.9 0.6 50.1 2.86 0.265 0.498 0.484
Table 2. Step response results of the PID controlled plant for different weights using GA
Fitness Weights PID Parameters Response Parameters
W_ts W_tr W_tp W_os KP KI KD TS Tr TP OS%
0.7 0.1 0.1 0.1 165.3 5.8 20 2.73 0.293 0.652 35.2
0.1 0.7 0.1 0.1 171.5 45.3 18.8 3.21 0.271 0.657 37.7
0.1 0.1 0.7 0.1 111 11.6 12.8 4.220 0.355 0.820 26.4
0.1 0.1 0.1 0.7 74 0 18.2 2.700 0.470 0.850 0.464

5. Conclusions
In this paper, an approach for the optimal tuning [5] K. Ogata, Modern Control Engineering. Prentice Hall.
of the PID controller parameters using genetic USA, 4th edition, 2002.
algorithms is introduced. In this approach, the user [6] R. Bandyopadhyay, U. Chakraborty, D. Patranabis,
specifies his own design specifications of the plant "Auto tuning a PID controller: A fuzzy- genetic
response in time domain. The genetic algorithm will approach", Journal of systems Architecture. Vol. 47,
then tune the three parameters of the PID controller 2001, pp. 663-673.
in an adaptive manner, where the desired [7] C. Jiang, Y. Ma, C. Wang, PID controller parameters
optimization of hydro-turbine governing systems using
specification values will be reduced automatically deterministic –chaotic- mutation evolutionary
once any of the actual response parameters is equal programming (DCMEP). Energy conversion and
to or smaller than the desired value. In this manner, management, 2006.
the designer will get the best results of the genetic [8] S. Skogestad, "Simple analytic rules for model
algorithm after the termination process of the reduction and PID controller Tuning", Journal of Elsevier
evolution. Process Control, V. 13, 2003, pp. 291-309.
Simulation results show that the proposed [9] W. Tan, F. Lu, A. Loh, K. Tan, "Modeling and control
genetic approach outperforms the conventional root of a pilot pH plant using genetic algorithm", Engineering
locus method for the tuning process. Furthermore, it applications of artificial inelegance. Vol. 18, No. 4,
is also concluded that the weighting factors used in 2005, pp. 485-494.
the fitness function may have a noticeable impact on [10] J. Holland, Adaptation in Natural and Artificial
Systems. Ann Arbor: University of Michigan Press, 1975.
the tuning process and correspondingly plant [11] D. Godberg, Genetic Algorithms in Search,
response. Optimization and Machine Learning, Reissue, Addison-
Wesley Publishing Company, 1980.
6. References [12] J. Lima, A. Ruano, "Neuro-genetic PID auto tuning:
time invariant case", IMACS Journal of Mathematics and
[1] N. Koivo, J. Tanttu, "Tuning of PID Controller: Computers in Simulation, Vol. 51, 2000, pp. 287-300.
Survey of SISO and MIMO techniques", Proc. IFAC [13] Z. Abo-Hammour, Advanced continuous Genetic
Inteelligent Tuning Adaptive Control Symp., Singaphore, Algorithm and their Applications in the motion planning
1991, pp. 75-80. of robot manipulators and in the numerical solution of
[2] W. Bialkowski, The Control Handbook, W.S. Levine, boundary value problems, Pakistan Institute of
Ed. Boca Raton, Florida: CRC/IEEE Press, 1996, pp. engineering and applied science, Pakistan, 2002.
1219-1242. [14] C. Lin, H. Jan, T. Hwang, Structure Variable PID
[3] L. Desborough, R. Miller, "Increasing customer value Control Design Based on DNA Coding Method. Proc.
of industrial control performance monitoring – IEEE Int. Conf. Control Applications, 2004.
honeywell’s experience", Proc. 6th Int'l Conf. Chemical [15] A. Seyedkazaemi, A. Akbarimajed, A. Rahnamaei,
Process Control (CPC VI), John Wiley & Sons, 2002, pp. A. Baghbanpourasl, A genetically Tuned Optimal
172-192. Controller. Proc. Int. Conf. on Artificial Intelligence,
[4] K. Astrom, T. Hagglund, Advanced PID Control. Corfu Island, Greece, 2007.
Research T. Park, NC: ISA, 2005.

View publication stats

You might also like