M384 · Logic · Week 10

The Completeness Theorem

Day 1: consistent and maximally consistent sets. Day 2: Lindenbaum's Lemma, the Truth Lemma and the Completeness Theorem. Day 3: strong completeness and compactness.

Goals for this week

By the end of this week you will be able to:

Day 1: Consistent and maximally consistent sets

Today we set up the plan of the proof of the Completeness Theorem and carry out its first step: from a formula that cannot be deduced we build a consistent set, and we study the largest consistent sets.

What we are using from before
  • Since Week 9, the only connectives are \(\neg\) and \(\to\); \(\varphi\wedge\psi\) abbreviates \(\neg(\varphi\to\neg\psi)\) and \(\varphi\vee\psi\) abbreviates \(\neg\varphi\to\psi\) (Definition 9.1). A deduction from \(\Gamma\) uses the axioms (L1) to (L9), members of \(\Gamma\) and MP. In proofs that a deduction exists we also use the derived rule HS and theorems proved earlier, cited by their number.
  • Definition 9.21: \(\Gamma\) is inconsistent if \(\Gamma\vdash\varphi\) and \(\Gamma\vdash\neg\varphi\) for some formula \(\varphi\); otherwise \(\Gamma\) is consistent.
  • Theorem 9.17 (Soundness): if \(\Gamma\vdash\varphi\) then \(\Gamma\models\varphi\). Corollary 9.22: a satisfiable set is consistent; in particular \(\varnothing\) is consistent.
  • The Deduction Theorem (Corollary 9.10): \(\Gamma,\varphi\vdash\psi\) if and only if \(\Gamma\vdash\varphi\to\psi\).
  • Proposition 8.35: (a) if \(\varphi\in\Gamma\) then \(\Gamma\vdash\varphi\); (b) if \(\Gamma\subseteq\Delta\) and \(\Gamma\vdash\varphi\) then \(\Delta\vdash\varphi\); (c) if \(\Gamma\vdash\varphi\) and \(\Gamma\vdash\varphi\to\psi\) then \(\Gamma\vdash\psi\).
  • Lemma 9.5: (a) \(\vdash\neg\varphi\to(\varphi\to\psi)\); (f) \(\vdash(\neg\varphi\to\varphi)\to\varphi\).

1. The plan

The Soundness Theorem says that \(\vdash\) never proves too much: every theorem is a tautology. The Completeness Theorem says that \(\vdash\) proves enough: every tautology is a theorem. In symbols, if \(\models\varphi\) then \(\vdash\varphi\). Soundness was proved by looking at a deduction line by line. For completeness there is no deduction to look at: we are given only a truth table, and we must show that a deduction exists.

