Definitionadvanced
Well-founded semantics
Also called Van Gelder-Ross-Schlipf semantics, WFS.
The well-founded semantics gives every normal program one three-valued model. Atoms are true when forced by the rules, false when only unfounded support exists, and undefined otherwise.
The well-founded semantics assigns to every normal logic program a single three-valued model, the well-founded model. An atom is true if the rules force it, false if every way to derive it depends on atoms that are false or on itself, and undefined if neither holds. Van Gelder, Ross and Schlipf (1991) defined it with unfounded sets. It extends the standard model of stratified programs to all programs, and it is more cautious than the stable model semantics: it never picks between alternatives. This page gives the definition and its properties. The two ways to compute it are on their own pages: the bottom-up alternating fixpoint and the goal-directed SLG resolution.
Definition
Let be a ground normal program over the atoms . A partial interpretation is a pair of disjoint sets of atoms, the true and the false ones; the other atoms are undefined. A positive literal is true in if and false if ; a literal is true if and false if . Pairs are ordered by if and .
A set is unfounded with respect to if each rule with its head in has
- a body literal that is false in , or
- a positive body atom in .
The union of unfounded sets is unfounded, so there is a greatest unfounded set . Let be the set of heads of the rules whose body is true in . The operator
is monotone, and the well-founded model is its least fixed point, reached by iterating from . The model is total if every atom is true or false. For programs with variables, is the ground instance and the iteration can be transfinite.
Van Gelder (1993) gave an equivalent form with the reduct. Let . Since is antimonotone, is monotone. If is the least fixed point of and , then the true atoms are and the false atoms are .
Examples and non-examples
Take the program
a ← not b. b ← not a.
c ← not c.
d ← not e. e ← e.
f ← d, not c.
g ← a.
The iteration of from is
| step | true | false |
|---|---|---|
| 0 | ||
| 1 | ||
| 2 | ||
| 3 |
In step 1, is unfounded because its only rule needs itself. In step 2, is true since is true. The atoms stay undefined: and block each other, blocks itself, and and depend on them. This program has no stable model, because of , while its well-founded model exists and says something about and .
- Stratified program. For , the model is total: true, false. This is the standard model.
- Positive loop. makes false, since is unfounded. The completion allows to be true.
- Win game. With , a position is true if it is won, false if it is lost, and undefined if the play can be drawn by moving around a cycle.
- Not the intersection of stable models. For , , , , the atom is in both stable models but undefined in the well-founded model.
Related definitions
- Stable models. Every atom true in the well-founded model is in every stable model, and every false atom is in none. If the well-founded model is total, it is the unique stable model (Van Gelder, Ross and Schlipf 1991). The converse fails: has the unique stable model , but in its well-founded model and are undefined.
- Three-valued stable models. Przymusinski showed that the well-founded model is the least three-valued stable model, which links the two semantics in one framework.
- Complexity. The well-founded model of a finite ground program can be computed in polynomial time, in steps for atoms and program size by the alternating fixpoint. For Datalog with negation under this semantics, the data complexity is P-complete, by a reduction from the circuit value problem.
- Systems. XSB Prolog computes the well-founded model goal by goal with SLG resolution, and answer set solvers use it to simplify a program before search.
References
- Allen Van Gelder, Kenneth A. Ross and John S. Schlipf, The well-founded semantics for general logic programs, Journal of the ACM 38(3), 620 to 650 (1991), the definitions of unfounded sets, the greatest unfounded set and the operator W_P, and the relation to stratified programs and stable models
- Allen Van Gelder, The alternating fixpoint of logic programs with negation, Journal of Computer and System Sciences 47(1), 185 to 221 (1993), the characterization of the well-founded model by the alternating fixpoint
- Weidong Chen and David S. Warren, Tabled evaluation with delaying for general logic programs, Journal of the ACM 43(1), 20 to 74 (1996), the goal-directed computation of the well-founded model by SLG resolution
- Krzysztof R. Apt and Roland N. Bol, Logic programming and negation: a survey, Journal of Logic Programming 19/20, 9 to 71 (1994), the section on the well-founded semantics
- Evgeny Dantsin, Thomas Eiter, Georg Gottlob and Andrei Voronkov, Complexity and expressive power of logic programming, ACM Computing Surveys 33(3), 374 to 425 (2001), the complexity results for the well-founded semantics
Where this leads
About this page
The build computes these levels from the evidence in the repository. Each row says what the next level needs. Read what the levels mean.
| Ladder | Level | What the next level needs |
|---|---|---|
| Human proof | H0 no proof |
|
| Lean | L0 no Lean part |
|
| Visual | V0 none |
|
| Writing | W4 complete |
|
Tag 9NTS8A Edit this page History Report an error Markdown