Algorithm Search⌘K

Theoremadvanced

Splitting set theorem

Also called Lifschitz-Turner splitting.

If a set U of atoms contains every body atom of each rule whose head is in U, the stable models of a program are the stable models of its U part, each extended by the stable models of the rest.

The splitting set theorem of Lifschitz and Turner (1994) breaks the computation of stable models into parts. If a set UU of atoms is closed in one direction, so that the rules that define atoms of UU mention only atoms of UU, then the program splits into a bottom part about UU and a top part about the rest. Each stable model of the whole program is a stable model of the bottom, extended by a stable model of the top in which the atoms of UU have been replaced by their values. The theorem is the general form of the layer-by-layer evaluation of stratified programs, and it is the standard tool to prove that an answer set program does what it should.

Statement

Let PP be a ground normal program over the atoms AA. For a rule r=h←b1,…,bm,not c1,…,not ckr = h \leftarrow b_1, \ldots, b_m, \mathit{not}\ c_1, \ldots, \mathit{not}\ c_k, write head(r)=h\mathrm{head}(r) = h, pos(r)={b1,…,bm}\mathrm{pos}(r) = \{b_1, \ldots, b_m\} and neg(r)={c1,…,ck}\mathrm{neg}(r) = \{c_1, \ldots, c_k\}.

  • A set U⊆AU \subseteq A is a splitting set for PP if, for every rule rr of PP with head(r)∈U\mathrm{head}(r) \in U, also pos(r)∪neg(r)⊆U\mathrm{pos}(r) \cup \mathrm{neg}(r) \subseteq U.
  • The bottom bU(P)b_U(P) is the set of rules of PP whose head is in UU, and the top is tU(P)=P∖bU(P)t_U(P) = P \setminus b_U(P).
  • For a set X⊆UX \subseteq U, the partial evaluation eU(tU(P),X)e_U(t_U(P), X) is obtained from the top as follows. Delete each rule rr with pos(r)∩U⊈X\mathrm{pos}(r) \cap U \not\subseteq X or neg(r)∩X≠∅\mathrm{neg}(r) \cap X \neq \emptyset. From each remaining rule, delete all body literals whose atom is in UU.

Theorem (Lifschitz and Turner 1994). Let UU be a splitting set for PP. A set M⊆AM \subseteq A is a stable model of PP if and only if M=X∪YM = X \cup Y, where XX is a stable model of bU(P)b_U(P) and YY is a stable model of eU(tU(P),X)e_U(t_U(P), X).

Then X=M∩UX = M \cap U and Y=M∖UY = M \setminus U, because the heads of the bottom are in UU and those of the top are not. Lifschitz and Turner proved the theorem for programs with disjunction and strong negation; there a splitting set must contain all atoms of a rule as soon as it contains one atom of its head. They also proved a splitting sequence theorem, for a monotone sequence of splitting sets, possibly transfinite.

In plain words

Some parts of a program only feed others. The rules that decide which items are chosen may never look at the rules that check the choice, while the checks look at the choices. The theorem says that such a program can be solved in two rounds. First solve the part that does not look outside itself, and list its solutions. Then, for each solution, put its values into the rest, which becomes simpler, and solve that. Each combination of a first-round solution with a second-round solution is a solution of the whole program, and no solution is lost. The condition is that the first part really does not look at the second, not even through a negation.

Proof

The proof is from Lifschitz and Turner (1994), here for normal programs. It uses the reduct PMP^M and its least model lm(PM)\mathrm{lm}(P^M). Fix M⊆AM \subseteq A, and let X=M∩UX = M \cap U, Y=M∖UY = M \setminus U, B=bU(P)B = b_U(P) and E=eU(tU(P),X)E = e_U(t_U(P), X). Let N=lm(PM)N = \mathrm{lm}(P^M).

Lemma 1. N∩U=lm(BX)N \cap U = \mathrm{lm}(B^X).

