1 / 12

Lecture Notes 2

Lecture Notes 2. Prof. Dechter ICS 270A Winter 2003. Explicit Graph. Graph Theory. Sates: board configurations Operators: move-blank: up, down, right, left (when possible). Graph Theory (continued). Breadth-First Search (BFS) Properties. Solution Length: optimal Search Time: O ( B d )

tannar
Download Presentation

Lecture Notes 2

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Lecture Notes 2 Prof. Dechter ICS 270A Winter 2003

  2. Explicit Graph

  3. Graph Theory • Sates: board configurations • Operators: move-blank: up, down, right, left (when possible)

  4. Graph Theory (continued)

  5. Breadth-First Search (BFS) Properties • Solution Length: optimal • Search Time: O(Bd) • Memory Required: O(Bd) • Drawback: require exponential space 1 2 3 7 4 6 5 8 9 10 11 12 13 14 15

  6. Iterative Deepening (DFS) • Every iteration is a DFS with a depth cutoff. Iterative deepening (ID) • i = 1 • While no solution, do • DFS from initial state S0 with cutoff i • If found goal, stop and return solution, else, increment cutoff Comments: • ID implements BFS with DFS • Only one path in memory • BFS at step i may need to keep 2i nodes in OPEN

  7. Iterative Deepening (DFS) • Time: • BFS time is O(bn) • B is the branching degree • ID is asymptotically like BFS • For b=10 d=5 d=cut-off • DFS = 1+10+100,…,=111,111 • IDS = 123,456 • Ratio is

  8. Bi-Directional Search

  9. Bi-Directional Search (continued)

  10. Breadth First Search • Put the start node s on OPEN. • If OPEN is empty exit with failure. • Remove the first node n from OPEN and place it on CLOSED. • If n is a goal node, exit successfully with the solution obtained by tracing back pointers from n to s. • Otherwise, expand n, generating all its successors attach to them pointer back to n, and put them at the end of OPEN • Go to step 2. For shortest cost path: 5’. Otherwise, expand n, generating all its successors attach to them pointer back to n, put them at in OPEN and order OPEN based on shortest cost partial path.

  11. Uniform Cost Search • Expand lowest-cost OPEN node (g(n)) • In BFS g(n) = depth(n) • Requirement • g(successor)(n))  g(n)

  12. Comparison of Algorithms

More Related