The situation calculus is a logic formalism designed for representing and reasoning about dynamical domains. It was first introduced by John McCarthy in 1963. The main version of the situational calculus that is presented in this article is based on that introduced by Ray Reiter in 1991. It is followed by sections about McCarthy's 1986 version and a logic programming formulation.
Overview The situation calculus represents changing scenarios as a set of first-order logic formulae. The basic elements of the calculus are:
The fluents that describe the state of the world The actions that can be performed in the world The situations A domain is formalized by a number of formulae, namely:
Action precondition axioms, one for each action Successor state axioms, one for each fluent Axioms describing the world in various situations The foundational axioms of the situation calculus A simple robot world will be modeled as a running example. In this world there is a single robot and several inanimate objects. The world is laid out according to a grid so that locations can be specified in terms of ( x , y ) {\displaystyle (x,y)} coordinate points. It is possible for the robot to move around the world, and to pick up and drop items. Some items may be too heavy for the robot to pick up, or fragile so that they break when they are dropped. The robot also has the ability to repair any broken items that it is holding.
Elements The main elements of the situation calculus are the actions, fluents and the situations. A number of objects are also typically involved in the description of the world. The situation calculus is based on a sorted domain with three sorts: actions, situations, and objects, where the objects include everything that is not an action or a situation. Variables of each sort can be used. While actions, situations, and objects are elements of the domain, the fluents are modeled as either predicates or functions.
Actions The actions form a sort of the domain. Variables of sort action can be used and also functions whose result is of sort action. Actions can be quantified. In the example robot world, possible action terms would be m o v e ( x , y ) {\displaystyle move(x,y)} to model the robot moving to a new location ( x , y ) {\displaystyle (x,y)} , and p i c k u p ( o ) {\displaystyle pickup(o)} to model the robot picking up an object o. A special predicate Poss is used to indicate when an action is executable.
Situations In the situation calculus, a dynamic world is modeled as progressing through a series of situations as a result of various actions being performed within the world. A situation represents a history of action occurrences. In the Reiter version of the situation calculus described here, a situation does not represent a state, contrarily to the literal meaning of the term and contrarily to the original definition by McCarthy and Hayes. This point has been summarized by Reiter as follows:
… excerpt ends here. Continue reading the full article.