All atoms of the rules of BB are in UU, so BM=BXB^M = B^X, and BX⊆PMB^X \subseteq P^M. Hence lm(BX)⊆N\mathrm{lm}(B^X) \subseteq N. Conversely, the set lm(BX)∪(A∖U)\mathrm{lm}(B^X) \cup (A \setminus U) is closed under PMP^M: a rule with head in UU is in BXB^X and has its body in UU, so if its body is in the set, it is in lm(BX)\mathrm{lm}(B^X) and so is its head; a rule with head outside UU puts its head in A∖UA \setminus U. So N⊆lm(BX)∪(A∖U)N \subseteq \mathrm{lm}(B^X) \cup (A \setminus U), and N∩U⊆lm(BX)N \cap U \subseteq \mathrm{lm}(B^X).

Lemma 2. If N∩U=XN \cap U = X, then N∖U=lm(EY)N \setminus U = \mathrm{lm}(E^Y).

A rule rr of the top gives a rule of PMP^M when neg(r)∩M=∅\mathrm{neg}(r) \cap M = \emptyset, that is, when neg(r)∩X=∅\mathrm{neg}(r) \cap X = \emptyset and neg(r)∩Y=∅\mathrm{neg}(r) \cap Y = \emptyset. It gives a rule of EYE^Y when, in addition, pos(r)∩U⊆X\mathrm{pos}(r) \cap U \subseteq X, and that rule is head(r)←pos(r)∖U\mathrm{head}(r) \leftarrow \mathrm{pos}(r) \setminus U. First, X∪lm(EY)X \cup \mathrm{lm}(E^Y) is closed under PMP^M. The bottom rules of PMP^M are the rules of BXB^X, and X=lm(BX)X = \mathrm{lm}(B^X) by Lemma 1, so they keep inside XX. A top rule of PMP^M with its body in X∪lm(EY)X \cup \mathrm{lm}(E^Y) has pos(r)∩U⊆X\mathrm{pos}(r) \cap U \subseteq X, so it gives a rule of EYE^Y with body in lm(EY)\mathrm{lm}(E^Y), and its head is in lm(EY)\mathrm{lm}(E^Y). So N∖U⊆lm(EY)N \setminus U \subseteq \mathrm{lm}(E^Y). Second, N∖UN \setminus U is closed under EYE^Y. If a rule of EYE^Y from rr has pos(r)∖U⊆N\mathrm{pos}(r) \setminus U \subseteq N, then pos(r)⊆N\mathrm{pos}(r) \subseteq N, because pos(r)∩U⊆X⊆N\mathrm{pos}(r) \cap U \subseteq X \subseteq N. The rule head(r)←pos(r)\mathrm{head}(r) \leftarrow \mathrm{pos}(r) is in PMP^M, so its head is in N∖UN \setminus U. So lm(EY)⊆N∖U\mathrm{lm}(E^Y) \subseteq N \setminus U.

The theorem. If MM is stable, then N=MN = M. By Lemma 1, X=lm(BX)X = \mathrm{lm}(B^X), so XX is a stable model of BB. Then Lemma 2 applies and gives Y=lm(EY)Y = \mathrm{lm}(E^Y), so YY is a stable model of EE. Conversely, let XX be a stable model of BB and YY one of EE, and M=X∪YM = X \cup Y. By Lemma 1, N∩U=lm(BX)=XN \cap U = \mathrm{lm}(B^X) = X. By Lemma 2, N∖U=lm(EY)=YN \setminus U = \mathrm{lm}(E^Y) = Y. So N=MN = M, and MM is stable.

A check by hand. Take

a ← not b.    b ← not a.    c ← a.    d ← not c.

