SlideShare a Scribd company logo
1 of 8
Artificial Intelligence
State Space Representation in AI
Mr. M Ratnakar babu
• To find the solution to any problem first condition is that it must be defined or
represented precisely. That means to present an abstract problem in real workable
states that are understandable.
• These states are then operated by some set of operators and finally the solution is
obtained.
• The decision of which operator is to be applied is taken by the control strategy
used.
There are two ways in which AI Problems can be represented.
 State Space Representation.
 Problem Reduction.
State Space Representation
State space representation consist of defining initial state(From start state),
The Goal state (The destination) and Then we follow certain set of sequence of
steps(called States).
• State: AI problem can be represented as a well formed set of possible states.
State can initial state i.e. starting point ,Goal state i.e. destination point and
various other possible set of states between them which are formed by
applying certain set of rules.
• Space: In an AI problem set of all possible states are called space.
• Search: Search is a technique which takes the initial state to the goal state by
applying certain set of valid rules while moving through space of all possible states.
• So to do the search process we need the following
• Initial state
• Set of valid rules
• Goal state
So set of all possible states for a given problem is known as State Space
Representation.
Water jug problem in Artificial Intelligence
• In the water jug problem in Artificial Intelligence, we are provided with two jugs:
one having the capacity to hold 3 gallons of water and the other has the capacity
to hold 4 gallons of water.
• There is no other measuring equipment available and the jugs also do not have
any kind of marking on them.
• So, the agent’s task here is to fill the 4-gallon jug with 2 gallons of water by using
only these two jugs and no other material.
• Initially, both our jugs are empty.
Production rules for solving the water jug problem
Here, let x denote the 4-gallon jug and y denote the 3-gallon jug.
S.
No
.
Initial
State
Condition Final state Description of action taken
1. (x,y) If x<4 (4,y) Fill the 4 gallon jug completely
2. (x,y) if y<3 (x,3) Fill the 3 gallon jug completely
3. (x,y) If x>0 (x-d,y) Pour some part from the 4 gallon jug
4. (x,y) If y>0 (x,y-d) Pour some part from the 3 gallon jug
5. (x,y) If x>0 (0,y) Empty the 4 gallon jug
6. (x,y) If y>0 (x,0) Empty the 3 gallon jug
7. (x,y) If (x+y)<7 (4, y-[4-x]) Pour some water from the 3 gallon jug to fill the four gallon jug
8. (x,y) If (x+y)<7 (x-[3-y],y) Pour some water from the 4 gallon jug to fill the 3 gallon jug.
9. (x,y) If (x+y)<4 (x+y,0) Pour all water from 3 gallon jug to the 4 gallon jug
10. (x,y) if (x+y)<3 (0, x+y) Pour all water from the 4 gallon jug to the 3 gallon jug
Solution of water jug problem according to the production rules
S.No. 4 gallon jug contents 3 gallon jug contents Rule followed
1. 0 gallon 0 gallon Initial state
2. 0 gallon 3 gallons Rule no.2
3. 3 gallons 0 gallon Rule no. 9
4. 3 gallons 3 gallons Rule no. 2
5. 4 gallons 2 gallons Rule no. 7
6. 0 gallon 2 gallons Rule no. 5
7. 2 gallons 0 gallon Rule no. 9
On reaching the 7th attempt, we reach a state which is our goal state. Therefore, at this
state, our problem is solved.
Continue…

More Related Content

Similar to AI-State Space Representation.pptx

Chapter2final 130103081315-phpapp02
Chapter2final 130103081315-phpapp02Chapter2final 130103081315-phpapp02
Chapter2final 130103081315-phpapp02
Madhan Kumar
 
(Radhika) presentation on chapter 2 ai
(Radhika) presentation on chapter 2 ai(Radhika) presentation on chapter 2 ai
(Radhika) presentation on chapter 2 ai
Radhika Srinivasan
 

Similar to AI-State Space Representation.pptx (20)

Ai lecture 8(unit02)
Ai lecture  8(unit02)Ai lecture  8(unit02)
Ai lecture 8(unit02)
 
Problems problem spaces and search
Problems problem spaces and searchProblems problem spaces and search
Problems problem spaces and search
 
Amit ppt
Amit pptAmit ppt
Amit ppt
 
AI problem solving.pptx
AI problem solving.pptxAI problem solving.pptx
AI problem solving.pptx
 
Problem space
Problem spaceProblem space
Problem space
 
Problem space
Problem spaceProblem space
Problem space
 
