0% found this document useful (0 votes)
17 views9 pages

PID Controller Tuning with AI Techniques

ưaesrdfhg

Uploaded by

Hải Đăng
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)
17 views9 pages

PID Controller Tuning with AI Techniques

ưaesrdfhg

Uploaded by

Hải Đăng
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

See discussions, stats, and author profiles for this publication at: [Link]

net/publication/296083500

Tuning PID Controllers Using Artificial Intelligence Techniques";

Conference Paper · January 2014

CITATIONS READS
0 1,116

3 authors, including:

Mohamed Ahmed Moustafa Hassan Mohammed E. Ammar


Cairo University Cairo University
177 PUBLICATIONS 1,702 CITATIONS 23 PUBLICATIONS 197 CITATIONS

SEE PROFILE SEE PROFILE

All content following this page was uploaded by Mohamed Ahmed Moustafa Hassan on 06 May 2017.

The user has requested enhancement of the downloaded file.


Tuning PID Controller Using Artificial Intelligence Techniques

Tuning PID Controller Using Artificial Intelligence Techniques

Eng. A. Salem* Dr. M. Ammar** Prof. Dr. M. Moustafa***

*Shams Industry Company (HISENSE), Giza, Egypt.


*** Department of Electrical Power and Machines, Faculty of Engineering, Cairo University, Egypt.
Corresponding E-mails:
* ahmedsdcs@[Link] ** [Link]@[Link] *** mmustafa_98@[Link]

Abstract: This paper studies PID controller parameters improving using the genetic
algorithm, modified genetic algorithm, particle swarm optimization techniques. The
proposed techniques compared with conventional PID controllers tuned by Ziegler-
Nicholas technique using two applications DC-Motor and AVR system. The overshoots,
rise time and settling time with the proposed techniques are better than these of the
conventional PID controllers. The effectiveness of the proposed techniques is confirmed
using MATLAB M-files software and genetic algorithm toolbox.

Keywords: PID-controller, DC-Motor, AVR system, Genetic Algorithm, Modified


Genetic Algorithm, Particle Swarm Optimization.
hard to determined optimal PID
I. Introduction parameters and usually is not caused
good tuning, it produces oscillations and
Proportional-Integral-Derivative (PID) big overshoot [2].
controller is one of the earliest control Artificial intelligent approaches such as
technique and is still used widely in genetic algorithm and particle swarm
industrial because of its easy optimization have been proposed which
implementation, robust performance and have received much interest and have
being simple of physical principle of been applied successfully to solve the
parameters. For achieving appropriate problem of optimization PID controller
closed loop performance, three Parameters.
parameters of the PID controller must be
tuned [1]. II. Artificial Intelligence optimization
techniques
Tuning methods of PID parameters are
classified as traditional and intelligent Genetic Algorithms (GA’s) are a
methods. Conventional methods such as stochastic global search method that
Ziegler and Nichols method which is simulators the process of natural

Page 1
Tuning PID Controller Using Artificial Intelligence Techniques

evolution and they are a family of  Supply a list of optimum variables,


computational models inspired by not just a single solution.
evolution. The genetic algorithm starts  Encode the variables so that the
with no knowledge of the correct optimization is done with the
solution and depends entirely on encoded variables.
responses from its environment and  Working with numerically generated
evolution operators (i.e. reproduction, data, experimental data, or analytical
crossover and mutation) to arrive at the functions.
best solution. By starting at several These advantages are exciting and
independent points and searching in produce better results when traditional
parallel, the algorithm avoids local optimization approaches fail.
minima and converging to sub optimal
solutions. In this way, GAs have been Start

shown to be capable of locating high


performance areas in complex domains Create Population

without experiencing the difficulties


associated with high dimensionality, as Generation = 0
may occur with gradient decent
techniques or methods that rely on Evaluate Fitness
Value
derivative information [3]. Figure (1)
shows the steps of creating and Perform
implementing the genetic algorithm. Selection,
Crossover, and
The genetic Algorithm advantages are: Mutation Process

 Optimization with continuous or


discrete variables.
Gen > Max
 Derivative information isn’t Generation = No generation or min
required. Generation + 1 performance index
reached
 Simultaneously searching from a
wide sampling of the cost surface. Yes
 Dealing with a large number of End
variables.
 Fitting for parallel computers. Figure (1): Genetic Algorithm Flowchart
 Optimization of the variables with
The Particle Swarm Optimization (PSO)
extremely complex cost surfaces
was inspired from the computer
(they can jump out of a local
simulation of the social behavior of bird
minimum).
flocking. Computer graphics simulate

Page 2
Tuning PID Controller Using Artificial Intelligence Techniques

the complicated flocking behavior of current position of particle at iteration 𝑘,


birds [4]. In a PSO system, a swarm of
individuals (called particles or intelligent new position of particle at iteration

agents) fly through the search space. next iteration 𝑘+1 ,