and U={a,b}U = \{a, b\}. The rules for aa and bb mention only aa and bb, so UU is a splitting set. The bottom {a←not b, b←not a}\{a \leftarrow \mathit{not}\ b,\ b \leftarrow \mathit{not}\ a\} has the stable models {a}\{a\} and {b}\{b\}. For X={a}X = \{a\}, the partial evaluation of the top is {c, d←not c}\{c,\ d \leftarrow \mathit{not}\ c\}, with the stable model {c}\{c\}. For X={b}X = \{b\}, the rule c←ac \leftarrow a is deleted and the evaluation is {d←not c}\{d \leftarrow \mathit{not}\ c\}, with the stable model {d}\{d\}. So the stable models of the program are {a,c}\{a, c\} and {b,d}\{b, d\}.

Consequences

  • Stratified programs. The strata of a stratified program form a chain of splitting sets. Each layer, after partial evaluation, is a definite program, so by the splitting sequence theorem the program has exactly one stable model, its standard model.
  • Generate, define and test. An answer set program usually has a part that generates candidates, a part that defines auxiliary atoms and constraints that test. When the atoms of the generating part form a splitting set, the stable models are the candidates for which the rest has a stable model. Constraints in the top only remove candidates. This is how correctness proofs of answer set programs are usually written.
  • Evaluation by components. In the dependency graph with positive and negative edges, a set of atoms that contains every atom its atoms depend on is a splitting set. So a topological order of the strongly connected components, with each component after the components it depends on, gives a splitting sequence. Grounders and solvers use this order to evaluate the stratified part of a program completely before search.
  • Adding a top part. If new rules have heads outside UU and the old rules mention only UU, every stable model of the new program agrees on UU with a stable model of the old one. If the new rules are definite, each old stable model extends to exactly one new one.

Tightness

The condition on UU cannot be dropped. Take P={a←not b, b←not a}P = \{a \leftarrow \mathit{not}\ b,\ b \leftarrow \mathit{not}\ a\} and U={a}U = \{a\}, which is not a splitting set, since the rule for aa mentions b∉Ub \notin U. The rules with head in UU are {a←not b}\{a \leftarrow \mathit{not}\ b\}; bb has no rule there, so the only stable model of this part is {a}\{a\}. Then the rule b←not ab \leftarrow \mathit{not}\ a is deleted, and the procedure gives only {a}\{a\}. The stable model {b}\{b\} of PP is lost.

The condition is one-sided. Rules of the top can mention atoms of UU in any way, positively or negatively; only the bottom must not look up. Every program has the trivial splitting sets ∅\emptyset and AA, and the theorem is useful only when a proper splitting set exists. A program whose atoms all depend on each other, such as {a←not b, b←not a}\{a \leftarrow \mathit{not}\ b,\ b \leftarrow \mathit{not}\ a\}, has no proper splitting set.

History

Lifschitz and Turner presented the splitting set theorem and the splitting sequence theorem at the International Conference on Logic Programming in 1994. Their setting includes disjunctive programs with strong negation. The theorem became a basic tool in the theory of answer set programming, and later work extended it to arbitrary propositional theories and first-order programs, and to modules that depend on each other in both directions.

References

  1. Vladimir Lifschitz and Hudson Turner, Splitting a logic program, in Logic Programming: Proceedings of the Eleventh International Conference on Logic Programming, MIT Press, 23 to 37 (1994), the definitions of splitting sets and partial evaluation, the splitting set theorem and the splitting sequence theorem
  2. Michael Gelfond and Vladimir Lifschitz, The stable model semantics for logic programming, in Robert A. Kowalski and Kenneth A. Bowen (eds.), Logic Programming: Proceedings of the Fifth International Conference and Symposium, MIT Press, 1070 to 1080 (1988), the definition of stable models and the result for stratified programs
  3. Vladimir Lifschitz, Answer Set Programming, Springer (2019), the section on splitting and its use in generate and test programs

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.

LadderLevelWhat the next level needs
Human proofH0 no proof
  • add a proof in proofs/ (06.5)
LeanL0 no Lean part
  • name a Lean module in the lean field (07)
VisualV0 none
  • add viz/scene.ts or a figure (10)
WritingW4 complete
  • a review of the text: no review record reviews/ED99PW/text.yaml