Next Article in Journal
Path Tracking and Anti-Roll Control of Unmanned Mining Trucks on Mine Site Roads
Next Article in Special Issue
Research on Obstacle Avoidance Trajectory Planning for Autonomous Vehicles on Structured Roads
Previous Article in Journal
An Overview of Diagnosis Methods of Stator Winding Inter-Turn Short Faults in Permanent-Magnet Synchronous Motors for Electric Vehicles
Previous Article in Special Issue
Adaptive MPC-Based Lateral Path-Tracking Control for Automatic Vehicles
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Omnidirectional AGV Path Planning Based on Improved Genetic Algorithm

College of Mechanical Engineering, Xi’an University of Science and Technology, Xi’an 710054, China
*
Author to whom correspondence should be addressed.
World Electr. Veh. J. 2024, 15(4), 166; https://doi.org/10.3390/wevj15040166
Submission received: 15 March 2024 / Revised: 31 March 2024 / Accepted: 11 April 2024 / Published: 16 April 2024
(This article belongs to the Special Issue Research on Intelligent Vehicle Path Planning Algorithm)

Abstract

:
To address the issues with traditional genetic algorithm (GA) path planning, which often results in redundant path nodes and local optima, we propose an Improved Genetic Algorithm that incorporates an ant colony algorithm (ACO). Firstly, a new population initialization method is proposed. This method adopts a higher-quality random point generation strategy to generate random points centrally near the start and end of connecting lines. It combines the improved ACO algorithm to connect these random points quickly, thus greatly improving the quality of the initial population. Secondly, path smoothness constraints are proposed in the adaptive function. These constraints reduce the large-angle turns and non-essential turns, improving the smoothness of the generated path. The algorithm integrates the roulette and tournament methods in the selection stage to enhance the searching ability and prevent premature convergence. Additionally, the crossover stage introduces the edit distance and a two-layer crossover operation based on it to avoid ineffective crossover and improve convergence speed. In the mutation stage, we propose a new mutation method and introduce a three-stage mutation operation based on the idea of simulated annealing. This makes the mutation operation more effective and efficient. The three-stage mutation operation ensures that the mutated paths also have high weights, increases the diversity of the population, and avoids local optimality. Additionally, we added a deletion operation to eliminate redundant nodes in the paths and shorten them. The simulation software and experimental platform of ROS (Robot Operating System) demonstrate that the improved algorithm has better path search quality and faster convergence speed. This effectively prevents the algorithm from maturing prematurely and proves its effectiveness in solving the path planning problem of AGV (automated guided vehicle).

1. Introduction

