SlideShare a Scribd company logo
Simulated
Annealing
Dr L.Srinivasan
Associate Professor/CSE
Dr N.G.P IT
CS3491 –AI & ML
UNIT-1
01
Simulated Annealing
 A variation of hill climbing in which, at the beginning of the process, some
downhill moves may be made.
 Idea is to do enough exploration of the whole space early on , so that the
final solution is relatively insensitive to the starting state.
 Lowering the chances of getting caught at a local maximum, or plateau,
or a ridge.
2
Simulated Annealing
Hill climbing with a twist:
 allow some moves downhill (to worse states)
 start out allowing large downhill moves (to much worse states)and
gradually allow, only small downhill moves
 Based on physical process of annealing a metal to get the best (minimal
energy) state
3
Simulated Annealing
Physical Annealing
 Physical substances are melted and then gradually cooled until some
solid state is reached.
 The goal is to produce a minimal-energy final state.
 This process is one of valley descending where the objective function is
the energy level
4
Simulated Annealing
The rate at which the system is cooled is called annealing schedule
 Annealing schedule: if the temperature is lowered sufficiently slowly,
then the goal will be attained(global minimum).
 If cooled rapidly local minimum but not global minimum is reached
 If too slow time is wasted
 Nevertheless, there is some probability for a transition to a higher energy
state: 𝒆−∆𝑬/𝑻
5
Simulated Annealing
 The search initially jumps around a lot, exploring many regions of the
state space.
 The jumping is gradually reduced and the search becomes a simple hill
climb (search for local optimum).
 The simulated annealing process lowers the temperature by slow stages
until the system ``freezes" and no further changes occur.
6
Simulated Annealing
Algorithm
1. Evaluate the initial state. If it is goal state then return
2. Initialize BEST-SO-FAR to the current state
3. Set T according to an annealing schedule
4. Loop until a solution is found or there are no new operators left to be
applied:
- Selects and applies a new operator
- Evaluate the new state:
goal ->quit
compute ΔE = Val(current state) - Val(new state)
ΔE < 0 -> new current state-if is not goal state but better than the current
state then make it current. Set this state as BEST-SO-FAR 7
Simulated Annealing
Algorithm
else -> If it is not better than the current state make it the
current state with probability p= 𝒆−∆𝑬/𝑻
.
Randomly generate number between [0 1], if
p>number generated, move is accepted else do nothing
- Revise T as necessary according to annealing schedule
5. Return BEST-SO-FAR as answer
8

More Related Content

Similar to CS3491-Unit-1 Simulated Annealing.pptx

Lec 6 bsc csit
Lec 6 bsc csitLec 6 bsc csit
Lec 6 bsc csit
Subash Chandra Pakhrin
 
BeyondClassicalSearch.ppt
BeyondClassicalSearch.pptBeyondClassicalSearch.ppt
BeyondClassicalSearch.ppt
GauravWani20
 
BeyondClassicalSearch.ppt
BeyondClassicalSearch.pptBeyondClassicalSearch.ppt
BeyondClassicalSearch.ppt
jpradha86
 
Thermodynamics
ThermodynamicsThermodynamics
Thermodynamics
Sohaib Butt
 
2nd Law of Thermodynamics.pptx
2nd Law of Thermodynamics.pptx2nd Law of Thermodynamics.pptx
2nd Law of Thermodynamics.pptx
BhaskarTupte2
 
2nd Law of Thermodynamics.pptx
2nd Law of Thermodynamics.pptx2nd Law of Thermodynamics.pptx
2nd Law of Thermodynamics.pptx
BhaskarTupte2
 
unit1.ppt
unit1.pptunit1.ppt
unit1.ppt
samygs1
 

Similar to CS3491-Unit-1 Simulated Annealing.pptx (7)

Lec 6 bsc csit
Lec 6 bsc csitLec 6 bsc csit
Lec 6 bsc csit
 
BeyondClassicalSearch.ppt
BeyondClassicalSearch.pptBeyondClassicalSearch.ppt
BeyondClassicalSearch.ppt
 
BeyondClassicalSearch.ppt
BeyondClassicalSearch.pptBeyondClassicalSearch.ppt
BeyondClassicalSearch.ppt
 
Thermodynamics
ThermodynamicsThermodynamics
Thermodynamics
 
2nd Law of Thermodynamics.pptx
2nd Law of Thermodynamics.pptx2nd Law of Thermodynamics.pptx
2nd Law of Thermodynamics.pptx
 
2nd Law of Thermodynamics.pptx
2nd Law of Thermodynamics.pptx2nd Law of Thermodynamics.pptx
2nd Law of Thermodynamics.pptx
 
unit1.ppt
unit1.pptunit1.ppt
unit1.ppt
 

Recently uploaded

Water Industry Process Automation and Control Monthly - May 2024.pdf
Water Industry Process Automation and Control Monthly - May 2024.pdfWater Industry Process Automation and Control Monthly - May 2024.pdf
Water Industry Process Automation and Control Monthly - May 2024.pdf
Water Industry Process Automation & Control
 
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
obonagu
 
HYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generationHYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generation
Robbie Edward Sayers
 
ML for identifying fraud using open blockchain data.pptx
ML for identifying fraud using open blockchain data.pptxML for identifying fraud using open blockchain data.pptx
ML for identifying fraud using open blockchain data.pptx
Vijay Dialani, PhD
 
The Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdfThe Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdf
Pipe Restoration Solutions
 
