SlideShare a Scribd company logo
1 of 22
ARTIFICAL INTELLIGENCE
(R18 III(II Sem))
Department of computer science and
engineering (AI/ML)
Session 9
by
Asst.Prof.M.Gokilavani
VITS
3/4/2023 Department of CSE (AI/ML) 1
TEXTBOOK:
• Artificial Intelligence A modern Approach, Third
Edition, Stuart Russell and Peter Norvig, Pearson
Education.
REFERENCES:
• Artificial Intelligence, 3rd Edn, E. Rich and K.Knight
(TMH).
• Artificial Intelligence, 3rd Edn, Patrick Henny
Winston, Pearson Education.
• Artificial Intelligence, Shivani Goel, Pearson
Education.
• Artificial Intelligence and Expert Systems- Patterson,
Pearson Education.
3/4/2023 Department of CSE (AI/ML) 2
Topics covered in session 9
3/4/2023 Department of CSE (AI/ML) 3
• Problem solving by search-I: Introduction to AI, Intelligent
Agents.
• Problem solving by search-II: Problem solving agents, searching
for solutions
• Uniformed search strategies: BFS, Uniform cost search, DFS,
Iterative deepening Depth-first search, Bidirectional search,
• Informed ( Heuristic) search strategies: Greedy best-first search,
A* search, Heuristic functions
• Beyond classical search: Hill- climbing Search, Simulated annealing
search, Local search in continuous spaces, Searching with non-
deterministic Actions, searching with partial observations, online
search agents and unknown environments.
Beyond classical search
• We have seen methods that systematically
explore the search space, possibly using
principled pruning (e.g., A*)
What if we have much larger search spaces?
• Search spaces for some real-world problems
may be much larger e.g., 1030,000 states as in
certain reasoning and planning tasks.
• Some of these problems can be solved by
Iterative Improvement Methods
3/4/2023 4
Department of CSE (AI/ML)
Local Search Algorithms and
Optimization Problems
• In many optimization problems the goal state itself is the
solution.
• The state space is a set of complete configurations.
• Search is about finding the optimal configuration (as in
TSP) or just a feasible configuration (as in scheduling
problems).
• In such cases, one can use iterative improvement, or
local search, methods.
• An evaluation, or objective, function h must be available
that measures the quality of each state.
• Main Idea: Start with a random initial configuration and
make small, local changes to it that improve its quality.
3/4/2023 5
Department of CSE (AI/ML)
Hill Climbing Algorithm
• In Hill-Climbing technique, starting at the base of a
hill, we walk upwards until we reach the top of the
hill.
• In other words, we start with initial state and we keep
improving the solution until its optimal.
• It's a variation of a generate-and-test algorithm which
discards all states which do not look promising or
seem unlikely to lead us to the goal state.
• To take such decisions, it uses heuristics (an
evaluation function) which indicates how close the
current state is to the goal state.
• Hill-Climbing = generate-and-test + heuristics
3/4/2023 6
Department of CSE (AI/ML)
Features of Hill Climbing
Following are some main features of Hill Climbing
Algorithm:
• Generate and Test variant: Hill Climbing is the
variant of Generate and Test method. The Generate and
Test method produce feedback which helps to decide
which direction to move in the search space.
• Greedy approach: Hill-climbing algorithm search
moves in the direction which optimizes the cost.
• No backtracking: It does not backtrack the search
space, as it does not remember the previous states.
3/4/2023 Department of CSE (AI/ML) 7
Types of Hill Climbing Algorithm
• Simple hill Climbing
• Steepest-Ascent hill-climbing
• Stochastic hill Climbing
• Random-restart hill climbing
3/4/2023 Department of CSE (AI/ML) 8
Simple Hill Climbing
• Simple hill climbing is the simplest way to implement a
hill climbing algorithm.
• It only evaluates the neighbor node state at a time and
selects the first one which optimizes current cost and
set it as a current state.
• It only checks it's one successor state, and if it finds better
than the current state, then move else be in the same state.
• This algorithm has the following features:
• Less time consuming
• Less optimal solution and the solution is not
guaranteed
3/4/2023 Department of CSE (AI/ML) 9
Algorithm
• Define the current state as an initial state
• Loop until the goal state is achieved or no more operators
can be applied on the current state:
– Apply an operation to current state and get a new state
– Compare the new state with the goal
– Quit if the goal state is achieved
– Evaluate new state with heuristic function
and compare it with the current state
– If the newer state is closer to the goal compared to
current state, update the current state
• As we can see, it reaches the goal state with iterative
improvements. In Hill-Climbing algorithm, finding goal
is equivalent to reaching the top of the hill.
3/4/2023 10
Department of CSE (AI/ML)
Example
• Key point while solving any
hill-climbing problem is to
choose an
appropriate heuristic
function.
• Let's define such function h:
• h(x) = +1 for all the blocks
in the support structure if
the block is correctly
positioned otherwise -1 for
all the blocks in the
support structure.
3/4/2023 Department of CSE (AI/ML) 11
3/4/2023 Department of CSE (AI/ML) 12
Steepest-ascent Hill climbing
• Steepest-ascent hill climbing is different from
simple hill climbing search.
• Unlike simple hill climbing search, It considers
all the successive nodes, compares them, and
choose the node which is closest to the solution.
• Steepest hill climbing search is similar to best-
first search because it focuses on each node
instead of one.
• Note: Both simple, as well as steepest-ascent hill
climbing search, fails when there is no closer
node.
3/4/2023 13
Department of CSE (AI/ML)
Algorithm
• Create a CURRENT node and a GOAL node.
• If the CURRENT node=GOAL node,
return GOAL and terminate the search.
• Loop until a better node is not found to reach
the solution.
• If there is any better successor node present,
expand it.
• When the GOAL is attained,
return GOAL and terminate.
3/4/2023 14
Department of CSE (AI/ML)
Simulated Annealing
3/4/2023 Department of CSE (AI/ML) 15
• A hill-climbing algorithm which never makes a move towards a
lower value guaranteed to be incomplete because it can get stuck on
a local maximum.
• And if algorithm applies a random walk, by moving a successor,
then it may complete but not efficient.
• Simulated Annealing is an algorithm which yields both efficiency
and completeness.
• In mechanical term Annealing is a process of hardening a metal or
glass to a high temperature then cooling gradually, so this allows the
metal to reach a low-energy crystalline state.
• The same process is used in simulated annealing in which the
algorithm picks a random move, instead of picking the best move.
• If the random move improves the state, then it follows the same
path.
• Otherwise, the algorithm follows the path which has a probability of
less than 1 or it moves downhill and chooses another path.
Stochastic hill climbing
• Stochastic hill climbing does not focus on all the nodes.
• It selects one node at random and decides whether it
should be expanded or search for a better one.
Random-restart hill climbing
• Random-restart algorithm is based on try and try
strategy.
• It iteratively searches the node and selects the best one
at each step until the goal is not found.
• The success depends most commonly on the shape of
the hill.
• If there are few plateaus, local maxima, and ridges, it
becomes easy to reach the destination.
3/4/2023 16
Department of CSE (AI/ML)
State-space Diagram for Hill Climbing
3/4/2023 Department of CSE (AI/ML) 17
• Local Maximum: Local maximum is a state
which is better than its neighbor states, but there
is also another state which is higher than it.
• Global Maximum: Global maximum is the best
possible state of state space landscape. It has the
highest value of objective function.
• Current state: It is a state in a landscape diagram
where an agent is currently present.
• Flat local maximum: It is a flat space in the
landscape where all the neighbor states of current
states have the same value.
• Shoulder: It is a plateau region which has an
uphill edge.
3/4/2023 18
Department of CSE (AI/ML)
Genetic Algorithm
3/4/2023 Department of CSE (AI/ML) 19
3/4/2023 Department of CSE (AI/ML) 20
3/4/2023 Department of CSE (AI/ML) 21
Topics to be covered in next session 10
• Local Search in Continuous Spaces
3/4/2023 Department of CSE (AI/ML) 22
Thank you!!!

