- Breadth-first searches begin the search at the root directory or requested start directory. The algorithm identifies the next nodes on the tree and identifies the shortest paths between nodes. If the solution is not found, the breadth-first search scans the branches under each of those nodes. Breadth-first searches do not save the path based tree searching results as the search is performed. According to “Algorithms Unplugged” by Berthold Vöcking, “breadth-first search is not applicable for searching a labyrinth. One cannot simply note a junction on a list and jump to it on demand.”
- Depth-first searches search the path of a tree as deep as it goes. Once the end of a branch is reached, the algorithm moves back to the nearest child node and searches its children. “Algorithms in a Nutshell” says “the heart of the depth-first search is a recursive dfs_visit(u) operation, which visits a vertex u that previously has not been visited before.” After all paths of a tree branch are searched, the search algorithm returns to the top of the tree structure and identifies another node to search.
- The Greedy Randomized Adaptive Search Procedure (GRASP) heuristic search method begins by searching randomly for the best match. The heuristic builds a list of likely search candidates. The GRASP heuristic saves partial searches and their path in the tree structure. The algorithm searches the candidate list iteratively. The search method traces the path of each branch of the folders of candidates identified to find the best answer to the search query.
- Integer Linear Programming (ILP) merges tree and path-based searching methods. According to “The Compiler Design Handbook,” “it allows (limited) integration of infeasible path information while (often) being much less expensive than the path-based approaches.” Boolean searches can be performed within ILP searches. Path based tree searching of likely candidates from the Boolean search can be used to identify the best search candidates. Branch and bound searches in ILP cut nonoptimal results too far from the optimal result. Branch and cut searches in ILP identify possible matches and add additional search criteria to cut the weakest search results.
Breadth-First Search
Depth-First Search
GRASP Heuristic
Integer Linear Programming
SHARE