Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can someone give me an example of admissible heuristic that is not consistent?

In this figure:

enter image description here let's assume that h(C)=1 If f(A)=g(A)+h(A)=0+4=4, and f(C)=g(C)+h(C)=1+1=2 Then f(C) is NOT greater than or equal to f(A) Therefore this example is consistent and admissible, but can someone give me an example of admissible heuristic that is not consistent? please

like image 667
user3880907 Avatar asked Oct 02 '15 11:10

user3880907


People also ask

Can a heuristic be admissible but not consistent?

No. Consistency implies admissibility. In other words, if a heuristic is consistent, it is also admissible. However, admissibility does not imply consistency.

What is an admissible heuristic example?

A heuristic h is admissible (optimistic) if: 0 ≤ h(n) ≤ h∗(n) where h∗(n) is the true cost to a nearest goal Note: Coming up with admissible heuristics is most of what's involved in using A* in practice. Examples: Optimize: number of flips.

Is an admissible heuristic always consistent?

In an admissible heuristic, the estimated cost from the current node to the goal state is never greater than the actual cost. All consistent heuristics are admissible heuristics, however, all admissible heuristics are not necessarily consistent heuristics.

What happens if heuristic is not consistent?

A known problem with inconsistent heuristics is that they may cause algorithms like A∗ to find shorter paths to nodes that were previously expanded and inserted into the closed list. If this happens, then these nodes must be moved back to the open list, where they might be chosen for expansion again.


1 Answers

  • Admissibility

if you want your heuristics to be admissible then you should have that h(n) <=h*(n) for every node n where h* is the real cost to the goal. In your case you want:

h(A) <= 4
h(C) <= 3
h(G) <= 0
  • Consistency

If you want your heuristics to be consistent then you should have that h(G) = 0 and h(n) <= cost(n, c) + h(c) where the node c is a child of node c. So in your case

h(A) <= 1 + h(C)
h(C) <= 3 + h(G) = 3

If you want inconsistency and since h(C) <= 3 for the admissibility condition then you should have that h(A) > 1 + h(C). So any heristics that satisfies:

h(A) > 1 + h(C)
h(C) <= 3
h(G) = 0

is admissible and not consistent. You gave

h(A) = 4
h(C) = 1
h(G) = 0

which is a valid candidate.

like image 152
sve Avatar answered Sep 23 '22 18:09

sve