More Related Content

What's hot

AI_Session 6 Iterative deepening Depth-first and bidirectional search.pptx
AI_Session 6 Iterative deepening Depth-first and bidirectional search.pptxAI_Session 6 Iterative deepening Depth-first and bidirectional search.pptx
AI_Session 6 Iterative deepening Depth-first and bidirectional search.pptxAsst.prof M.Gokilavani
 
AI_Session 4 Uniformed search strategies.pptx
AI_Session 4 Uniformed search strategies.pptxAI_Session 4 Uniformed search strategies.pptx
AI_Session 4 Uniformed search strategies.pptxAsst.prof M.Gokilavani
 
Chapter3 Search
Chapter3 SearchChapter3 Search
Chapter3 SearchKhiem Ho
 
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.pptxAsst.prof M.Gokilavani
 
AI search techniques
AI search techniquesAI search techniques
AI search techniquesOmar Isaid
 
Local search algorithms
Local search algorithmsLocal search algorithms
Local search algorithmsbambangsueb
 
Informed and Uninformed search Strategies
Informed and Uninformed search StrategiesInformed and Uninformed search Strategies
Informed and Uninformed search StrategiesAmey Kerkar
 
Heuristic Search Techniques {Artificial Intelligence}
Heuristic Search Techniques {Artificial Intelligence}Heuristic Search Techniques {Artificial Intelligence}
Heuristic Search Techniques {Artificial Intelligence}FellowBuddy.com
 
Heuristic search
Heuristic searchHeuristic search
Heuristic searchNivethaS35
 
Artificial Intelligence -- Search Algorithms
Artificial Intelligence-- Search Algorithms Artificial Intelligence-- Search Algorithms
Artificial Intelligence -- Search Algorithms Syed Ahmed
 
Lecture 11 Informed Search
Lecture 11 Informed SearchLecture 11 Informed Search
Lecture 11 Informed SearchHema Kashyap
 
