Problem Solving Well-formed predicate calculus expressions provide a means of describing objects and relations in a problem domain and inference rule.

Slides:



Advertisements
Similar presentations
ARTIFICIAL INTELLIGENCE [INTELLIGENT AGENTS PARADIGM] Professor Janis Grundspenkis Riga Technical University Faculty of Computer Science and Information.
Advertisements

CSC411Artificial Intelligence 1 Chapter 3 Structures and Strategies For Space State Search Contents Graph Theory Strategies for Space State Search Using.
1 SE-561 Formal Methods in Software Petri Nets - I.
22C:19 Discrete Math Graphs Fall 2010 Sukumar Ghosh.
Introduction to Graph “theory”
Chapter 7 Graph Theory 7.1 Modeling with graphs and finding Euler circuits. Learning Objectives: Know how to use graphs as models and how to determine.
Formal Description of a Problem
KU NLP Artificial Intelligence1 Ch 3. Structures and Strategies for State Space Search q Introduction q Graph Theory  Structures for state space search.
CSC 423 ARTIFICIAL INTELLIGENCE
Graphs Graphs are the most general data structures we will study in this course. A graph is a more general version of connected nodes than the tree. Both.
ISBN Chapter 3 Describing Syntax and Semantics.
1 Semantic Description of Programming languages. 2 Static versus Dynamic Semantics n Static Semantics represents legal forms of programs that cannot be.
Problem Solving and Search in AI Part I Search and Intelligence Search is one of the most powerful approaches to problem solving in AI Search is a universal.
A RTIFICIAL I NTELLIGENCE Problem-Solving Solving problems by searching.
Graphs and Trees This handout: Total degree of a graph Applications of Graphs.
Building Control Algorithms For State Space Search
State Spaces Introduction to Artificial Intelligence Dr. Robin Burke.
Problem solving by Searching Problem Formulation.
Structures and Strategies for State Space Search
Structures and Strategies for State Space Search
Artificial Intelligence Problem solving by searching CSC 361 Prof. Mohamed Batouche Computer Science Department CCIS – King Saud University Riyadh, Saudi.
Representing Graphs Wade Trappe. Lecture Overview Introduction Some Terminology –Paths Adjacency Matrix.
Introduction to Networks HON207. Graph Theory In mathematics and computer science, graph theory is the study of graphs, mathematical structures used to.
Dr Eleni Mangina – COURSE: LOGIC PROGRAMMING (during a joint degree with Fudan University in Software Engineering) DEPT. OF COMPUTER SCIENCE UCD Problem.
Artificial Intelligence Problem solving by searching CSC 361
Graphs. Graph A “graph” is a collection of “nodes” that are connected to each other Graph Theory: This novel way of solving problems was invented by a.
Describing Syntax and Semantics
Representation  A farmer wants to move himself, a hunrgry silver fox, a hungry, fat goose, and a sack of tasty grain across a river. Unfortunately, his.
1 Structures and Strategies for State Space Search 3 3.0Introduction 3.1Graph Theory 3.2Strategies for State Space Search 3.3Using the State Space to Represent.
Graphs and Trees This handout: Terminology of Graphs Applications of Graphs.
Artificial Intelligence Problem solving by searching CSC 361 Prof. Mohamed Batouche Computer Science Department CCIS – King Saud University Riyadh, Saudi.
The Bridge Obsession Problem By Vamshi Krishna Vedam.
1 State Space of a Problem Lecture 03 ITS033 – Programming & Algorithms Asst. Prof.
Formal Description of a Problem In AI, we will formally define a problem as –a space of all possible configurations where each configuration is called.
It's a world-wide webby wonderland.. Graphs are often used to represent real-world information and real-world structures. Graph Theory was even invented.
Lecture 07: Formal Methods in SE Finite Automata Lecture # 07 Qaisar Javaid Assistant Professor.
Knowledge and search, page 1 CSI 4106, Winter 2005 Knowledge and search Points Properties of knowledge  Completeness  Objectivity  Certainty  Formalizability.
ARTIFICIAL INTELLIGENCE [INTELLIGENT AGENTS PARADIGM] Professor Janis Grundspenkis Riga Technical University Faculty of Computer Science and Information.
CS 415 – A.I. Slide Set 5. Chapter 3 Structures and Strategies for State Space Search – Predicate Calculus: provides a means of describing objects and.
Formal Description of a Problem In AI, we will formally define a problem as –a space of all possible configurations where each configuration is called.
3.2 Semantics. 2 Semantics Attribute Grammars The Meanings of Programs: Semantics Sebesta Chapter 3.
Knowledge Representation
Combinatorial Optimization Lecturer Kononov Alexander Veniaminovich.
The Seven Bridges of Konigsberg (circa 1735) In Konigsberg, Germany, a river ran through the city such that in its centre was an island, and after passing.
Lecture 11: 9.4 Connectivity Paths in Undirected & Directed Graphs Graph Isomorphisms Counting Paths between Vertices 9.5 Euler and Hamilton Paths Euler.
1/16 Problem solving by Searching Problem Formulation.
Chap 4: Searching Techniques Artificial Intelligence Dr.Hassan Al-Tarawneh.
Knowledge Representation & Logic
Knowledge Representation
Week 7 - Monday CS 113.
Breadth First and Depth First
Problem solving by Searching
Introduction to Artificial Intelligence
Some problems Cse-402 K3r20,k3r23.
STATE SPACE REPRESENTATION
Knowledge Representation
Chap 4: Searching Techniques Artificial Intelligence Dr.Hassan Al-Tarawneh.
Artificial Intelligence Problem solving by searching CSC 361
4. Computational Problem Solving
Some problems Cse-402 K3r20,k3r23.
STATE SPACE REPRESENTATION
Problem Solving by Searching Search Methods :
Knowledge Representation
Chap 4: Searching Techniques
CSE (c) S. Tanimoto, 2002 State-Space Search
Artificial Intelligence
ARTIFICIAL INTELLIGENCE
CSE (c) S. Tanimoto, 2004 State-Space Search
Lecture One: Automata Theory Amjad Ali
Problem Solving by Searching Search Methods :
Presentation transcript:

Problem Solving Well-formed predicate calculus expressions provide a means of describing objects and relations in a problem domain and inference rule. These inferences define a space that is searched to find a problem solution. Questions: -Is the problem solver guaranteed to find a solution? -Will the problem solver always terminate, or can it become caught in an infinite loop? -What is the complexity of the search process in terms of time usage? Space usage? -How can the interpreted most effectively reduce search complexity? -How can an interpreter be designed to most effectively utilize a representation language? PROBLEM  STATE SPACE GRAPH!

GRAPH A graph consists of a set of nodes and a set of arcs and links connecting pairs of nodes. In the state space model of problem solving, the nodes of a graph are taken to represent discrete states in a problem solving process, such as the results of logical inferences or configuration of a game board. The arcs of the graph represent transitions between states. These transitions correspond to logical inferences or legal moves of a game. In expert systems for example, states describe our knowledge of a problem instance at some stage of a reasoning process. Expert knowledge in the form of If.. Then.. Else…, allows us to generate new information; the act of applying a rule is represented as an arc between states.

The city of Konigsberg The Austrian mathematician Leonhard Euler invented graph theory to solve the “bridges of Konigsberg problem”. The city of Konigsberg occupied both banks and two islands of a river. The islands and the riverbanks were connected by seven bridges: RIVERBANK 1 RIVERBANK 2 ISLAND 1ISLAND

The city of Konigsberg (cont.) The bridges of Konigsberg problem asks if there is a walk around the city that crosses each bridge exactly once! Although the residents had failed to find such a walk and doubled that it was possible, no one had proved its impossibility. Euler  graph theory rb1: riverbank 1 rb2: riverbank 2 b3 b1 b6 b2 b4 b5 b7 rb1 rb2 i1i2

The city of Konigsberg (cont.) The graph representation ignores features such as distance and direction! Predicate Calculus: connect(i1,i2,b1)connect(i2,i1,b1) connect(rb1,i1,b2)connect(i1,rb1,b2) connect(rb1,i1,b3)connect(i1,rb1,b3) connect(rb1,i2,b4)connect(i2,rb1,b4) connect(rb2,i1,b5)connect(i1,rb2,b5) connect(rb2,i1,b6)connect(i1,rb2,b6) connect(rb2,i2,b7)connect(i2,rb2,b7) b3 b1 b6 b2 b4 b5 b7 rb1 rb2 i1i2

A river runs through it! A farmer wishes to carry a wolf (the family pet), a goat and a cabbage across a river, from the south to the north shore. The farmer is the proud owner of a small rowing boat called Bounty which he feels is easily up to the job. Unfortunately the boat is only large enough to carry at most the farmer and one other item. Worse again, if left unattended the wolf will eat the goat and the goat will eat the cabbage. How can the farmer safely transport the wolf, goat and cabbage to the opposite shore? North Shore South Shore FW CG

Problem Representation The key to problem solving is a good representation. A good representation scheme has the following properties:- Make important objects and relations explicit Suppress unimportant and irrelevant detail Expose natural constraints Concise – efficiently describe a given scenario Complete – everything necessary can be described Described in English the river problem is confusing enough to be difficult to solve. It emphasizes irrelevant detail (the wolf being a family pet, the name of the boat etc.) and disguises relevant information (the position of the objects, etc.)

States & Operators We can come up with a much better representation… One way is to think in terms of states. A state is a description of a system at some point in time. Many problems can be formally defined by the following components: - An initial state A goal state An operator set – each operator can transform one state into another A problem is solved by moving from the initial state to the goal state by applying valid operators in sequence – this defines the problem state space, the set of states reachable from a particular initial state. A problem solution is simply the set of operators (actions) needed to reach the goal state from the initial state

Initial Goal

For Example… Consider again the farmer and his boat. In this problem state information can be represented in the form of the following 4- tuple ( a?b?c?d?) FarmerWolfGoatCabbage Each variable position stores the location of a particular object. For example the initial state where everyone is on the south bank is given by (S,S,S,S) while the goal state is represented by (N,N,N,N). There are 4 state transforming operators:- Farmer-Takes-Self: (a?,b?,c?,d?)  (Opposite(a?), b?,c?,d?) Farmer-Takes-Wolf: (a?,b?,c?,d?)  (Opposite(a?), Opposite(b?),c?,d?) Farmer-Takes-Goat: (a?,b?,c?,d?)  (Opposite(a?), b?,Opposite(c?),d?) Farmer-Takes-Cabbage: (a?,b?,c?,d?)  (Opposite(a?), b?, c?,Opposite( d?)) Finally, a state is safe as long as the wolf and goat or the goat and cabbage are not left unattended – this precondition each operator.

Cont.. Here is one 7 step solution to the boating problem. There are of course other possibilities. S1: (S,S,S,S)S2: (N,S,N,S) S4: (S,S,N,S) S3: (N,N,N,S) S5: (S,N,S,S) S6: (N,N,S,N) S8: (N,N,N,N) S7: (S,N,S,N) NN F W G C W C F G G F W C F W G C W F G C F W C G W C F G F W G C