In scenarios such as intelligent manufacturing factories and logistics and transportation systems, automated guided vehicles (AGVs) have been widely used as the main tools for intelligent material transportation [1]. AGV path planning technology refers to AGVs that autonomously generate safe and feasible paths based on evaluation criteria such as travel time, path length, and turning frequency, combined with their own sensors’ perception of the environment [2,3].
The use of traditional genetic algorithms in path planning typically involves identifying the most efficient route from a starting point to a destination. The fundamental concept of traditional genetic algorithm path planning is to search for the optimal path by simulating the process of genetic evolution in nature through population evolution and fitness evaluation. The general steps and characteristics of traditional genetic algorithm path planning are as follows: Firstly, the path planning problem must be transformed into an optimization problem that can be handled by a genetic algorithm. This requires defining the objective function of the problem, constraints, and the solution space of the problem. Secondly, the population must be initialized. A set of initial paths, or chromosomes, is randomly generated based on the problem’s characteristics. The fitness value of each path is then calculated to measure its superiority, typically based on factors such as path length and obstacle avoidance ability. Finally, a selection operation is performed. The path’s fitness value determines the probability of selecting it as the parent for generating the next generation of the population. The crossover operation generates new paths by crossing over chromosomes to increase population diversity and explore the search space. The mutation operation is also performed as follows: Mutate the chromosomes of the paths with a certain probability to introduce new path information and increase the diversity of the population, preventing it from falling into local optimal solutions. Repeat the selection, crossover, and mutation operations until the termination conditions are met. The traditional genetic algorithm is advantageous for coping with complex path-planning problems and has better global search capability and robustness. The language used should be clear, objective, and value-neutral, avoiding biased, emotional, figurative, or ornamental language. The text should adhere to style guides, use consistent citation, and follow a consistent footnote style and formatting features. Additionally, the language should be formal, avoiding contractions, colloquial words, informal expressions, and unnecessary jargon. Finally, the text should be free from grammatical errors, spelling mistakes, and punctuation errors. However, it also has drawbacks, such as low search efficiency and a tendency to fall into local optimal solutions. It is important to note that subjective evaluations should be excluded unless clearly marked as such. Therefore, when faced with different path-planning problems, it is necessary to select the appropriate optimization algorithm or enhance it by combining it with other heuristic algorithms based on the specific situation.
As of now, a considerable number of researchers worldwide have conducted extensive studies in this area. For example, Tian et al. [4] proposed an approach based on improved adaptive genetic algorithms to address the problem of infeasible paths generated by genetic algorithms by ensuring feasible paths for population individuals after genetic operations using prior knowledge. Li et al. [5], recognizing that the performance of basic genetic algorithms depends on factors such as the initial population quality, introduced an artificial bee colony algorithm to initialize the population and improve the population diversity. They then designed an adaptive strategy adjustment for crossover and mutation operators based on trigonometric functions to improve the convergence speed of the algorithm. Qiao et al. [6] corrected non-smooth paths generated by genetic algorithm planning using an enhanced artificial potential field method, optimizing paths by adding nodes for smoother trajectories. Liu et al. [7] addressed the problems of traditional mutation operators struggling to produce high-quality solutions and premature algorithm convergence by presenting a path fine-tuning algorithm and incorporating simulated annealing operations in each generation for local optimization. Xu et al. [8] proposed a combination of immune operators to improve solution quality. Andranik S. Akopov et al. [9] introduces a novel approach using parallel genetic algorithms for simulation-based optimization, addressing large-scale optimization problems characterized by wide feasible ranges and multiple local extrema. This methodology is successfully applied to minimize the potential number of traffic accidents in an Artificial Multi-Connected Road Network (AMCRN). R Zhou et al. [10] proposed a genetic algorithm-based entry event and car following event framework to solve the problem of a lack of scenarios and low efficiency in virtual testing of CAV (Connected automated vehicles), which significantly improves accident scenarios and challenging scenarios and is more efficient. CHAYMAA et al. [11] proposed a mobile robot path planning method based on improved crossover genetic algorithm in terms of efficiency and applicability of scene generation, which was improved in terms of distance and safety to find a feasible and efficient path between two points. Chen et al. [12] proposed a genetic algorithm fused with the fireworks algorithm to compensate for the premature convergence disadvantage of genetic algorithms. Li et al. [13] used the A-star algorithm as heuristic information in population initialization and added deletion sub-operators, etc., which reduced the number of iterations, but the computation time was long when faced with complex paths.
The study aims to address the limitations of traditional genetic algorithms (GA) in path planning. The proposed Improved Genetic Algorithm (IGA) incorporates the ant colony algorithm (ACO) to solve issues such as poor initialized path quality, premature convergence, long turn times and angles, easy deadlock, regional extremes, and too many redundant path nodes. First, a new population initialization method is proposed to improve the quality of random point generation by generating points near the start and end point connecting lines. This results in higher-quality random points and shorter generated paths. Additionally, an improved ant colony algorithm is used to efficiently connect these random points, resulting in a higher-quality population under this initialization strategy. During the selection phase, a combination of tournament and roulette wheel selection is utilized to prevent premature convergence of the population. Additionally, an elite retention strategy is employed to prevent the degradation of the algorithm. In the crossover phase, the algorithm introduces the concept of edit distance and proposes a two-layer crossover operation based on edit distance to prevent invalid crossover and expedite the evolution of the algorithm. During the mutation stage, a new method that incorporates the concept of simulated annealing is proposed to introduce novel mutations. Additionally, a three-stage mutation method is suggested to enhance population diversity and accelerate convergence to the optimal solution. To eliminate redundant nodes in the paths and expedite the algorithm’s convergence, a deletion operator is also included to remove non-essential paths. The fitness function introduces the constraint of path smoothness to guide the algorithm towards smoother paths. To balance population diversity and the algorithm’s ability to determine optimal individuals in later stages, we use adaptive crossover and mutation probability adjustment strategies. This ensures greater species diversity in the early stages and the faster determination of optimal individuals in later stages. The simulation results indicate that the improved algorithm is more effective than the traditional genetic algorithm. It can avoid local extremes better, converge faster, and generate higher quality and shorter length paths. Practical experiments confirmed the advantages of the improved algorithm in terms of algorithm convergence speed, path smoothness, and path length.

2. Establishment of Environmental Model

In this paper, the grid method is used to model the working environment of an automated guided vehicle. Obstacles are represented by black grid cells, free space is represented by white grid cells, and the grid width is unit length. As shown in Figure 1 below, the start point is denoted by S, and the end point is denoted by E. The following assumptions are made in the modeling process: The actual size of the AGV is not considered as a point mass [14]. A Cartesian coordinate system is established with the lower left corner of the grid map as the origin. The grids are numbered sequentially from 0, bottom to top and left to right. The formula for converting the grid number n into real coordinates (Xn, Yn) in an m × m grid environment is as follows:
X n = mod ( n , m ) + 1 Y n = f i x ( n m ) + 1
In Equation (1), m is the number of grids in each row or column, mod is the remainder operation, and fix is the rounding operation.

3. Genetic Algorithm Improvement and Implementation

3.1. Encoding Method

This article uses grid serial numbers to encode chromosomes; that is, each path of the AGV is composed of the grid serial numbers it passes through in the process of moving from S to G. The red path in Figure 1 can be expressed as {S, 10, 21, 31, 42, 43, 44, 55, 66, 77, 78, 89, G}.

3.2. Population Initialization

