Path finding Algorithms : A* Vs Jump Point Search

夙愿已清 提交于 2019-12-22 04:31:43

问题


I know that A* is better than Dijkstra's algorithm because it takes heuristic values into account, but from A* and Jump Point search which is the most efficient algorithm for finding the shortest path in an environment with obstacles? and what are the differences?


回答1:


Jump Point Search is an improved A* based on some conditions on the graph. Thus, if you meet these conditions (uniform-cost grid mostly), JPS is strictly better than A* (same optimality, best cases can be order of magnitudes better and worse case is probably the same complexity but with a slightly worse constant), but if you do not meet the conditions, you cannot use it.

The improvements of JPS over A* is basically, if you have a graph with an uniform cost function (it costs the same to go from A to B and from B to C, in the same direction), you can skip some steps in some cases and go directly from A to C without expanding nodes in B.

JPS is a pruning technique over A*, you remove cases you do not need to evaluate, because you know they will be sub-optimal. You know this because of the uniform-cost grid condition.
Conceptually, this is equivalent to using A* over a non uniform grid, where neighbouring nodes represent how far you can go in that direction without encountering an obstacle, with the cost of the jump you performed. So if you can go 10 nodes on the right without encountering an obstacle, you can reduce this (or jump directly to) a single node with a cost of 10*c, where c is the (constant) cost to go from one node to another on the right.

The original paper can be found here.



来源:https://stackoverflow.com/questions/43639533/path-finding-algorithms-a-vs-jump-point-search

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!