Title: Informed Search Strategies
1Informed Search Strategies
2Informed Search Strategies
3Heuristics for 8-puzzle
- These heuristics were obtained by relaxing
constraints (Explain !!!) - h1 The number of misplaced tiles (squares with
number). - h2 The sum of the distances of the tiles from
their goal positions.
4Heuristics for 8-puzzle I
Current State
- The number of misplaced tiles (not including the
blank)
Goal State
In this case, only 8 is misplaced, so the
heuristic function evaluates to 1. In other
words, the heuristic is telling us, that it
thinks a solution might be available in just 1
more move.
Notation h(n) h(current state) 1
5Heuristics for 8-puzzle II
3
3
Current State
2 spaces
- The Manhattan Distance (not including the blank)
8
3 spaces
Goal State
8
1
In this case, only the 3, 8 and 1 tiles are
misplaced, by 2, 3, and 3 squares respectively,
so the heuristic function evaluates to 8. In
other words, the heuristic is telling us, that it
thinks a solution is available in just 8 more
moves.
3 spaces
1
Total 8
Notation h(n) h(current state) 8
6Greedy Search(with systematic checking of
repeated states)
- 8-Puzzle with h2()
- h2() Manhattan Distance
78-Puzzle Problem
- Solve the following 8-puzzle problem using Greedy
search algorithm as search strategy and Manhattan
distance as heuristic.
3
2
1
8
4
5
6
7
8Greedy Search(with systematic checking of
repeated states)
- 8-Puzzle with h1()
- h1() the number of misplaced tiles
98-Puzzle Problem
- Solve the following 8-puzzle problem using Greedy
search algorithm as search strategy and h1() as
heuristic.
3
2
1
8
4
5
6
7
10A Search(with systematic checking of repeated
states)
- 8-Puzzle with h1()
- h1() the number of misplaced tiles
118-Puzzle Problem
- Solve the following 8-puzzle problem using A
search algorithm as search strategy and the
following function f(n) as heuristic
f(n)g(n)h(n) - h(n)the number of misplaced tiles
- g(n)the number of steps from the initial state
3
8
2
4
6
1
5
7
12A Search(with systematic checking of repeated
states)
- 8-Puzzle with h2()
- h2() Manhattan Distance
138-Puzzle Problem
- Solve the following 8-puzzle problem using A
search algorithm as search strategy and the
following function f(n) as heuristic
f(n)g(n)h(n) - h(n)the Manhattan Distance
- g(n)the number of steps from the initial state
3
8
2
4
6
1
5
7
14IDA Search
- 8-Puzzle with h1()
- h1(n) the number of misplaced tiles
158-Puzzle Problem
- Solve the following 8-puzzle problem using IDA
search algorithm as search strategy and the
following function f(n) as heuristic
f(n)g(n)h(n) - h(n)the number of misplaced tiles
- g(n)the number of steps from the initial state
16Informed Search Strategies
17Maze Traversal
- Consider the Maze Traversal Problem
18Maze Traversal
- Give a formulation for this problem
- Solve this problem by using
- Greedy search technique with Manhattan distance
as heuristic. - A Algorithm and Manhattan distance as heuristic.
- propose another heuristic h().
19Maze Traversal
- Consider the following problem
- Where A3 is the Starting node and E2 the End
node.
20Maze Traversal
- Solve this problem by using
- Greedy search technique with Manhattan distance
as heuristic. - A Algorithm and Manhattan distance as heuristic.
- IDA Algorithm and Manhattan distance as
heuristic.
21MAP Searching
- Consider the following Map
22Map Searching
City
h()
- SLD heuristic h()
- Straight Line Distance between any city and
the End city Munchen - Is h() admissible ?
23Map searching
- We wish to move from Hannover to Munchen,
solve this problem using - Greedy search with SLD heuristic
- A algorithm with SLD heuristic