In the existing literature, population initialization methods usually use random generation [15]. This approach tends to generate a large number of infeasible paths in the initialized population, which affects the rate of population evolution and the quality of individual chromosomes [15]. On this basis, this paper proposes a heuristic strategy based on the reference [16], which integrates an improved ACO algorithm for generating initial populations, as shown in Figure 2. The specific steps are summarized below:
(1)
Determine the population size M by connecting the points S and G with a straight line, using S as the starting point and G as the destination point.
(2)
Divide the line SG vertically by the dotted line L i into n − 2 parts.
(3)
The point P i is randomly generated on the dashed line L i {i = 1, 2, …, n − 2} on the dashed line L i {i = 1, 2, …, n − 2}, the point P i is randomly generated, and the coordinates of P i are calculated as shown in Equation (2). If the generated P i is not in free space, a point in the neighborhood of P i in free space is regenerated to replace it.
X i = X 1 + i 1 n 1 X n X 1 + m r a n d d g r i d X 1 X n 2 + Y 1 Y n 2 Y n Y 1 Y i = Y 1 + i 1 n 1 Y n Y 1 + m r a n d d g r i d X 1 X n 2 + Y 1 Y n 2 X n X 1
In Equation (2), n represents the length of the chromosome, d g r i d is the grid size, x i , y i denotes the coordinates of the randomly generated point P i , x 1 , y 1 and x n , y n are the starting point S and the target point G of the AGV movement, respectively, and m_rand is a random number selected from {−m, 1 − m, ⋯, m − 1, m}.
(4)
Connect the randomly generated points into a continuous path. Starting from point S, if there is no obstacle between neighboring nodes, connect them with a straight line and go to step six. If there are obstacles, go to the next step.
(5)
Since the ACO algorithm is characterized by fast search speed and optimization on simple paths, this paper uses the ACO algorithm between two points with obstacles [17]. The maximum value of horizontal distance D and vertical distance H is taken as a square to determine the area to be planned S. Assuming that the starting point is A and the ending point is B, the centroid coordinates of the area S are ( X A + X B 2 , Y A + Y B 2 ) . If the path generation fails because the area is too small and there is no path, the area of area S is increased by one unit in all directions, and then replanning is performed. In order to increase the initialization speed of the algorithm, the area of region S can only be increased twice. After two times, the area is set to fail to generate a feasible path, and random points A and B are regenerated for path planning. Consider P i and P i + 1 at the two ends of the obstacle as the start and end points, respectively. There are two key factors for the ants to move from the current position i to the next position j: probabilistic selection and pheromone updating. To further improve the convergence of the ACO algorithm and the quality of the initial population, the weighting factor r ( r ( 0 , 1 ) ) in the state transition probability formula is
P i j k = r τ i j γ × η i j ε k a l l o w e d k τ i j γ × η i j ε , j a l l o w e d k 0 , o t h e r w i s e
η i j = 1 ( x i x j ) 2 + ( y i y j ) 2 1 2
where τ i j denotes the pheromone concentration, η i j denotes the pheromone inspiration factor, γ and ε are τ i j and η i j the weighting coefficients, respectively, and a l l o w e d k are the nodes that the ants can pass through when moving.
In terms of pheromone updating, this paper takes the path length as the criterion for better convergence. If the path is smaller than the average path, it is rewarded, and vice versa. The specific equations are as follows:
τ i j ( t + 1 ) = ( 1 ζ ) τ i j ( t ) + k = 1 m Δ τ i j k ( t )
Δ τ i j k ( t ) = 3 ς L k + φ L k L b e s t L a v e L b e s t , L k < L b e s t 2 ς L k + φ L k L b e s t L a v e L b e s t , L b e s t < L k < L a v e ς L k , e l s e
where ζ denotes the pheromone volatilization system; k = 1 m Δ τ i j k ( t ) denotes the pheromone left between paths (i, j) in this iteration; Δ τ i j k ( t ) denotes the pheromone’s left by the ants on the path (i, j) at the moment t; L k denotes the path length of the ants; ς denotes the pheromone strength, which is generally a constant; L b e s t is the optimal path length; L a v e is the average length of the paths in this iteration; φ and is the weighting factor.
(6)
Determine whether goal point G has been reached. If it has, go to the next step; if it has not, return to step 4.
(7)
If there are duplicate paths in the generated individuals, delete them.
(8)
If the population size equals M, stop; otherwise, repeat steps 3 to 7.

3.3. Adaptation Function

In genetic algorithms, the fitness function is used to evaluate the quality of chromosomes under predetermined conditions to determine the evolutionary direction of the population. Considering the stability and economy of AGVs in practical applications, the evaluation criteria for generating paths are path length and path smoothness. Therefore, the objective function of the feasible path can be expressed as follows:
F f i t W * = min F f i t 1 W , F f i t 2 W
In Equation (7), W * denotes the planned path and F f i t 1 W and F f i t 2 W are given by Equations (8) and (9), respectively.
(1)
Path length:
F f i t 1 W = i = 1 n 1 x i + 1 x i 2 + y i + 1 y i 2
In Equation (5), n is the number of nodes that generate the path, and x i and y i are the abscissa and ordinate of the ith node, respectively.
(2)
Path smoothness:
F f i t 2 W = i = 2 n 1 f i t 2
f i t 2 = arccos a b a b + 1 10 , 1 a b a b 0.7 arccos a b a b + 10 10 , 0.7 < a b a b 0 arccos a b a b + 100 10 , 0 < a b a b 1
In Equation (10), vector a = ( x i x i 1 , y i y i 1 ), vector b = ( x i x i + 1 , y i y i + 1 ).
From Equation (7), it can be seen that the evolutionary direction of the paths planned by the IGA is towards shorter paths and shorter number of turns and turning angles. Therefore, the fitness function is shown in Equation (11), and the fitness function value of the optimal path is the smallest.
F f i t W = α F f i t 1 W + β F f i t 2 W
In Equation (11), α and β are the weights of each part.

