This is a collection of my implementation of robotic 2D path planning algorithms in c++.
This repo shows each algo individually.
For a more complete navigation module, please check my this repo navigation_package_V1 .
Using only C++ standard libraries for algorithms, and OpenCV for visulization.
Methods in progress:
- LPA*
- Reeds-shepp (code done, need to make GIF)
- Potential field
update some of the GIFs, since they were recorded with a very early version of code, which may casue non-optimal solution.
(The code has been updated, but GIFs need re-recording)
Each of the demo contains 5 samples played in sequence.
They are using tasks with identical start/goal position.
After the first path is found, the robot starts moveing along the path.
The path is shown as orange line.
Some obstacles are added into the map while the robot is moving.
When the next step is blocked, it stops and looks for a new path to the goal.
The green line is the path during replanning; the new valid path is orange line.
This sample is using Manhattan distance as h-cost.
(I will update the GIF later)
This sample is using Euclidean distance as the primary source of h-cost.
Then modify the h-cost based on the motion direction, steer, and priximity to obstacle.
The g-cost is the same as A-star.
Both position and direction are considered.
This sample assume that the motion model contains only forward motion.
This algo is based on the paper
"Classification of the Dubins set"
by Andrei M. Shkel, Vladimir Lumelsky.
The types of curves being tried are listed at the top left corner of gif; and their costs are printed as well.
Those 2 black shart lines are the current pose and target pose.
Max sample number: 1000
The final path is much smoother than RRT above.