Each particle represents a candidate personal best of particle ,
solution to the optimization problem.
gbest Global best of the population.
The position of a particle is influenced
by the best position visited by itself (i.e. Figure (2) illustrates the general
its own experience) and the position of flowchart for the PSO technique. The
the best particle in its entire population. sequence can be described as follows:
The best position obtained is referred to
as the global best particle. The Step 1: Generation of initial conditions
performance of each particle is measured of each particle.
using a fitness function that varies Initial searching points ( ) and the
depending on the optimization problem. velocities ( ) of each particle are
Modification of the particles position is usually generated randomly within the
realized by the position and velocity allowable range. The current searching
information according equations (1) and point is set to pbest for each particle.
(2) respectively: The best evaluated value of pbest is set
to gbest and the particle number with the
= + ( - best value is stored.
)+ (gbest - ) Step 2: Evaluation of searching point of
(1)
each particle.
= + (2)
The objective function is calculated for
Where: each particle. If the value is better than
the current pbest value of the particle,
then pbest is replaced by the current
current velocity of particle at iteration 𝑘,
value. If the best value of pbest is better
new velocity of particle next at iteration than the current gbest, the gbest value is
𝑘 +1, replaced by the best value and the
cognitive acceleration constant (self-
particle number with the best value is
stored.
confidence),
social acceleration constant (swarm Step 3: Modification of each searching
confidence), point.

Page 3
Tuning PID Controller Using Artificial Intelligence Techniques

Start GA/MGA/PSO

Generation of initial condition of each particle. Set point + Plant(DC-Motor/ Output y(t)
r(t) PID controller
AVR)
-
Evaluation of each searching point of each particle.
Figure (3): Tuning PID Controller with
GA, MGA and PSO.

Modification of each searching point III.1. PERFORMANCE INDICES:

The performance index (objective


function) can be calculated and used to
evaluate the system’s performance,
NO whether the aim is to improve the design
Termination
Iteration = iteration + 1
criteria met? of a system or to design a control system.

a) Integral of the Square of the Error


Yes (ISE):
End
ISE is determined by equation (3); the
squared error is mathematically
Figure (2): The Particle Swarm convenient for analytical and
Optimization Flowchart [5].
computational purposes.
III. GA, MGA and PSO Tuning PID
Controller: ∫ (3)

Figure (3) illustrates the block diagram b) Integral of the Absolute Magnitude
of tuning PID-controller using the of the Error (IAE):
Genetic Algorithm (GA), the Modified
∫ | | (4)
Genetic Algorithm (MGA) and the
Particle Swarm Optimization (PSO)
applying for the two models DC-Motor IAE gets the absolute value of the error
and the Automatic Voltage Regulator to remove negative error components.
(AVR) system. IAE is particularly useful for computer
simulations studies, calculated by
equation (4) [6].

Page 4
Tuning PID Controller Using Artificial Intelligence Techniques

c) Integral of the Time Absolute The proposed methods used MATLAB


Magnitude of the Error (ITAE): M-files for the two models, GA, MGA
and PSO. Figures (5) and (6) present
ITAE weights the error with time and
respectively the step response of DC-
hence emphasizes the error values later
Motor with PI-Controller and PID-
on in the response rather than the initial
Controller with GA, MGA and PSO.
large errors. As shown in equation (5).

∫ | | (5)
In Modified Genetic Algorithm (MGA)
the objective function is illustrated as in
equation (6) below [7].

(6)

IV. Applications:

These papers apply the proposed tuning


methods on two models and compare the
results to Z-N tuning method.
Figure (5): Step Response of DC-Motor with
IV.1. Position Control of DC-Motor: PI-Controller using ZN, GA, MGA and PSO.

This paper use the DC-Motor as the first


model with the following specifications:-

2hp,230 v, 8.5 amperes, 1500 rpm


(Armature resistance) = 2.45Ω,
(Armature inductance) = 0.035H,
(Back EMF) = 1.2Vs/rad, (Moment
of inertia) = 0.022 kg , (Frictional
constant) = 0.5* (Nms/rad)
Then the transfer function of DC-Motor
is as illustrated in (7) [8].
Figure (6): Step Response of DC-Motor with
.
(7) PID-Controller using ZN, GA, MGA and PSO.
. . .

Page 5
Tuning PID Controller Using Artificial Intelligence Techniques

IV.2. Automatic Voltage Regulator Figures (7) and (8) present respectively
(AVR) System: the step response of AVR system with
PI-Controller and PID-Controller with
The role of an AVR is to hold the
genetic algorithm modified genetic
terminal voltage magnitude of a
algorithm and particle swarm
synchronous generator at a specified
optimization.
level. A simple AVR system comprises
four main components, namely amplifier, Tables (1) and (2) content the results for
exciter, generator, and sensor [9]-[10]. all techniques discussed in this proposal.
The reasonable transfer function of these
components may be represented,
respectively, as shown in (8), (9), (10)
and (11) [11].

, , . (8)

, , .4 (9)

, . , (10)

, , . (11)

Figure (7): Step Response of AVR System with


The block diagram of AVR system with PI-Controller using ZN, GA, MGA and PSO.
PID-controller is presented in figure (4).

Figure (4): AVR System with PID-


Controller [12].
Figure (8): Step Response of AVR System with
PID-Controller using ZN, GA, MGA and PSO.