We prove the contrapositive: if \(\nvdash\varphi\), then \(\not\models\varphi\). So we start from a formula \(\varphi\) that has no deduction, and we must produce a valuation that makes \(\varphi\) false. The plan has four steps, shown in Figure 1.

  1. If \(\nvdash\varphi\), then the set \(\{\neg\varphi\}\) is consistent (Proposition 10.4, today).
  2. Every consistent set can be extended to a maximally consistent set, a consistent set to which no formula can be added (Lindenbaum's Lemma, Day 2). We define these sets today and prove their main properties.
  3. A maximally consistent set \(\Gamma\) decides every formula: for each \(\varphi\), exactly one of \(\varphi\in\Gamma\) and \(\neg\varphi\in\Gamma\) holds. So \(\Gamma\) can be read as a valuation: a primitive proposition \(p\) is true exactly when \(p\in\Gamma\). The Truth Lemma (Day 2) says that this valuation makes exactly the members of \(\Gamma\) true.
  4. Since \(\neg\varphi\in\Gamma\), this valuation makes \(\neg\varphi\) true and \(\varphi\) false. So \(\not\models\varphi\).
⊬ φφ has no deduction{¬φ} is consistentProposition 10.4 (Day 1)Γ′ ⊇ {¬φ}maximally consistentLindenbaum's Lemma (Day 2)vΓ′ makes ¬φ truep is true iff p ∈ Γ′Truth Lemma (Day 2)⊭ φφ is false under vΓ′Read the chart from thetop left: it proves"if ⊬ φ then ⊭ φ", thecontrapositive of completeness.
Figure 1. The plan of the proof. Day 1 proves the first step and defines what the second step produces. Day 2 proves the remaining steps and puts them together.

Step 2 is where the real work is. A consistent set such as \(\{\neg\varphi\}\) says very little; a maximally consistent set says something about every formula, and that is what a valuation needs.

2. Consistency, revisited

We collect the facts about consistency that the plan needs. The first says that an inconsistent set is useless as a set of assumptions: it proves everything.

Proposition 10.1: the principle of explosion
(a) \(\Gamma\) is inconsistent if and only if \(\Gamma\vdash\psi\) for every formula \(\psi\).
(b) If \(\Gamma\subseteq\Delta\) and \(\Gamma\) is inconsistent, then \(\Delta\) is inconsistent. Equivalently: a subset of a consistent set is consistent.

Proof. (a) Let \(\Gamma\) be inconsistent: \(\Gamma\vdash\varphi\) and \(\Gamma\vdash\neg\varphi\) for some \(\varphi\). Let \(\psi\) be any formula. By Lemma 9.5(a), \(\vdash\neg\varphi\to(\varphi\to\psi)\), so \(\Gamma\vdash\neg\varphi\to(\varphi\to\psi)\) by Proposition 8.35(b). Two applications of MP (Proposition 8.35(c)) give \(\Gamma\vdash\varphi\to\psi\) and then \(\Gamma\vdash\psi\). Conversely, if \(\Gamma\) deduces every formula, it deduces \(p\) and \(\neg p\), so it is inconsistent.

(b) If \(\Gamma\vdash\varphi\) and \(\Gamma\vdash\neg\varphi\), then \(\Delta\vdash\varphi\) and \(\Delta\vdash\neg\varphi\) by Proposition 8.35(b). □

Example 10.2: deductions from inconsistent sets

The proof of Proposition 10.1(a) is a recipe. From \(\varphi\) and \(\neg\varphi\) we deduce any \(\psi\) by writing out the deduction of \(\neg\varphi\to(\varphi\to\psi)\): (L1) gives \(\neg\varphi\to(\neg\psi\to\neg\varphi)\), and (L3) turns \(\neg\psi\to\neg\varphi\) into \(\varphi\to\psi\).

(a) \(p,\ \neg p\vdash q\):
1\(p\)(assump.)2\(\neg p\)(assump.)3\(\neg p \to (\neg q \to \neg p)\)(L1)4\(\neg q \to \neg p\)(2,3 MP)5\((\neg q \to \neg p) \to (p \to q)\)(L3)6\(p \to q\)(4,5 MP)7\(q\)(1,6 MP)

Line 3 is (L1) with \(\varphi:=\neg p\) and \(\psi:=\neg q\); line 5 is (L3) with \(\varphi:=p\) and \(\psi:=q\).

(b) \(p\to q,\ p,\ \neg q\vdash r\). The set \(\{p\to q,\ p,\ \neg q\}\) is inconsistent (Week 9, Section 10): it deduces \(q\) by MP and \(\neg q\) by (assump.). The same recipe, with \(\varphi:=q\) and \(\psi:=r\), gives \(r\):
1\(p \to q\)(assump.)2\(p\)(assump.)3\(\neg q\)(assump.)4\(q\)(1,2 MP)5\(\neg q \to (\neg r \to \neg q)\)(L1)6\(\neg r \to \neg q\)(3,5 MP)7\((\neg r \to \neg q) \to (q \to r)\)(L3)8\(q \to r\)(6,7 MP)9\(r\)(4,8 MP)

The next lemma is the tool for step 1 of the plan. It says: if \(\neg\varphi\) leads both to \(\psi\) and to \(\neg\psi\), then \(\varphi\) holds.

Lemma 10.3

For all formulas \(\varphi,\psi\): \(\ \vdash(\neg\varphi\to\neg\psi)\to((\neg\varphi\to\psi)\to\varphi)\).

Proof. By the Deduction Theorem, applied twice, it is enough to show \(\neg\varphi\to\neg\psi,\ \neg\varphi\to\psi\vdash\varphi\):

1\(\neg \varphi \to \neg \psi\)(assump.)2\(\neg \varphi \to \psi\)(assump.)3\((\neg \varphi \to \neg \psi) \to (\psi \to \varphi)\)(L3)4\(\psi \to \varphi\)(1,3 MP)5\(\neg \varphi \to \varphi\)(2,4 HS)6\((\neg \varphi \to \varphi) \to \varphi\)(Lemma 9.5(f))7\(\varphi\)(5,6 MP)

Line 3 is (L3) with \(\psi\) in place of \(\varphi\) and \(\varphi\) in place of \(\psi\). □

Proposition 10.4: adding the negation of an undeducible formula

If \(\Gamma\nvdash\varphi\), then \(\Gamma\cup\{\neg\varphi\}\) is consistent.

Proof. Suppose that \(\Gamma\cup\{\neg\varphi\}\) is inconsistent: for some \(\psi\), \(\Gamma,\neg\varphi\vdash\psi\) and \(\Gamma,\neg\varphi\vdash\neg\psi\). By the Deduction Theorem, \(\Gamma\vdash\neg\varphi\to\psi\) and \(\Gamma\vdash\neg\varphi\to\neg\psi\). By Lemma 10.3 and MP twice, \(\Gamma\vdash\varphi\). This contradicts \(\Gamma\nvdash\varphi\). □

Note that the proposition does not assume that \(\Gamma\) is consistent. It does not need to: if \(\Gamma\) is inconsistent, then \(\Gamma\vdash\varphi\) for every \(\varphi\) by Proposition 10.1(a), so the hypothesis \(\Gamma\nvdash\varphi\) never holds. With \(\Gamma=\varnothing\) the proposition is step 1 of the plan: if \(\nvdash\varphi\), then \(\{\neg\varphi\}\) is consistent.

Proposition 10.5: adding a formula to a consistent set

Let \(\Gamma\) be consistent.

(a) If \(\Gamma\vdash\varphi\), then \(\Gamma\cup\{\varphi\}\) is consistent.
(b) For every formula \(\varphi\), at least one of \(\Gamma\cup\{\varphi\}\) and \(\Gamma\cup\{\neg\varphi\}\) is consistent.

Proof. (a) Suppose \(\Gamma,\varphi\vdash\psi\) and \(\Gamma,\varphi\vdash\neg\psi\). By the Deduction Theorem, \(\Gamma\vdash\varphi\to\psi\) and \(\Gamma\vdash\varphi\to\neg\psi\). Since \(\Gamma\vdash\varphi\), MP gives \(\Gamma\vdash\psi\) and \(\Gamma\vdash\neg\psi\). So \(\Gamma\) is inconsistent, contrary to the assumption.

(b) Either \(\Gamma\nvdash\varphi\), and then \(\Gamma\cup\{\neg\varphi\}\) is consistent by Proposition 10.4; or \(\Gamma\vdash\varphi\), and then \(\Gamma\cup\{\varphi\}\) is consistent by (a). □

Exercise 1: deductions from inconsistent sets

Self-check only. Nothing here counts towards your grade.

Write a deduction for each claim, following the recipe of Example 10.2. You may use (assump.), (L1) to (L9), MP and HS. Type \(\neg\) as ~, \(\to\) as ->, \(\wedge\) as & and \(\vee\) as \/, or use the buttons. Use "Add line" for more lines.

(a) \(q,\ \neg q\vdash p\)
(b) \(p\to q,\ \neg q,\ p\vdash\neg r\)
(c) \(p\wedge\neg p\vdash q\)

(a) As in Example 10.2(a), with \(q\) in place of \(p\) and \(p\) in place of \(q\):

1\(q\)(assump.)2\(\neg q\)(assump.)3\(\neg q \to (\neg p \to \neg q)\)(L1)4\(\neg p \to \neg q\)(2,3 MP)5\((\neg p \to \neg q) \to (q \to p)\)(L3)6\(q \to p\)(4,5 MP)7\(p\)(1,6 MP)

(b) First \(q\) by MP, then the recipe with \(\varphi:=q\) and \(\psi:=\neg r\):

1\(p \to q\)(assump.)2\(\neg q\)(assump.)3\(p\)(assump.)4\(q\)(1,3 MP)5\(\neg q \to (\neg \neg r \to \neg q)\)(L1)6\(\neg \neg r \to \neg q\)(2,5 MP)7\((\neg \neg r \to \neg q) \to (q \to \neg r)\)(L3)8\(q \to \neg r\)(6,7 MP)9\(\neg r\)(4,8 MP)

(c) First take the conjunction apart with (L4) and (L5):

1\(p \wedge \neg p\)(assump.)2\((p \wedge \neg p) \to p\)(L4)3\(p\)(1,2 MP)4\((p \wedge \neg p) \to \neg p\)(L5)5\(\neg p\)(1,4 MP)6\(\neg p \to (\neg q \to \neg p)\)(L1)7\(\neg q \to \neg p\)(5,6 MP)8\((\neg q \to \neg p) \to (p \to q)\)(L3)9\(p \to q\)(7,8 MP)10\(q\)(3,9 MP)

3. Maximally consistent sets

Definition 10.6: maximally consistent sets

A set of formulas \(\Gamma\) is maximally consistent if \(\Gamma\) is consistent and every set \(\Delta\) with \(\Gamma\subsetneq\Delta\) is inconsistent.

Equivalently: \(\Gamma\) is consistent, and \(\Gamma\cup\{\varphi\}\) is inconsistent for every formula \(\varphi\notin\Gamma\). (If some \(\Delta\supsetneq\Gamma\) were consistent, pick \(\varphi\in\Delta\setminus\Gamma\); then \(\Gamma\cup\{\varphi\}\subseteq\Delta\) would be consistent by Proposition 10.1(b).)

So a maximally consistent set is a consistent set that is as large as a consistent set can be: adding any new formula destroys consistency.

Example 10.7: sets that are maximally consistent, and sets that are not
(a) \(\{p\}\) is consistent (it is satisfiable, Corollary 9.22) but not maximally consistent: \(\{p,q\}\) is a consistent proper superset, since the valuation \(v(p)=v(q)=\mathrm T\) satisfies it.
(b) For a valuation \(v\), let \(T_v=\{\varphi : [\![\varphi]\!]_v=\mathrm T\}\), the set of all formulas true under \(v\). Then \(T_v\) is maximally consistent. It is consistent, because \(v\) satisfies it (Corollary 9.22). Let \(\Delta\supsetneq T_v\) and pick \(\psi\in\Delta\setminus T_v\). Then \([\![\psi]\!]_v=\mathrm F\), so \([\![\neg\psi]\!]_v=\mathrm T\) and \(\neg\psi\in T_v\subseteq\Delta\). Now \(\Delta\vdash\psi\) and \(\Delta\vdash\neg\psi\) by (assump.), so \(\Delta\) is inconsistent.
(c) No finite set is maximally consistent. Let \(\Gamma\) be finite and consistent. There are infinitely many formulas of the form \(\theta\to\theta\), so some \(\theta\to\theta\) is not in \(\Gamma\). Since \(\vdash\theta\to\theta\) (Example 8.27), \(\Gamma\vdash\theta\to\theta\), and \(\Gamma\cup\{\theta\to\theta\}\) is consistent by Proposition 10.5(a). It is a proper superset of \(\Gamma\), so \(\Gamma\) is not maximally consistent.

Part (b) gives, for every valuation, one maximally consistent set. The next proposition is the form in which maximality is used.

Proposition 10.8: a maximally consistent set decides every formula

\(\Gamma\) is maximally consistent if and only if \(\Gamma\) is consistent and for every formula \(\varphi\), \(\varphi\in\Gamma\) or \(\neg\varphi\in\Gamma\).

Since \(\Gamma\) is consistent, it never contains both: so for every \(\varphi\), exactly one of \(\varphi\in\Gamma\) and \(\neg\varphi\in\Gamma\) holds.

Proof. (\(\Rightarrow\)) Let \(\Gamma\) be maximally consistent and let \(\varphi\) be a formula. By Proposition 10.5(b), \(\Gamma\cup\{\varphi\}\) or \(\Gamma\cup\{\neg\varphi\}\) is consistent. By maximality a consistent superset of \(\Gamma\) is \(\Gamma\) itself. So \(\varphi\in\Gamma\) or \(\neg\varphi\in\Gamma\).

(\(\Leftarrow\)) Let \(\Gamma\) be consistent and contain \(\varphi\) or \(\neg\varphi\) for every \(\varphi\). Let \(\Delta\supsetneq\Gamma\) and pick \(\psi\in\Delta\setminus\Gamma\). Since \(\psi\notin\Gamma\), we have \(\neg\psi\in\Gamma\subseteq\Delta\). So \(\Delta\vdash\psi\) and \(\Delta\vdash\neg\psi\), and \(\Delta\) is inconsistent. Hence \(\Gamma\) is maximally consistent.

If both \(\varphi\in\Gamma\) and \(\neg\varphi\in\Gamma\), then \(\Gamma\vdash\varphi\) and \(\Gamma\vdash\neg\varphi\) by (assump.), so \(\Gamma\) is inconsistent. □

Proposition 10.9: maximally consistent sets are closed under deduction

If \(\Gamma\) is maximally consistent and \(\Gamma\vdash\varphi\), then \(\varphi\in\Gamma\). In particular, every theorem belongs to every maximally consistent set.

Proof. Suppose \(\Gamma\vdash\varphi\) and \(\varphi\notin\Gamma\). By Proposition 10.8, \(\neg\varphi\in\Gamma\), so \(\Gamma\vdash\neg\varphi\). Then \(\Gamma\) is inconsistent, a contradiction. If \(\vdash\varphi\), then \(\Gamma\vdash\varphi\) by Proposition 8.35(b), so \(\varphi\in\Gamma\). □

Membership in a maximally consistent set behaves like truth: a negation is in \(\Gamma\) exactly when the formula is not, and an implication is in \(\Gamma\) exactly when its antecedent is not or its consequent is.

Proposition 10.10: membership rules

Let \(\Gamma\) be maximally consistent. For all formulas \(\varphi,\psi\):

(a) \(\neg\varphi\in\Gamma\) if and only if \(\varphi\notin\Gamma\).
(b) \(\varphi\to\psi\in\Gamma\) if and only if \(\varphi\notin\Gamma\) or \(\psi\in\Gamma\).
(c) \(\varphi\wedge\psi\in\Gamma\) if and only if \(\varphi\in\Gamma\) and \(\psi\in\Gamma\).
(d) \(\varphi\vee\psi\in\Gamma\) if and only if \(\varphi\in\Gamma\) or \(\psi\in\Gamma\).

Proof. (a) is Proposition 10.8: exactly one of \(\varphi\), \(\neg\varphi\) is in \(\Gamma\).

(b) (\(\Leftarrow\)) If \(\psi\in\Gamma\): by (L1), \(\Gamma\vdash\psi\to(\varphi\to\psi)\), and MP gives \(\Gamma\vdash\varphi\to\psi\). If \(\varphi\notin\Gamma\): then \(\neg\varphi\in\Gamma\) by (a); by Lemma 9.5(a), \(\Gamma\vdash\neg\varphi\to(\varphi\to\psi)\), and MP gives \(\Gamma\vdash\varphi\to\psi\). In both cases \(\varphi\to\psi\in\Gamma\) by Proposition 10.9. (\(\Rightarrow\)) Let \(\varphi\to\psi\in\Gamma\). If \(\varphi\in\Gamma\), then MP gives \(\Gamma\vdash\psi\), so \(\psi\in\Gamma\) by Proposition 10.9. So \(\varphi\notin\Gamma\) or \(\psi\in\Gamma\).

(c) If \(\varphi\wedge\psi\in\Gamma\), then (L4), (L5) and MP give \(\Gamma\vdash\varphi\) and \(\Gamma\vdash\psi\), so both are in \(\Gamma\). If \(\varphi,\psi\in\Gamma\), then (L6) and MP twice give \(\Gamma\vdash\varphi\wedge\psi\), so \(\varphi\wedge\psi\in\Gamma\).

(d) If \(\varphi\in\Gamma\), then (L7) and MP give \(\Gamma\vdash\varphi\vee\psi\); if \(\psi\in\Gamma\), use (L8). Conversely, let \(\varphi\vee\psi\in\Gamma\) and \(\varphi\notin\Gamma\). Then \(\neg\varphi\in\Gamma\). By Definition 9.1, \(\varphi\vee\psi\) is the formula \(\neg\varphi\to\psi\), so MP gives \(\Gamma\vdash\psi\) and \(\psi\in\Gamma\). □

Example 10.11: deciding membership

Let \(\Gamma\) be maximally consistent with \(p\in\Gamma\) and \(q\notin\Gamma\). We decide, for several formulas, whether they belong to \(\Gamma\). Each answer follows from the status of the parts.

(a) \(\neg q\in\Gamma\), by (a): \(q\notin\Gamma\).
(b) \(p\to q\notin\Gamma\), by (b): the antecedent \(p\) is in \(\Gamma\) and the consequent \(q\) is not.
(c) \(q\to p\in\Gamma\), by (b): the antecedent \(q\) is not in \(\Gamma\).
(d) \((p\to q)\to q\in\Gamma\), by (b): the antecedent \(p\to q\) is not in \(\Gamma\), by part (b) of this example.
(e) \(\neg(p\wedge\neg q)\notin\Gamma\). By (c), \(p\wedge\neg q\in\Gamma\), because \(p\in\Gamma\) and \(\neg q\in\Gamma\). So its negation is not in \(\Gamma\), by (a).

The answers depend only on which primitive propositions are in \(\Gamma\), in the same way that the truth value of a formula depends only on the values of its primitive propositions. Compare: under the valuation with \(v(p)=\mathrm T\), \(v(q)=\mathrm F\), the five formulas have the values \(\mathrm T,\mathrm F,\mathrm T,\mathrm T,\mathrm F\), matching the answers above. This is no accident; it is the Truth Lemma of Day 2.

Exercise 2: membership in a maximally consistent set

Self-check only. Nothing here counts towards your grade.

Let \(\Gamma\) be maximally consistent with \(p\in\Gamma\), \(q\notin\Gamma\) and \(r\in\Gamma\). For each formula, decide whether it is in \(\Gamma\), using Proposition 10.10.

(a) \(\neg r\notin\Gamma\): \(r\in\Gamma\), rule (a).

(b) \(q\to p\in\Gamma\): the antecedent \(q\) is not in \(\Gamma\), rule (b).

(c) \(p\to q\notin\Gamma\): \(p\in\Gamma\) and \(q\notin\Gamma\), rule (b).

(d) \(\neg(p\to q)\in\Gamma\): \(p\to q\notin\Gamma\) by (c), rule (a).

(e) \(p\wedge\neg q\in\Gamma\): \(p\in\Gamma\) and \(\neg q\in\Gamma\), rule (c).

(f) \(q\vee r\in\Gamma\): \(r\in\Gamma\), rule (d).

(g) \(\neg p\vee\neg r\notin\Gamma\): neither \(\neg p\) nor \(\neg r\) is in \(\Gamma\), rule (d).

(h) \(\neg(p\to p)\notin\Gamma\): \(p\to p\in\Gamma\) by rule (b) (its consequent is in \(\Gamma\)), or because it is a theorem (Proposition 10.9); then rule (a).

Day 2: Lindenbaum's Lemma, the Truth Lemma and the Completeness Theorem

Today we extend any consistent set to a maximally consistent one, read the result as a valuation, and prove that every tautology has a deduction.

What we are using from before
  • \(\Gamma\) is consistent if there is no \(\varphi\) with \(\Gamma\vdash\varphi\) and \(\Gamma\vdash\neg\varphi\). A subset of a consistent set is consistent (Proposition 10.1(b)). A satisfiable set is consistent (Corollary 9.22).
  • Proposition 10.4: if \(\Gamma\nvdash\varphi\), then \(\Gamma\cup\{\neg\varphi\}\) is consistent.
  • \(\Gamma\) is maximally consistent if it is consistent and \(\Gamma\cup\{\varphi\}\) is inconsistent for every \(\varphi\notin\Gamma\) (Definition 10.6). Then for every \(\varphi\) exactly one of \(\varphi\in\Gamma\), \(\neg\varphi\in\Gamma\) holds (Proposition 10.8), and \(\varphi\to\psi\in\Gamma\) iff \(\varphi\notin\Gamma\) or \(\psi\in\Gamma\) (Proposition 10.10).
  • A valuation \(v\) gives each primitive proposition a value; \([\![\varphi]\!]_v\) is computed by \([\![\neg\varphi]\!]_v=\mathrm T\) iff \([\![\varphi]\!]_v=\mathrm F\), and \([\![\varphi\to\psi]\!]_v=\mathrm T\) iff \([\![\varphi]\!]_v=\mathrm F\) or \([\![\psi]\!]_v=\mathrm T\). Since \(\wedge\) and \(\vee\) are abbreviations (Definition 9.1), these two clauses cover every formula.
  • A deduction is a finite sequence of formulas, so it uses only finitely many members of \(\Gamma\) as assumptions.

4. Listing all formulas

The construction of today adds formulas to a set one at a time, and it must consider every formula. So we need all formulas in a single list \(\varphi_1,\varphi_2,\varphi_3,\dots\). The primitive propositions are \(p_1,p_2,p_3,\dots\); as usual we write \(p,q,r\) for \(p_1,p_2,p_3\).

Lemma 10.12: the formulas can be listed

There is a list \(\varphi_1,\varphi_2,\varphi_3,\dots\) in which every formula appears exactly once.

Proof. A formula is a finite string of symbols from \(\neg\), \(\to\), \((\), \()\) and the primitive propositions. For \(n\ge1\) let \(F_n\) be the set of formulas that have at most \(n\) symbols and use only \(p_1,\dots,p_n\). Each \(F_n\) is finite: there are finitely many strings of length at most \(n\) over an alphabet of \(n+4\) symbols. Every formula lies in some \(F_n\): take \(n\) at least the length of the formula and at least the largest index of a primitive proposition in it. Now list the members of \(F_1\) in any order, then the members of \(F_2\) that are not in \(F_1\), then the members of \(F_3\) that are not in \(F_2\), and so on. Every formula appears, at the stage of the first \(F_n\) that contains it, and it appears only there. □

Many lists work. For the examples below we choose short lists that begin with the formulas we care about; the rest of the list does not matter for the first few steps.

5. Lindenbaum's Lemma

Lemma 10.13: Lindenbaum's Lemma

Every consistent set \(\Gamma\) is contained in a maximally consistent set \(\Gamma'\).

Proof. Fix a list \(\varphi_1,\varphi_2,\dots\) of all formulas (Lemma 10.12). We define sets \(\Gamma_0,\Gamma_1,\Gamma_2,\dots\) by recursion: \[\Gamma_0=\Gamma,\qquad \Gamma_{n+1}=\begin{cases}\Gamma_n\cup\{\varphi_{n+1}\}&\text{if }\Gamma_n\cup\{\varphi_{n+1}\}\text{ is consistent,}\\ \Gamma_n&\text{otherwise.}\end{cases}\] So at stage \(n+1\) we look at the formula \(\varphi_{n+1}\) and add it if this keeps the set consistent; otherwise we skip it. Let \(\Gamma'=\bigcup_{n\ge0}\Gamma_n\), the set of formulas that belong to some \(\Gamma_n\). We prove four claims.

Claim 1: each \(\Gamma_n\) is consistent. By induction on \(n\). \(\Gamma_0=\Gamma\) is consistent by assumption. If \(\Gamma_n\) is consistent, then \(\Gamma_{n+1}\) is either \(\Gamma_n\cup\{\varphi_{n+1}\}\), which was added only because it is consistent, or \(\Gamma_n\) itself.

Claim 2: \(\Gamma=\Gamma_0\subseteq\Gamma_1\subseteq\Gamma_2\subseteq\cdots\subseteq\Gamma'\). Each \(\Gamma_{n+1}\) contains \(\Gamma_n\) by definition, and each \(\Gamma_n\) is contained in the union \(\Gamma'\).

Claim 3: \(\Gamma'\) is consistent. Suppose \(\Gamma'\vdash\psi\) and \(\Gamma'\vdash\neg\psi\). Take a deduction of \(\psi\) from \(\Gamma'\) and a deduction of \(\neg\psi\) from \(\Gamma'\). Together they have finitely many lines, so they use finitely many members of \(\Gamma'\) as assumptions, say \(\chi_1,\dots,\chi_m\). Each \(\chi_i\) lies in some \(\Gamma_{n_i}\). Let \(N\) be the largest of \(n_1,\dots,n_m\) (and \(N=0\) if \(m=0\)). By Claim 2, all of \(\chi_1,\dots,\chi_m\) lie in \(\Gamma_N\). So both deductions are deductions from \(\Gamma_N\): every line is an axiom, a member of \(\Gamma_N\), or follows by MP. Hence \(\Gamma_N\vdash\psi\) and \(\Gamma_N\vdash\neg\psi\), which contradicts Claim 1.

Claim 4: \(\Gamma'\) is maximally consistent. By Definition 10.6 and Claim 3, it is enough to show that \(\Gamma'\cup\{\psi\}\) is inconsistent for every \(\psi\notin\Gamma'\). Let \(\psi\notin\Gamma'\). The formula \(\psi\) is in the list, say \(\psi=\varphi_k\). Since \(\varphi_k\notin\Gamma'\) and \(\Gamma_k\subseteq\Gamma'\), we have \(\varphi_k\notin\Gamma_k\). So at stage \(k\) the formula was skipped, which means that \(\Gamma_{k-1}\cup\{\varphi_k\}\) is inconsistent. Since \(\Gamma_{k-1}\subseteq\Gamma'\), the set \(\Gamma'\cup\{\varphi_k\}\) contains \(\Gamma_{k-1}\cup\{\varphi_k\}\), so it is inconsistent by Proposition 10.1(b).

By Claims 2 to 4, \(\Gamma'\) is a maximally consistent set containing \(\Gamma\). □

Two remarks on the proof. First, the recursion is a definition, not a procedure that we could run: at each stage, exactly one of "\(\Gamma_n\cup\{\varphi_{n+1}\}\) is consistent" and "it is inconsistent" is true, and this is all the definition needs; it does not tell us how to find out which one. Second, Claim 3 uses the finiteness of deductions in an essential way: a deduction from an infinite set still has finitely many lines.

Γ = Γ₀ ⊆ Γ₁ ⊆ Γ₂ ⊆ Γ₃ ⊆ ⋯ ⊆ Γ′Γ₀ = ΓΓ₁Γ₀ ∪ {φ₁}Γ₂= Γ₁Γ₃Γ₂ ∪ {φ₃}⋯Γ′= ⋃ Γₙφ₁addedφ₂skippedφ₃added
Figure 2. The construction in Lindenbaum's Lemma. At stage \(n+1\) the formula \(\varphi_{n+1}\) is added if the result is consistent and skipped otherwise. The sets grow, and \(\Gamma'\) is their union. Every formula was considered at some stage; the ones that are missing from \(\Gamma'\) were skipped because adding them created an inconsistency.
Example 10.14: running the construction

Let \(\Gamma=\{p\to q\}\). To decide whether a set is consistent we use the two tools we have: a satisfying valuation shows consistency (Corollary 9.22), and a pair of deductions of \(\psi\) and \(\neg\psi\) shows inconsistency.

(a) Suppose the list begins \(\varphi_1=\neg q\), \(\varphi_2=p\), \(\varphi_3=q\), \(\varphi_4=\neg p\), \(\varphi_5=q\to p\).
StageSet consideredConsistent?Result
1\(\Gamma_0\cup\{\neg q\}=\{p\to q,\ \neg q\}\)Yes: \(v(p)=v(q)=\mathrm F\) satisfies it.\(\Gamma_1=\{p\to q,\ \neg q\}\)
2\(\Gamma_1\cup\{p\}=\{p\to q,\ \neg q,\ p\}\)No: it deduces \(q\) by MP and \(\neg q\) by (assump.).\(\Gamma_2=\Gamma_1\)
3\(\Gamma_2\cup\{q\}=\{p\to q,\ \neg q,\ q\}\)No: \(q\) and \(\neg q\) are both members.\(\Gamma_3=\Gamma_2\)
4\(\Gamma_3\cup\{\neg p\}=\{p\to q,\ \neg q,\ \neg p\}\)Yes: \(v(p)=v(q)=\mathrm F\) satisfies it.\(\Gamma_4=\{p\to q,\ \neg q,\ \neg p\}\)
5\(\Gamma_4\cup\{q\to p\}\)Yes: under \(v(p)=v(q)=\mathrm F\), \(q\to p\) is true.\(\Gamma_5=\{p\to q,\ \neg q,\ \neg p,\ q\to p\}\)

The valuation \(v(p)=v(q)=\mathrm F\) satisfies every set in this run.

(b) Now suppose the list begins \(\varphi_1=p\), \(\varphi_2=\neg q\), \(\varphi_3=q\). Stage 1: \(\{p\to q,\ p\}\) is satisfied by \(v(p)=v(q)=\mathrm T\), so \(\Gamma_1=\{p\to q,\ p\}\). Stage 2: \(\{p\to q,\ p,\ \neg q\}\) is inconsistent, as in (a), so \(\Gamma_2=\Gamma_1\). Stage 3: \(\{p\to q,\ p,\ q\}\) is satisfied by \(v(p)=v(q)=\mathrm T\), so \(\Gamma_3=\{p\to q,\ p,\ q\}\).

In (a), \(\neg p\in\Gamma'\); in (b), \(p\in\Gamma'\). The maximally consistent extension depends on the order of the list. Lindenbaum's Lemma promises some extension, not a unique one.

6. The Truth Lemma

Step 3 of the plan: a maximally consistent set can be read as a valuation.

Definition 10.15: the valuation of a maximally consistent set

Let \(\Gamma\) be maximally consistent. The valuation \(v_\Gamma\) is defined on the primitive propositions by \[v_\Gamma(p)=\begin{cases}\mathrm T&\text{if }p\in\Gamma,\\ \mathrm F&\text{if }p\notin\Gamma.\end{cases}\]

By definition, \(v_\Gamma\) agrees with \(\Gamma\) on the primitive propositions. The Truth Lemma says that it agrees with \(\Gamma\) on all formulas.

Lemma 10.16: the Truth Lemma

Let \(\Gamma\) be maximally consistent. For every formula \(\varphi\), \[[\![\varphi]\!]_{v_\Gamma}=\mathrm T\quad\text{if and only if}\quad\varphi\in\Gamma.\]

Proof. By induction on the number of connectives in \(\varphi\). Since \(\wedge\) and \(\vee\) are abbreviations, \(\varphi\) is a primitive proposition, a negation or an implication.

\(\varphi=p\). \([\![p]\!]_{v_\Gamma}=v_\Gamma(p)\), and \(v_\Gamma(p)=\mathrm T\) iff \(p\in\Gamma\) by Definition 10.15.

\(\varphi=\neg\psi\). Assume the claim for \(\psi\). Then \([\![\neg\psi]\!]_{v_\Gamma}=\mathrm T\) iff \([\![\psi]\!]_{v_\Gamma}=\mathrm F\) iff \(\psi\notin\Gamma\) (induction hypothesis) iff \(\neg\psi\in\Gamma\) (Proposition 10.10(a)).

\(\varphi=\psi\to\chi\). Assume the claim for \(\psi\) and \(\chi\). Then \([\![\psi\to\chi]\!]_{v_\Gamma}=\mathrm T\) iff \([\![\psi]\!]_{v_\Gamma}=\mathrm F\) or \([\![\chi]\!]_{v_\Gamma}=\mathrm T\) iff \(\psi\notin\Gamma\) or \(\chi\in\Gamma\) (induction hypothesis) iff \(\psi\to\chi\in\Gamma\) (Proposition 10.10(b)). □

The proof is short because Proposition 10.10 did the work: the membership rules for \(\neg\) and \(\to\) are the truth table clauses for \(\neg\) and \(\to\), with "\(\in\Gamma\)" in place of "true".

Example 10.17: why maximal consistency is needed

Definition 10.15 makes sense for any set \(\Gamma\), but the Truth Lemma fails without maximal consistency.

(a) \(\Gamma=\{p\to q\}\) is consistent but not maximally consistent. Neither \(p\) nor \(q\) is in \(\Gamma\), so \(v_\Gamma(p)=v_\Gamma(q)=\mathrm F\). Then \([\![\neg p]\!]_{v_\Gamma}=\mathrm T\), but \(\neg p\notin\Gamma\). The negation step of the proof breaks: \(p\notin\Gamma\) does not give \(\neg p\in\Gamma\), because Proposition 10.8 is not available.
(b) \(\Gamma=\{p,\neg p\}\) is inconsistent. Here \(v_\Gamma(p)=\mathrm T\), so \([\![\neg p]\!]_{v_\Gamma}=\mathrm F\), but \(\neg p\in\Gamma\). The lemma fails because \(\Gamma\) contains both \(p\) and \(\neg p\), and a valuation can make only one of them true.

7. The Completeness Theorem

We now put the steps together. The first theorem is the heart of the matter: it turns a consistent set into a valuation.

Theorem 10.18: consistent sets are satisfiable

Every consistent set of formulas is satisfiable.

Proof. Let \(\Gamma\) be consistent. By Lindenbaum's Lemma there is a maximally consistent \(\Gamma'\supseteq\Gamma\). By the Truth Lemma, \(v_{\Gamma'}\) makes every member of \(\Gamma'\) true. In particular it makes every member of \(\Gamma\) true, so \(v_{\Gamma'}\) satisfies \(\Gamma\). □

Together with Corollary 9.22 this says: a set is consistent if and only if it is satisfiable. We can now decide consistency with truth tables, in both directions. For example, in a run of Lindenbaum's construction a formula is skipped exactly when the set considered is unsatisfiable.

Exercise 3: run the construction

Self-check only. Nothing here counts towards your grade.

Let \(\Gamma=\{\neg p\to q\}\) and suppose the list of all formulas begins \(\varphi_1=\neg q\), \(\varphi_2=\neg p\), \(\varphi_3=p\to q\), \(\varphi_4=q\to r\), \(\varphi_5=r\), \(\varphi_6=p\to\neg r\). For each stage decide whether \(\varphi_n\) is added to \(\Gamma_{n-1}\) or skipped. By Theorem 10.18 and Corollary 9.22, the formula is added exactly when \(\Gamma_{n-1}\cup\{\varphi_n\}\) is satisfiable.

Stage 1. \(\{\neg p\to q,\ \neg q\}\) is satisfied by \(v(p)=\mathrm T\), \(v(q)=\mathrm F\). Added: \(\Gamma_1=\{\neg p\to q,\ \neg q\}\).

Stage 2. \(\Gamma_1\cup\{\neg p\}\): a satisfying valuation would need \(q\) false and \(\neg p\) true, and then \(\neg p\to q\) false. Unsatisfiable, so skipped: \(\Gamma_2=\Gamma_1\).

Stage 3. \(\Gamma_2\cup\{p\to q\}\): \(q\) must be false, so \(\neg p\to q\) forces \(p\) true, and then \(p\to q\) is false. Skipped: \(\Gamma_3=\Gamma_2\).

Stage 4. \(\Gamma_3\cup\{q\to r\}\) is satisfied by \(v(p)=\mathrm T\), \(v(q)=\mathrm F\) and any value of \(r\). Added: \(\Gamma_4=\{\neg p\to q,\ \neg q,\ q\to r\}\).

Stage 5. \(\Gamma_4\cup\{r\}\) is satisfied by \(v(p)=\mathrm T\), \(v(q)=\mathrm F\), \(v(r)=\mathrm T\). Added: \(\Gamma_5=\{\neg p\to q,\ \neg q,\ q\to r,\ r\}\).

Stage 6. \(\Gamma_5\cup\{p\to\neg r\}\): \(r\) is a member, and \(p\) is forced true as in stage 3, so \(p\to\neg r\) is false under every valuation that satisfies \(\Gamma_5\). Skipped: \(\Gamma_6=\Gamma_5\).

Theorem 10.19: the Completeness Theorem

For every formula \(\varphi\): if \(\models\varphi\), then \(\vdash\varphi\).

Proof. We prove the contrapositive. Suppose \(\nvdash\varphi\). By Proposition 10.4 with \(\Gamma=\varnothing\), the set \(\{\neg\varphi\}\) is consistent. By Theorem 10.18 some valuation \(v\) satisfies \(\{\neg\varphi\}\), that is, \([\![\neg\varphi]\!]_v=\mathrm T\) and \([\![\varphi]\!]_v=\mathrm F\). So \(\varphi\) is not a tautology: \(\not\models\varphi\). □

With Corollary 9.18 (every theorem is a tautology) we get: \(\vdash\varphi\) if and only if \(\models\varphi\). The two regions of Week 9, Figure 2 are the same region (Figure 3).

all formulastautologies: ⊨ φ= theorems: ⊢ φp → p(p ∧ q) → p((p → q) → p) → pSoundness: ⊢ φ ⇒ ⊨ φ. Completeness: ⊨ φ ⇒ ⊢ φ.pp → (p → q)¬(p → p)
Figure 3. After the Completeness Theorem the two regions of Week 9, Figure 2 coincide: a formula is a theorem exactly when it is a tautology. The formula \(((p\to q)\to p)\to p\) of Example 10.20 is inside, although we never wrote a deduction for it.
Method: is \(\varphi\) a theorem?

To show \(\vdash\varphi\), it is enough to check that \(\varphi\) is a tautology, with a truth table or a short argument; the Completeness Theorem then guarantees that a deduction exists. To show \(\nvdash\varphi\), give a valuation that makes \(\varphi\) false (Soundness). No deduction needs to be written in either case.

Example 10.20: theorems without deductions
(a) \(\vdash((p\to q)\to p)\to p\). This formula is known as Peirce's law, and a deduction of it from (L1) to (L9) is not easy to find. Its truth table:
\(p\)\(q\)\(p\to q\)\((p\to q)\to p\)\(((p\to q)\to p)\to p\)
TTTTT
TFFTT
FTTFT
FFTFT

The main column is all T, so the formula is a tautology, and by Theorem 10.19 it has a deduction. We know this without having seen the deduction.

(b) \(\vdash(\neg p\to p)\to p\). If \(v(p)=\mathrm T\) the consequent is true; if \(v(p)=\mathrm F\) the antecedent \(\neg p\to p\) is \(\mathrm T\to\mathrm F=\mathrm F\). So the formula is a tautology, and a theorem. In Week 9 we proved this by hand (Lemma 9.5(f)) in six lines that each needed an idea.
(c) \(\nvdash((p\to q)\to p)\to q\). Take \(v(p)=\mathrm T\), \(v(q)=\mathrm F\): then \(p\to q\) is false, \((p\to q)\to p\) is true, and the formula is \(\mathrm T\to\mathrm F=\mathrm F\). Compare with (a): changing the last \(p\) to \(q\) moves the formula out of the ellipse in Figure 3.
Exercise 4: theorem or not?

Self-check only. Nothing here counts towards your grade.

For each formula decide whether it is a theorem. Use the Method above: a truth table for yes, a valuation for no.

(a) Theorem: this is Peirce's law, Example 10.20(a).

(b) Theorem. False would need \(p\to q\) true, \(\neg q\) true and \(\neg p\) false, so \(p\) true and \(q\) false, and then \(p\to q\) is false.

(c) Not a theorem: \(v(p)=v(q)=\mathrm T\) makes \(\neg p\to q\) true and \(p\to\neg q\) false.

(d) Theorem: it is an instance of (L2), so it even has a one-line deduction.

(e) Not a theorem: \(v(p)=\mathrm T\), \(v(q)=\mathrm F\) makes \(p\vee q\) true and \(p\wedge q\) false.

(f) Theorem. \(\neg(p\to q)\) is true only when \(p\) is true and \(q\) is false, and then the consequent \(p\) is true.

Day 3: Strong completeness and its consequences

Today we prove that \(\Gamma\vdash\varphi\) and \(\Gamma\models\varphi\) are the same relation, and we derive the Compactness Theorem.

What we are using from before
  • \(v\) satisfies \(\Gamma\) if it makes every member of \(\Gamma\) true; \(\Gamma\) is satisfiable if some valuation satisfies it (Definition 8.1). \(\Gamma\models\varphi\) means that every valuation that satisfies \(\Gamma\) makes \(\varphi\) true (Definition 8.3).
  • Theorem 9.17 (Soundness): \(\Gamma\vdash\varphi\) implies \(\Gamma\models\varphi\). Corollary 9.22: a satisfiable set is consistent.
  • Proposition 10.4: if \(\Gamma\nvdash\varphi\), then \(\Gamma\cup\{\neg\varphi\}\) is consistent. Theorem 10.18: every consistent set is satisfiable.
  • A deduction has finitely many lines, so it uses finitely many assumptions.

8. Strong soundness and completeness

The Completeness Theorem is about tautologies, that is, about \(\varnothing\models\varphi\). The same proof works for any set of assumptions.

Theorem 10.21: Strong Soundness and Completeness

For every set of formulas \(\Gamma\) and every formula \(\varphi\): \[\Gamma\vdash\varphi\quad\text{if and only if}\quad\Gamma\models\varphi.\]

Corollary 10.22: consistent means satisfiable

A set of formulas is consistent if and only if it is satisfiable.

Proof. Satisfiable sets are consistent by Corollary 9.22; consistent sets are satisfiable by Theorem 10.18. □

The two notions of consequence of this course, the semantic \(\models\) defined by truth tables and the syntactic \(\vdash\) defined by deductions, are the same relation. In Week 9 we had one tool for each side of a question: a deduction to show \(\Gamma\vdash\varphi\), a valuation to show \(\Gamma\nvdash\varphi\). Now one tool decides both sides.

Method: deciding \(\Gamma\vdash\varphi\) and consistency
  1. To show \(\Gamma\vdash\varphi\): show \(\Gamma\models\varphi\), by a truth table or by an argument about an arbitrary valuation that satisfies \(\Gamma\). Then cite Theorem 10.21. To show \(\Gamma\nvdash\varphi\): give a valuation that satisfies \(\Gamma\) and makes \(\varphi\) false.
  2. To show that \(\Gamma\) is consistent: give a valuation that satisfies it. To show that \(\Gamma\) is inconsistent: show that no valuation satisfies it. Then cite Corollary 10.22.
Example 10.23: deductions decided by valuations
(a) \(p\to(q\vee r),\ \neg q\vdash p\to r\). Let \(v\) satisfy the two assumptions. If \(v(p)=\mathrm F\), then \(p\to r\) is true. If \(v(p)=\mathrm T\), then \(q\vee r\) is true; since \(\neg q\) is true, \(q\) is false, so \(r\) is true, and \(p\to r\) is true. So \(p\to(q\vee r),\ \neg q\models p\to r\), and the deduction exists by Theorem 10.21.
(b) \((p\to q)\to r\vdash\neg p\to r\). Let \(v\) satisfy \((p\to q)\to r\). If \(v(p)=\mathrm T\), then \(\neg p\) is false and \(\neg p\to r\) is true. If \(v(p)=\mathrm F\), then \(p\to q\) is true, so \(r\) is true by the assumption, and \(\neg p\to r\) is true.
(c) \(p\vee q,\ \neg p\vdash q\). If \(v\) makes \(\neg p\) true, then \(p\) is false, so \(p\vee q\) true forces \(q\) true. In Week 9 this needed a deduction with (L9); now it is one sentence.
(d) \(p\to q\nvdash\neg p\to\neg q\). The valuation \(v(p)=\mathrm F\), \(v(q)=\mathrm T\) makes \(p\to q\) true and \(\neg p\to\neg q\) false.
(e) \(\{p\to q,\ q\to r,\ \neg(p\to r)\}\) is inconsistent. A satisfying valuation would make \(p\to r\) false, so \(p\) true and \(r\) false; then \(p\to q\) forces \(q\) true, and \(q\to r\) is false. No valuation works, so the set is inconsistent by Corollary 10.22. We did not write the two deductions that Definition 9.21 asks for; Theorem 10.21 says they exist.
Example 10.24: infinitely many assumptions

Let \(\Gamma=\{p_1\}\cup\{p_n\to p_{n+1}: n\ge1\}=\{p_1,\ p_1\to p_2,\ p_2\to p_3,\ p_3\to p_4,\ \dots\}\). We claim \(\Gamma\vdash p_{100}\). By Theorem 10.21 it is enough to show \(\Gamma\models p_{100}\). Let \(v\) satisfy \(\Gamma\). We show \(v(p_n)=\mathrm T\) for every \(n\ge1\), by induction on \(n\). For \(n=1\), \(p_1\in\Gamma\). If \(v(p_n)=\mathrm T\), then since \(p_n\to p_{n+1}\) is true under \(v\), also \(v(p_{n+1})=\mathrm T\). In particular \(v(p_{100})=\mathrm T\).

Here the deduction is easy to describe (write \(p_1\), then \(p_1\to p_2\) and \(p_2\) by MP, and so on up to \(p_{100}\)), but note what it uses: only the first hundred members of the infinite set \(\Gamma\). The next section shows that this is always so.

Exercise 5: deducible or not, decided by truth tables

Self-check only. Nothing here counts towards your grade.

For each claim, decide whether it holds, by Theorem 10.21. If it does not hold, give a valuation that satisfies the left side and makes the right side false.

(a) Deducible: if \(p\to q\) and \(\neg q\) are true, then \(p\) cannot be true, so \(\neg p\) is true.

(b) Not deducible: \(v(p)=\mathrm T\), \(v(q)=\mathrm F\) makes \(p\vee q\) true and \(p\to q\) false.

(c) Deducible: if \(p\wedge q\) is false, one of \(p\), \(q\) is false, so one of \(\neg p\), \(\neg q\) is true.

(d) Deducible: if \(p\wedge q\) is true then \(p\) is true, so \(r\) is true by \(p\to r\).

(e) Not deducible: \(v(p)=\mathrm T\), \(v(q)=v(r)=\mathrm F\) makes \(p\wedge q\) false, so \((p\wedge q)\to r\) is true, while \(p\to r\) is false.

(f) Deducible. If \(v(p)=\mathrm T\), the consequent \((q\to p)\to p\) is true. If \(v(p)=\mathrm F\), then \((p\to q)\to q\) has the value of \(q\), and \((q\to p)\to p\) is \(\neg q\to\mathrm F\), which also has the value of \(q\); so the formula is \(q\to q\), true.

9. Compactness

A deduction is finite. This simple fact, passed through Theorem 10.21, gives a statement about valuations that mentions no deductions at all.

Lemma 10.25: finitely many assumptions suffice

If \(\Gamma\vdash\varphi\), then there is a finite set \(\Gamma_0\subseteq\Gamma\) with \(\Gamma_0\vdash\varphi\).

Proof. Take a deduction of \(\varphi\) from \(\Gamma\) and let \(\Gamma_0\) be the set of members of \(\Gamma\) that occur as lines of it. \(\Gamma_0\) is finite, because the deduction has finitely many lines, and the same sequence is a deduction of \(\varphi\) from \(\Gamma_0\). □

Theorem 10.26: the Compactness Theorem

A set of formulas \(\Gamma\) is satisfiable if and only if every finite subset of \(\Gamma\) is satisfiable.

Proof. (\(\Rightarrow\)) A valuation that satisfies \(\Gamma\) satisfies every subset of \(\Gamma\).

(\(\Leftarrow\)) We prove the contrapositive: if \(\Gamma\) is unsatisfiable, then some finite subset of \(\Gamma\) is unsatisfiable. Let \(\Gamma\) be unsatisfiable. By Corollary 10.22, \(\Gamma\) is inconsistent: \(\Gamma\vdash\psi\) and \(\Gamma\vdash\neg\psi\) for some \(\psi\). By Lemma 10.25 there are finite \(\Gamma_1,\Gamma_2\subseteq\Gamma\) with \(\Gamma_1\vdash\psi\) and \(\Gamma_2\vdash\neg\psi\). Let \(\Gamma_0=\Gamma_1\cup\Gamma_2\), a finite subset of \(\Gamma\). By Proposition 8.35(b), \(\Gamma_0\vdash\psi\) and \(\Gamma_0\vdash\neg\psi\), so \(\Gamma_0\) is inconsistent, and by Corollary 9.22 it is unsatisfiable. □

Corollary 10.27: finitely many assumptions suffice for \(\models\)

If \(\Gamma\models\varphi\), then there is a finite set \(\Gamma_0\subseteq\Gamma\) with \(\Gamma_0\models\varphi\).

Proof. From \(\Gamma\models\varphi\) we get \(\Gamma\vdash\varphi\) by Theorem 10.21, then \(\Gamma_0\vdash\varphi\) for a finite \(\Gamma_0\subseteq\Gamma\) by Lemma 10.25, then \(\Gamma_0\models\varphi\) by Soundness. □

Both statements are about truth tables only, but the proof goes through deductions. A direct proof is possible but much longer; the Completeness Theorem lets the finiteness of deductions do the work.

Example 10.28: an unsatisfiable finite subset

Let \(\Gamma=\{p_1,\ \neg p_5\}\cup\{p_n\to p_{n+1}: n\ge1\}\). The set is unsatisfiable: as in Example 10.24, a valuation that satisfies \(p_1\) and all \(p_n\to p_{n+1}\) makes every \(p_n\) true, so it does not satisfy \(\neg p_5\). By the Compactness Theorem some finite subset is unsatisfiable, and here we can point to it: \[\Gamma_0=\{p_1,\ p_1\to p_2,\ p_2\to p_3,\ p_3\to p_4,\ p_4\to p_5,\ \neg p_5\}.\] A valuation satisfying the first five members makes \(p_5\) true, so it falsifies \(\neg p_5\). The members \(p_5\to p_6,\ p_6\to p_7,\dots\) play no role. Removing any member of \(\Gamma_0\) gives a satisfiable set: for example, without \(p_3\to p_4\), the valuation with \(p_1,p_2,p_3\) true and \(p_4,p_5\) false satisfies the rest.

Homework 10

Instructions

  • Write your full name in the box below before you start.
  • Show your work. For every answer give the reasons, not only the result.
  • You may use every result of Weeks 8 to 10, cited by its number. In deductions you may use (assump.), (L1) to (L9), MP, HS and theorems proved in the notes. Where Theorem 10.21 or Corollary 10.22 applies, a truth table or an argument about valuations is a complete proof; say which theorem you use.
  • Each question has two answer modes, Type and Write by hand. In Write by hand mode the text boxes are replaced by a drawing area where you can write with a pen, a finger or a mouse. For each question, only the answer in the selected mode goes into the PDF. Switching modes does not delete what you entered in the other mode.
  • The symbol buttons under a text box insert symbols at the cursor.
  • To submit, press Save homework as PDF, save the PDF and upload it to Canvas.
  • Your answers are saved automatically in this browser. If you open this page on a different computer or in a different browser, they will not be there.

Question 1: adding a formula to a set20 points

Proposition 10.4 says: if \(\Gamma\cup\{\neg\varphi\}\) is inconsistent, then \(\Gamma\vdash\varphi\). This question proves the companion statement for \(\Gamma\cup\{\varphi\}\).

(a) (12 points) Show that if \(\Gamma\cup\{\varphi\}\) is inconsistent, then \(\Gamma\vdash\neg\varphi\). Hint: first show \(\varphi\to\psi,\ \varphi\to\neg\psi\vdash\neg\varphi\) with a deduction; Lemma 9.5(c), (d), (e), (f) and HS are enough. Write the deduction in Fitch notation, then the argument.
(b) (8 points) Conclude that for all \(\Gamma\) and \(\varphi\): \(\Gamma\cup\{\varphi\}\) is inconsistent if and only if \(\Gamma\vdash\neg\varphi\), and \(\Gamma\cup\{\neg\varphi\}\) is inconsistent if and only if \(\Gamma\vdash\varphi\).

Question 2: maximally consistent sets25 points

(a) (15 points) Let \(\Gamma\) be maximally consistent with \(p\in\Gamma\), \(q\notin\Gamma\) and \(r\to q\in\Gamma\). For each formula decide whether it belongs to \(\Gamma\), and give the reason: which part of Proposition 10.10 you use and what it says about the parts of the formula.
FormulaIn \(\Gamma\)?Reason
(i) \(r\)
(ii) \(p\to r\)
(iii) \(\neg r\vee q\)
(iv) \((q\to p)\wedge\neg r\)
(v) \(\neg(p\to q)\to r\)
(vi) \((r\to p)\to(p\to\neg q)\)
(b) (10 points) Let \(\Gamma\) and \(\Delta\) be maximally consistent sets with \(\Gamma\ne\Delta\). Show that \(\Gamma\cap\Delta\) is consistent but not maximally consistent.

Question 3: Lindenbaum's construction by hand25 points

Let \(\Gamma=\{p\to\neg q\}\).

(a) (15 points) Suppose the list of all formulas begins \(\varphi_1=q\), \(\varphi_2=p\), \(\varphi_3=\neg p\), \(\varphi_4=q\to p\), \(\varphi_5=\neg p\vee\neg q\). Carry out the first five stages of the construction in the proof of Lemma 10.13. For each stage say whether \(\varphi_n\) is added or skipped, write \(\Gamma_n\), and justify the decision: a satisfying valuation if the set is consistent, and an argument that no valuation satisfies it (Corollary 10.22) if it is not.
\(n\)\(\varphi_n\)Added or skipped?\(\Gamma_n\)Reason
1\(q\)
2\(p\)
3\(\neg p\)
4\(q\to p\)
5\(\neg p\vee\neg q\)
(b) (6 points) Now suppose the list begins \(\varphi_1=p\), \(\varphi_2=q\), \(\varphi_3=\neg p\). Compute \(\Gamma_1,\Gamma_2,\Gamma_3\) with justification. Which of \(p\), \(\neg p\) belongs to \(\Gamma'\) in this run, and which in the run of part (a)?
(c) (4 points) For the run of part (a), determine \(v_{\Gamma'}(p)\) and \(v_{\Gamma'}(q)\), and explain why these two values are already fixed after stage 3, whatever the rest of the list is.

Question 4: strong completeness at work30 points

(a) (12 points) Decide each claim using Theorem 10.21. If it holds, give a truth table or an argument about an arbitrary valuation that satisfies the left side. If it fails, give a valuation that shows this.
  1. \(p\to(q\to r),\ q\vdash p\to r\)
  2. \(\neg p\to q,\ \neg q\vdash p\)
  3. \(p\to q,\ r\to q\vdash p\to r\)
(b) (8 points) Show that the infinite set \(\Gamma=\{p_n\vee p_{n+1}: n\ge1\}\cup\{\neg(p_n\wedge p_{n+1}): n\ge1\}\) is consistent.
(c) (10 points) Let \(\Delta=\{p_1\}\cup\{p_n\to p_{n+1}: n\ge1\}\cup\{\neg p_{20}\}\). Show that \(\Delta\) is inconsistent. Then give a finite inconsistent subset of \(\Delta\) with as few members as possible, say how many members it has, and explain why it is inconsistent.