leftmost leaf node with the smallest heuristic value”). After this, the search tree
has the form displayed in Figure 11.12.
The heuristic value of the leftmost leaf node is now five, indicating that this
branch is perhaps not a good choice to pursue after all. The algorithm picks up
on this and in the next pass through the while statement instructs us to expand
the tree from the rightmost node (which now is the “leftmost leaf node with the
smallest heuristic value”). Having been expanded in this fashion, the search tree
appears as in Figure 11.13.
At this point the algorithm seems to be on the right track. Because the heuristic
value of this last node is only three, the while statement instructs us to continue pursuing this path, and the search focuses toward the goal, producing the search
tree appearing in Figure 11.14. Comparing this with the tree in Figure 11.7 shows
that, even with the temporary wrong turn taken early on by the new algorithm,
the use of heuristic information has greatly decreased the size of the search tree
and produced a much more efficient process.