Mobile robot path planning method based on Dsl _ GA algorithm

文档序号:849053 发布日期:2021-03-16 浏览:2次 中文

阅读说明:本技术 一种基于Dsl_GA算法的移动机器人路径规划方法 (Mobile robot path planning method based on Dsl _ GA algorithm ) 是由 路瑞 张兆军 赵明龙 于 2020-11-06 设计创作,主要内容包括:一种基于Dsl_GA算法的移动机器人路径规划方法,包括采用栅格法对移动机器人的工作环境进行建模;使用实数编码和二维坐标法对自由栅格进行编码;随机选取自由栅格作为路径的中间节点,再利用Dstar_lite算法补齐起始节点、中间节点、终止节点之间的路径,从而形成一条从起始节点到终止节点不经过任何障碍物的可行连续路径;设置欧式距离为适应度函数;采用锦标赛选择法和最优保护策略作为选择操作、算术交叉、随机变异的方式对初始化种群进行遗传操作;最后通过仿真实验表明本文提出算法的有效性和可行性。本发明增加了生成路径的可行性,为解决路径规划问题提供了新的思路。(A mobile robot path planning method based on Dsl _ GA algorithm comprises the steps of adopting a grid method to model the working environment of a mobile robot; coding the free grid by using a real number coding method and a two-dimensional coordinate method; randomly selecting a free grid as an intermediate node of a path, and then filling the paths among the starting node, the intermediate node and the terminating node by using a Dstar _ lite algorithm, thereby forming a feasible continuous path from the starting node to the terminating node without passing through any barrier; setting the Euclidean distance as a fitness function; adopting a championship selection method and an optimal protection strategy as selection operation, arithmetic crossover and random variation modes to carry out genetic operation on the initialized population; finally, the effectiveness and feasibility of the algorithm provided by the method are shown through simulation experiments. The invention increases the feasibility of generating the path and provides a new idea for solving the path planning problem.)

1. A mobile robot path planning method based on Dsl _ GA algorithm is characterized by comprising the following steps:

s1: modeling the working environment of the mobile robot by adopting a grid method;

s2: numbering the free grids from bottom to top and from left to right by using a real number coding and two-dimensional coordinate method;

s3: setting initialization parameters; setting a starting point, a terminal point, a population number, iteration times, a ditch, a cross rate, a variation rate and the number of intermediate nodes of the mobile robot;

s4: randomly generating an initialization population and generating an initial path;

s5: calculating a fitness value;

s6: executing selection operation, and updating the intermediate node generated by the initialized population;

s7: executing cross operation, and updating the intermediate node generated by the selection operation;

s8: performing mutation operation, and updating the intermediate node generated by the cross operation;

s9: and judging whether the maximum iteration times is reached, if so, stopping searching, and outputting a global optimal path, otherwise, jumping to S5 for the next iteration.

2. The mobile robot path planning method based on the Dsl _ GA algorithm of claim 1, wherein the grid method modeling of step S1 is specifically:

dividing the working environment of the robot into a series of grids with equal size, wherein the black grids represent obstacles and the robot cannot pass through; the white grid represents a free grid through which the robot can pass.

3. The mobile robot path planning method based on the Dsl _ GA algorithm of claim 1, wherein the generating of the initial path in step S4 specifically includes:

firstly, randomly selecting num free grids between a starting point and an end point as intermediate nodes by using a formula (1) (2), and then, filling paths between the starting point, the num intermediate nodes and the end point by using a Dstar _ lite algorithm so as to generate a feasible and continuous path from the starting point to the end point without passing through any obstacle;

Node=[Node1,Node2,…Nodenum] (1)

node represents the grid serial number corresponding to the intermediate Node which can be generated, and num represents the number of the intermediate nodes which can be generated;

wherein A, B represents the minimum and maximum values of the grid serial numbers corresponding to the intermediate nodes that can be generated, and r represents a value of [0,1]]A random number within the range of the random number,to round down.

4. The mobile robot path planning method based on the Dsl _ GA algorithm of claim 1, wherein the fitness function in step S5 is specifically:

wherein (x)i,yi)、(xi+1,yi+1) Respectively representing the coordinates of two points.