Problem space
Problem spaceProblem space
Problem space
 
Water jug problem ai part 6
Water jug problem ai part 6Water jug problem ai part 6
Water jug problem ai part 6
 
Ch 2 State Space Search - slides part 1.pdf
Ch 2 State Space Search - slides part 1.pdfCh 2 State Space Search - slides part 1.pdf
Ch 2 State Space Search - slides part 1.pdf
 
aiMODULE 1.pptx
aiMODULE 1.pptxaiMODULE 1.pptx
aiMODULE 1.pptx
 
Chapter2final 130103081315-phpapp02
Chapter2final 130103081315-phpapp02Chapter2final 130103081315-phpapp02
Chapter2final 130103081315-phpapp02
 
Production system
Production systemProduction system
Production system
 
chapterThree.pptx
chapterThree.pptxchapterThree.pptx
chapterThree.pptx
 
Ai unit-3
Ai unit-3Ai unit-3
Ai unit-3
 
Chapter 2 (final)
Chapter 2 (final)Chapter 2 (final)
Chapter 2 (final)
 
Goal stack planning.ppt
Goal stack planning.pptGoal stack planning.ppt
Goal stack planning.ppt
 
Search-Beyond-Classical-no-exercise-answers.pdf
Search-Beyond-Classical-no-exercise-answers.pdfSearch-Beyond-Classical-no-exercise-answers.pdf
Search-Beyond-Classical-no-exercise-answers.pdf
 
(Radhika) presentation on chapter 2 ai
(Radhika) presentation on chapter 2 ai(Radhika) presentation on chapter 2 ai
(Radhika) presentation on chapter 2 ai
 
Cs 361 2015 lec 1-2
Cs 361 2015 lec 1-2Cs 361 2015 lec 1-2
Cs 361 2015 lec 1-2
 
Cs 361 2015 lec 1-2
Cs 361 2015 lec 1-2Cs 361 2015 lec 1-2
Cs 361 2015 lec 1-2
 

More from Ratnakar Mikkili (9)

AI-State Space Representation.pptx
AI-State Space Representation.pptxAI-State Space Representation.pptx
AI-State Space Representation.pptx
 
Artificial Intelligence_Searching.pptx
Artificial Intelligence_Searching.pptxArtificial Intelligence_Searching.pptx
Artificial Intelligence_Searching.pptx
 
Artificial Intelligence_Environment.pptx
Artificial Intelligence_Environment.pptxArtificial Intelligence_Environment.pptx
Artificial Intelligence_Environment.pptx
 
2_2Specification of Tokens.ppt
2_2Specification of Tokens.ppt2_2Specification of Tokens.ppt
2_2Specification of Tokens.ppt
 
2_4 Finite Automata.ppt
2_4 Finite Automata.ppt2_4 Finite Automata.ppt
2_4 Finite Automata.ppt
 
Regular expressions
Regular expressionsRegular expressions
Regular expressions
 
Push down automata
Push down automataPush down automata
Push down automata
 
Context free grammar
Context free grammarContext free grammar
Context free grammar
 
Introduction TO Finite Automata
Introduction TO Finite AutomataIntroduction TO Finite Automata
Introduction TO Finite Automata
 

Recently uploaded

Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Christo Ananth
 
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
 
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
dharasingh5698
 
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
rknatarajan
 
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar ≼🔝 Delhi door step de...
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar  ≼🔝 Delhi door step de...Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar  ≼🔝 Delhi door step de...
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar ≼🔝 Delhi door step de...
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 

Recently uploaded (20)

Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 
Vivazz, Mieres Social Housing Design Spain
Vivazz, Mieres Social Housing Design SpainVivazz, Mieres Social Housing Design Spain
Vivazz, Mieres Social Housing Design Spain
 
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
 
PVC VS. FIBERGLASS (FRP) GRAVITY SEWER - UNI BELL
PVC VS. FIBERGLASS (FRP) GRAVITY SEWER - UNI BELLPVC VS. FIBERGLASS (FRP) GRAVITY SEWER - UNI BELL
PVC VS. FIBERGLASS (FRP) GRAVITY SEWER - UNI BELL
 
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...
 
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
 
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance BookingCall Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
 
Call for Papers - International Journal of Intelligent Systems and Applicatio...
Call for Papers - International Journal of Intelligent Systems and Applicatio...Call for Papers - International Journal of Intelligent Systems and Applicatio...
Call for Papers - International Journal of Intelligent Systems and Applicatio...
 
Thermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - VThermal Engineering-R & A / C - unit - V
Thermal Engineering-R & A / C - unit - V
 
University management System project report..pdf
University management System project report..pdfUniversity management System project report..pdf
University management System project report..pdf
 
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
 
Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)
 
UNIT-IFLUID PROPERTIES & FLOW CHARACTERISTICS
UNIT-IFLUID PROPERTIES & FLOW CHARACTERISTICSUNIT-IFLUID PROPERTIES & FLOW CHARACTERISTICS
UNIT-IFLUID PROPERTIES & FLOW CHARACTERISTICS
 
Thermal Engineering Unit - I & II . ppt
Thermal Engineering  Unit - I & II . pptThermal Engineering  Unit - I & II . ppt
Thermal Engineering Unit - I & II . ppt
 
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
 
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
 
Roadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and RoutesRoadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and Routes
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and Properties
 
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar ≼🔝 Delhi door step de...
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar  ≼🔝 Delhi door step de...Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar  ≼🔝 Delhi door step de...
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar ≼🔝 Delhi door step de...
 

AI-State Space Representation.pptx

  • 1. Artificial Intelligence State Space Representation in AI Mr. M Ratnakar babu
  • 2. • To find the solution to any problem first condition is that it must be defined or represented precisely. That means to present an abstract problem in real workable states that are understandable. • These states are then operated by some set of operators and finally the solution is obtained. • The decision of which operator is to be applied is taken by the control strategy used. There are two ways in which AI Problems can be represented.  State Space Representation.  Problem Reduction.
  • 3. State Space Representation State space representation consist of defining initial state(From start state), The Goal state (The destination) and Then we follow certain set of sequence of steps(called States). • State: AI problem can be represented as a well formed set of possible states. State can initial state i.e. starting point ,Goal state i.e. destination point and various other possible set of states between them which are formed by applying certain set of rules. • Space: In an AI problem set of all possible states are called space.
  • 4. • Search: Search is a technique which takes the initial state to the goal state by applying certain set of valid rules while moving through space of all possible states. • So to do the search process we need the following • Initial state • Set of valid rules • Goal state So set of all possible states for a given problem is known as State Space Representation.
  • 5. Water jug problem in Artificial Intelligence • In the water jug problem in Artificial Intelligence, we are provided with two jugs: one having the capacity to hold 3 gallons of water and the other has the capacity to hold 4 gallons of water. • There is no other measuring equipment available and the jugs also do not have any kind of marking on them. • So, the agent’s task here is to fill the 4-gallon jug with 2 gallons of water by using only these two jugs and no other material. • Initially, both our jugs are empty.
  • 6. Production rules for solving the water jug problem Here, let x denote the 4-gallon jug and y denote the 3-gallon jug. S. No . Initial State Condition Final state Description of action taken 1. (x,y) If x<4 (4,y) Fill the 4 gallon jug completely 2. (x,y) if y<3 (x,3) Fill the 3 gallon jug completely 3. (x,y) If x>0 (x-d,y) Pour some part from the 4 gallon jug 4. (x,y) If y>0 (x,y-d) Pour some part from the 3 gallon jug 5. (x,y) If x>0 (0,y) Empty the 4 gallon jug 6. (x,y) If y>0 (x,0) Empty the 3 gallon jug 7. (x,y) If (x+y)<7 (4, y-[4-x]) Pour some water from the 3 gallon jug to fill the four gallon jug 8. (x,y) If (x+y)<7 (x-[3-y],y) Pour some water from the 4 gallon jug to fill the 3 gallon jug. 9. (x,y) If (x+y)<4 (x+y,0) Pour all water from 3 gallon jug to the 4 gallon jug 10. (x,y) if (x+y)<3 (0, x+y) Pour all water from the 4 gallon jug to the 3 gallon jug
  • 7. Solution of water jug problem according to the production rules S.No. 4 gallon jug contents 3 gallon jug contents Rule followed 1. 0 gallon 0 gallon Initial state 2. 0 gallon 3 gallons Rule no.2 3. 3 gallons 0 gallon Rule no. 9 4. 3 gallons 3 gallons Rule no. 2 5. 4 gallons 2 gallons Rule no. 7 6. 0 gallon 2 gallons Rule no. 5 7. 2 gallons 0 gallon Rule no. 9 On reaching the 7th attempt, we reach a state which is our goal state. Therefore, at this state, our problem is solved.