3.4. Improved Genetic Operations

3.4.1. Improve Selection Operations

Traditional genetic algorithms usually use the roulette wheel selection method in the selection phase, which may lead to premature convergence and local optimization of the algorithm [18]. To address this phenomenon, this paper combines the improved roulette wheel selection method with the tournament selection method. To prevent population degradation, this paper also employs an elite preservation strategy.
The enhanced roulette wheel selection method follows a specific procedure. Individuals are sorted according to their fitness values from high to low and proportionally categorized into “high fitness individuals”, “medium fitness individuals”, and “low fitness individuals”. If the roulette wheel selects individuals with “high fitness individuals” or “medium fitness individuals”, they are selected accordingly. In contrast to the common method in the literature, where “low fitness individuals” are directly discarded during selection and the corresponding “high fitness individuals” are selected, a 2:1 ratio is used in this paper, i.e., if “low fitness individuals” are selected, they are reselected from the “high fitness individuals” and “medium fitness individuals”. This ensures species diversity and effectively avoids local optimization. In addition, tournament selection is introduced, where a number of individuals are selected directly using a tournament selection method. This further preserves species diversity while the algorithm converges. Finally, an elite preservation strategy was introduced to prevent species degradation.

3.4.2. Double Crossover Based on Edit Distance

As populations evolve, identical chromosomes become more common, and crossover operations on identical chromosomes are ineffective and slow down the evolution of populations. Therefore, a screening process based on edit distance is applied before performing crossover operations [19]. If the edit distance between two chromosomes is too small, the crossover operation is not performed.
After the screening process, the chromosomes are sorted in ascending order based on their fitness values for single-point crossover. Specifically, two parent chromosomes are randomly selected from the population, and common genes (excluding S-points and G-points) are identified for crossover. If multiple common genes are found, any one of them is selected for crossover.
If no common genes can be found, the decision is made based on the sorting results. If the fitness value of the chromosome is in the top 60%, no crossover is performed to avoid destroying the best chromosomes and to prevent population degradation. If the fitness value of the chromosome is in the bottom 40%, a gene is randomly selected from each of the two parent chromosomes and a new "binding chromosome" is initialized between these two genes. The bonded chromosome is then used as an intermediary for the crossover operation. This enhanced crossover operation can result in pathway duplication. If a bonding chromosome is present during the crossover process, the duplicated pathway will be removed after the crossover operation. Figure 3 below shows the flowchart of the crossover operation based on edit distance.

3.4.3. Simulated Annealing Three-Stage Mutation

The main purpose of the mutation operation is to improve the local searching ability of the algorithm so that the algorithm can rid the local optimum, ensure global exploration, maintain the diversity of the population, and prevent premature convergence [20]. The traditional single-point random mutation operation often suffers from the problems of path blocking and weak local searching ability. In view of this, this paper proposes a three-step mutation strategy by combining the concept of simulated annealing on the basis of the literature [21]. Figure 4 below illustrates the improved mutation operation. Figure 5 illustrates the Improved Mutation Operation flowchart. The specific steps are as follows.
(1)
Use P m to determine whether the current chromosome should be mutated. If P m > random number r, then mutation occurs.
(2)
Randomly select two nodes P a and P b (excluding S and G points) from the parent individual W F to be mutated.
(3)
These two random points divide the parent individual W F into three segments. Reinitializing these three segments results in a mutated chromosome.
After a trisection mutation, the newly acquired chromosome must be evaluated for acceptance based on the Metropolis guidelines. If the fitness value of the new chromosome is lower than that of the old chromosome, the new chromosome is accepted. Otherwise, the acceptance of the new chromosome depends on the Metropolis policy defined below.
P = 1 , Fit new > Fit old exp ( Fit new Fit old T ) , Fit new Fit old
In Equation (12), Fit new represents the fitness value of the new chromosome, Fit old represents the fitness value of the old chromosome, and T denotes the current temperature. The calculation formula for T is given by
T = T 0 × Q Gen
In Equation (13), T0 represents the initial temperature, Q is the cooling rate, and Gen stands for the number of mutation occurrences.

3.4.4. Deletion Operator

After the mutation process, the paths generated may still require several iterations to achieve smoothing [22]. Deletion operations are necessary to refine the genetic algorithm’s chromosome [23], removing redundant nodes, speeding up population convergence, and improving algorithm efficiency. In the following example, the red dashed line represents the replanned path after the deletion operation.
(1)
First, determine if there is an obstacle between the starting point S and P 11 using the method described in [23]. If there is no obstacle (see Figure 6), connect the redundant nodes and delete them.
(2)
Next, evaluate the connectivity between S and P 17 . As shown in the figure, there is an obstacle between these two points, so P 17 is retained.
(3)
The process is repeated using P 17 as a new reference point and applying the rules from the first two steps, until the evaluation reaches the final node.

3.5. Adaptive Adjustment of Crossover and Mutation