5. The method for planning a path of a mobile robot based on Dsl _ GA algorithm of claim 1, wherein the selecting operation in step S6 is specifically:

and adopting a championship selection method and an optimal protection strategy as selection operation.

6. The mobile robot path planning method based on the Dsl _ GA algorithm of claim 1, wherein the interleaving operation in step S7 specifically includes:

the method adopts arithmetic intersection, and the intersection formula is as follows:

wherein, Nodey1、Nodey2Respectively representing the crossed individuals, Nodex1And Nodex2Respectively representing superior parent individuals and poor parent individuals, and K is [0,0.5 ]]Any number within the interval of time,to round down.

7. The method for planning a path of a mobile robot based on Dsl _ GA algorithm of claim 1, wherein the variation operation in step S8 is specifically:

the variation formula is as follows:

wherein, Node1、Node2Respectively representing individuals before and after intersection, A, B respectively representing the minimum value and the maximum value of the grid serial numbers corresponding to the nodes capable of generating the intermediate nodes, and r is [0,1]]A random number within the range of the random number,to round down.

Technical Field

The invention belongs to the field of robots, and relates to a mobile robot path planning method based on a Dsl _ GA algorithm.

Background

With the rapid development of scientific technology, optimization methods have been successfully applied in the fields of automatic control, image processing, combinatorial optimization, data mining, national defense and military, artificial intelligence, transportation, electronic science, and the like. Many experts at home and abroad inspire from nature and bionics, and a series of group intelligent optimization algorithms are provided, which comprise: ant colony algorithm, particle swarm algorithm, genetic algorithm, cuckoo algorithm, wolf colony algorithm and the like. The ant colony algorithm has strong robustness in solving performance, but has the defects of overlarge calculated amount, overlong searching time and the like; the particle swarm algorithm is long used for solving continuous problems, but is easy to fall into local optimization, and the local optimization capability is poor.

Since the 60's of the last century, many scholars began the study of robots. Until now, robots have been successfully applied to various fields such as transportation, industrial production, medical treatment, artificial intelligence, and the like. The robot path planning is an important link of the robot, and the aim of the robot path planning is to find a feasible path from a starting node to an ending node without any obstacles. The research on the robot path planning is always an important content in the field of robots at home and abroad. From the current research results, the population intelligent optimization algorithm represented by genetic algorithm, ant colony algorithm and particle swarm algorithm is applied to the field of robot path planning, and good progress is achieved.

The genetic algorithm is one of the main algorithms of the group intelligent optimization algorithm. Compared with other algorithms, the genetic algorithm can search from a plurality of initial solutions by virtue of the algorithm, is easy to jump out local optima, has better capability of searching for the optimal solution globally, is naturally parallel and is widely applied to the robot path planning problem.

Disclosure of Invention

The invention aims to provide a mobile robot path planning method based on a Dsl _ GA algorithm. The algorithm randomly generates initial populations with different fitness degrees by combining randomly selected free grids and a Dstar _ lite algorithm, and then optimizes the initial populations through a championship selection method, an optimal protection strategy, arithmetic intersection and random variation to obtain an optimal path from a starting point to a terminal point without any obstacle, so that the feasibility of generating the path is increased, and a new solution is provided for solving the path planning problem of the mobile robot.

The technical scheme adopted by the invention is as follows: a mobile robot path planning method based on Dsl _ GA algorithm comprises the following steps:

s1: the invention adopts a grid method to model the working environment of the mobile robot;

s2: numbering free grids by using a real number coding and two-dimensional coordinate method according to the sequence from bottom to top and from left to right;

s3: and setting initialization parameters. Setting a starting point, a terminal point, a population number, iteration times, a ditch, a cross rate, a variation rate and the number of intermediate nodes of the mobile robot;

s4: randomly generating an initialization population and generating an initial path;

s5: calculating a fitness value;

s6: executing selection operation, and updating the intermediate node generated by the initialized population;

s7: executing cross operation, and updating the intermediate node generated by the selection operation;

s8: performing mutation operation, and updating the intermediate node generated by the cross operation;

