Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Hands-On Artificial Intelligence for Search

You're reading from   Hands-On Artificial Intelligence for Search Building intelligent applications and perform enterprise searches

Arrow left icon
Product type Paperback
Published in Aug 2018
Publisher Packt
ISBN-13 9781789611151
Length 124 pages
Edition 1st Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
Devangini Patel Devangini Patel
Author Profile Icon Devangini Patel
Devangini Patel
Arrow right icon
View More author details
Toc

What is a good heuristic function?

To answer the question, why is a good heuristic function required? We will compare the DFS and BFS methods to the heuristic search approach. In DFS and BFS, the costs of all of the edges are equal to 1, and DFS explores all of the child nodes, whereas BFS explores all of the sibling nodes. In a heuristic search, the costs of the edges are different, and the heuristic search selects the nodes to explore based on heuristic functions.

By using a heuristic function, we can reduce the memory that is used, and we can reach the solution in less time. The next question to be answered is, why is a good heuristic function required? The answer is in order to find the optimal solution. In our A* Search example, we illustrated that by using a better heuristic function, we can find the optimal solution; it is clear that A* explores the least number of nodes...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image