PRM Pseudocode

1: Generate a set of n configurations in free space S from some distribution

2: Let G = f, ethe empty graph on S.

3: for each configuration siÎS do

4: Find k neighbors for si, Nk(si)

5: for each configuration siÎNk(si) do

6: if j > i and the local planner can find a collision-free path from si to sj

7: then

8: add an edge (i,j) in G.

9: end if

10: end for

11: end for

12: return the graph G and the set S.