Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

Assignment 2

Name/Mohamed Yousef Moustafa


ID/320210006
Q1) 10Nodes
Q2) Depth-First Graph Search

Final Path / S -> B -> C -> G


Q3) Breadth- First Graph search

1/ S -> B
2/ S -> C
3/ S -> B -> C
4/ S-> C -> A
5/ S -> C -> G {Final path}
Q4) Greedy search

1/ S -> D: H=7
2/ D -> E: H=3
3/ E -> G: H=0
Final Path / S -> D -> E -> G
Q5) (A star) A*

1/ S -> B: 4
2/ B -> D: 7
3/ D -> G
Final Path: S -> B -> D -> G
Q6)
the total number of dots let: This heuristic is not admissible because it doesn't
take into
account for the cost of reaching those dots, and it assumes a uniform cost for all
dots.

• the distance to the closest dot: This heuristic is admissible as it underestimates


the true cost since it assumes the Pacman can move directly to the closest dot
without any obstacles.
• the distance to the furthest dot: This heuristic is not admissible because it
overestimates the cost, as it assumes the Pacman must travel to the furthest dot,
which is not necessarily true.
• the distance to the closest dot plus the distance to the furthest dot: This
heuristic is not admissible because it overestimates the cost by considering both
the closest and the furthest dots.
So, the admissible heuristics is: The distance to the closest dot(b)
Q7)
TRUE
Q8)
When you have multiple admissible heuristics, the maximum (max) of those
heuristics will be admissible because it provides an optimistic estimate of the true
cost to reach the goal. This is because the maximum heuristic value is at least as
large as any individual heuristic.
So, statement (a) is true, and statement (b) is not necessarily true.

You might also like