Page 6
Tuning PID Controller Using Artificial Intelligence Techniques

Table (1): Comparison of Results for DC-Motor.

Tuning DC-Motor with PI-Controller


Method Max. OS (Sec) (Sec)
ZN 37.8 151.2 - 63 0.0423s 0.752s
GA 6.94 0.011 - 0.0273 0.291s 0.547s
MGA 10.589 0.012 - 0.0128 0.157s 0.288s
PSO 11.4274 0.002 - 0.00184 0.14s 0.246s
DC-Motor with PID-Controller
ZN 49.41 329.4 1.852 16.9 0.0298s 0.355s
GA 14.859 0.01 3.589 0.00542 0.0258s 0.771s
MGA 19.873 0.009 3.221 0.00273 0.184s 0.541s
PSO 32.6051 0.0125 1.0441 0.00141 0.08s 0.0981s

Table (2): Comparison of Results for AVR System.

Tuning AVR System with PI-Controller


Method Max. OS (Sec) (Sec)
ZN 1.093 1.203 - 78.7 0.289s 15.2s
GA 0.413 0.251 - 18 0.604s 3.38
MGA 0.424 0.243 - 17.5 0.598s 3.36s
PSO 0.4379 0.2329 - 16.9 0.59s 3.35s
AVR System with PID-Controller
ZN 1.457 2.006 0.149 53.4 0.249s 3.63s
GA 0.893 0.848 0.236 9.37 0.326s 1.64s
MGA 0.96 0.826 0.265 7.82 0.301 1.22
PSO 0.9564 0.6725 0.2613 5.95 0.301 0.926

V. Conclusion: Robustness (no overshoot, minimal rise


time, steady state error is 0).
The PID controller based on Genetic
Algorithm (GA) and Particle Swarm VI. References:
Optimization (PSO) has better steady
state response and performance indices [1] [Link], T. Hagglund, “PID
than conventional methods and it took Controllers: Theory, Design and
Tuning”, International Society for
only less than the second to solve the
Measurement and Con., 2nd Ed.,
problem. The Particle Swarm pp. 200-210, 1995.
Optimization (PSO) algorithms is the
best controller which presented [2] [Link], R.J. Mantz, C.F.
satisfactory performances and good Christiansen, “Multivariable PID

Page 7
Tuning PID Controller Using Artificial Intelligence Techniques

Control with Set-Point Weighting Improved Performance”,


via BMI Optimization”, JOURNAL OF INFORMATION
Automatica, Vol. 44, pp. 472-478, SCIENCE AND ENGINEERING
2008. 23, 1469-1480 (2007).

[3] Ali Zilouchian and Mohammad [8] Neenu Thomas, Dr. P. Poongodi,
Jamshidi, “Intelligent control “Position Control of DC Motor
systems using soft computing Using Genetic Algorithm Based
methodologies”, by CRC Press PID Controller”, Proceedings of the
LLC, 2001. World Congress on Engineering
2009 Vol II, London, U.K., 2009.
[4] NELENDRAN PILLAY, “A
PARTICLE SWARM [9] Zwe-Lee Gaing, “A Particle Swarm
OPTIMIZATION APPROACH Optimization Approach for
FOR TUNING OF SISO PID Optimum Design of PID Controller
CONTROL LOOPS”, DURBAN in AVR System”, IEEE
UNIVERSITY OF TRANSACTIONS ON ENERGY
TECHNOLOGY, 2008. CONVERSION, VOL. 19, NO. 2,
JUNE 2004.
[5] Ali Marzoughi, Hazlina Selamat,
Mohd Fua’ad Rahmat and Herlina [10] Ching-Chang Wong, Shih-An Li
Abdul Rahim, “ Optimized and Hou-Yi Wang, “Optimal PID
proportional integral derivative Controller Design for AVR
(PID) controller for the exhaust System”, Tamkang Journal of
temperature control of a gas turbine Science and Engineering, Vol. 12,
system using particle swarm No. 3, pp. 259_270 (2009).
optimization”, International Journal
of the Physical Sciences Vol. 7(5), [11] S. F. M Kheder, M. E. Ammar, M.
pp. 720-729, 2012. A. Moustafa Hassan;"Multi
objective genetic algorithm
[6] M. A. Tammam, M. A. S. Aboelela, controller’s Tuning for non-linear
M. A. Moustafa, A. E. A. Seif; " automatic voltage regulator"
Fuzzy Like PID Controller Tuning Accepted for presentation at CoDIT
by Multi-Objective Genetic 2013, Tunis, May 6-8, 2013
Algorithm for Load Frequency
Control in Nonliear Electric Power [12] Ching-Chang Wong, Shih-An Li
Systems", International Journal of and Hou-Yi Wang, “Optimal PID
Advances in Engineering & Controller Design for AVR
Technology, , Vol. 5, Issue 1, Nov. System”, Tamkang Journal of
2012, pp. 572-583. Science and Engineering, Vol. 12,
No. 3, pp. 259_270 (2009).
[7] AYTEKIN BAGIS, “Determination
of the PID Controller Parameters by
Modified Genetic Algorithm for

Page 8

View publication stats

You might also like