CS402, Spring 2018
G for Predicate Logic Let s remind ourselves of semantic tableaux. Consider xp(x) xq(x) x(p(x) q(x)). ( xp(x) xq(x) x(p(x) q(x))) xp(x) xq(x), x(p(x) q(x)) xp(x), x(p(x) q(x)) xq(x), x(p(x) q(x)) xp(x), (p(a) q(a)) xq(x), (p(a) q(a)) xp(x), p(a), q(a) xq(x), p(a), q(a) xp(x), p(a), p(a), q(a) (X) xq(x), q(a), p(a), q(a) (X)
Upside Down, Negated... xp(x), p(a), p(a), q(a) xp(x), p(a), q(a) xp(x), p(a) q(a) xp(x), x(p(x) q(x)) xq(x), q(a), p(a), q(a) xq(x), p(a), q(a) xq(x), p(a) q(a) xq(x), x(p(x) q(x)) ( xp(x) xq(x)), x(p(x) q(x)) xp(x) xq(x) x(p(x) q(x))
G for Predicate Logic Definition 1 (8.1) The Gentzen system, G, for predicate logic is a deductive system. Its axioms are sets of formulas, U, containing a complementary pair of literals. The rules of inference are the rules given for α and β formulas discussed for Proposition Logic, together with the following rules for γ and δ formulas. γ γ(a) δ δ(a) xa(x) A(a) xa(x) A(a) xa(x) A(a) xa(x) A(a) U {γ, γ(a)} U {γ} U {δ(a)} U {δ} The δ rule can be applied only if the constant a does not occur in any formula in U.
G for Predicate Logic γ γ(a) δ δ(a) xa(x) A(a) xa(x) A(a) xa(x) A(a) xa(x) A(a) U {γ, γ(a)} U {γ} U {δ(a)} U {δ} γ rule: if an existential formula and some instantiation of it are true, then the instantiation is redundant. δ rule: Let a be an arbitrary constand. Suppose A(a) can be proved. Since a was arbitrary, the proof holds for xa(x). For this to work, it is essential that a is an arbitrary constant, not constrained by any other subformula.
G: Example Prove x yp(x, y) y xp(x, y). 1. yp(a, y), p(a, b), xp(x, b), p(a, b) Axiom 2. yp(a, y), xp(x, b), p(a, b) γ, 1 3. yp(a, y), xp(x, b) γ, 2 4. yp(a, y), y xp(x, y) δ, 3 5. x yp(x, y), y xp(x, y) δ, 4 6. x yp(x, y) y xp(x, y) α, 5
H for Predicate Logic Definition 2 (8.4) The axioms of H for predicate logic are: Axiom 1 (A (B A)) Axiom 2 (A (B C)) ((A B) (A C)) Axiom 3 ( B A) (A B) Axiom 4 xa(x) A(a) Axiom 5 x(a B(x)) (A xb(x)) The rules of inference are modus ponens and generalisation: A B A A(a) MP: B, Gen.: xa(x) Note that Axiom 1, 2, 3 and MP rule are generalized to any formulas in predicate logic: hence we can use any derived rules and theorems that we proved for propositional logic.
Specialisation and Generalisation Axiom 4 can be used as an inference rule (specialisation): U xa(x) U A(a) Any occurrence of xa(x) can be replaced by A(a) for any a. If A(x) is true whatever the assignment of a domain element of an interpretation I to x, then A(a) is true for the domain element that I assigns to a. Note that this rule holds when we have U (i.e., other assumptions).
Specialisation and Generalisation Generalisation rule is given without a set of assumptions, U: A(a) xa(x) Suppose we allow applying generalisation to A(a) A(a), to obtain A(a) xa(x). Consider the following interpretation for this formula: (Z, {even(x)}, {2}). A(a) is true, but obviously xa(x) is not true. To cater for assumptions involved in proofs, generalisation can be also presented like the following: U A(a) U xa(x) provided that a does not appear anywyere in U.
Deduction Rule U {A} B U A B Theorem 1 (8.10) The deduction rule is a sound derived rule. Proof. See the proof for Theorem 3.14 for propositional logic. We use the induction on the length of the proof of U {A} B, and show that we can obtain a proof for U A B without using the deduction rule.
Deduction Rule Prof. Cont. For n = 1, B is proved in a single step, which means either B U {A}, an axiom, or a theorem. Refer to the proof of Theorem 3.14 for axioms. If n > 1, the last step in the proof of U {A} B is either an one-step inference of B, an inference based on MP, or an inference based on generalisation. We focus on generalisation: if the last rule applied was generalisation, we can assume that the preceding line was U {A} B(a) (by definition, a does not appear in U or A: i U {A} B(a) i + 1 U {A} xb(x) Generalisation The inductive hypothesis is that the deduction rule holds up to line i. i U {A} B(a) i U A B(a) Inductive Hypothesis, i i + 1 U x(a B(x)) Generalisation, i (a / U) i + 2 U x(a B(x)) (A xb(x)) Axiom 5 (a / A) i + 3 U A xb(x) MP, i + 1, i + 2
Equivalence between G and H We already know that any proof in G can be mechanically converted into a proof in H for propositional logic. We only need to extend the existing proof to cover γ and δ rules. Theorem 2 (8.11) The rule for a γ formula can be simulated in H. Proof. Suppose we use the following γ rule: U xa(x) A(a) U xa(x). Then: 1. xa(x) A(a) Axiom 4 2. (x)a(x) A(a) Propositional Deduction 3. U (x)a(x) A(a) Propositional Deduction (Weakening) 4. U (x)a(x) A(a) Assumption 5. U (x)a(x) Propositional Deduction 3, 4
Equivalence between G and H Theorem 3 (8.12) The rule for a δ formula can be simulated in H. Proof. Suppose we use the following γ rule: U A(a) U xa(x). Then: 1. U A(a) Assumption 2. U A(a) Propositional Deduction, 1 3. x( U A(x)) Gen., 2 4. x( U A(x)) ( U xa(x)) Axiom 5 5. U xa(x) MP, 3, 4 6. U xa(x) Propositional Deduction, 5
Equivalence between G and H This is one-direction: how do we prove that any proof in H can be done in G?
Examples of proofs in H Theorem 4 (8.14) A(a) xa(x) Proof. 1. x A(x) A(a) Axiom 4 2. A(a) x A(x) Prop. (Contrapositive) 1 3. A(a) xa(x) Duality, 2
Examples of proofs in H Theorem 5 (8.15) xa(x) xa(x) Proof. 1. { xa(x)} xa(x) Assumption 2. { xa(x)} xa(x) A(a) Axiom 4 3. { xa(x)} A(a) MP, 1, 2 4. { xa(x)} A(a) xa(x) Theorem 8.14 5. { xa(x)} xa(x) MP, 3, 4 6. xa(x) xa(x) Deduction
Examples of proofs in H Theorem 6 (8.19) x(a B(x)) (A xb(x)) x(a B(x)) (A xb(x))
Examples of proofs in H Theorem 7 (8.20) xa(x) ya(y) Proof. 1. xa(x) A(a) Axiom 4 2. y( xa(x) A(y)) Generalisation, 1 3. y( xa(x) A(y)) ( xa(x) ya(y)) Axiom 5 4. xa(x) ya(y) MP 2, 3 Repeat in the reverse direction.
Examples of proofs in H This may appear a bit counter-intuitive at first (careful with the parentheses). Theorem 8 (8.21) x(a(x) B) ( xa(x) B) Proof. 1. { x(a(x) B)} x(a(x) B) Assumption 2. { x(a(x) B)} B x(a(x)) 3. { x(a(x) B)} B x A(x) Axiom 5 + MP 4. { x(a(x) B)} x A(x) B Prop. (Contrapositive) 5. { x(a(x) B)} xa(x) B Duality 6. x(a(x) B) xa(x) B Deduction
Examples of proofs in H This may appear a bit counter-intuitive at first (careful with the parentheses). Theorem 9 (8.21) x(a(x) B) ( xa(x) B) Proof. 1. { xa(x) B} xa(x) B Assumption 2. { xa(x) B} x A(x) B Duality 3. { xa(x) B} B x A(x) Contrapositive 4. { xa(x) B} x( B A(x)) Theorem 8.19 5. { xa(x) B} x(a(x) B) 6. xa(x) B x(a(x) B) Deduction