The genetic algorithm’s convergence and optimal solution quality are affected by the crossover probability ( P ) and mutation probability ( P m ). A small P can make it difficult to generate new individuals and result in a slow search process, while a large P can disrupt the genetic model. A small P m can impede population renewal and hinder the generation of new individuals, while a large P m can lead to a lack of direction in the search process and the loss of good individuals [23]. An optimal balance between P m and P is crucial for the success of the algorithm. To address this issue, an adaptive adjustment strategy is adopted in this paper [24]. This strategy increases P and P m in the early stages to enhance the algorithm’s searching ability and decreases them in the later stages to determine the optimal individuals. The formula used for this strategy is as follows:
P c = P c 1 + P c 2 2 + P c 1 P c 2 2 sin f 1 f a v g f max f a v g π 2 , f 1 f a v g P c , f 1 < f a v g
P m = P m 1 + P m 2 2 + P m 1 P m 2 2 sin f 2 f a v g f max f a v g π 2 , f 2 f a v g P m , f 2 < f a v g
In Equations (14) and (15), P c 1 and P c 2 represent the maximum and minimum values of the crossover probability, respectively, while P m 1 and P m 2 represent the maximum and minimum values of the mutation probability, respectively. f m a x denotes the maximum fitness value in the population, f a v g represents the average fitness value in the population, f 1 is the fitness value of the individual with higher fitness during crossover and f 2 is the fitness value of the individual involved in the mutation operation.

3.6. Improved Flowchart

Figure 7 below shows a flowchart of the improved genetic algorithm of this paper.

4. Simulation and Results Analysis

4.1. Simulation Experiment

MATLAB 2020b was used to conduct path-planning simulation experiments. A comparison and analysis of the traditional genetic algorithm [25] and the Improved Genetic Algorithm proposed in this paper was performed on different scaled grid maps. Table 1 shows the specific parameters.
The starting and ending points are labeled as S and G, respectively. Here is a comparison of the three path planning results on a 30 × 30 grid map (see Figure 8, Figure 9, Figure 10, Figure 11, Figure 12, Figure 13, Figure 14, Figure 15, Figure 16, Figure 17, Figure 18, Figure 19, Figure 20 and Figure 21):
As shown in Figure 8, Figure 9 and Figure 10 and Figure 15, Figure 16 and Figure 17, the quality of the paths generated by the three algorithms improves sequentially under different scaled maps. However, the traditional genetic algorithm generates a large number of redundant nodes, unnecessary paths and too many corners after the same iteration due to its inherent limitations. The improved algorithm in reference [2] reduces the path length, but still contains excessive corners and unnecessary paths due to the fact that it does not consider the smoothness of the paths in the fitness function. In this paper, an improved algorithm is proposed to minimize the path corners, length and smoothness by increasing the initial population size, improving the adaptive function and other operations. After the same number of iterations, the IGA has the highest quality, the shortest path and the least number of corners among the three algorithms.
Comparing Figure 11 and Figure 18, it can be observed that the IGA exhibits the fastest convergence rate during the path iterations, despite the presence of more obstacles, which results in fewer feasible paths. This is due to the new initialization population operation as well as the improved crossover and mutation operations proposed in this paper. In addition, due to the use of more advanced crossover and mutation operations, IGA shows the best search capability and produces the shortest paths compared to the three different algorithms.
The three algorithms compared in Figure 12, Figure 13, Figure 19 and Figure 20 can be hit first, IGA has the best search capability and the shortest path. Therefore, IGA has the best quality. This is due to the introduction of the concept of path smoothing in this paper, which greatly reduces the number of turns at the beginning of the iteration.
Figure 14 and Figure 21 show that among the three algorithms, IGA has the best path fitness value due to the improvements made at different stages. IGA also has advantages in terms of number of iterations, path length and convergence speed compared to the algorithm in reference [2].
Here are the results of comparing the path planning algorithms on a 40 × 40 grid map:
Table 2 below shows the simulated data for different map sizes.
The simulation results and data comparison show that the traditional genetic algorithm produces poor-quality initial population results. This leads to uneven paths and too many redundant nodes, which do not effectively reduce the path length. Although the improved algorithm in reference [2] reduces the path length, it still has unnecessary turns and redundant paths. This paper proposes the Improved Genetic Algorithm (IGA), which enhances path smoothness and path length, prevents premature convergence, improves population initialization quality, and increases convergence speed.

4.2. ROS Platform Experiment

