Iterated Choice Fixpoint for a Stratiied Program Q: = ; Induction: for J > 0, Let M J = a Choice Model for M J?1 Q J Example 10 Computing a Spanning Tree St(root; A)
S Ceri,C Faloutsos,R Snodgrass,V S Subrahmanian,R Zicari,D B Kemp,K Ramamohanarao,P J Stuckey,esl,Jayen Vaghani,Kotagiri Ramamohanarao,David B Kemp,Zoltan Somo-Gyi,Peter J Stuckey,Tim S Leask,James Harland The,Aditi Deduc,Ev,Rno
1997-01-01
Abstract:Appendix Let det(P) be a stratiication (i.e., an ordered partition of the predicate names) of P. We can now extend this stratiication to the predicate names in foe(P) to obtain a partition of foe(P) by assigning each chosen r , and diff choice r predicates to the same stratum as that to which the head of r belongs to. Now for a stratiied program Q let Q j denote the rules in Q with the head predicate name in the j th stratum. Then, the following algorithm provides a simple generalization to the stratiied xpoint used to compute the (unique) stable model for a stratiied program: 0j<! M j For an XY-stratiied choice program P, we extend the local stratiication of det(P) to foe(P) by making sure that, for a recursive rule r with temporal variable k, the atoms chosen r (k; : : :) and diff choice (k; :::) are assigned to the same stratum as head r (k; : : :), where head r is the predicate name of the head of r. Now, with Q a locally stratiied program, we denote by ground j (Q) the clauses of ground(Q) with head in the j-th stratum. Then, the iterated choice xpoint can then modiied by letting the induction step be as follows: For j > 0, let M j = a choice model for M j?1 ground j (Q). The soundness and completeness of the iterated choice xpoint to compute the stable models of XY-stratiied programs then follow directly from the dee-nitions: Theorem 2 Let P be a stratiied choice program. Then, the set of results of the Iterated Choice Fixpoint is equal to the set of stable models for P. Finally, with the modiications in the choice rules for P bis described in Section 5, Procedure 2 provides an eecient implementation of the iterated choice xpoint. Statelog-based approach 8] has many techniques in common with the Datalog 1s approach used here. Another interesting problem is the modeling of diierent activation semantics for rules, including immediate-before, and deferred-activation semantics, but also the durable-change semantics 13] (originally deened only for deterministic rule activation), which has the important advantage of avoiding innnite activation loops. Acknowledgment The author would like to thank Nanni Mirko for his critical comments on XY-stratiied choice programs.programs and the eecient evaluation of nonstratiied programs by transformation to ESL"," rule/event pair has not been used before). Then, …