search strategies in artificial intelligence
search strategies in artificial intelligencesearch strategies in artificial intelligence
search strategies in artificial intelligenceHanif Ullah (Gold Medalist)
 
Uninformed Search technique
Uninformed Search techniqueUninformed Search technique
Uninformed Search techniqueKapil Dahal
 
Ch2 3-informed (heuristic) search
Ch2 3-informed (heuristic) searchCh2 3-informed (heuristic) search
Ch2 3-informed (heuristic) searchchandsek666
 
Uninformed search /Blind search in AI
Uninformed search /Blind search in AIUninformed search /Blind search in AI
Uninformed search /Blind search in AIKirti Verma
 

What's hot (20)

AI_Session 6 Iterative deepening Depth-first and bidirectional search.pptx
AI_Session 6 Iterative deepening Depth-first and bidirectional search.pptxAI_Session 6 Iterative deepening Depth-first and bidirectional search.pptx
AI_Session 6 Iterative deepening Depth-first and bidirectional search.pptx
 
AI_Session 4 Uniformed search strategies.pptx
AI_Session 4 Uniformed search strategies.pptxAI_Session 4 Uniformed search strategies.pptx
AI_Session 4 Uniformed search strategies.pptx
 
Chapter3 Search
Chapter3 SearchChapter3 Search
Chapter3 Search
 
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 search techniques
AI search techniquesAI search techniques
AI search techniques
 
Local search algorithms
Local search algorithmsLocal search algorithms
Local search algorithms
 
AI Lecture 3 (solving problems by searching)
AI Lecture 3 (solving problems by searching)AI Lecture 3 (solving problems by searching)
AI Lecture 3 (solving problems by searching)
 
Informed and Uninformed search Strategies
Informed and Uninformed search StrategiesInformed and Uninformed search Strategies
Informed and Uninformed search Strategies
 
Heuristic Search Techniques {Artificial Intelligence}
Heuristic Search Techniques {Artificial Intelligence}Heuristic Search Techniques {Artificial Intelligence}
Heuristic Search Techniques {Artificial Intelligence}
 
Hill climbing
Hill climbingHill climbing
Hill climbing
 
Knowledge based agents
Knowledge based agentsKnowledge based agents
Knowledge based agents
 
Hill climbing algorithm
Hill climbing algorithmHill climbing algorithm
Hill climbing algorithm
 
Heuristic search
Heuristic searchHeuristic search
Heuristic search
 
Artificial Intelligence -- Search Algorithms
Artificial Intelligence-- Search Algorithms Artificial Intelligence-- Search Algorithms
Artificial Intelligence -- Search Algorithms
 
Lecture 11 Informed Search
Lecture 11 Informed SearchLecture 11 Informed Search
Lecture 11 Informed Search
 
A greedy algorithms
A greedy algorithmsA greedy algorithms
A greedy algorithms
 
search strategies in artificial intelligence
search strategies in artificial intelligencesearch strategies in artificial intelligence
search strategies in artificial intelligence
 
Uninformed Search technique
Uninformed Search techniqueUninformed Search technique
Uninformed Search technique
 
Ch2 3-informed (heuristic) search
Ch2 3-informed (heuristic) searchCh2 3-informed (heuristic) search
Ch2 3-informed (heuristic) search
 
Uninformed search /Blind search in AI
Uninformed search /Blind search in AIUninformed search /Blind search in AI
Uninformed search /Blind search in AI
 

Similar to AI_Session 9 Hill climbing algorithm.pptx

AI3391 Session 11 Hill climbing algorithm.pptx
AI3391 Session 11 Hill climbing algorithm.pptxAI3391 Session 11 Hill climbing algorithm.pptx
AI3391 Session 11 Hill climbing algorithm.pptxAsst.prof M.Gokilavani
 
Heuristc Search Techniques
Heuristc Search TechniquesHeuristc Search Techniques
Heuristc Search TechniquesJismy .K.Jose
 
Informed Search Techniques new kirti L 8.pptx
Informed Search Techniques new kirti L 8.pptxInformed Search Techniques new kirti L 8.pptx
Informed Search Techniques new kirti L 8.pptxKirti Verma
 
hill climbing algorithm.pptx
hill climbing algorithm.pptxhill climbing algorithm.pptx
hill climbing algorithm.pptxMghooolMasier
 
Heuristic Search Techniques Unit -II.ppt
Heuristic Search Techniques Unit -II.pptHeuristic Search Techniques Unit -II.ppt
Heuristic Search Techniques Unit -II.pptkarthikaparthasarath
 
Artificial Intelligence_Anjali_Kumari_26900122059.pptx
Artificial Intelligence_Anjali_Kumari_26900122059.pptxArtificial Intelligence_Anjali_Kumari_26900122059.pptx
Artificial Intelligence_Anjali_Kumari_26900122059.pptxCCBProduction
 
Problem solving in Artificial Intelligence.pptx
Problem solving in Artificial Intelligence.pptxProblem solving in Artificial Intelligence.pptx
Problem solving in Artificial Intelligence.pptxkitsenthilkumarcse
 