Student information management system project report ii.pdf
Student information management system project report ii.pdfStudent information management system project report ii.pdf
Student information management system project report ii.pdf
Kamal Acharya
 
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
 
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
Amil Baba Dawood bangali
 
block diagram and signal flow graph representation
block diagram and signal flow graph representationblock diagram and signal flow graph representation
block diagram and signal flow graph representation
Divya Somashekar
 
MCQ Soil mechanics questions (Soil shear strength).pdf
MCQ Soil mechanics questions (Soil shear strength).pdfMCQ Soil mechanics questions (Soil shear strength).pdf
MCQ Soil mechanics questions (Soil shear strength).pdf
Osamah Alsalih
 
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
H.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdfH.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdf
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
MLILAB
 
Standard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - NeometrixStandard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - Neometrix
Neometrix_Engineering_Pvt_Ltd
 
Architectural Portfolio Sean Lockwood
Architectural Portfolio Sean LockwoodArchitectural Portfolio Sean Lockwood
Architectural Portfolio Sean Lockwood
seandesed
 
一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理
一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理
一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理
bakpo1
 
DESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docxDESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docx
FluxPrime1
 
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
 
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
 
CME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional ElectiveCME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional Elective
karthi keyan
 
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptxCFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
R&R Consult
 
Hierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power SystemHierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power System
Kerry Sado
 

Recently uploaded (20)

Water Industry Process Automation and Control Monthly - May 2024.pdf
Water Industry Process Automation and Control Monthly - May 2024.pdfWater Industry Process Automation and Control Monthly - May 2024.pdf
Water Industry Process Automation and Control Monthly - May 2024.pdf
 
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
 
HYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generationHYDROPOWER - Hydroelectric power generation
HYDROPOWER - Hydroelectric power generation
 
ML for identifying fraud using open blockchain data.pptx
ML for identifying fraud using open blockchain data.pptxML for identifying fraud using open blockchain data.pptx
ML for identifying fraud using open blockchain data.pptx
 
The Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdfThe Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdf
 
Student information management system project report ii.pdf
Student information management system project report ii.pdfStudent information management system project report ii.pdf
Student information management system project report ii.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...
 
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...
 
block diagram and signal flow graph representation
block diagram and signal flow graph representationblock diagram and signal flow graph representation
block diagram and signal flow graph representation
 
MCQ Soil mechanics questions (Soil shear strength).pdf
MCQ Soil mechanics questions (Soil shear strength).pdfMCQ Soil mechanics questions (Soil shear strength).pdf
MCQ Soil mechanics questions (Soil shear strength).pdf
 
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
H.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdfH.Seo,  ICLR 2024, MLILAB,  KAIST AI.pdf
H.Seo, ICLR 2024, MLILAB, KAIST AI.pdf
 
Standard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - NeometrixStandard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - Neometrix
 
Architectural Portfolio Sean Lockwood
Architectural Portfolio Sean LockwoodArchitectural Portfolio Sean Lockwood
Architectural Portfolio Sean Lockwood
 
一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理
一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理
一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理
 
DESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docxDESIGN A COTTON SEED SEPARATION MACHINE.docx
DESIGN A COTTON SEED SEPARATION MACHINE.docx
 
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
 
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
 
CME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional ElectiveCME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional Elective
 
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptxCFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
 
Hierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power SystemHierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power System
 

CS3491-Unit-1 Simulated Annealing.pptx

  • 2. Simulated Annealing  A variation of hill climbing in which, at the beginning of the process, some downhill moves may be made.  Idea is to do enough exploration of the whole space early on , so that the final solution is relatively insensitive to the starting state.  Lowering the chances of getting caught at a local maximum, or plateau, or a ridge. 2
  • 3. Simulated Annealing Hill climbing with a twist:  allow some moves downhill (to worse states)  start out allowing large downhill moves (to much worse states)and gradually allow, only small downhill moves  Based on physical process of annealing a metal to get the best (minimal energy) state 3
  • 4. Simulated Annealing Physical Annealing  Physical substances are melted and then gradually cooled until some solid state is reached.  The goal is to produce a minimal-energy final state.  This process is one of valley descending where the objective function is the energy level 4
  • 5. Simulated Annealing The rate at which the system is cooled is called annealing schedule  Annealing schedule: if the temperature is lowered sufficiently slowly, then the goal will be attained(global minimum).  If cooled rapidly local minimum but not global minimum is reached  If too slow time is wasted  Nevertheless, there is some probability for a transition to a higher energy state: 𝒆−∆𝑬/𝑻 5
  • 6. Simulated Annealing  The search initially jumps around a lot, exploring many regions of the state space.  The jumping is gradually reduced and the search becomes a simple hill climb (search for local optimum).  The simulated annealing process lowers the temperature by slow stages until the system ``freezes" and no further changes occur. 6
  • 7. Simulated Annealing Algorithm 1. Evaluate the initial state. If it is goal state then return 2. Initialize BEST-SO-FAR to the current state 3. Set T according to an annealing schedule 4. Loop until a solution is found or there are no new operators left to be applied: - Selects and applies a new operator - Evaluate the new state: goal ->quit compute ΔE = Val(current state) - Val(new state) ΔE < 0 -> new current state-if is not goal state but better than the current state then make it current. Set this state as BEST-SO-FAR 7
  • 8. Simulated Annealing Algorithm else -> If it is not better than the current state make it the current state with probability p= 𝒆−∆𝑬/𝑻 . Randomly generate number between [0 1], if p>number generated, move is accepted else do nothing - Revise T as necessary according to annealing schedule 5. Return BEST-SO-FAR as answer 8