To test the improved algorithm’s practical feasibility, we conducted experiments on an omnidirectional AGV platform with Mecanum wheel drives, as shown in Figure 21.
The platform’s main components are as follows:
The industrial computer has the ROS (Robot Operating System) system installed.
The motion control uses microcontrollers, specifically the STM32F103ZET6 model with three USART interfaces, a CAN bus interface, and a 485 bus interface. Additionally, it integrates the JY901B IMU sensor.
The motors used are MOTEC’s DSEM-G series DC servo geared motors rated at 24 V with a 30.25:1 reduction ratio and integrated high-resolution encoders. These motors are used with MOTEC-CONRA series DC servo drives and support RS232 and CAN communication modes.
The power supply comes from a 100 Ah Li-FePO4 battery with an output voltage of 48 V and an operating voltage range of 40 V to 58 V. The IGAs are designed for practical evaluation purposes.
The experimental platform provides a comprehensive verification environment for evaluating the practical applicability of the IGA.
Figure 22 shows the experimental scenario, including the cost maps displayed by RVIZ. Black areas represent obstacles, while gray areas represent inflated areas. The navigation task configuration and results are presented below.
Figure 23 illustrates the experimental scenario. The AGV is passing through an obstacle in the figure.
Figure 24, Figure 25, Figure 26 and Figure 27 show that in a real-world working environment, the GA algorithm contains a large number of redundant nodes and right-angle turns, which increases the probability of collisions. In contrast, the IGA is more efficient than the previous algorithm because it has a shorter planning path and avoids redundant and nonessential turns. Table 3 indicates that the improved algorithm reduces the path length by approximately 28%, turns by about 76%, and improves the convergence speed by about 59%. Table 4 shows that the improved algorithm reduces the path length by approximately 20%, turns by approximately 84%, and improves convergence speed by approximately 58%. After conducting several experiments, the combined data indicate that the improved algorithm reduces the path length by approximately 27%, turns by approximately 63%, and improves convergence speed by approximately 58%. These results demonstrate the feasibility and stability of the improved algorithm proposed in this study.
Figure 24. GA algorithm planning path1.
Figure 24. GA algorithm planning path1.
Wevj 15 00166 g024
Figure 25. IGA algorithm planning path2.
Figure 25. IGA algorithm planning path2.
Wevj 15 00166 g025
The following is a comparison of the planned paths by the two algorithms after resetting the start and goal points following adjustments to the obstacle positions in the experimental scene:
Figure 26. GA algorithm planning path3.
Figure 26. GA algorithm planning path3.
Wevj 15 00166 g026
Figure 27. IGA algorithm planning path4.
Figure 27. IGA algorithm planning path4.
Wevj 15 00166 g027
Table 3. Comparison of Path 1 and Path 2 results.
Table 3. Comparison of Path 1 and Path 2 results.
Algorithm TypePath Length/mTurn CountConvergence Count
GA9.7462541741
IGA6.985546417
Table 4. Comparison of Path 3 and Path 4 results.
Table 4. Comparison of Path 3 and Path 4 results.
Algorithm TypePath Length/mTurn CountConvergence Count
GA12.441342538
IGA9.99693416

5. Conclusions

This paper proposes an improvement to the traditional genetic algorithm to address issues of premature convergence, excessive redundant nodes in generated paths, and slow convergence speed in path planning. A new initialization method, which combines the improved ant colony algorithm, is proposed to enhance the quality of the initial population during the population initialization process. During the selection stage, the algorithm’s searching ability is enhanced and premature convergence is prevented by fusing the roulette wheel selection method and tournament selection method. In the crossover phase, a two-layer crossover operation based on edit distance is designed to prevent ineffective crossover and improve the iteration speed of the algorithm. During the mutation stage, a new three-stage mutation operation inspired by the simulated annealing idea is proposed. This enables the algorithm to effectively escape local optima. Additionally, dynamic mutation and crossover strategies enhance the algorithm’s searching ability in the early stage and improve the determination of optimal individuals in the later stage. The software simulation results indicate that the Improved Genetic Algorithm (IGA) presented in this paper outperforms both the GA and the methods described in the literature [2] in terms of path length, path smoothness, turn freedom, and algorithm convergence speed. Practical experiments on the ROS experimental platform have shown that the path generated by the IGA algorithm can effectively control the algorithm to avoid falling into a local optimum and improve the convergence speed compared to the traditional GA algorithm while ensuring the shortest path.

Author Contributions

Conceptualization, Q.N. and Y.F.; investigation, Y.F.; methodology, Q.N. and Y.F.; project administration, Y.F.; resources, Y.F.; software, Y.F. and X.D.; supervision, Q.N.; validation, Q.N.; writing—original draft, Y.F and X.D.; writing—review and editing, Y.F. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Data Availability Statement

The original contributions presented in the study are included in the article, further inquiries can be directed to the corresponding author.

Conflicts of Interest

The authors declare no conflicts of interest.

