Skip to main content
. 2021 Feb 6;21(4):1152. doi: 10.3390/s21041152
Algorithm 3 PruneTree

Input:

q : State

O : Obstacles

  •     1:

    procedure PruneTree

  •     2:

        if Valid(q,O) then

  •     3:

            for each q^qoffsprings do

  •     4:

               PruneTree(q^,O)

  •     5:

            end for

  •     6:

        else

  •     7:

            DeleteState(q)            ▹ Delete state q (and all offsprings recursively) from tree

  •     8:

        end if

  •     9:

    end procedure