AI3391 ARTIFICAL INTELLIGENCE Session 5 Problem Solving Agent and searching f...
AI3391 ARTIFICAL INTELLIGENCE Session 5 Problem Solving Agent and searching f...AI3391 ARTIFICAL INTELLIGENCE Session 5 Problem Solving Agent and searching f...
AI3391 ARTIFICAL INTELLIGENCE Session 5 Problem Solving Agent and searching f...Asst.prof M.Gokilavani
 
Heuristic or informed search
Heuristic or informed searchHeuristic or informed search
Heuristic or informed searchHamzaJaved64
 
Heuristic search
Heuristic searchHeuristic search
Heuristic searchNivethaS35
 
AI_Session 3 Problem Solving Agent and searching for solutions.pptx
AI_Session 3 Problem Solving Agent and searching for solutions.pptxAI_Session 3 Problem Solving Agent and searching for solutions.pptx
AI_Session 3 Problem Solving Agent and searching for solutions.pptxAsst.prof M.Gokilavani
 
24.09.2021 Reinforcement Learning Algorithms.pptx
24.09.2021 Reinforcement Learning Algorithms.pptx24.09.2021 Reinforcement Learning Algorithms.pptx
24.09.2021 Reinforcement Learning Algorithms.pptxManiMaran230751
 
AI3391 Session 12 Local search in continious space.pptx
AI3391 Session 12 Local search in continious space.pptxAI3391 Session 12 Local search in continious space.pptx
AI3391 Session 12 Local search in continious space.pptxAsst.prof M.Gokilavani
 
Heuristic Searching Algorithms Artificial Intelligence.pptx
Heuristic Searching Algorithms Artificial Intelligence.pptxHeuristic Searching Algorithms Artificial Intelligence.pptx
Heuristic Searching Algorithms Artificial Intelligence.pptxSwagat Praharaj
 
Artificial intelligence(04)
Artificial intelligence(04)Artificial intelligence(04)
Artificial intelligence(04)Nazir Ahmed
 
AI3391 ARTIFICIAL INTELLIGENCE UNIT II notes.pdf
AI3391 ARTIFICIAL INTELLIGENCE UNIT II notes.pdfAI3391 ARTIFICIAL INTELLIGENCE UNIT II notes.pdf
AI3391 ARTIFICIAL INTELLIGENCE UNIT II notes.pdfAsst.prof M.Gokilavani
 
UNIT-I Part2 Heuristic Search Techniques.pptx
UNIT-I Part2 Heuristic Search Techniques.pptxUNIT-I Part2 Heuristic Search Techniques.pptx
UNIT-I Part2 Heuristic Search Techniques.pptxVijayaAhire2
 
Heuristic search-in-artificial-intelligence
Heuristic search-in-artificial-intelligenceHeuristic search-in-artificial-intelligence
Heuristic search-in-artificial-intelligencegrinu
 

Similar to AI_Session 9 Hill climbing algorithm.pptx (20)

AI3391 Session 11 Hill climbing algorithm.pptx
AI3391 Session 11 Hill climbing algorithm.pptxAI3391 Session 11 Hill climbing algorithm.pptx
AI3391 Session 11 Hill climbing algorithm.pptx
 
Heuristc Search Techniques
Heuristc Search TechniquesHeuristc Search Techniques
Heuristc Search Techniques
 
Informed Search Techniques new kirti L 8.pptx
Informed Search Techniques new kirti L 8.pptxInformed Search Techniques new kirti L 8.pptx
Informed Search Techniques new kirti L 8.pptx
 
hill climbing algorithm.pptx
hill climbing algorithm.pptxhill climbing algorithm.pptx
hill climbing algorithm.pptx
 
Heuristic Search Techniques Unit -II.ppt
Heuristic Search Techniques Unit -II.pptHeuristic Search Techniques Unit -II.ppt
Heuristic Search Techniques Unit -II.ppt
 
Artificial Intelligence_Anjali_Kumari_26900122059.pptx
Artificial Intelligence_Anjali_Kumari_26900122059.pptxArtificial Intelligence_Anjali_Kumari_26900122059.pptx
Artificial Intelligence_Anjali_Kumari_26900122059.pptx
 
Problem solving in Artificial Intelligence.pptx
Problem solving in Artificial Intelligence.pptxProblem solving in Artificial Intelligence.pptx
Problem solving in Artificial Intelligence.pptx
 
AI_ppt.pptx
AI_ppt.pptxAI_ppt.pptx
AI_ppt.pptx
 
AI3391 ARTIFICAL INTELLIGENCE Session 5 Problem Solving Agent and searching f...
AI3391 ARTIFICAL INTELLIGENCE Session 5 Problem Solving Agent and searching f...AI3391 ARTIFICAL INTELLIGENCE Session 5 Problem Solving Agent and searching f...
AI3391 ARTIFICAL INTELLIGENCE Session 5 Problem Solving Agent and searching f...
 
