A Comparison Study Between Using The Pso Algorithm and The Ga in Mobile Robot's Motion
A Comparison Study Between Using The Pso Algorithm and The Ga in Mobile Robot's Motion
1, January 2013
ABSTRACT
This paper introduces using Particle Swarm Optimization algorithm (PSO) to improve the robot motion to
arrive to its goal in cluttered environments. The Particle Swarm Optimizer is used to optimize the forces
applied to the robot by selecting optimum factors of these applied forces. This improvement raises the robot
ability to avoid the obstacles. A measure of smoothness is used to guide the PSO algorithm during the
optimization. The optimized controller is simulated with different cases on Windows Vista using Matlab
Software. These cases include environments with single obstacle up to three obstacles and multi-knee
corridor. An Advanced Artificial Potential Field (AAPF) controller is used to control the robot’s motion. A
comparison study of the robot motion optimization between using the PSO and using the Genetic
algorithms is given. The results of the proposed system and the results of a previous work are introduced.
KEYWORDS
Advanced Artificial Potential Field, Genetic Algorithm, Obstacle Avoidance, Particle Swarm Optimization
algorithm, Robot Motion
1. INTRODUCTION
Mobile robots from path guidance methods to autonomous mobility, resulting on obstacle
avoidance of robots have emerged steadily over the years including directional command
methods, such as artificial potential fields [1-5] and speed-space commands, such as the curvature
foundation system [6-9]. However, most previous results remain a challenging problem as most
existing methods have not considered the mobility of robots and obstacles. These algorithms
cause a robot to move very slowly for obstacle avoidance. If a robot moves very slowly, most of
the established algorithms can be applied to avoid obstacles. As it moves faster and faster,
avoidance control is more difficult and the robot tends to collide more frequently with obstacles.
The Artificial Potential Field controller determines the net forces which applied on the robot to
identify the behaviour of the robot against the objects in its environment. The traditional Artificial
Potential Field (APF) controller is used in [1], [10]. While the Advanced Artificial Potential Field
(AAPF) controller that is introduced in [11] with less computation is used here.
DOI:10.5121/ijitca.2013.3101 1
International Journal of Information Technology, Control and Automation (IJITCA) Vol.3, No.1, January 2013
The virtual sensor concept that was introduced in [10] is used in our work. This concept is similar
to that of the Doppler Effect. When a robot heads to an obstacle, the distance on the robot sensor
is longer than the virtual sensor. Likewise, the physical distance on the robot sensor is shorter
than the virtual one when it goes away from an obstacle.
In this paper, an improvement of robot motion to reach its goal with in cluttered environments
using the Particle Swarm Optimizer is introduced. This improvement gives high reaction speed of
the robot without any abrupt changes in robot path. Efficiency of robot obstacle avoidance will be
regarded too. The Particle Swarm optimization (PSO) is used to select the optimum factors of the
repulsive and the attractive forces in the offline state which are determined by the AAPF
controller and then applied on the robot in the online state as in [11]. The optimum factors are
those who make the robot motion much smoother. Simulation on Matlab is executed for testing
the performance of the proposed system in the task of robot obstacle avoidance. The simulation is
done at four workspaces as at [11]. The simulation results of the proposed system are then
compared with the performance in [11]. This comparison study introduces that using the GA
achieves better optimization than using the PSO. While PSO is faster than GA at selecting the
optimum values. The odometry of the robot is calculated using the angle approach [12].
This paper is organized as follows. Section 2 illustrates the Advanced Artificial Potential Field
(AAPF). Section 3 explains the different PSOs techniques which are used in this paper. Section 4
illustrates the determination of the optimum factors of the advanced potential field controller
forces using PSO and illustrates the fitness function which is used in our work. Section 5 shows
the performance of the proposed system by simulation in four different cases. In addition,
comparison with the results in [11] will be reviewed. Conclusion and future work are given in
Section 6.
An advanced artificial potential field Uaap(t) consists of the attractive force Ug(t) and the
repulsive force Uk(t) as shown in equation 1.
, , = , + , (1)
Where: is the robot position at time t, is the obstacle position at time t, and is the
goal position.
ln ≤
, = (2)
0 >
, = − , (3)
Where: Kr is the repulsive force factor, is the virtual sensor reading of the distance between the
robot and the obstacle which is calculated as in [10], and is the threshold distance between the
robot and the obstacle, , and Ka is the attractive force factor.
The forces on the robot can be calculated from the gradient function of the artificial potential
field as:
2
International Journal of Information Technology, Control and Automation (IJITCA) Vol.3, No.1, January 2013
As the robot approaches the obstacle the repulsive force Fo(Pr(t)) increases. On the other hand,
the attractive force to the goal Fg(Pr(t)) will be decreased as it approaches its goal. Therefore, the
net force from the artificial potential fields enables the robot to smoothly move to the goal.
PSO is an optimization method that utilizes swarm intelligences in solving problems. It mimics
the social behavior of bird flock and fish schools when they search for food [13]. It is very
different from evolutionary algorithms, in which various operators are applied to the population
yielding next generation with higher fitness value (better solution). In other words, the population
evolves itself until it converges to the optimal solution in evolutionary algorithm.
In PSO, each particle is searching for the optimal solution therefore they are moving with a
certain velocity. Each particle also remembers the best result achieved so far (personal best) and
exchanges information with other particles to determine the best particle (global best) among the
swarm. At each time step, a particle has to move to a new position by adjusting its velocity. The
particle would tend to move towards its historical best position and the best position recorded by
the swarm. Hence, the velocity is actually comprised of the following three components: (i) the
current velocity (ii) weighted random portion in the direction of its personal best and (iii)
weighted random portion in the direction of global best. The new position is merely the sum of
current position with the new velocity.
In short, let the solution space to be D-dimensional, then the i-th particle in the swarm is Xi =
(xi1, xi2,…,xiD)T; the velocity vector is Vi = (vi1, vi2,…,viD)T; the historical best position of
the i-th particle is Pi = (pi1, pi2,…,piD)T. The best particle is recognized by fixing g as the index
of the above expressions. Standard PSO is only governed by the following two equations:
(5)
(6)
Equation (5) is the velocity update equation and (2) is the position update equation. Where d=1,
2,…,D; i=1, 2,…,S, S is the swarm size; c1 and c2 are weight of personal best and weight of
global best, respectively; r1 and r2 are random numbers distributed uniformly in [0,1]. Often, vid
is truncated to a threshold value Vmax to increase the stability and resolution of search process
[14].
With the concept of standard PSO structure, later exploration leads to the development of inertia
weight concept. It is an effort motivated to discard Vmax while increasing search space
exploration and exploitation. Later it is found that addition of inertia weight is unable to replace
the role of Vmax. However, the introduction of inertia weight enables the use of another
parameter to tune the performance of PSO [14]. Hence with inertia weight, (5) then becomes
3
International Journal of Information Technology, Control and Automation (IJITCA) Vol.3, No.1, January 2013
(7)
Where w is the inertia weight. According to Eberhartand Shi [15], the optimal strategy is to set w
to 0.9 initially and then reduce it linearly to 0.4, allowing early exploration before exploiting in
the proximity of global optimum later.
Also, Clerc [16] introduced a constriction factor, , which enhances the constraint and control on
velocities. is defined as
(8)
(9)
It is known that proper selection of parameters such as c1 and c2 in (5) and w in (7) could greatly
enhance the performance of PSO. Therefore a light study on parameter selection was performed
before utilizing these PSOs in solving the problem in hand. The standard PSOs assumptions for
w, c1, and c2 are 1, 2, and 2, respectively. According to [15], inertia weight coefficient, w in
PSO-W should be linearly decreased from 0.9 to 0.4 and assume c1 = c2 = 2. In [14], the same
strategy is adopted with a slight change where w is decreased for the first 100 iterations only. The
motivation is to enhance exploration of solution space earlier to increase convergence speed. [14]
used assumptions of c1 and c2 at PSO-W are 0.7 and 1.0, respectively, while it is 5.8 and 2.8,
respectively, for PSO-C. While [17] sets the three weight factors w, c1, and c2 with 0.5, 1.5, and
1.5 respectively. In this paper, we use these assumptions to find the best one for robot motion.
These assumptions are applied and simulated on different workspaces.
[18] used the genetic algorithm (GA) to determine the attractive and repulsive coefficients Ka, Kr
of the forces. Another one of the optimization techniques such as Particle Swarm Optimization
(PSO) algorithm is used in this paper to optimize those factors.
The fitness function which is used in PSOs optimizers is the smoothness (SM) [10] that is defined
as a criterion of the evaluation to measure the various robot trajectories as:
(10)
(11)
4
International Journal of Information Technology, Control and Automation (IJITCA) Vol.3, No.1, January 2013
Where = the last pose number of robot trajectory, and represent the robot position at
nth sampling time. is the angle between current and former position at nth sampling time.
First the optimum parameters for the advanced potential field controller are obtained in offline
state. It includes guided random search operation using PSO algorithm to determine the optimum
factors for Kr and Ka. Four different environments with the advanced potential field controller are
used. The start point of the robot at the first three workspaces are (0,0), while at the fourth, the
start point of the robot is (2,0). The end points (goals) at the four workspaces are (4,2), (4,3), (4,3)
and (6.5,6.5) respectively. These cases are those typically used in [11]. Ka and Kr values for each
workspace according to using PSOs and GA are determined. And the results (smoothness) of
using the values of these factors with the mentioned assumption in section 3.3 at each case are
noted in Tables 1, 2, 3, and 4. These results are also compared with the results in [11].
5. SIMULATION RESULTS
This section shows the simulation results of robot's motion to reach to its static goal at four
different environments. The performance of different PSOs techniques are computed and
compared with other performance that are introduced in [11].
In Case 1, there is only one obstacle in the workspace. The different values of w, c1, and c2 are
used at different PSO's techniques. These assumptions are shown in table 1. According to these
assumptions, each PSO technique gives its optimum values of Ka (attractive force factor), and Kr
(repulsive force factor) which are noted also in table 1.
Table 1. The results comparison for both of using GA and PSOs optimizers at case 1
The SM results (smoothness value) due to these optimum values for each PSO technique are
written also in table 1. And the optimum values of Ka and Kr using GA and its result (SM)
according to this selection is shown also in table 1.
5
International Journal of Information Technology, Control and Automation (IJITCA) Vol.3, No.1, January 2013
After applying the standard PSO, PSO_W, and PSO_C techniques we find as illustrated in table 1
that those achieve similar results (SM). The PSO optimizer gives higher smoothness than GA
optimizer. PSOs optimizers determine the optimum values faster than GA optimizer.
Fig 1 shows the robot motion using GA as introduced in [11] with the red line and the robot
motion using PSO with the best values of Ka and Kr (9, 1) with the blue line.
Fig 1: Robot motion at case 1(red: using GA, blue: using PSO)
In Case 2, there are 2 obstacles in the workspace, table 2 illustrates the optimum values of Ka and
Kr which are given by PSOs techniques at different assumptions for w, c1, and c2 values. It also
shows the optimum values of the same parameters using GA as in [11].
Table 2. The results comparison for both of using GA and PSOs optimizers at case 2
6
International Journal of Information Technology, Control and Automation (IJITCA) Vol.3, No.1, January 2013
The comparison between the SM values achieved by using PSOs techniques and the other
achieved by GA is illustrated in table 2.
Fig 2 shows the robot motion using GA as introduced in [11] with the red line and the robot
motion using PSO with the best values of Ka and Kr (21, 1) with the blue line.
From the table, we find that the GA optimizer achieved better result than the PSOs techniques at
this case. But, from fig 2, we find that the PSO achieved higher avoidance than the GA. And
PSOs optimizers are still faster than GA optimizer.
Fig 2: Robot motion at case 2(red: using GA, blue: using PSO)
In this Case, 3 obstacles are in the workspace. Table 3 shows the optimum values of Ka and Kr
which are obtained by PSOs techniques at different assumptions for w, c1, and c2 values. It also
shows the optimum values of the same parameters using GA as in [11].
Table 3. The results comparison for both of using GA and PSOs optimizers at case 3
The comparison results (SM) are shown also in table 3. Fig 3 shows the robot motion using GA as
introduced in [11] with the red line and the robot motion using PSO with the best values of Ka
and Kr (19, 1) with the blue line.
From table 3, we find that the GA optimizer achieved better results than the PSOs technique at
this case. While PSO optimizer is faster and achieves better avoidance than GA optimizer.
Fig 3: Robot motion at case 3(red: using GA, blue: using PSO)
In this Case, the robot moves in the corridor and two obstacles are given. As previous tables, table
4 illustrates the optimum values of Ka and Kr which are obtained by PSOs techniques with
different assumptions for w, c1, and c2 parameters. It also shows the optimum values of the same
parameters using GA as in [11].
Table 4. The results comparison for both of using GA and PSOs optimizers at case 4
8
International Journal of Information Technology, Control and Automation (IJITCA) Vol.3, No.1, January 2013
The SM results achieved by using PSOs techniques and the other achieved using GA are shown
in table 4. From the table, we find a large difference at SM results. Where, the GA optimizer has
better result (SM) than the PSOs techniques at this case. While from fig 4 we find that the PSO
achieves better performance than GA in avoiding the obstacle. And PSOs optimizers are still
compute the optimum values faster than GA optimizer.
Fig 4: Robot motion at case 4(red: using GA, blue: using PSO)
From the four tables, we find the PSOs techniques have similar results at each case. And these
slight differences between them depend on the parameters selection. GA achieves better
performance than PSO in the cluttered environment with the expense of time.
So, there will be a trade of between selecting the GA optimizer with its best results or any of
PSOs optimizers with its high speed for any application. This selection depends on the application
used.
6. CONCLUSION
In this paper, the improvement in the robot motion using PSOs is introduced. PSOs optimizers are
used to select the optimum factors of the forces to reach the goal while avoiding obstacles. The
optimized parameters are tested in four different environments. The results generally showed the
superiority of the proposed controller and inclusively compared to the work in [11]. Graceful
optimization regarding the path motion is achieved. GA optimizer gives better smoothness value
than the PSO optimizer. While PSO is faster than GA at determining the optimum values and has
better obstacle avoidance than GA. So, we select the optimizer that we use according to the
application. The real implementation of the proposed work and robots formation can be done as a
future work.
REFERENCES
[1] O. Khatib, (1986) "Real-Time Obstacle Avoidance for Manipulators and Mobile Robots", Int. J.
Robotics Research, Vol. 5, No. 1, pp. 90-98.
[2] J. Borenstein and Y. Koren, (1991) "The Vector Field Histogram-Fast Obstacle Avoidance for Mobile
Robots", IEEE Trans. on Robotics Automation, Vol. 7, No. 3, pp. 278-288.
[3] J. Borenstein and Y. Koren, (1988) "Obstacle Avoidance with Ultrasonic Sensors", IEEE Journal of
Robotics, Vol. 4, No. 2, pp. 213-218.
9
International Journal of Information Technology, Control and Automation (IJITCA) Vol.3, No.1, January 2013
[4] E. Shi, T. Cai, C. He and J. Guo, (2007) "Study of the New Method for Improving Artificial Potential
Field in Mobile Robot Obstacle Avoidance", Proc. of IEEE International Conference on Automation
and Logistics, pp 282-286.
[5] J. Gong, Y. Duan, Y. Man, and G. Xiong, (2007) "VPH+: An Enhanced Vector Polar Histogram
Method for Mobile Robot Obstacle Avoidance", Proc. of International Conference on Mechatronics
and Automation, pp. 2784-2788.
[6] R. G. Simmons, (1996) "The Curvature-Velocity Method for Local Obstacle Avoidance", Proc. of
IEEE International Conference on Robotics and Automation, pp.3375-3382.
[7] N. Y. Ko, R. G. Simmons, and K. S. Kim, (2003) "A Lane Based Obstacle Avoidance Method for
Mobile Robot Navigation", Journal of Mechanical Science and Technology, Vol. 17, No. 11, pp.
1693-1703.
[8] A. Kelly, (1995) "An Intelligent Predictive Control Approach to the High Speed Cross Country
Autonomous Navigation Problem", Tech Report CMU-CS-TR-95-33, School of Computer Science,
Carnegie Mellon University.
[9] C. Schlegel, (1998) "Fast Local Obstacle Avoidance under Kinematic and Dynamic Constrains for a
Mobile Robot", Proc. of IEEE/RSJ International Conference on Intelligent Robots and Systems, Vol.
1, pp. 594- 599.
[10] Dong Jin Seo, Nak Yong Ko, and Jung Eun Son, (2010) "A Method for Combining Odometry and
Distance Sensor Information for Effective Obstacle Avoidance of Autonomous Mobile Robots",
International Journal of Control, Automation, and Systems, Vol. 8, No. 3, pp. 597-603.
[11] Marwa T. Yousef, Elsayed M. Saad, Shahira M. Habashy, (2012) " Obstacle Avoidance with Virtual
sensor in Mobile Robot’s Motion using the Advanced Potential Field Controller ", International
Journal of Computer Applications, Volume 53– No.4, September (0975 – 8887).
[12] Philip Machler, (1998) "Robot Positioning by Supervised and Unsupervised Odometry Correction",
PhD thesis, Department of Information, École Poly Technique Federal of Lausanne.
[13] Eberhart RC, Kennedy J., (1995) “A new optimizer using particle swarm theory”. In: Proceedings of
the sixth international symposium on micro-machine and human science. Nagoya, Japan; p. 39–43.
[14] Goh Shyh Chyan, S.G. Ponnambalam, (2012) “Obstacle avoidance control of redundant robots using
variants of particle swarm optimization” , Robotics and Computer-Integrated Manufacturing 28 147–
153.
[15] Eberhart RC, Shi y. (2000) “Comparing inertia weights and constriction factors in particle swarm
optimization”. Congress on Evolutionary Computing,1:84–8.
[16] Clerc M. (1999) “The swarm and the queen: towards a deterministic and adaptive particle swarm
optimization”. In: Proceedings of the ICEC. Washington, DC; p. 1951–7.
[17] R. Hassan, B. Cohanim, O. De Weck, G. Venter, (2005) "A Comparison Of Particle Swarm
Optimization And The Genetic Algorithm", the 46th AIAA/ ASME/ ASCE/ AHS/ ASC Structures,
Structural Dynamics, and Materials Conference, pp. 1-13.
[18] Marwa T. Yousef 1, Hosam Eldin I. Ali 2, Shahira M. Habashy 3, Elsayed M. Saad, (2012)"
Improved Potential Field Controller for Obstacle Avoidance in Mobile Robots", the 29th National
Radio Science Conference, April 10 - 12, Faculty of Engineering/Cairo University, Egypt, pp. 495-
502.
10