Skip to main content

Lecture 3 Exercises

Laura Kovács

Problem 3.1

Let I\mathbb{I} be a sound inference system on clauses and let S0S_0 be a non-empty set of clauses. Consider a fair I\mathbb{I}-inference process

S0S1S2S_0 \Rightarrow S_1 \Rightarrow S_2 \Rightarrow \cdots

and let SS_\infty denote its limit. Show that SS_\infty is the I\mathbb{I}-closure of S0S_0.

Note. Prove that SS_\infty is the smallest I\mathbb{I}-saturated set containing S0S_0. Recall the property from the lecture that every SiS_i is a subset of the I\mathbb{I}-closure of S0S_0.

Solution

We prove three statements.

  1. SS_\infty is saturated. Suppose not. Then there are C1,,CnSC_1,\dots,C_n \in S_\infty and an inference

    C1        CnC\frac{C_1 \;\; \cdots \;\; C_n}{C}

    with CSC \notin S_\infty. Because each CiC_i is persistent, all appear from some index onward. Fairness ensures CC is eventually derived, hence CSjSC \in S_j \subseteq S_\infty, a contradiction.

  2. Every I\mathbb{I}-saturated superset of S0S_0 contains SS_\infty. Let XX be saturated with S0XS_0 \subseteq X. We show by induction on ii that SiXS_i \subseteq X.

    • Base: S0XS_0 \subseteq X holds by assumption.
    • Step: assume SiXS_i \subseteq X. If Si+1=SiS_{i+1} = S_i we are done. Otherwise the new clause CC in Si+1S_{i+1} is inferred from premises in SiS_i. By the induction hypothesis the premises lie in XX, and saturation of XX implies CXC \in X. Thus Si+1XS_{i+1} \subseteq X. As S=i0SiS_\infty = \bigcup_{i \ge 0} S_i, we conclude SXS_\infty \subseteq X.
  3. Combining (1) and (2), SS_\infty is saturated, contains S0S_0, and is contained in every saturated set containing S0S_0. Therefore it is the smallest such set, i.e., the I\mathbb{I}-closure of S0S_0.

Problem 3.2

Let \succ be a total well-founded ordering on ground non-equality atoms, and use the same symbol for the induced literal ordering. Let CC and DD be ground clauses without equality literals. Denote by AA and BB the maximal atoms of CC and DD (with respect to \succ). Assume AA and BB are the same atom syntactically, that AA occurs negatively in CC, and that AA occurs only positively in DD. Show that CbagDC \succ_{\text{bag}} D.

Solution

Since AA and BB are the same atom, AA is also maximal in DD. Because AA occurs only positively in DD, every other literal LL in DD satisfies ¬AA¬LL\neg A \succ A \succ \neg L \succ L under the literal ordering. Hence the multiset extension yields ¬AbagD\neg A \succ_{\text{bag}} D.

By assumption AA occurs only negatively in CC, so ¬A\neg A is a literal of CC and is maximal there: for every other atom CiC_i we have ¬A¬CiCi\neg A \succ \neg C_i \succ C_i. Thus ¬A\neg A is the top literal of CC. Since ¬AbagD\neg A \succ_{\text{bag}} D and ¬A\neg A is the maximal literal in CC, the bag extension ordering gives CbagDC \succ_{\text{bag}} D.

Problem 3.3

Let 1\succ_1 and 2\succ_2 be strict well-founded orderings on sets M1M_1 and M2M_2. Define an ordering \succ^* on M1×M2M_1 \times M_2 by

(a1,a2)(b1,b2)(a11b1    or    (a1=b1 and a22b2)).(a_1,a_2) \succ^* (b_1,b_2) \quad \Longleftrightarrow \quad \big(a_1 \succ_1 b_1 \;\;\text{or}\;\; (a_1 = b_1 \text{ and } a_2 \succ_2 b_2)\big).

Show that \succ^* is well-founded.

Solution

Assume for contradiction that \succ^* admits an infinite descending chain

(x0,y0)(x1,y1)(x2,y2).(x_0,y_0) \succ^* (x_1,y_1) \succ^* (x_2,y_2) \succ^* \cdots.

Examining the first components, each transition either decreases strictly in 1\succ_1 or keeps the first component equal. Because 1\succ_1 is well-founded, the sequence {xi}\{x_i\} has a minimal element: there is nn such that xn1xix_n \preceq_1 x_i for all ini \ge n. Hence for ini \ge n we must have xi=xi+1x_i = x_{i+1}, and the definition of \succ^* forces yi2yi+1y_i \succ_2 y_{i+1}. That yields an infinite descending 2\succ_2-chain, contradicting well-foundedness of 2\succ_2. Therefore \succ^* is well-founded.

Problem 3.4

Let \succ be a total well-founded ordering on the ground atoms p1,,p6p_1,\dots,p_6 with p6p5p4p3p2p1p_6 \succ p_5 \succ p_4 \succ p_3 \succ p_2 \succ p_1. Consider the bag extension of \succ (denoted again by \succ). Using this ordering, compare and order the clauses

p6¬p6,¬p2p4p5,p2p3.p_6 \vee \neg p_6, \qquad \neg p_2 \vee p_4 \vee p_5, \qquad p_2 \vee p_3.
Solution

Since \succ is total, for i>ji > j we have pipjp_i \succ p_j and pi¬pjp_i \succ \neg p_j. In particular p6¬p2p_6 \succ \neg p_2, p6p4p_6 \succ p_4, p6p5p_6 \succ p_5, and p5p2p_5 \succ p_2, p5p3p_5 \succ p_3.

For multisets, if BBB \supset B' then BBB \succ B', so p6¬p6p6p_6 \vee \neg p_6 \succ p_6 and ¬p2p4p5p5\neg p_2 \vee p_4 \vee p_5 \succ p_5. Combining the comparisons yields

p6¬p6p6¬p2p4p5p5p2p3.p_6 \vee \neg p_6 \succ p_6 \succ \neg p_2 \vee p_4 \vee p_5 \succ p_5 \succ p_2 \vee p_3.

By transitivity,

p6¬p6¬p2p4p5p2p3.p_6 \vee \neg p_6 \succ \neg p_2 \vee p_4 \vee p_5 \succ p_2 \vee p_3.