Heuristic or informed search
Heuristic or informed searchHeuristic or informed search
Heuristic or informed search
 
Heuristic search
Heuristic searchHeuristic search
Heuristic search
 
AI_Session 3 Problem Solving Agent and searching for solutions.pptx
AI_Session 3 Problem Solving Agent and searching for solutions.pptxAI_Session 3 Problem Solving Agent and searching for solutions.pptx
AI_Session 3 Problem Solving Agent and searching for solutions.pptx
 
02LocalSearch.pdf
02LocalSearch.pdf02LocalSearch.pdf
02LocalSearch.pdf
 
24.09.2021 Reinforcement Learning Algorithms.pptx
24.09.2021 Reinforcement Learning Algorithms.pptx24.09.2021 Reinforcement Learning Algorithms.pptx
24.09.2021 Reinforcement Learning Algorithms.pptx
 
AI3391 Session 12 Local search in continious space.pptx
AI3391 Session 12 Local search in continious space.pptxAI3391 Session 12 Local search in continious space.pptx
AI3391 Session 12 Local search in continious space.pptx
 
Heuristic Searching Algorithms Artificial Intelligence.pptx
Heuristic Searching Algorithms Artificial Intelligence.pptxHeuristic Searching Algorithms Artificial Intelligence.pptx
Heuristic Searching Algorithms Artificial Intelligence.pptx
 
Artificial intelligence(04)
Artificial intelligence(04)Artificial intelligence(04)
Artificial intelligence(04)
 
AI3391 ARTIFICIAL INTELLIGENCE UNIT II notes.pdf
AI3391 ARTIFICIAL INTELLIGENCE UNIT II notes.pdfAI3391 ARTIFICIAL INTELLIGENCE UNIT II notes.pdf
AI3391 ARTIFICIAL INTELLIGENCE UNIT II notes.pdf
 
UNIT-I Part2 Heuristic Search Techniques.pptx
UNIT-I Part2 Heuristic Search Techniques.pptxUNIT-I Part2 Heuristic Search Techniques.pptx
UNIT-I Part2 Heuristic Search Techniques.pptx
 
Heuristic search-in-artificial-intelligence
Heuristic search-in-artificial-intelligenceHeuristic search-in-artificial-intelligence
Heuristic search-in-artificial-intelligence
 

More from Asst.prof M.Gokilavani

CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete RecordCCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete RecordAsst.prof M.Gokilavani
 
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdfCCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdfAsst.prof M.Gokilavani
 
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfCCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfAsst.prof M.Gokilavani
 
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdfCCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdfAsst.prof M.Gokilavani
 
IT8073_Information Security_UNIT I _.pdf
IT8073_Information Security_UNIT I _.pdfIT8073_Information Security_UNIT I _.pdf
IT8073_Information Security_UNIT I _.pdfAsst.prof M.Gokilavani
 
IT8073 _Information Security _UNIT I Full notes
IT8073 _Information Security _UNIT I Full notesIT8073 _Information Security _UNIT I Full notes
IT8073 _Information Security _UNIT I Full notesAsst.prof M.Gokilavani
 
GE3151 PSPP UNIT IV QUESTION BANK.docx.pdf
GE3151 PSPP UNIT IV QUESTION BANK.docx.pdfGE3151 PSPP UNIT IV QUESTION BANK.docx.pdf
GE3151 PSPP UNIT IV QUESTION BANK.docx.pdfAsst.prof M.Gokilavani
 
GE3151 PSPP UNIT III QUESTION BANK.docx.pdf
GE3151 PSPP UNIT III QUESTION BANK.docx.pdfGE3151 PSPP UNIT III QUESTION BANK.docx.pdf
GE3151 PSPP UNIT III QUESTION BANK.docx.pdfAsst.prof M.Gokilavani
 
GE3151 UNIT II Study material .pdf
GE3151 UNIT II Study material .pdfGE3151 UNIT II Study material .pdf
GE3151 UNIT II Study material .pdfAsst.prof M.Gokilavani
 
GE3151 PSPP All unit question bank.pdf
GE3151 PSPP All unit question bank.pdfGE3151 PSPP All unit question bank.pdf
GE3151 PSPP All unit question bank.pdfAsst.prof M.Gokilavani
 
AI3391 Artificial intelligence Unit IV Notes _ merged.pdf
AI3391 Artificial intelligence Unit IV Notes _ merged.pdfAI3391 Artificial intelligence Unit IV Notes _ merged.pdf
AI3391 Artificial intelligence Unit IV Notes _ merged.pdfAsst.prof M.Gokilavani
 
AI3391 Artificial intelligence Session 29 Forward and backward chaining.pdf
AI3391 Artificial intelligence Session 29 Forward and backward chaining.pdfAI3391 Artificial intelligence Session 29 Forward and backward chaining.pdf
AI3391 Artificial intelligence Session 29 Forward and backward chaining.pdfAsst.prof M.Gokilavani
 
