Concept

Stable model semantics

Summary
The concept of a stable model, or answer set, is used to define a declarative semantics for logic programs with negation as failure. This is one of several standard approaches to the meaning of negation in logic programming, along with program completion and the well-founded semantics. The stable model semantics is the basis of answer set programming. Research on the declarative semantics of negation in logic programming was motivated by the fact that the behavior of SLDNF resolution — the generalization of SLD resolution used by Prolog in the presence of negation in the bodies of rules — does not fully match the truth tables familiar from classical propositional logic. Consider, for instance, the program Given this program, the query p will succeed, because the program includes p as a fact; the query q will fail, because it does not occur in the head of any of the rules. The query r will fail also, because the only rule with r in the head contains the subgoal q in its body; as we have seen, that subgoal fails. Finally, the query s succeeds, because each of the subgoals p, succeeds. (The latter succeeds because the corresponding positive goal q fails.) To sum up, the behavior of SLDNF resolution on the given program can be represented by the following truth assignment: {| cellpadding=5 style="width:18em" |p |q |r |s |- |T |F |F |T. |} On the other hand, the rules of the given program can be viewed as propositional formulas if we identify the comma with conjunction , the symbol with negation , and agree to treat as the implication written backwards. For instance, the last rule of the given program is, from this point of view, alternative notation for the propositional formula If we calculate the truth values of the rules of the program for the truth assignment shown above then we will see that each rule gets the value T. In other words, that assignment is a model of the program. But this program has also other models, for instance {| cellpadding=5 style="width:18em" |p |q |r |s |- |T |T |T |F.
About this result
This page is automatically generated and may contain information that is not correct, complete, up-to-date, or relevant to your search query. The same applies to every other page on this website. Please make sure to verify the information with EPFL's official sources.