Ask HN: Have you ever seen a pathfinding algorithm of this type?
blog.breathingworld.com
Ask HN: Have you ever seen a pathfinding algorithm of this type?
1–10 of 77 posts
Re: Ask HN: Have you ever seen a pathfinding algorithm of this type?
#2Re: Ask HN: Have you ever seen a pathfinding algorithm of this type?
#3Re: Ask HN: Have you ever seen a pathfinding algorithm of this type?
#4I think that the problem with A* is that it use a mix of horizontal and vertical and 45° lines, but your proposal makes more natural straigh lines. I think it's more nice, but don't think it's more efficient (but I don't have a hard proof).
PS: The guidelines ask to use the original title. https://news.ycombinator.com/newsguidelines.html
Re: Ask HN: Have you ever seen a pathfinding algorithm of this type?
#5Is this faster than A*? I think that the problem with A* is that it use a mix of horizontal and vertical and 45° lines, but your proposal makes more natural straigh lines. I think it's more nice, but don't think it's more efficient (but I don't have a hard proof). PS: The guidelines ask to use the original title. https://news.ycombinator.com/newsguidelines.html
Re: Ask HN: Have you ever seen a pathfinding algorithm of this type?
#6Re: Ask HN: Have you ever seen a pathfinding algorithm of this type?
#7this looks to be solving a different problem than A*, which operates over discrete graphs. this looks to be operating in 2D continuous space instead.
so, what is the algorithm for finding the optimal point on the obstacle's outline for bypass (4)? is it finding the point on the outline nearest the destination?
then, how do you subsequently "backtrack" to a different bypass point on the obstacle if the first choice of bypass point doesn't work out?
there's something interesting here for trying to directly operate on 2D space rather than discretizing it into a graph, but I'm curious how the details shake out.
Re: Ask HN: Have you ever seen a pathfinding algorithm of this type?
#8This is still technically A* if you squint. The straight line is like using a eulicdean heuristic. The "optimal point" is just an abstracted way of navigating around obstacles.
The main thing you lose is that your path is no longer guaranteed to be optimal or guaranteed to be found if a solution exists. This was a problem I encountered, but I was trying to pathfind in a dynamic environment.
If your environment is static, you're better off just doing a pre-processing step where you divide your world into chunks of terrain. Maybe by using a flood fill algorithm and breaking off chunks when they reach the size of 100 tiles. Then you can maintain a graph that tells you if you can traverse from one chunk to another.
Your pathfinding over large distances would consist of an A* search on the graph of pre-computed chunks, and another A* search from your current chunk->next chunk.
Re: Ask HN: Have you ever seen a pathfinding algorithm of this type?
#9It seems like this would do OK for open areas with a few simple obstructions. I'm not sure how it would do if there were complex obstructions. For instance, it's unclear how it would work if you were trying to pathfind through a maze.