AI3391 Artificial intelligence Session 28 Resolution.pptx
AI3391 Artificial intelligence Session 28 Resolution.pptxAI3391 Artificial intelligence Session 28 Resolution.pptx
AI3391 Artificial intelligence Session 28 Resolution.pptxAsst.prof M.Gokilavani
 
AI3391 Artificial intelligence session 27 inference and unification.pptx
AI3391 Artificial intelligence session 27 inference and unification.pptxAI3391 Artificial intelligence session 27 inference and unification.pptx
AI3391 Artificial intelligence session 27 inference and unification.pptxAsst.prof M.Gokilavani
 
AI3391 Artificial Intelligence Session 26 First order logic.pptx
AI3391 Artificial Intelligence Session 26 First order logic.pptxAI3391 Artificial Intelligence Session 26 First order logic.pptx
AI3391 Artificial Intelligence Session 26 First order logic.pptxAsst.prof M.Gokilavani
 

More from Asst.prof M.Gokilavani (20)

CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete RecordCCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
CCS335 _ Neural Networks and Deep Learning Laboratory_Lab Complete Record
 
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdfCCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
 
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfCCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
 
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdfCCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
 
IT8073_Information Security_UNIT I _.pdf
IT8073_Information Security_UNIT I _.pdfIT8073_Information Security_UNIT I _.pdf
IT8073_Information Security_UNIT I _.pdf
 
IT8073 _Information Security _UNIT I Full notes
IT8073 _Information Security _UNIT I Full notesIT8073 _Information Security _UNIT I Full notes
IT8073 _Information Security _UNIT I Full notes
 
GE3151 PSPP UNIT IV QUESTION BANK.docx.pdf
GE3151 PSPP UNIT IV QUESTION BANK.docx.pdfGE3151 PSPP UNIT IV QUESTION BANK.docx.pdf
GE3151 PSPP UNIT IV QUESTION BANK.docx.pdf
 
GE3151 PSPP UNIT III QUESTION BANK.docx.pdf
GE3151 PSPP UNIT III QUESTION BANK.docx.pdfGE3151 PSPP UNIT III QUESTION BANK.docx.pdf
GE3151 PSPP UNIT III QUESTION BANK.docx.pdf
 
GE3151 UNIT II Study material .pdf
GE3151 UNIT II Study material .pdfGE3151 UNIT II Study material .pdf
GE3151 UNIT II Study material .pdf
 
GE3151 PSPP All unit question bank.pdf
GE3151 PSPP All unit question bank.pdfGE3151 PSPP All unit question bank.pdf
GE3151 PSPP All unit question bank.pdf
 
GE3151_PSPP_All unit _Notes
GE3151_PSPP_All unit _NotesGE3151_PSPP_All unit _Notes
GE3151_PSPP_All unit _Notes
 
GE3151_PSPP_UNIT_5_Notes
GE3151_PSPP_UNIT_5_NotesGE3151_PSPP_UNIT_5_Notes
GE3151_PSPP_UNIT_5_Notes
 
GE3151_PSPP_UNIT_4_Notes
GE3151_PSPP_UNIT_4_NotesGE3151_PSPP_UNIT_4_Notes
GE3151_PSPP_UNIT_4_Notes
 
GE3151_PSPP_UNIT_3_Notes
GE3151_PSPP_UNIT_3_NotesGE3151_PSPP_UNIT_3_Notes
GE3151_PSPP_UNIT_3_Notes
 
GE3151_PSPP_UNIT_2_Notes
GE3151_PSPP_UNIT_2_NotesGE3151_PSPP_UNIT_2_Notes
GE3151_PSPP_UNIT_2_Notes
 
AI3391 Artificial intelligence Unit IV Notes _ merged.pdf
AI3391 Artificial intelligence Unit IV Notes _ merged.pdfAI3391 Artificial intelligence Unit IV Notes _ merged.pdf
AI3391 Artificial intelligence Unit IV Notes _ merged.pdf
 
AI3391 Artificial intelligence Session 29 Forward and backward chaining.pdf
AI3391 Artificial intelligence Session 29 Forward and backward chaining.pdfAI3391 Artificial intelligence Session 29 Forward and backward chaining.pdf
AI3391 Artificial intelligence Session 29 Forward and backward chaining.pdf
 
AI3391 Artificial intelligence Session 28 Resolution.pptx
AI3391 Artificial intelligence Session 28 Resolution.pptxAI3391 Artificial intelligence Session 28 Resolution.pptx
AI3391 Artificial intelligence Session 28 Resolution.pptx
 
AI3391 Artificial intelligence session 27 inference and unification.pptx
AI3391 Artificial intelligence session 27 inference and unification.pptxAI3391 Artificial intelligence session 27 inference and unification.pptx
AI3391 Artificial intelligence session 27 inference and unification.pptx
 
AI3391 Artificial Intelligence Session 26 First order logic.pptx
AI3391 Artificial Intelligence Session 26 First order logic.pptxAI3391 Artificial Intelligence Session 26 First order logic.pptx
AI3391 Artificial Intelligence Session 26 First order logic.pptx
 

Recently uploaded

Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝soniya singh
 
Introduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxIntroduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxupamatechverse
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Dr.Costas Sachpazis
 
Top Rated Pune Call Girls Budhwar Peth âźź 6297143586 âźź Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth âźź 6297143586 âźź Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth âźź 6297143586 âźź Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth âźź 6297143586 âźź Call Me For Genuine Se...Call Girls in Nagpur High Profile
 
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...Call Girls in Nagpur High Profile
 
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSAPPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSKurinjimalarL3
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINESIVASHANKAR N
 
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptxDecoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptxJoĂŁo Esperancinha
 
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSHARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSRajkumarAkumalla
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Serviceranjana rawat
 
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptxthe ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptxhumanexperienceaaa
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxupamatechverse
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCollege Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCall Girls in Nagpur High Profile
 
HARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IVHARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IVRajaP95
 
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINEDJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINEslot gacor bisa pakai pulsa
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...Soham Mondal
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingrknatarajan
 

Recently uploaded (20)

Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
Model Call Girl in Narela Delhi reach out to us at 🔝8264348440🔝
 
Introduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxIntroduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptx
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
 
Top Rated Pune Call Girls Budhwar Peth âźź 6297143586 âźź Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth âźź 6297143586 âźź Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth âźź 6297143586 âźź Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth âźź 6297143586 âźź Call Me For Genuine Se...
 
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
 
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICSAPPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
APPLICATIONS-AC/DC DRIVES-OPERATING CHARACTERISTICS
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
 
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptxDecoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
Decoding Kotlin - Your guide to solving the mysterious in Kotlin.pptx
 
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICSHARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
HARDNESS, FRACTURE TOUGHNESS AND STRENGTH OF CERAMICS
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
 
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
(RIA) Call Girls Bhosari ( 7001035870 ) HI-Fi Pune Escorts Service
 
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptxthe ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
the ladakh protest in leh ladakh 2024 sonam wangchuk.pptx
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptx
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCollege Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
 
HARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IVHARMONY IN THE NATURE AND EXISTENCE - Unit-IV
HARMONY IN THE NATURE AND EXISTENCE - Unit-IV
 
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINEDJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
 

