pyrobosim.navigation.rrt.RRTPlannerPolygon.rewire_node

RRTPlannerPolygon.rewire_node(graph, n_tgt)

Rewires a node in the RRT by checking if switching the parent node to another nearby node will reduce its total cost from the root node.

This is the key modification in the RRT* algorithm which requires more computation, but produces paths that are shorter and smoother than plain RRT. The vicinity around the node is defined by the rewire_radius parameter.

Parameters: