SlideShare a Scribd company logo
Chapter 4Chapter 4
Informed search & ExplorationInformed search & Exploration
CSE 4701
Review: Tree searchReview: Tree search
A search strategy is defined by picking the
order of node expansion
Uninformed search strategies use only the
information available in the problem definition
◦ Breadth-first search
◦ Uniform-cost search
◦ Depth-first search
◦ Depth-limited search
◦ Iterative deepening search
HeuristicsHeuristics
Heuristics examplesHeuristics examples
A heuristic function at a node n is an estimate
of the optimum cost from the current node to
a goal. Denoted by h(n)
h(n)= estimated cost of the cheapest path from
node n to a goal node.
Example: want path from Dhaka to Chittagong
Heuristics for Chittagong may be straight line
distance between Dhaka and Chittagong
Heuristic examplesHeuristic examples
Best-first searchBest-first search
 Idea: use an evaluation function f(n) for each node
◦ estimate of "desirability“
1. Greedy Best-First Search
2. A*
search
Romania with step costs in kmRomania with step costs in km
Greedy best-first searchGreedy best-first search
Evaluation function f(n) = h(n) (heuristic)
= estimate of cost from n to goal
e.g., hSLD(n) = straight-line distance from n
to Bucharest
Greedy best-first search expands the
node that appears to be closest to goal
Greedy best-first search exampleGreedy best-first search example
Greedy best-first search exampleGreedy best-first search example
Greedy best-first search exampleGreedy best-first search example
Greedy best-first search exampleGreedy best-first search example
But is this solution optimal?
No, because instead of using the via Sibiu and
fagaras to Bucharest, if we follow the path
through Rimmicu Vilcea and Pitesti, then we
have to go 32 km less than the first path.
This shows why the algorithm is called
“greedy”- at every step it tries to get as close
to the goal as it can.
Drawbacks of greedy searchDrawbacks of greedy search
Minimizing h(n) is susceptible to false
starts. Consider the problem of getting
from Iasi to Fagaras. The heuristic
suggests that Neamt be expanded first,
because it is closest to Fagaras, but this is
a dead end. The solution is to go first to
vaslui- a step that is actually farther from
the goal according to the heuristis
Properties of greedy best-firstProperties of greedy best-first
searchsearch
 Greedy Best first search resembles depth first search in
the way it prefers to follow a single path all the way to
the goal, but will back up when it hits a dead end.
 Complete? No – can get stuck in loops, e.g., Iasi 
Neamt  Iasi  Neamt 
 Time? O(bm
), but a good heuristic can give dramatic
improvement
 Space? O(bm
) -- keeps all nodes in memory
 Optimal? No
AA**
searchsearch
Idea: avoid expanding paths that are
already expensive
Evaluation function f(n) = g(n) + h(n)
g(n) = cost so far to reach n
h(n) = estimated cost from n to goal
f(n) = estimated total cost of path
through n to goal
AA**
search examplesearch example
AA**
search examplesearch example
AA**
search examplesearch example
AA**
search examplesearch example
AA**
search examplesearch example
AA**
search examplesearch example
Admissible heuristicsAdmissible heuristics
 A heuristic h(n) is admissible if for every node n,
h(n) ≤ h*
(n), where h*
(n) is the true cost to reach the
goal state from n.
 An admissible heuristic never overestimates the cost to
reach the goal, i.e., it is optimistic
 Example: hSLD(n) (never overestimates the actual road
distance)
 Theorem: If h(n) is admissible, A*
using TREE-SEARCH
is optimal



Properties of A*Properties of A*
Complete? Yes (unless there are infinitely
many nodes with f ≤ f(G) )
Time? Exponential
Space? Keeps all nodes in memory
Optimal? Yes
Example:Example: nn-queens-queens
Put n queens on an n × n board with no
two queens on the same row, column, or
diagonal
Hill-climbing searchHill-climbing search
Problem: depending on initial state, can
get stuck in local maxima

Genetic algorithmsGenetic algorithms
 A successor state is generated by combining two parent
states
 Start with k randomly generated states (population)
 A state is represented as a string over a finite alphabet
(often a string of 0s and 1s)
 Evaluation function (fitness function). Higher values for
better states.
 Produce the next generation of states by selection,
crossover, and mutation
ExampleExample
 Example: 8 queens problem.
A state could be represented as 8 digits each in the range from 1 to
8
Each state is rated by the evaluation function or fitness function. A
Fitness function returns higher values for better states.
Suppose for 8 queens problem fitness function will be based on the
number of non attacking pairs of queens. Suppose fitness value 28
provides a solution.
In the example, the values of 4 states are 24,23, 20 and 11 and for
this variant of genetic algorithm the probability of being chosen a
state for reproducing is directly proportional to be fitness score.
The next steps are selection of parents for reproducing, crossover
and mutation.
Crossover point is randomly selected
from the positions in the string.
Lastly, each location is subject to random
mutation with a small independent
probability
Genetic algorithmsGenetic algorithms
Genetic algorithmsGenetic algorithms
 Fitness function: number of non-attacking pairs of
queens (suppose 28 for a solution)
 24/(24+23+20+11) = 31%
 23/(24+23+20+11) = 29% etc

More Related Content

What's hot

I. Hill climbing algorithm II. Steepest hill climbing algorithm
I. Hill climbing algorithm II. Steepest hill climbing algorithmI. Hill climbing algorithm II. Steepest hill climbing algorithm
I. Hill climbing algorithm II. Steepest hill climbing algorithm
vikas dhakane
 
Problem reduction AND OR GRAPH & AO* algorithm.ppt
Problem reduction AND OR GRAPH & AO* algorithm.pptProblem reduction AND OR GRAPH & AO* algorithm.ppt
Problem reduction AND OR GRAPH & AO* algorithm.ppt
arunsingh660
 
Heuristic Search Techniques {Artificial Intelligence}
Heuristic Search Techniques {Artificial Intelligence}Heuristic Search Techniques {Artificial Intelligence}
Heuristic Search Techniques {Artificial Intelligence}
FellowBuddy.com
 
search strategies in artificial intelligence
search strategies in artificial intelligencesearch strategies in artificial intelligence
search strategies in artificial intelligence
Hanif Ullah (Gold Medalist)
 
Backtracking
Backtracking  Backtracking
Backtracking
Vikas Sharma
 
Knowledge representation in AI
Knowledge representation in AIKnowledge representation in AI
Knowledge representation in AIVishal Singh
 
Artificial intelligence and knowledge representation
Artificial intelligence and knowledge representationArtificial intelligence and knowledge representation
Artificial intelligence and knowledge representation
Sajan Sahu
 
Heuristic search-in-artificial-intelligence
Heuristic search-in-artificial-intelligenceHeuristic search-in-artificial-intelligence
Heuristic search-in-artificial-intelligence
grinu
 
AI Lecture 4 (informed search and exploration)
AI Lecture 4 (informed search and exploration)AI Lecture 4 (informed search and exploration)
AI Lecture 4 (informed search and exploration)
Tajim Md. Niamat Ullah Akhund
 
Problem solving agents
Problem solving agentsProblem solving agents
Problem solving agents
Megha Sharma
 
AI: Logic in AI
AI: Logic in AIAI: Logic in AI
AI: Logic in AI
DataminingTools Inc
 
Heuristc Search Techniques
Heuristc Search TechniquesHeuristc Search Techniques
Heuristc Search Techniques
Jismy .K.Jose
 
AI_Session 7 Greedy Best first search algorithm.pptx
AI_Session 7 Greedy Best first search algorithm.pptxAI_Session 7 Greedy Best first search algorithm.pptx
AI_Session 7 Greedy Best first search algorithm.pptx
Asst.prof M.Gokilavani
 
AI - Local Search - Hill Climbing
AI - Local Search - Hill ClimbingAI - Local Search - Hill Climbing
AI - Local Search - Hill Climbing
Andrew Ferlitsch
 
AI: AI & Problem Solving
AI: AI & Problem SolvingAI: AI & Problem Solving
AI: AI & Problem Solving
DataminingTools Inc
 
Hill climbing algorithm
Hill climbing algorithmHill climbing algorithm
Hill climbing algorithm
Dr. C.V. Suresh Babu
 
A* Search Algorithm
A* Search AlgorithmA* Search Algorithm
A* Search Algorithm
vikas dhakane
 
Solving problems by searching
Solving problems by searchingSolving problems by searching
Solving problems by searchingLuigi Ceccaroni
 
State Space Search in ai
State Space Search in aiState Space Search in ai
State Space Search in ai
vikas dhakane
 

What's hot (20)

I. Hill climbing algorithm II. Steepest hill climbing algorithm
I. Hill climbing algorithm II. Steepest hill climbing algorithmI. Hill climbing algorithm II. Steepest hill climbing algorithm
I. Hill climbing algorithm II. Steepest hill climbing algorithm
 
Problem reduction AND OR GRAPH & AO* algorithm.ppt
Problem reduction AND OR GRAPH & AO* algorithm.pptProblem reduction AND OR GRAPH & AO* algorithm.ppt
Problem reduction AND OR GRAPH & AO* algorithm.ppt
 
Heuristic Search Techniques {Artificial Intelligence}
Heuristic Search Techniques {Artificial Intelligence}Heuristic Search Techniques {Artificial Intelligence}
Heuristic Search Techniques {Artificial Intelligence}
 
search strategies in artificial intelligence
search strategies in artificial intelligencesearch strategies in artificial intelligence
search strategies in artificial intelligence
 
Backtracking
Backtracking  Backtracking
Backtracking
 
Knowledge representation in AI
Knowledge representation in AIKnowledge representation in AI
Knowledge representation in AI
 
Artificial intelligence and knowledge representation
Artificial intelligence and knowledge representationArtificial intelligence and knowledge representation
Artificial intelligence and knowledge representation
 
Heuristic search-in-artificial-intelligence
Heuristic search-in-artificial-intelligenceHeuristic search-in-artificial-intelligence
Heuristic search-in-artificial-intelligence
 
AI Lecture 4 (informed search and exploration)
AI Lecture 4 (informed search and exploration)AI Lecture 4 (informed search and exploration)
AI Lecture 4 (informed search and exploration)
 
Problem solving agents
Problem solving agentsProblem solving agents
Problem solving agents
 
AI: Logic in AI
AI: Logic in AIAI: Logic in AI
AI: Logic in AI
 
Heuristc Search Techniques
Heuristc Search TechniquesHeuristc Search Techniques
Heuristc Search Techniques
 
AI_Session 7 Greedy Best first search algorithm.pptx
AI_Session 7 Greedy Best first search algorithm.pptxAI_Session 7 Greedy Best first search algorithm.pptx
AI_Session 7 Greedy Best first search algorithm.pptx
 
AI - Local Search - Hill Climbing
AI - Local Search - Hill ClimbingAI - Local Search - Hill Climbing
AI - Local Search - Hill Climbing
 
AI: AI & Problem Solving
AI: AI & Problem SolvingAI: AI & Problem Solving
AI: AI & Problem Solving
 
Hill climbing algorithm
Hill climbing algorithmHill climbing algorithm
Hill climbing algorithm
 
A* Search Algorithm
A* Search AlgorithmA* Search Algorithm
A* Search Algorithm
 
Solving problems by searching
Solving problems by searchingSolving problems by searching
Solving problems by searching
 
Iterative deepening search
Iterative deepening searchIterative deepening search
Iterative deepening search
 
State Space Search in ai
State Space Search in aiState Space Search in ai
State Space Search in ai
 

Similar to Informed search (heuristics)

Search 2
Search 2Search 2
Searchadditional2
Searchadditional2Searchadditional2
Searchadditional2chandsek666
 
Artificial intelligence and machine learning
Artificial intelligence and machine learningArtificial intelligence and machine learning
Artificial intelligence and machine learning
GuruKiran18
 
Chapter3 Search
Chapter3 SearchChapter3 Search
Chapter3 SearchKhiem Ho
 
2-Heuristic Search.ppt
2-Heuristic Search.ppt2-Heuristic Search.ppt
2-Heuristic Search.ppt
MIT,Imphal
 
shamwari dzerwendo.mmmmmmfmmfmfkksrkrttkt
shamwari dzerwendo.mmmmmmfmmfmfkksrkrttktshamwari dzerwendo.mmmmmmfmmfmfkksrkrttkt
shamwari dzerwendo.mmmmmmfmmfmfkksrkrttkt
PEACENYAMA1
 
Chap11 slides
Chap11 slidesChap11 slides
Chap11 slides
BaliThorat1
 
CptS 440 / 540 Artificial Intelligence
CptS 440 / 540 Artificial IntelligenceCptS 440 / 540 Artificial Intelligence
CptS 440 / 540 Artificial Intelligencebutest
 
3.informed search
3.informed search3.informed search
3.informed search
KONGU ENGINEERING COLLEGE
 
Informed-search TECHNIQUES IN ai ml data science
Informed-search TECHNIQUES IN ai ml data scienceInformed-search TECHNIQUES IN ai ml data science
Informed-search TECHNIQUES IN ai ml data science
devvpillpersonal
 
13256181.ppt
13256181.ppt13256181.ppt
13256181.ppt
JohnWilliam111370
 
Perform brute force
Perform brute forcePerform brute force
Perform brute force
SHC
 
Artificial intelligence(06)
Artificial intelligence(06)Artificial intelligence(06)
Artificial intelligence(06)
Nazir Ahmed
 
Artificial intelligence(06)
Artificial intelligence(06)Artificial intelligence(06)
Artificial intelligence(06)
Nazir Ahmed
 
Jarrar.lecture notes.aai.2011s.ch4.informedsearch
Jarrar.lecture notes.aai.2011s.ch4.informedsearchJarrar.lecture notes.aai.2011s.ch4.informedsearch
Jarrar.lecture notes.aai.2011s.ch4.informedsearchPalGov
 
A Star Search
A Star SearchA Star Search
A Star Search
Computing Cage
 
A Star Search
A Star SearchA Star Search
09_Informed_Search.ppt
09_Informed_Search.ppt09_Informed_Search.ppt
09_Informed_Search.ppt
rnyau
 

Similar to Informed search (heuristics) (20)

Search 2
Search 2Search 2
Search 2
 
Searchadditional2
Searchadditional2Searchadditional2
Searchadditional2
 
Artificial intelligence and machine learning
Artificial intelligence and machine learningArtificial intelligence and machine learning
Artificial intelligence and machine learning
 
Chapter3 Search
Chapter3 SearchChapter3 Search
Chapter3 Search
 
2-Heuristic Search.ppt
2-Heuristic Search.ppt2-Heuristic Search.ppt
2-Heuristic Search.ppt
 
AIw06.pptx
AIw06.pptxAIw06.pptx
AIw06.pptx
 
shamwari dzerwendo.mmmmmmfmmfmfkksrkrttkt
shamwari dzerwendo.mmmmmmfmmfmfkksrkrttktshamwari dzerwendo.mmmmmmfmmfmfkksrkrttkt
shamwari dzerwendo.mmmmmmfmmfmfkksrkrttkt
 
Chap11 slides
Chap11 slidesChap11 slides
Chap11 slides
 
CptS 440 / 540 Artificial Intelligence
CptS 440 / 540 Artificial IntelligenceCptS 440 / 540 Artificial Intelligence
CptS 440 / 540 Artificial Intelligence
 
3.informed search
3.informed search3.informed search
3.informed search
 
Informed-search TECHNIQUES IN ai ml data science
Informed-search TECHNIQUES IN ai ml data scienceInformed-search TECHNIQUES IN ai ml data science
Informed-search TECHNIQUES IN ai ml data science
 
13256181.ppt
13256181.ppt13256181.ppt
13256181.ppt
 
Perform brute force
Perform brute forcePerform brute force
Perform brute force
 
Searching techniques
Searching techniquesSearching techniques
Searching techniques
 
Artificial intelligence(06)
Artificial intelligence(06)Artificial intelligence(06)
Artificial intelligence(06)
 
Artificial intelligence(06)
Artificial intelligence(06)Artificial intelligence(06)
Artificial intelligence(06)
 
Jarrar.lecture notes.aai.2011s.ch4.informedsearch
Jarrar.lecture notes.aai.2011s.ch4.informedsearchJarrar.lecture notes.aai.2011s.ch4.informedsearch
Jarrar.lecture notes.aai.2011s.ch4.informedsearch
 
A Star Search
A Star SearchA Star Search
A Star Search
 
A Star Search
A Star SearchA Star Search
A Star Search
 
09_Informed_Search.ppt
09_Informed_Search.ppt09_Informed_Search.ppt
09_Informed_Search.ppt
 

More from Bablu Shofi

Cyber security
Cyber securityCyber security
Cyber security
Bablu Shofi
 
Genetic algorithm
Genetic algorithmGenetic algorithm
Genetic algorithm
Bablu Shofi
 
Uninformed search
Uninformed searchUninformed search
Uninformed search
Bablu Shofi
 
computer-memory
computer-memorycomputer-memory
computer-memory
Bablu Shofi
 
Data linkcontrol
Data linkcontrolData linkcontrol
Data linkcontrol
Bablu Shofi
 
ERP
ERPERP
Inventory Management
Inventory ManagementInventory Management
Inventory Management
Bablu Shofi
 

More from Bablu Shofi (7)

Cyber security
Cyber securityCyber security
Cyber security
 
Genetic algorithm
Genetic algorithmGenetic algorithm
Genetic algorithm
 
Uninformed search
Uninformed searchUninformed search
Uninformed search
 
computer-memory
computer-memorycomputer-memory
computer-memory
 
Data linkcontrol
Data linkcontrolData linkcontrol
Data linkcontrol
 
ERP
ERPERP
ERP
 
Inventory Management
Inventory ManagementInventory Management
Inventory Management
 

Recently uploaded

Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdfHybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
fxintegritypublishin
 
space technology lecture notes on satellite
space technology lecture notes on satellitespace technology lecture notes on satellite
space technology lecture notes on satellite
ongomchris
 
Cosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdfCosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdf
Kamal Acharya
 
Governing Equations for Fundamental Aerodynamics_Anderson2010.pdf
Governing Equations for Fundamental Aerodynamics_Anderson2010.pdfGoverning Equations for Fundamental Aerodynamics_Anderson2010.pdf
Governing Equations for Fundamental Aerodynamics_Anderson2010.pdf
WENKENLI1
 
English lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdfEnglish lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdf
BrazilAccount1
 
HYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generationHYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generation
Robbie Edward Sayers
 
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Dr.Costas Sachpazis
 
AP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specificAP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specific
BrazilAccount1
 
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdfAKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
SamSarthak3
 
Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...
Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...
Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...
AJAYKUMARPUND1
 
一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理
一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理
一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理
ydteq
 
Investor-Presentation-Q1FY2024 investor presentation document.pptx
Investor-Presentation-Q1FY2024 investor presentation document.pptxInvestor-Presentation-Q1FY2024 investor presentation document.pptx
Investor-Presentation-Q1FY2024 investor presentation document.pptx
AmarGB2
 
Standard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - NeometrixStandard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - Neometrix
Neometrix_Engineering_Pvt_Ltd
 
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
MdTanvirMahtab2
 
Final project report on grocery store management system..pdf
Final project report on grocery store management system..pdfFinal project report on grocery store management system..pdf
Final project report on grocery store management system..pdf
Kamal Acharya
 
CW RADAR, FMCW RADAR, FMCW ALTIMETER, AND THEIR PARAMETERS
CW RADAR, FMCW RADAR, FMCW ALTIMETER, AND THEIR PARAMETERSCW RADAR, FMCW RADAR, FMCW ALTIMETER, AND THEIR PARAMETERS
CW RADAR, FMCW RADAR, FMCW ALTIMETER, AND THEIR PARAMETERS
veerababupersonal22
 
Immunizing Image Classifiers Against Localized Adversary Attacks
Immunizing Image Classifiers Against Localized Adversary AttacksImmunizing Image Classifiers Against Localized Adversary Attacks
Immunizing Image Classifiers Against Localized Adversary Attacks
gerogepatton
 
road safety engineering r s e unit 3.pdf
road safety engineering  r s e unit 3.pdfroad safety engineering  r s e unit 3.pdf
road safety engineering r s e unit 3.pdf
VENKATESHvenky89705
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
thanhdowork
 
CME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional ElectiveCME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional Elective
karthi keyan
 

Recently uploaded (20)

Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdfHybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
Hybrid optimization of pumped hydro system and solar- Engr. Abdul-Azeez.pdf
 
space technology lecture notes on satellite
space technology lecture notes on satellitespace technology lecture notes on satellite
space technology lecture notes on satellite
 
Cosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdfCosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdf
 
Governing Equations for Fundamental Aerodynamics_Anderson2010.pdf
Governing Equations for Fundamental Aerodynamics_Anderson2010.pdfGoverning Equations for Fundamental Aerodynamics_Anderson2010.pdf
Governing Equations for Fundamental Aerodynamics_Anderson2010.pdf
 
English lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdfEnglish lab ppt no titlespecENG PPTt.pdf
English lab ppt no titlespecENG PPTt.pdf
 
HYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generationHYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generation
 
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...
 
AP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specificAP LAB PPT.pdf ap lab ppt no title specific
AP LAB PPT.pdf ap lab ppt no title specific
 
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdfAKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
AKS UNIVERSITY Satna Final Year Project By OM Hardaha.pdf
 
Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...
Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...
Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...
 
一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理
一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理
一比一原版(UofT毕业证)多伦多大学毕业证成绩单如何办理
 
Investor-Presentation-Q1FY2024 investor presentation document.pptx
Investor-Presentation-Q1FY2024 investor presentation document.pptxInvestor-Presentation-Q1FY2024 investor presentation document.pptx
Investor-Presentation-Q1FY2024 investor presentation document.pptx
 
Standard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - NeometrixStandard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - Neometrix
 
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)
 
Final project report on grocery store management system..pdf
Final project report on grocery store management system..pdfFinal project report on grocery store management system..pdf
Final project report on grocery store management system..pdf
 
CW RADAR, FMCW RADAR, FMCW ALTIMETER, AND THEIR PARAMETERS
CW RADAR, FMCW RADAR, FMCW ALTIMETER, AND THEIR PARAMETERSCW RADAR, FMCW RADAR, FMCW ALTIMETER, AND THEIR PARAMETERS
CW RADAR, FMCW RADAR, FMCW ALTIMETER, AND THEIR PARAMETERS
 
Immunizing Image Classifiers Against Localized Adversary Attacks
Immunizing Image Classifiers Against Localized Adversary AttacksImmunizing Image Classifiers Against Localized Adversary Attacks
Immunizing Image Classifiers Against Localized Adversary Attacks
 
road safety engineering r s e unit 3.pdf
road safety engineering  r s e unit 3.pdfroad safety engineering  r s e unit 3.pdf
road safety engineering r s e unit 3.pdf
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
 
CME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional ElectiveCME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional Elective
 

Informed search (heuristics)

  • 1. Chapter 4Chapter 4 Informed search & ExplorationInformed search & Exploration CSE 4701
  • 2. Review: Tree searchReview: Tree search A search strategy is defined by picking the order of node expansion Uninformed search strategies use only the information available in the problem definition ◦ Breadth-first search ◦ Uniform-cost search ◦ Depth-first search ◦ Depth-limited search ◦ Iterative deepening search
  • 4. Heuristics examplesHeuristics examples A heuristic function at a node n is an estimate of the optimum cost from the current node to a goal. Denoted by h(n) h(n)= estimated cost of the cheapest path from node n to a goal node. Example: want path from Dhaka to Chittagong Heuristics for Chittagong may be straight line distance between Dhaka and Chittagong
  • 6. Best-first searchBest-first search  Idea: use an evaluation function f(n) for each node ◦ estimate of "desirability“ 1. Greedy Best-First Search 2. A* search
  • 7. Romania with step costs in kmRomania with step costs in km
  • 8. Greedy best-first searchGreedy best-first search Evaluation function f(n) = h(n) (heuristic) = estimate of cost from n to goal e.g., hSLD(n) = straight-line distance from n to Bucharest Greedy best-first search expands the node that appears to be closest to goal
  • 9. Greedy best-first search exampleGreedy best-first search example
  • 10. Greedy best-first search exampleGreedy best-first search example
  • 11. Greedy best-first search exampleGreedy best-first search example
  • 12. Greedy best-first search exampleGreedy best-first search example
  • 13. But is this solution optimal? No, because instead of using the via Sibiu and fagaras to Bucharest, if we follow the path through Rimmicu Vilcea and Pitesti, then we have to go 32 km less than the first path. This shows why the algorithm is called “greedy”- at every step it tries to get as close to the goal as it can.
  • 14. Drawbacks of greedy searchDrawbacks of greedy search Minimizing h(n) is susceptible to false starts. Consider the problem of getting from Iasi to Fagaras. The heuristic suggests that Neamt be expanded first, because it is closest to Fagaras, but this is a dead end. The solution is to go first to vaslui- a step that is actually farther from the goal according to the heuristis
  • 15. Properties of greedy best-firstProperties of greedy best-first searchsearch  Greedy Best first search resembles depth first search in the way it prefers to follow a single path all the way to the goal, but will back up when it hits a dead end.  Complete? No – can get stuck in loops, e.g., Iasi  Neamt  Iasi  Neamt   Time? O(bm ), but a good heuristic can give dramatic improvement  Space? O(bm ) -- keeps all nodes in memory  Optimal? No
  • 16. AA** searchsearch Idea: avoid expanding paths that are already expensive Evaluation function f(n) = g(n) + h(n) g(n) = cost so far to reach n h(n) = estimated cost from n to goal f(n) = estimated total cost of path through n to goal
  • 23. Admissible heuristicsAdmissible heuristics  A heuristic h(n) is admissible if for every node n, h(n) ≤ h* (n), where h* (n) is the true cost to reach the goal state from n.  An admissible heuristic never overestimates the cost to reach the goal, i.e., it is optimistic  Example: hSLD(n) (never overestimates the actual road distance)  Theorem: If h(n) is admissible, A* using TREE-SEARCH is optimal   
  • 24. Properties of A*Properties of A* Complete? Yes (unless there are infinitely many nodes with f ≤ f(G) ) Time? Exponential Space? Keeps all nodes in memory Optimal? Yes
  • 25. Example:Example: nn-queens-queens Put n queens on an n × n board with no two queens on the same row, column, or diagonal
  • 26. Hill-climbing searchHill-climbing search Problem: depending on initial state, can get stuck in local maxima 
  • 27. Genetic algorithmsGenetic algorithms  A successor state is generated by combining two parent states  Start with k randomly generated states (population)  A state is represented as a string over a finite alphabet (often a string of 0s and 1s)  Evaluation function (fitness function). Higher values for better states.  Produce the next generation of states by selection, crossover, and mutation
  • 28. ExampleExample  Example: 8 queens problem. A state could be represented as 8 digits each in the range from 1 to 8 Each state is rated by the evaluation function or fitness function. A Fitness function returns higher values for better states. Suppose for 8 queens problem fitness function will be based on the number of non attacking pairs of queens. Suppose fitness value 28 provides a solution. In the example, the values of 4 states are 24,23, 20 and 11 and for this variant of genetic algorithm the probability of being chosen a state for reproducing is directly proportional to be fitness score. The next steps are selection of parents for reproducing, crossover and mutation.
  • 29. Crossover point is randomly selected from the positions in the string. Lastly, each location is subject to random mutation with a small independent probability
  • 31. Genetic algorithmsGenetic algorithms  Fitness function: number of non-attacking pairs of queens (suppose 28 for a solution)  24/(24+23+20+11) = 31%  23/(24+23+20+11) = 29% etc