AI_Session 9 Hill climbing algorithm.pptx

  • 1. ARTIFICAL INTELLIGENCE (R18 III(II Sem)) Department of computer science and engineering (AI/ML) Session 9 by Asst.Prof.M.Gokilavani VITS 3/4/2023 Department of CSE (AI/ML) 1
  • 2. TEXTBOOK: • Artificial Intelligence A modern Approach, Third Edition, Stuart Russell and Peter Norvig, Pearson Education. REFERENCES: • Artificial Intelligence, 3rd Edn, E. Rich and K.Knight (TMH). • Artificial Intelligence, 3rd Edn, Patrick Henny Winston, Pearson Education. • Artificial Intelligence, Shivani Goel, Pearson Education. • Artificial Intelligence and Expert Systems- Patterson, Pearson Education. 3/4/2023 Department of CSE (AI/ML) 2
  • 3. Topics covered in session 9 3/4/2023 Department of CSE (AI/ML) 3 • Problem solving by search-I: Introduction to AI, Intelligent Agents. • Problem solving by search-II: Problem solving agents, searching for solutions • Uniformed search strategies: BFS, Uniform cost search, DFS, Iterative deepening Depth-first search, Bidirectional search, • Informed ( Heuristic) search strategies: Greedy best-first search, A* search, Heuristic functions • Beyond classical search: Hill- climbing Search, Simulated annealing search, Local search in continuous spaces, Searching with non- deterministic Actions, searching with partial observations, online search agents and unknown environments.
  • 4. Beyond classical search • We have seen methods that systematically explore the search space, possibly using principled pruning (e.g., A*) What if we have much larger search spaces? • Search spaces for some real-world problems may be much larger e.g., 1030,000 states as in certain reasoning and planning tasks. • Some of these problems can be solved by Iterative Improvement Methods 3/4/2023 4 Department of CSE (AI/ML)
  • 5. Local Search Algorithms and Optimization Problems • In many optimization problems the goal state itself is the solution. • The state space is a set of complete configurations. • Search is about finding the optimal configuration (as in TSP) or just a feasible configuration (as in scheduling problems). • In such cases, one can use iterative improvement, or local search, methods. • An evaluation, or objective, function h must be available that measures the quality of each state. • Main Idea: Start with a random initial configuration and make small, local changes to it that improve its quality. 3/4/2023 5 Department of CSE (AI/ML)
  • 6. Hill Climbing Algorithm • In Hill-Climbing technique, starting at the base of a hill, we walk upwards until we reach the top of the hill. • In other words, we start with initial state and we keep improving the solution until its optimal. • It's a variation of a generate-and-test algorithm which discards all states which do not look promising or seem unlikely to lead us to the goal state. • To take such decisions, it uses heuristics (an evaluation function) which indicates how close the current state is to the goal state. • Hill-Climbing = generate-and-test + heuristics 3/4/2023 6 Department of CSE (AI/ML)
  • 7. Features of Hill Climbing Following are some main features of Hill Climbing Algorithm: • Generate and Test variant: Hill Climbing is the variant of Generate and Test method. The Generate and Test method produce feedback which helps to decide which direction to move in the search space. • Greedy approach: Hill-climbing algorithm search moves in the direction which optimizes the cost. • No backtracking: It does not backtrack the search space, as it does not remember the previous states. 3/4/2023 Department of CSE (AI/ML) 7
  • 8. Types of Hill Climbing Algorithm • Simple hill Climbing • Steepest-Ascent hill-climbing • Stochastic hill Climbing • Random-restart hill climbing 3/4/2023 Department of CSE (AI/ML) 8
  • 9. Simple Hill Climbing • Simple hill climbing is the simplest way to implement a hill climbing algorithm. • It only evaluates the neighbor node state at a time and selects the first one which optimizes current cost and set it as a current state. • It only checks it's one successor state, and if it finds better than the current state, then move else be in the same state. • This algorithm has the following features: • Less time consuming • Less optimal solution and the solution is not guaranteed 3/4/2023 Department of CSE (AI/ML) 9
  • 10. Algorithm • Define the current state as an initial state • Loop until the goal state is achieved or no more operators can be applied on the current state: – Apply an operation to current state and get a new state – Compare the new state with the goal – Quit if the goal state is achieved – Evaluate new state with heuristic function and compare it with the current state – If the newer state is closer to the goal compared to current state, update the current state • As we can see, it reaches the goal state with iterative improvements. In Hill-Climbing algorithm, finding goal is equivalent to reaching the top of the hill. 3/4/2023 10 Department of CSE (AI/ML)
  • 11. Example • Key point while solving any hill-climbing problem is to choose an appropriate heuristic function. • Let's define such function h: • h(x) = +1 for all the blocks in the support structure if the block is correctly positioned otherwise -1 for all the blocks in the support structure. 3/4/2023 Department of CSE (AI/ML) 11
  • 12. 3/4/2023 Department of CSE (AI/ML) 12
  • 13. Steepest-ascent Hill climbing • Steepest-ascent hill climbing is different from simple hill climbing search. • Unlike simple hill climbing search, It considers all the successive nodes, compares them, and choose the node which is closest to the solution. • Steepest hill climbing search is similar to best- first search because it focuses on each node instead of one. • Note: Both simple, as well as steepest-ascent hill climbing search, fails when there is no closer node. 3/4/2023 13 Department of CSE (AI/ML)
  • 14. Algorithm • Create a CURRENT node and a GOAL node. • If the CURRENT node=GOAL node, return GOAL and terminate the search. • Loop until a better node is not found to reach the solution. • If there is any better successor node present, expand it. • When the GOAL is attained, return GOAL and terminate. 3/4/2023 14 Department of CSE (AI/ML)
  • 15. Simulated Annealing 3/4/2023 Department of CSE (AI/ML) 15 • A hill-climbing algorithm which never makes a move towards a lower value guaranteed to be incomplete because it can get stuck on a local maximum. • And if algorithm applies a random walk, by moving a successor, then it may complete but not efficient. • Simulated Annealing is an algorithm which yields both efficiency and completeness. • In mechanical term Annealing is a process of hardening a metal or glass to a high temperature then cooling gradually, so this allows the metal to reach a low-energy crystalline state. • The same process is used in simulated annealing in which the algorithm picks a random move, instead of picking the best move. • If the random move improves the state, then it follows the same path. • Otherwise, the algorithm follows the path which has a probability of less than 1 or it moves downhill and chooses another path.
  • 16. Stochastic hill climbing • Stochastic hill climbing does not focus on all the nodes. • It selects one node at random and decides whether it should be expanded or search for a better one. Random-restart hill climbing • Random-restart algorithm is based on try and try strategy. • It iteratively searches the node and selects the best one at each step until the goal is not found. • The success depends most commonly on the shape of the hill. • If there are few plateaus, local maxima, and ridges, it becomes easy to reach the destination. 3/4/2023 16 Department of CSE (AI/ML)
  • 17. State-space Diagram for Hill Climbing 3/4/2023 Department of CSE (AI/ML) 17
  • 18. • Local Maximum: Local maximum is a state which is better than its neighbor states, but there is also another state which is higher than it. • Global Maximum: Global maximum is the best possible state of state space landscape. It has the highest value of objective function. • Current state: It is a state in a landscape diagram where an agent is currently present. • Flat local maximum: It is a flat space in the landscape where all the neighbor states of current states have the same value. • Shoulder: It is a plateau region which has an uphill edge. 3/4/2023 18 Department of CSE (AI/ML)
  • 20. 3/4/2023 Department of CSE (AI/ML) 20
  • 21. 3/4/2023 Department of CSE (AI/ML) 21
  • 22. Topics to be covered in next session 10 • Local Search in Continuous Spaces 3/4/2023 Department of CSE (AI/ML) 22 Thank you!!!