s9: and judging whether the maximum iteration times is reached, if so, stopping searching, and outputting a global optimal path, otherwise, jumping to S5 for the next iteration.

The mobile robot path planning method based on the Dsl _ GA algorithm of claim 1, wherein the grid method modeling of step S1 is specifically:

dividing the working environment of the robot into a series of grids with equal size, wherein the black grids represent obstacles and the robot cannot pass through; the white grid represents a free grid through which the robot can pass.

The mobile robot path planning method based on the Dsl _ GA algorithm of claim 1, wherein the generating of the initial path in step S4 specifically includes:

firstly, num free grids are randomly selected between a starting point and an end point by using the formula (1) and (2) to serve as intermediate nodes, then paths between the starting point and the num intermediate nodes and between the end points are completed by using a Dstar _ lite algorithm, and finally a feasible and continuous path which does not pass through any obstacle from the starting point to the end point is generated.

Node=[Node1,Node2,…Nodenum] (7)

Node represents the grid serial number corresponding to the intermediate Node capable of being generated, and num represents the number of the intermediate nodes capable of being generated.

A, B represents the minimum and maximum values of the grid serial numbers corresponding to the intermediate nodes that can be generated, and r represents a value of [0,1]]A random number within the range of the random number,to round down.

The mobile robot path planning method based on the Dsl _ GA algorithm of claim 1, wherein the fitness function in step S5 is specifically:

wherein (x)i,yi)、(xi+1,yi+1) Respectively representing the coordinates of two points.

The method for planning a path of a mobile robot based on Dsl _ GA algorithm of claim 1, wherein the selecting operation in step S6 is specifically:

the invention adopts a championship selection method and an optimal protection strategy as selection operation.

The mobile robot path planning method based on the Dsl _ GA algorithm of claim 1, wherein the interleaving operation in step S7 specifically includes:

the invention adopts arithmetic crossover, and the crossover formula is as follows:

wherein, Nodey1、Nodey2Respectively representing the crossed individuals, Nodex1And Nodex2Respectively represents a superior parent individual and a poor parent individual, and K is [0,0.5 ]]The random number within the interval is a random number,to round down.

The method for planning a path of a mobile robot based on Dsl _ GA algorithm of claim 1, wherein the variation operation in step S8 is specifically:

the invention adopts random variation, and the variation formula is as follows:

wherein, Node1、Node2Respectively representing individuals before and after intersection, A, B respectively representing the minimum value and the maximum value of the grid serial numbers corresponding to the nodes capable of generating the intermediate nodes, and r is [0,1]]A random number within the range of the random number,to round down.

Compared with the prior art, the invention has the beneficial effects that:

in order to ensure the feasibility of generating a path, on one hand, the invention selects a free grid as an intermediate node, thereby ensuring the feasibility of generating the node; and on the other hand, the Dstar _ lite algorithm is adopted, so that the feasibility of generating the path is ensured.

The invention can realize that the mobile robot can find a feasible continuous path from the starting point to the end point in the grid environment.

Drawings

FIG. 1 is a general flow chart of the mobile robot path planning based on Dsl _ GA algorithm of the present invention;

FIG. 2 is a schematic diagram of path planning in a 15 × 15 grid environment according to an embodiment of the present invention;

FIG. 3 is a graph of 10 independent runs of an average fitness function in a 15 × 15 grid environment according to an embodiment of the present invention;

FIG. 4 is a schematic diagram of path planning in a 25 × 25 grid environment according to an embodiment of the present invention;

FIG. 5 is a graph of an average fitness function of 10 independent runs in a 25 × 25 grid environment according to an embodiment of the present invention;

Detailed Description

For the convenience of understanding, the technical solutions in the embodiments of the present invention will be described in detail in the following with reference to the accompanying drawings in the embodiments of the present invention. The described embodiments are only some of the embodiments of the present invention.

As shown in fig. 1, a mobile robot path planning method based on Dsl _ GA algorithm mainly includes the following steps:

s1: the algorithm adopts a grid method to model the working environment of the mobile robot, and specifically comprises the following steps:

dividing the working environment of the robot into a series of grids with equal size, wherein the black grids represent obstacles and the robot cannot pass through; the white grid represents a free grid through which the robot can pass.

S2: the algorithm numbers the free grids by using a real number coding and a two-dimensional coordinate method according to the sequence from bottom to top and from left to right;

s3: and setting initialization parameters. Setting a starting point, a terminal point, a population number, iteration times, a ditch, a cross rate, a variation rate and the number of intermediate nodes of the mobile robot;

s4: randomly generating an initialization population and generating an initial path, specifically:

firstly, num free grids are randomly selected between a starting point and an end point by using the formula (1) and (2) to serve as intermediate nodes, then paths between the starting point and the num intermediate nodes and between the end points are completed by using a Dstar _ lite algorithm, and finally a feasible continuous path which does not pass through any obstacle from the starting point to the end point is generated.

Node=[Node1,Node2,…Nodenum] (13)

Node represents the grid serial number corresponding to the intermediate Node capable of being generated, and num represents the number of the intermediate nodes capable of being generated.

Node=A+r×(B-A) (14)

A, B represents the minimum and maximum values of the grid numbers corresponding to the intermediate nodes, and r represents a random number in the range of [0,1 ].

S5: calculating a fitness value;

wherein (x)i,yi)、(xi+1,yi+1) Respectively representing the coordinates of two points.

S6: executing selection operation, and updating the intermediate node generated by the initialized population;

the invention adopts a championship selection method and an optimal protection strategy as selection operation.

S7: executing cross operation, and updating the intermediate node generated by the selection operation;

the invention adopts arithmetic crossover, and the crossover formula is as follows:

wherein, Nodey1、Nodey2Respectively representing the crossed individuals, Nodex1And Nodex2Respectively representing superior parent individuals and poor parent individuals, and K is [0,0.5 ]]Any number within the interval.

S8: performing mutation operation, and updating the intermediate node generated by the cross operation;

the invention adopts random variation, and the variation formula is as follows:

wherein, Node1、Node2Respectively representing individuals before and after intersection, A, B respectively representing the minimum value and the maximum value of the grid serial numbers corresponding to the nodes capable of generating the intermediate nodes, and r is [0,1]]Random numbers within a range.

S9: and judging whether the maximum iteration times is reached, if so, stopping searching, and outputting a global optimal path, otherwise, jumping to S5 for the next iteration.

In order to verify the effectiveness of the improved algorithm, simulation experiments are respectively carried out on grid maps of 15 × 15 and 25 × 25 by using the improved algorithm provided by the invention, and the compiling environment of a program is MATLAB R2020. The experimental results are shown in fig. 2, 3, 4 and 5.

As can be seen from fig. 2 and 4, according to the mobile robot path planning method based on the Dsl _ GA algorithm provided by the present invention, the feasible optimal path with the shortest path length can be found on both 15 × 15 and 25 × 25 grid maps, and the corresponding fitness function values are 22.1421 and 38.0416m, respectively. Fig. (3) and (5) show the variation curves of the average fitness function in the grid maps of 15 × 15 and 25 × 25 according to the invention with the increase of the number of iterations. Wherein, the abscissa represents the iteration times, and the ordinate represents the average value of the fitness function after 10 experiments.

As can be seen from fig. 3 and 5, in the mobile robot path planning method based on the Dsl _ GA algorithm provided by the present invention, in the 15 × 15 grid map, in the initial stage of iteration, the fitness function starts to fall into the local optimum, and as the iteration progresses, the fitness function value starts to converge to the global optimum around 56 generations. In a 25 × 25 grid map, the fitness function starts to fall into a local optimum in the early stage of iteration, and as the iteration progresses, the fitness function value starts to converge to a global optimum around 48 generations. The effectiveness of the mobile robot path planning method based on the Dsl _ GA algorithm in solving the path planning problem is demonstrated. In addition, the invention provides a new idea for solving the problem of path planning.

While the present invention has been described in detail with reference to the embodiments shown in the drawings, the present invention is not limited to the embodiments, and various changes can be made without departing from the spirit and scope of the present invention.

10页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种基于级联卡尔曼滤波算法的水面舰船水平姿态测量方法

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!