References

  1. Chen, Y.; Lin, Q.; Deng, Z.; Chen, G. Research Progress on AGV Path Planning Algorithms. J. Mech. Electr. Technol. 2022, 2022, 39–43. [Google Scholar] [CrossRef]
  2. Wang, L.; Li, M. Application of Improved Adaptive Genetic Algorithm in Mobile Robot Path Planning. J. Nanjing Univ. Sci. Technol. 2017, 41, 627–633. [Google Scholar] [CrossRef]
  3. Zhu, D.; Yan, M. Overview of Mobile Robot Path Planning Technology. Control Decis. 2010, 25, 961–967. [Google Scholar] [CrossRef]
  4. Tian, X.; Liu, G.; Zhou, W.; Guo, K. Research on Robot Path Planning Based on Improved Adaptive Genetic Algorithm. Mach. Tool Hydraul. 2016, 44, 24–28+62. [Google Scholar]
  5. Li, Y.; Wan, Y.; Zhang, Y.; Kuang, H. Warehouse Robot Path Planning Based on Artificial Bee Colony—Adaptive Genetic Algorithm. J. Instrum. Meas. 2022, 43, 282–290. [Google Scholar] [CrossRef]
  6. Qiao, S.; Wu, Y.; Zhang, J.; Shi, G. Path Planning Based on Genetic Algorithm and Artificial Potential Field. Mod. Electron. Tech. 2012, 35, 75–78. [Google Scholar] [CrossRef]
  7. Liu, E.; Yao, X.; Lan, H.; Jin, H. Dynamic Path Planning and Implementation of Automatic Guided Vehicle Based on Improved Genetic Algorithm. Comput. Integr. Manuf. Syst. 2018, 24, 1455–1467. [Google Scholar] [CrossRef]
  8. Xu, M.; Wang, J.; Liu, B.; Ma, L.; Chai, L.; Xiang, L.; Zhou, J. Robot Path Planning Based on Improved Genetic Algorithm. J. Shihezi Univ. (Nat. Sci.) 2021, 39, 391–396. [Google Scholar] [CrossRef]
  9. Akopov, A.S.; Beklaryan, L.A.; Beklaryan, A.L. Simulation-Based Optimisation for Autonomous Transportation Systems Using a Parallel Real-Coded Genetic Algorithm with Scalable Nonuniform Mutation. Cybern. Inf. Technol. 2021, 21, 127–144. [Google Scholar] [CrossRef]
  10. Zhou, R.; Liu, Y.; Zhang, K.; Yang, O. Genetic Algorithm-Based Challenging Scenarios Generation for Autonomous Vehicle Testing. IEEE J. Radio Freq. Identif. 2022, 6, 928–933. [Google Scholar] [CrossRef]
  11. Chaymaa, L.; Said, B.; Ali, E. Genetic Algorithm Based Approach for Autonomous Mobile Robot Path Planning. Procedia Comput. Sci. 2019, 127, 180–189. [Google Scholar]
  12. Chen, X.; Li, Y.; Xiao, S. Optimization of Fresh Agricultural Products Logistics Distribution Path Based on Improved Genetic Algorithm. J. Dalian Jiaotong Univ. 2022, 43, 97–102+111. [Google Scholar] [CrossRef]
  13. Li, Y.; Dong, D.; Guo, X. Mobile robot path planning based on improved genetic algorithm with A-star heuristic method. In Proceedings of the 2020 IEEE 9th Joint International Information Technology and Artificial Intelligence Conference (ITAIC), Chongqing, China, 11–13 December 2020; Volume 9. [Google Scholar]
  14. Zhao, J. Research on Ant Colony Optimization Algorithm for Mobile Robot Path Planning. Doctoral Dissertation, Northeastern University, Boston, MA, USA, 2012. [Google Scholar]
  15. Wang, J.; Wang, X.; Tian, Q.; Sun, A.; Zhang, X.; Yuan, L. Robot Path Planning Based on Improved Fuzzy Adaptive Genetic Algorithm. Mach. Tool Hydraul. 2021, 49, 18–23. [Google Scholar]
  16. Niu, Q.; Li, B. Path Planning of Omnidirectional AGV Based on Simulated Annealing Genetic Algorithm. Comput. Integr. Manuf. Syst. 2023, 1–21. Available online: http://kns.cnki.net/kcms/detail/11.5946.TP.20220517.1105.014.html (accessed on 25 May 2023).
  17. Niu, Q.; Dong, X.; Fu, Y. Improved AGV Path Planning Based on Ant Colony Algorithm Heuristic Strategy. J. Comput. Integr. Manuf. Syst. 2024, 1–19. [Google Scholar] [CrossRef]
  18. Levenshtein, V. Binary codes capable of correcting deletions, insertions, and reversals. Sov. Phys. Dokl. 1966, 10, 707–710. [Google Scholar]
  19. Cao, J.; Zhu, R. A Genetic Algorithm Based on Adaptive Operators and Migration Strategy. Mech. Sci. Technol. 2003, 2003, 64–66. [Google Scholar]
  20. Xu, X.; Yu, X.; Zhao, Y.; Liu, C.; Wu, X. Global Path Planning of Mobile Robot Based on Improved Genetic Algorithm. Comput. Integr. Manuf. Syst. 2022, 28, 1659–1672. [Google Scholar] [CrossRef]
  21. Chang, J.; Ren, Y. Robot Path Planning Based on Improved Genetic Algorithm. Mod. Mach. Autom. Technol. 2023, 2023, 23–27. [Google Scholar] [CrossRef]
  22. Zhang, Z.; Ke, Z.; Zhou, J.; Qian, Q.; Hu, X. Robot Path Planning Based on Improved Multi-objective Adaptive Genetic Algorithm. J. Xi’an Univ. Technol. 2023, 69–78. Available online: http://kns.cnki.net/kcms/detail/61.1294.N.20221012.1019.002.html (accessed on 18 August 2023).
  23. Xu, L.; Liu, Y.; Wang, Q. Application of Adaptive Genetic Algorithm in Robot Path Planning. Comput. Eng. Appl. 2020, 56, 36–41. [Google Scholar]
  24. Hu, C.; Feng, W. Optimization of Mobile Robot Path Based on Improved Adaptive Genetic Algorithm. J. Lanzhou Univ. Technol. 2011, 37, 41–45. [Google Scholar]
  25. Zhang, X. Mobile Robot Path Planning Based on Genetic Algorithm. Master’s Thesis, Xi’an University of Architecture and Technology, Xi’an, China, 2014. [Google Scholar]
Figure 1. Genetic algorithm robot motion trajectory.
Figure 1. Genetic algorithm robot motion trajectory.
Wevj 15 00166 g001
Figure 2. Population initialization.
Figure 2. Population initialization.
Wevj 15 00166 g002
Figure 3. Flowchart of cross-operations based on edit distance.
Figure 3. Flowchart of cross-operations based on edit distance.
Wevj 15 00166 g003
Figure 4. Improved variant operation.
Figure 4. Improved variant operation.
Wevj 15 00166 g004
Figure 5. Improved variant operation flowchart.
Figure 5. Improved variant operation flowchart.
Wevj 15 00166 g005
Figure 6. Delete the road map before and after the operation is processed.
Figure 6. Delete the road map before and after the operation is processed.
Wevj 15 00166 g006
Figure 7. Flowchart for improving the algorithm.
Figure 7. Flowchart for improving the algorithm.
Wevj 15 00166 g007
Figure 8. GA algorithm planning path under 30 × 30 map.
Figure 8. GA algorithm planning path under 30 × 30 map.
Wevj 15 00166 g008
Figure 9. Ref. [2] algorithm planning path under 30 × 30 map.
Figure 9. Ref. [2] algorithm planning path under 30 × 30 map.
Wevj 15 00166 g009
Figure 10. IGA algorithm path planning under 30 × 30 map.
Figure 10. IGA algorithm path planning under 30 × 30 map.
Wevj 15 00166 g010
Figure 11. Comparison of path length iterations under 30 × 30 map.
Figure 11. Comparison of path length iterations under 30 × 30 map.
Wevj 15 00166 g011
Figure 12. Iterative comparison chart of the number of turns under 30 × 30 map.
Figure 12. Iterative comparison chart of the number of turns under 30 × 30 map.
Wevj 15 00166 g012
Figure 13. Smoothness iteration comparison chart under 30 × 30 map.
Figure 13. Smoothness iteration comparison chart under 30 × 30 map.
Wevj 15 00166 g013
Figure 14. Fitness iteration comparison chart under 30 × 30 map.
Figure 14. Fitness iteration comparison chart under 30 × 30 map.
Wevj 15 00166 g014
Figure 15. The GA algorithm plans the path under 40 × 40 map.
Figure 15. The GA algorithm plans the path under 40 × 40 map.
Wevj 15 00166 g015
Figure 16. Ref. [2] algorithm planning path under 40 × 40 map.
Figure 16. Ref. [2] algorithm planning path under 40 × 40 map.
Wevj 15 00166 g016
Figure 17. IGA algorithm path planning under 40 × 40 map.
Figure 17. IGA algorithm path planning under 40 × 40 map.
Wevj 15 00166 g017
Figure 18. Path length iteration comparison chart under 40 × 40 map.
Figure 18. Path length iteration comparison chart under 40 × 40 map.
Wevj 15 00166 g018
Figure 19. Iteration comparison chart of the number of turns under 40 × 40 map.
Figure 19. Iteration comparison chart of the number of turns under 40 × 40 map.
Wevj 15 00166 g019
Figure 20. Smoothness iteration comparison chart under 40 × 40 map.
Figure 20. Smoothness iteration comparison chart under 40 × 40 map.
Wevj 15 00166 g020
Figure 21. Fitness iteration comparison chart under 40 × 40 map.
Figure 21. Fitness iteration comparison chart under 40 × 40 map.
Wevj 15 00166 g021
Figure 22. Omnidirectional AGV experimental platform.
Figure 22. Omnidirectional AGV experimental platform.
Wevj 15 00166 g022
Figure 23. Experimental scene.
Figure 23. Experimental scene.
Wevj 15 00166 g023
Table 1. Simulation parameters.
Table 1. Simulation parameters.
Parameter NameParameter ValueParameter NameParameter Value
Number of populations200Grid size1 m × 1 m
Maximum crossover probability0.9Minimum crossover probability0.6
Maximum probability of variation0.2Minimum probability of variation0.005
Maximum number of iterations100Cooling rate0.9
Starting temperature300Termination temperature0
Table 2. Statistics of simulation results in maps of different scales.
Table 2. Statistics of simulation results in maps of different scales.
Map SizeThe Type of AlgorithmPath Length/mPath Angle/ ° Number of Turns
Average ValueOptimumAverage ValueOptimumAverage ValueOptimum
10 × 10GA15.285314.48523923608.28
[2]14.923714.48523813608.28
IGA14.634514.26242131274.23
20 × 20GA30.106429.799062958513.413
[2]29.446328.899559449512.811
IGA28.095427.8147316207108
30 × 30GA46.195545.1127104794522.421
[2]44.526944.52698027651717
IGA44.658144.4910289847.23
40 × 40GA68.188666.911778372016.916
[2]65.946065.941172872016.1916
IGA65.895365.82784693499.78
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Niu, Q.; Fu, Y.; Dong, X. Omnidirectional AGV Path Planning Based on Improved Genetic Algorithm. World Electr. Veh. J. 2024, 15, 166. https://doi.org/10.3390/wevj15040166

AMA Style

Niu Q, Fu Y, Dong X. Omnidirectional AGV Path Planning Based on Improved Genetic Algorithm. World Electric Vehicle Journal. 2024; 15(4):166. https://doi.org/10.3390/wevj15040166

Chicago/Turabian Style

Niu, Qinyu, Yao Fu, and Xinwei Dong. 2024. "Omnidirectional AGV Path Planning Based on Improved Genetic Algorithm" World Electric Vehicle Journal 15, no. 4: 166. https://doi.org/10.3390/wevj15040166

Article Metrics

Back to TopTop