# Notes - Logic MT24, Gödel's completeness theorem

> Source: https://ollybritton.com/notes/uni/part-b/mt24/logic/notes/godels-completeness-theorem/ · Updated: 2025-06-16 · Tags: uni, notes

- [Course - Logic MT24](https://ollybritton.com/notes/uni/part-b/mt24/logic/)
	- [Notes - Logic MT24, Proofs in first-order logic](https://ollybritton.com/notes/uni/part-b/mt24/logic/notes/proofs-in-first-order-logic/)

Although similar-sounding to [Gödel's incompleteness theorems](https://en.wikipedia.org/wiki/G%C3%B6del%27s_incompleteness_theorems), the completeness theorem actually establishes a positive result, namely that any formula entailed by a collection of sentences in a first order language is provable from those sentences (in the proof system this course uses).

### Proof summary
In other words, Gödel's completeness theorem says that if $\Sigma \models \phi$, then $\Sigma \vdash \phi$. To prove this, we first note that:

- $(1)$: $\Sigma \models \tau$ if and only if $\Sigma \cup \lbrace \lnot \tau\rbrace$ is unsatisfiable.
- $(2)$: $\Sigma \cup \lbrace \lnot \tau\rbrace$ is inconsistent if and only if $\Sigma \vdash \tau$.

If we could prove that

- If $\Sigma \cup \lbrace \lnot \tau\rbrace$ is unsatisfiable, then $\Sigma \cup \lbrace \lnot \tau\rbrace$ is inconsistent, or equivalently
- If $\Sigma \cup \lbrace \lnot \tau\rbrace$ is consistent, then $\Sigma \cup \lbrace \lnot \tau\rbrace$ is satisfiable.

Then we would bridge the gap between statements $(1)$ and $(2)$, and the result would follow. Instead of working with $\Sigma \cup \lbrace \lnot \tau\rbrace$, we just work with any $\mathcal L$-theory $\Sigma$, so need to show:

- If $\Sigma$ is consistent, then $\Sigma$ is satisfiable.

We break this down as follows:

- If $\Sigma$ is consistent, $\Sigma$ extends to a complete and 'witnessing' $\Sigma'$
	- A theory is witnessing if, whenever $\Sigma \vdash \exists x _ i \psi$ with $\exists x _ i \psi$ a sentence, there's some constant symbol $c$ such that $\Sigma \vdash \psi[c/x _ i]$.
	- (For example, Peano arithmetic is not witnessing since $\exists x _ i (x _ i = S(0))$ is true, but $1$ is not a constant symbol).
	- You can prove (in $K(\mathcal L)$) that if $\Sigma$ is not witnessing, you can just add constants from $\mathcal L$ in order to extend to $\Sigma'$.
	- You can also extend to a complete theory in the same way as for the completeness of proofs in propositional logic.
- If $\Sigma'$ is complete and witnessing, then $\Sigma$ is satisfiable.
	- First it's shown that $\Sigma'$ is satisfiable (i.e. has a model). This is done by the Henkin construction, which is very similar to the Herbrand construction but where you take equivalence classes of terms that the theory proves equal.
	- Then, since $\Sigma \subseteq \Sigma'$, this is also a model for $\Sigma$. The only slight problem is that $\Sigma'$ and $\Sigma$ are over different languages, but you can show this is actually fine.

### Flashcards
#### The basic statement
<!-- flash-start -->
@State Gödel's Completeness Theorem.::

Suppose:

- $\mathcal L$ is a first-order language
- $\Sigma \subseteq \mathrm{Sent}(\mathcal L)$
- $\phi \in \mathrm{Form}(\mathcal L)$
- $\Sigma \models \phi$

Then:

- $\Sigma \vdash \phi$

**Builds on**: ∆logical-consequence, ∆provable-from-sigma

^godel-completeness-theorem
<!-- flash-end -->

#### If a theory is consistent, it is consistent even when you add infinitely many constant symbols
<!-- flash-start -->
@State a result about proofs in a first-order language $\mathcal L$, but where you've added extra constants.::

Suppose:

- $\mathcal L$ is a first-order language
- $\Sigma \subseteq \mathrm{Sent}(\mathcal L)$ is an $\mathcal L$-theory
- $\mathcal L' := \mathcal L \cup \lbrace c _ 0, c _ 1, \ldots\rbrace$ where $c _ i$ not in $\mathcal L$

Then:

1. If $\Sigma \vdash _ {\mathcal L'} \tau \in \mathrm{Sent}(\mathcal L)$, then $\Sigma \vdash \tau$
2. If $\Sigma$ is inconsistent in $K(\mathcal L')$, then $\Sigma$ is inconsistent in $K(\mathcal L)$.

($\Sigma \vdash _ {\mathcal L'} \phi$ means that there is a proof of $\phi$ from $\Sigma$ in $K(\mathcal L')$). In other words, if you can prove something using the extra constants, you can also prove it without using the extra constants.

**Builds on**: ∆provable-from-sigma, ∆consistent-theory

^added-constants-conservative
<!-- flash-end -->

<!-- flash-start -->
@Prove that if:

- $\mathcal L$ is a first-order language
- $\Sigma \subseteq \mathrm{Sent}(\mathcal L)$ is an $\mathcal L$-theory
- $\mathcal L' := \mathcal L \cup \lbrace c _ 0, c _ 1, \ldots\rbrace$ where $c _ i$ not in $\mathcal L$
- $\Sigma \vdash _ {\mathcal L'} \phi$ means that there is a proof of $\phi$ from $\Sigma$ in $K(\mathcal L')$

then:

1. If $\Sigma \vdash _ {\mathcal L'} \tau \in \mathrm{Sent}(\mathcal L)$, then $\Sigma \vdash \tau$
2. If $\Sigma$ is consistent in $K(\mathcal L)$, then $\Sigma$ is consistent in $K(\mathcal L')$.

::

**Claim 1**: Since proofs are finite, there is a proof of $\tau$ from $\Sigma$ in $K(\mathcal L \cup \lbrace c _ 1, \ldots, c _ n\rbrace )$ for some $c _ 1, \ldots, c _ n \in C$. Since $\tau$ is a sentence, $\tau = \tau[c _ n / x _ 0]$ and so by ∆generalisation-on-constants-proof there is a proof of $\tau$ from $\Sigma$ in $K(\mathcal L')$ in which $c _ n$ does not appear, i.e. a proof in $K(\mathcal L \cup \lbrace c _ 1, \ldots, c _ {n-1}\rbrace )$. Iterating this, we obtain a proof in $K(\mathcal L)$.

**Claim 2**: Arguing by the contrapositive, if $\Sigma$ is inconsistent in $K(\mathcal L')$, $\Sigma \vdash _ {\mathcal L'} \tau$ and $\Sigma \vdash \lnot \tau$ for some $\tau$. But then by 1, it follows $\Sigma \vdash _ {\mathcal L} \tau$ and $\Sigma \vdash _ {\mathcal L} \lnot\tau$, hence $\Sigma$ is inconsistent.

**Builds on**: ∆added-constants-conservative, ∆generalisation-on-constants-proof

^added-constants-conservative-proof
<!-- flash-end -->

#### Every consistent theory with infinitely many constant symbols extends to a complete witnessing theory
<!-- flash-start -->
Suppose:

- $\mathcal L$ is a first-order language
- $\Sigma \subseteq \mathrm{Sent}(\mathcal L)$ is an $\mathcal L$-theory

@Define what it means for $\Sigma$ to be witnessing.::

For all $\psi \in \mathrm{Form}(\mathcal L)$ such that $\exists x _ i \psi \in \mathrm{Sent}(\mathcal L)$ and $\Sigma \vdash \exists x _ i \psi$, there exists some constant symbol $c \in \mathcal L$ such that $\Sigma \vdash \psi[c/x _ i]$.

^witnessing-theory
<!-- flash-end -->

<!-- flash-start -->
@Prove that if:

- $\mathcal L$ is a first-order language
- $\Sigma \subseteq \mathrm{Sent}(\mathcal L)$ is an $\mathcal L$-theory
- $c \in \mathcal L$ is a constant symbol which does not occur in $\phi$, nor in any sentence of $\Sigma$
- $\Sigma \vdash \phi[c / x _ i]$

then:

- $\Sigma \vdash \phi$
- There is a proof of $\phi$ from $\Sigma$ in which $c$ does not appear

(This is used in the proof of Gödel's completeness theorem, since it shows that if you've found an extension of $\Sigma$ to $\Sigma'$ to a theory that is complete and witnessing, you can show that $\Sigma$ is also satisfiable).

::

**Overall idea**: Let $\alpha_1, \ldots, \alpha_n$ be a proof of $\phi[c / x_i]$, and show that replacing each occurrence of $c$ in $\alpha_i$ by a fresh variable $x_m$ yields a proof $\alpha_1', \ldots, \alpha_n'$ of $\phi[x_m/x_i]$, which by **Gen** and **A4** gives a proof of $\phi[x_m/x_i][x_i/x_m] = \phi$ as required.

---

Suppose
$$
\alpha _ 1, \ldots, \alpha _ n = \phi[c/x _ i]
$$
is a proof of $\phi[c/x _ i]$ from $\Sigma$. Suppose $m \in \mathbb N$ such that no $\alpha _ k$ contains $x _ m$.

Let $\alpha _ 1', \ldots, \alpha _ n'$ be the sequence obtained by replacing in each $\alpha _ k$ each occurrence of $c$ by $x _ m$. We claim that $\alpha _ 1', \ldots, \alpha _ n'$ is a proof of $\alpha _ n' = \phi[x _ m / x _ i]$ from $\Sigma$.

Since $c$ doesn't occur in any formula in $\Sigma$, if $\alpha _ k \in \Sigma$, then $\alpha _ k' = \alpha _ k \in \Sigma$.

If $\alpha _ k$ is an axiom, then so is $\alpha _ k'$. This is clear for all axiom schemes except **A4**. For **A4**, note that if
$$
\alpha _ k = (\forall x _ j \phi \to \phi[t/x _ j])
$$
then
$$
\alpha _ k' = (\forall x _ j \phi' \to \phi'[t'/x _ j])
$$
where $\phi'$ and $t'$ are obtained by replacing $c$ with $x _ m$. Here $\phi'[t'/x _ j]$ is defined because $\phi[t/x _ j]$ is defined and the quantifier $\forall x _ m$ does not occur in $\phi'$.

Also, **Gen** and **MP** are not affected by the change.

Therefore $\Sigma \vdash \alpha _ n' = \phi[x _ m / x _ i]$. By **Gen**, this implies that $\Sigma \vdash \forall x _ m \phi[x _ m /x _ i]$.

Note that
$$
(\phi[x _ m / x _ i])[x _ i / x _ m]
$$
 is defined and equal to $\phi$. The effect of the substitutions is to replace the free occurrences of $x _ i$ in $\phi$ with $x _ m$ then revert them to $x _ i$ (which doesn't create new bound occurrences because only the free occurrences of $x _ i$ were substituted by $x _ m$).

So by **A4** with $t = x _ i$ and **MP**, we obtain $\Sigma \vdash (\phi[x _ m / x _ i])[x _ i / x _ m] = \phi$, and $c$ does not appear in the proof.

**Builds on**: ∆k-l-proof-system, ∆substitution-definition

^generalisation-on-constants-proof
<!-- flash-end -->

<!-- flash-start -->
@Prove that if:

- $\mathcal L$ is a first-order language
- $\Sigma \subseteq \mathrm{Sent}(\mathcal L)$ is an $\mathcal L$-theory
- $\Sigma$ is consistent
- $\Sigma \vdash \exists x _ i \psi \in \mathrm{Sent}(\mathcal L)$
- $c$ is a constant symbol of $\mathcal L$ which does not occur in $\psi$ nor in any $\sigma \in \Sigma$

then:

- $\Sigma \cup \lbrace \psi[c/x _ i]\rbrace$ is consistent

::

We prove the sub-claim that if

- $\tau$ is an $\mathcal L$-sentence
- $\Sigma \cup \lbrace \psi[c/x _ i]\rbrace  \vdash \tau$

then:

- $\Sigma \vdash \tau$

This implies the result, since if $\Sigma \cup \lbrace \psi[c/x _ i]\rbrace$ were inconsistent then we would have that for any $\tau$, $\Sigma \cup \lbrace \psi [c/x _ i]\rbrace  \vdash \tau$ and $\Sigma \cup \lbrace \psi [c/x _ i]\rbrace  \vdash \lnot\tau$. Picking $\tau$ in which $c$ does not occur, it would follow by the claim that $\Sigma \vdash \tau$ and $\Sigma \vdash \lnot \tau$, a contradiction.

---

Suppose that
$$
\Sigma \cup \lbrace \psi[c/x _ i]\rbrace  \vdash \tau \in \mathrm{Sent}(\mathcal L)
$$
and $c$ does not occur in $\tau$. By assumption, $c$ does not occur in $\Sigma$ or $\psi$.

Then $\psi[c/x _ i] \in \mathrm{Sent}(\mathcal L)$. By the deduction theorem,
$$
\Sigma \vdash (\psi [c/x _ i] \to \tau)
$$
By ∆generalisation-on-constants-proof, it follows that $\Sigma \vdash (\psi \to \tau)$.

By **Gen**, $\Sigma \vdash \forall x _ i (\psi \to \tau)$. Then $\Sigma \vdash (\exists x _ i \psi \to \tau)$ because it's possible to prove $\vdash (\forall x _ i (\psi \to \tau)\to(\exists x _ i \psi \to \tau))$ in $K(\mathcal L)$ (∆k-proof-exists-elimination).

But then by assumption $\Sigma \vdash \exists x _ i \psi$, so by **MP**, $\Sigma \vdash \tau$, as required. Hence the sub-claim follows.

**Builds on**: ∆first-order-deduction-theorem, ∆generalisation-on-constants-proof, ∆k-proof-exists-elimination

^witness-addition-consistent-proof
<!-- flash-end -->

<!-- flash-start -->
@Prove that if:

- $\mathcal L$ is a first-order language
- $\Sigma \subseteq \mathrm{Sent}(\mathcal L)$ is an $\mathcal L$-theory
- $\Sigma$ is consistent
- $\mathcal L$ contains infinitely many constant symbols not appearing in $\Sigma$

then:

- $\Sigma$ extends to a complete witnessing $\mathcal L$-theory $\Sigma^\ast \subseteq \mathrm{Sent}(\mathcal L)$

::

Note that $\mathrm{Sent}(\mathcal L)$ is countable, and consider an enumeration
$$
\mathrm{Sent}(\mathcal L) = \lbrace \tau _ 0, \tau _ 1, \ldots\rbrace 
$$
Construct a chain $\Sigma _ i \subseteq \mathrm{Sent}(\mathcal L)$
$$
\Sigma = \Sigma _ 0 \subseteq \Sigma _ 1 \subseteq \Sigma _ 2 \subseteq \cdots
$$
such that for each $n$:

- $\Sigma _ n$ is consistent
- $\mathcal L$ contains infinitely many constant symbols not appearing in $\Sigma _ n$

Note that $\Sigma _ 0$ satisfies these conditions by assumption.

Now suppose that we are given $\Sigma _ n$ satisfying these conditions, and let
$$
\Sigma _ n' := \begin{cases}
\Sigma _ n \cup \lbrace \tau _ n\rbrace  &\text{if } \Sigma _ n \cup \lbrace \tau _ n\rbrace  \text{ is consistent} \\
\Sigma _ n \cup \lbrace \lnot \tau _ n\rbrace  &\text{otherwise}
\end{cases}
$$
Then $\Sigma _ n'$ is consistent by the result that says: for a consistent $\mathcal L$-theory $\Sigma$ and an $\mathcal L$-sentence $\tau$, either $\Sigma \cup \lbrace \tau\rbrace$ is consistent or $\Sigma \cup \lbrace \lnot \tau\rbrace$ is consistent.

If $\tau _ n$ is not of the form $\exists x _ i \psi$, let $\Sigma _ {n+1} := \Sigma _ n'$ ($\tau_n$ might already be in the set, but this is okay). We need to handle the case where $\tau_n = \exists x_i \psi$ separately to ensure that the theory becomes witnessing.

If $\tau _ n = \exists x _ i \psi \in \Sigma _ n'$, choose a constant symbol $c \in \mathcal L$ which doesn't occur in any formulas in $\Sigma _ n' \cup \lbrace \psi\rbrace$ (whose existence is ensured by the conditions), and let $\Sigma _ {n+1} := \Sigma _ n' \cup \lbrace \psi[c/x _ i]\rbrace$. By ∆witness-addition-consistent-proof, it follows that $\Sigma _ {n+1}$ is consistent (note we include both $\exists x_i \psi$ and $\psi[c/x_i]$).

Since $\Sigma _ {n+1} \setminus \Sigma _ n$ is finite, $\mathcal L$ contains infinitely many constant symbols not appearing in $\Sigma _ {n+1}$. Therefore $\Sigma _ {n+1}$ meets the two required conditions.

Finally, let
$$
\Sigma^\ast := \bigcup _ {n \ge 0} \Sigma _ n
$$
Then $\Sigma^\ast$ is consistent since each $\Sigma _ n$ is, and $\Sigma^\ast$ is complete and witnessing by construction, since every sentence appears as some $\tau _ n$.

**Builds on**: ∆maximally-consistent-theory, ∆witnessing-theory, ∆witness-addition-consistent-proof, ∆l0-consistent-extension-lemma

^complete-witnessing-extension-proof
<!-- flash-end -->

#### Every complete witnessing theory has a model given by the Henkin construction
<!-- flash-start -->
@State a theorem that comes as a consequence of the Henkin construction.::

Every complete witnessing $\mathcal L$-theory $\Sigma$ has a model.

(The Henkin construction gives such a model).

**Builds on**: ∆maximally-consistent-theory, ∆witnessing-theory, ∆satisfiable-theory

^henkin-model-existence
<!-- flash-end -->

<!-- flash-start -->
@Define what it means for a term in a first-order language $\mathcal L$ to be closed.::

It doesn't contain any variables.

("no free variables" is also correct and equivalent, terms do not contain quantifiers so if a variable occurs, it occurs freely).

^closed-term
<!-- flash-end -->

<!-- flash-start -->
Suppose:

- $\Sigma$ is a complete, witnessing $\mathcal L$-theory

@State the components of the Henkin construction.::

Let $T$ be the set of all closed $\mathcal L$-terms (i.e. terms containing no variables). Define an equivalence relation $E$ on $T$ by
$$
t _ 1 E t _ 2 \iff \Sigma \vdash (t _ 1 \doteq t _ 2)
$$
Note that this is an equivalence relation (it is symmetric, reflexive and transitive by considering axioms A6-A8).

Let $T/E$ be the set of equivalence classes $t/E$ for each $t \in T$. Define an $\mathcal L$-structure $\mathcal M$ with domain $T/E$ by:

- $c^\mathcal M := c/E$
- $f^{\mathcal M}(t _ 1 / E, \ldots, t _ k / E) := f(t _ 1, \ldots, t _ k) / E$
- $P^\mathcal M := \lbrace (t _ 1 / E, \ldots, t _ k / E) \mid \Sigma \vdash P(t _ 1, \ldots, t _ k)\rbrace$

This is well-defined because the definitions do not depend on the choice of representatives (i.e. if $t _ i / E = t _ i' / E$, then $f(t _ 1, \ldots, t _ k) / E = f(t _ 1', \ldots, t' _ k)/E$, $\Sigma \vdash P(t _ 1, \ldots, t _ k) \iff \Sigma \vdash P(t' _ 1, \ldots, t' _ k)$, and $t^\mathcal M = t/E$ for any $t \in T$; this is non-trivial but follows from axioms A4, A8 and induction).

**Builds on**: ∆maximally-consistent-theory, ∆witnessing-theory, ∆closed-term, ∆l-structure

^henkin-construction
<!-- flash-end -->

<!-- flash-start -->
@Prove that every complete witnessing $\mathcal L$-theory $\Sigma$ has a model (∆henkin-model-existence).::

**(The Henkin construction)**. Let $T$ be the set of all closed $\mathcal L$-terms (i.e. terms containing no variables). Define an equivalence relation $E$ on $T$ by
$$
t _ 1 E t _ 2 \iff \Sigma \vdash (t _ 1 \doteq t _ 2)
$$
Note that this is an equivalence relation (it is symmetric, reflexive and transitive by considering axioms A6-A8; a more detailed justification is given at the end).

Let $T/E$ be the set of equivalence classes $t/E$ for each $t \in T$. Define an $\mathcal L$-structure $\mathcal M$ with domain $T/E$ by:

- $c^\mathcal M := c/E$
- $f^{\mathcal M}(t _ 1 / E, \ldots, t _ k / E) := f(t _ 1, \ldots, t _ k) / E$
- $P^\mathcal M := \lbrace (t _ 1 / E, \ldots, t _ k / E) \mid \Sigma \vdash P(t _ 1, \ldots, t _ k)\rbrace$

This is well-defined because the definitions do not depend on the choice of representatives (i.e. if $t _ i / E = t _ i' / E$, then $f(t _ 1, \ldots, t _ k) / E = f(t _ 1', \ldots, t' _ k)/E$, $\Sigma \vdash P(t _ 1, \ldots, t _ k) \iff \Sigma \vdash P(t' _ 1, \ldots, t' _ k)$, and $t^\mathcal M = t/E$ for any $t \in T$; this is non-trivial but follows from axioms A4, A8 and induction, a more detailed justification is given at the end).

We aim to show that $\mathcal M \models \Sigma$, i.e. $\mathcal M \models \sigma$ for all $\sigma \in \Sigma$.

---

**Claim**: For any $\sigma \in \mathrm{Sent}(\mathcal L)$
$$
\mathcal M \models \sigma \iff \Sigma \vdash \sigma
$$
(and hence in particular, since $\Sigma \vdash \sigma$ immediately when $\sigma \in \Sigma$, $\mathcal M \models \sigma$).

**Proof**: We prove this by induction on the number of symbols among $\lbrace \lnot, \to, \forall\rbrace$ in the sentence $\sigma$.

**Case $\sigma = P(t _ 1, \ldots, t _ k)$**:
$$
\begin{aligned}
\mathcal M \models \sigma &\iff (t _ 1^\mathcal M, \ldots, t _ k^\mathcal M) \in P^\mathcal M \\
&\iff (t _ 1 / E, \ldots, t _ k/E) \in P^\mathcal M \\
&\iff \Sigma \vdash \sigma
\end{aligned}
$$
with the middle equivalence following from the fact that the definitions do not depend on the choice of representative.

**Case $\sigma = t _ 1 \doteq t _ 2$**:
$$
\begin{aligned}
\mathcal M \models \sigma &\iff t _ 1^\mathcal M = t _ 2^\mathcal M \\
&\iff t _ 1 / E = t _ 2 / E \\
&\iff t _ 1 E t _ 2 \\
&\iff \Sigma \vdash \sigma
\end{aligned}
$$
**Case $\sigma = \lnot \tau$**:
$$
\begin{aligned}
\mathcal M \models \lnot \tau &\iff \mathcal M \not\models \tau  &&(\text{def. of} \models) \\
&\iff \Sigma \not\vdash \tau &&(\text{by inductive hyp.}) \\
&\iff \Sigma \vdash \lnot \tau &&(\Sigma \text{ complete})
\end{aligned}
$$

**Case $\sigma = (\tau \to \rho)$**:
$$
\begin{aligned}
\mathcal M \models (\tau \to \rho) &\iff \mathcal M \not\models \tau \text{ or } \mathcal M \models \rho &&(\text{def. of} \models) \\
&\iff \Sigma \not\vdash \tau \text{ or } \Sigma \vdash \rho &&\text{(by inductive hyp.)} \\
&\iff \text{not } (\Sigma \vdash \tau \text{ and } \Sigma \not\vdash \rho) &&\text{(De Morgan's)} \\
&\iff \text{not } (\Sigma \vdash \tau \text{ and }\Sigma \vdash \lnot \rho) &&(\Sigma \text{ complete}) \\
&\iff \Sigma \not\vdash \lnot (\tau \to \rho) &&\text{(tautology},\star) \\
&\iff \Sigma \vdash (\tau \to \rho) &&(\Sigma \text{ complete})
\end{aligned}
$$
where the penultimate line $(\star)$ uses the following tautologies:

- For the forward direction:
	- $(\tau \to (\lnot \rho \to \lnot (\tau \to \rho)))$ is a tautology. Then
	- $\text{not }(\Sigma \vdash \tau \text{ and } \Sigma \vdash \lnot \phi)$ implies
	- $\text{not }(\Sigma \vdash \lnot (\tau \to \rho))$ implies
	- $\Sigma \not\vdash (\tau \to \rho)$.
- For the backward direction:
	- $\lnot (\tau \to \rho) \to \tau$ is a tautology, and
	- $\lnot (\tau \to \rho) \to \lnot \rho$ is a tautology. Then
	- $\Sigma \not\vdash (\tau \to \rho)$ implies
	- $\text{not }(\Sigma \vdash \lnot (\tau \to \rho))$ implies
	- $\text{not }(\Sigma \vdash \tau \text{ and } \Sigma \vdash \lnot \rho)$.

**Case $\sigma = \forall x _ i \phi$**: 

$$
\begin{aligned}
\mathcal M \models \forall x _ i \phi &\iff \forall t/E \in T/E, \mathcal M \models _ {a _ {t/E} } \phi && (\text{where }a _ {t/E}(x _ i) = t/E) \\
&\iff \forall t \in T, \mathcal M \models _ {a _ {t/E} } \phi &&(\text{where }a _ {t/E}(x _ i) = t/E) \\
&\iff \forall t \in T, \mathcal M \models \phi [t/x _ i] &&(\text{sub. lemma}) \\
&\iff \forall t \in T, \Sigma \vdash \phi[t/x _ i] &&(\text{inductive hyp.}) \\
&\iff \Sigma \vdash \forall x _ i \phi &&(\ast)
\end{aligned}
$$

*For the backward direction* of $(\ast)$: Consider the proof

1. A4: $\forall x _ i \phi \to \phi[t/x _ i]$
2. MP: $\phi [t/x _ i]$ 

for arbitrary $t$.

*For the forward direction* of $(\ast)$, we show the contrapositive, i.e. that
$$
\Sigma \not\vdash \forall x _ i \phi \implies \exists t \in T \text{ s.t. } \Sigma \not\vdash \phi[t/x _ i]
$$
Since $\Sigma$ is complete and witnessing, we have
$$
\begin{aligned}
\Sigma \not\vdash \forall x _ i \phi &\implies \Sigma \not\vdash \forall x _ i \lnot \lnot \phi &&(\text{otherwise there is a short proof of the LHS}) \\
&\implies \Sigma \vdash \lnot \forall x _ i \lnot \lnot \phi &&(\text{completeness}) \\
&\implies \Sigma \vdash \exists x _ i \lnot \phi &&(\text{def. } \exists) \\
&\implies \Sigma \vdash \lnot \phi [c / x _ i] \text{ for some } c &&(\text{witnessing}) \\
&\implies \exists t \in T \text{ s.t. } \Sigma \not\vdash \phi[t/x _ i] &&(\text{just rephrasing})
\end{aligned}
$$

With this, we have shown $\mathcal M \models \sigma \iff \Sigma \vdash \sigma$, as required.

---

This covers all cases required for the induction, and hence the overall claim follows.

---

**Proof that $E$ is an equivalence relation, and that the definitions do not depend on the choice of representatives:**

*Symmetry*. This amounts to proving $\vdash (t_1 \doteq t_2 \to t_2 \doteq t_1)$:

1. **A7**: $(x_i \doteq x_j \to x_j \doteq x_i)$
2. **Gen1**: $\forall x_i (x_i \doteq x_j \to x_j \doteq x_i)$
3. **Gen2**: $\forall x_j \forall x_i (x_i \doteq x_j \to x_j \doteq x_i)$
4. **A4**: $\forall x_j \forall x_i (x_i \doteq x_j \to x_j \doteq x_i) \to \forall x_i (x_i \doteq t_2 \to t_2 \doteq x_i)$
5. **MP3,4**: $\forall x_i (x_i \doteq t_2 \to t_2 \doteq x_i)$
6. **A4**: $\forall x_i (x_i \doteq t_2 \to t_2 \doteq x_i) \to (t_1 \doteq t_2 \to t_2 \doteq t_1)$
7. **MP5,6**: $(t_1 \doteq t_2 \to t_2 \doteq t_1)$

Here the general idea is to use **Gen** and **A4** to show that the results which hold for variables hold for terms also.

*Transitivity*. This amounts to proving $\lbrace t_1 \doteq t_2, t_2 \doteq t_3 \rbrace \vdash t_1 \doteq t_3$. We first show $\lbrace x_1 \doteq x_2, x_2 \doteq x_3 \rbrace \vdash x_1 \doteq x_3$:

1. **A8**: $x_2 \doteq x_1 \to (x_2 \doteq x_3 \to x_1 \doteq x_3)$
2. **A7**: $x_1 \doteq x_2 \to x_2 \doteq x_1$
3. **Hyp**: $x_1 \doteq x_2$
4. **MP2,3**: $x_2 \doteq x_1$
5. **MP1,4**: $x_2 \doteq x_3 \to x_1 \doteq x_3$
6. **Hyp**: $x_2 \doteq x_3$
7. **MP5,6**: $x_1 \doteq x_3$

Then repeated applications of **Gen** and **A4** show the result for terms.

*Reflexivity*. This amounts to proving $\vdash (t \doteq t)$ for every closed term $t$. This follows similarly to showing symmetry.

*Does not depend on the choice of representatives (sketch)*: Suppose $t_i$, $t_i'$ are closed $\mathcal L$-terms such that $\Sigma \vdash t_i \doteq t_i'$. We want to show:

- $\Sigma \vdash P(t_1, \ldots, t_k) \iff \Sigma \vdash P(t_1', \ldots, t_k')$, and
- $\Sigma \vdash f(t_1, \ldots, t_k) \doteq f(t_1', \ldots, t_k')$, so that $f(t_1, \ldots, t_k)/E = f(t_1', \ldots, t_k')/E$.

Symmetry implies that it suffices to prove just one direction. Consider the versions of the results that just hold for equal variables, and then use **Gen**, **A4** and **A8**.

**Builds on**: ∆henkin-model-existence, ∆henkin-construction, ∆substitution-lemma

^henkin-model-existence-proof
<!-- flash-end -->

<!-- flash-start -->
The hard case in proving that the Henkin construction for a complete, witnessing theory yields a model (∆henkin-model-existence-proof) is showing that $\mathcal M \models \forall x _ i \phi$ iff $\Sigma \vdash \forall x _ i \phi$. The key step in this is concluding that
$$
\forall t \in T, \Sigma \vdash \phi[t/x _ i] \text{ iff } \Sigma \vdash \forall x _ i \phi \quad (\ast)
$$
@Prove this.

::

*For the backward direction* of $(\ast)$: Consider the proof

1. A4: $\forall x _ i \phi \to \phi[t/x _ i]$
2. MP: $\phi [t/x _ i]$ 

for arbitrary $t$.

*For the forward direction* of $(\ast)$, we show the contrapositive, i.e. that
$$
\Sigma \not\vdash \forall x _ i \phi \implies \exists t \in T \text{ s.t. } \Sigma \not\vdash \phi[t/x _ i]
$$
Since $\Sigma$ is complete and witnessing, we have
$$
\begin{aligned}
\Sigma \not\vdash \forall x _ i \phi &\implies \Sigma \not\vdash \forall x _ i \lnot \lnot \phi &&(\text{otherwise there is a short proof of the LHS}) \\
&\implies \Sigma \vdash \lnot \forall x _ i \lnot \lnot \phi &&(\text{completeness}) \\
&\implies \Sigma \vdash \exists x _ i \lnot \phi &&(\text{def. } \exists) \\
&\implies \Sigma \vdash \lnot \phi [c / x _ i] \text{ for some } c &&(\text{witnessing}) \\
&\implies \exists t \in T \text{ s.t. } \Sigma \not\vdash \phi[t/x _ i] &&(\text{just rephrasing})
\end{aligned}
$$

**Builds on**: ∆henkin-model-existence-proof, ∆maximally-consistent-theory, ∆witnessing-theory

^henkin-forall-case-proof
<!-- flash-end -->

<!-- flash-start -->
@Justify why the Henkin construction does not fail when the language under consideration has no closed terms.

(for example, in the language of linear orderings $\langle < \rangle$).

::

In the proof for the completeness theorem, you first show that if a theory is consistent, it remains consistent even when you add infinitely many constant symbols. So by working over the extended language, you avoid this problem.

**Builds on**: ∆henkin-construction, ∆added-constants-conservative

^henkin-no-closed-terms
<!-- flash-end -->

#### Putting it together
<!-- flash-start -->
@Prove that every consistent $\mathcal L$-theory is satisfiable, by appealing to other results.::

Suppose $\Sigma \subseteq \mathrm{Sent}(\mathcal L)$ is consistent in $K(\mathcal L)$.

By ∆added-constants-conservative, $\Sigma$ is also consistent in $K(\mathcal L')$, where $\mathcal L' = \mathcal L \cup \lbrace c _ 1, c _ 2, \ldots\rbrace$ for new constants $c _ i$. By ∆complete-witnessing-extension-proof, $\Sigma$ then extends to a complete witnessing $\mathcal L'$-theory $\Sigma^\ast \subseteq \mathrm{Sent}(\mathcal L')$, and by ∆henkin-model-existence, $\Sigma^\ast$ is satisfiable. Therefore there exists some $\mathcal L'$-structure $\mathcal M'$ such that $\mathcal M' \models \Sigma^\ast$, so in particular $\mathcal M' \models \Sigma$.

Let $\mathcal M$ be the $\mathcal L$-structure obtained from $\mathcal M'$ by forgetting the interpretations of the new constants. Then $\mathcal M \models \Sigma$ as required.

**Builds on**: ∆added-constants-conservative, ∆complete-witnessing-extension-proof, ∆henkin-model-existence

^model-existence-theorem-proof
<!-- flash-end -->

<!-- flash-start -->
@Prove Gödel's Completeness Theorem (∆godel-completeness-theorem), that if:

- $\mathcal L$ is a first-order language
- $\Sigma \subseteq \mathrm{Sent}(\mathcal L)$
- $\phi \in \mathrm{Form}(\mathcal L)$
- $\Sigma \models \phi$

then:

- $\Sigma \vdash \phi$

(do this by appealing to other results).::

If $\Sigma \models \phi$, then by the result that says $\Sigma \models \phi$ iff $\Sigma \cup \lbrace \lnot \phi\rbrace$ is unsatisfiable, it follows that $\Sigma \cup \lbrace \lnot \phi\rbrace$ is unsatisfiable. But every consistent $\mathcal L$-theory is satisfiable (∆model-existence-theorem-proof), so $\Sigma \cup \lbrace \lnot \phi\rbrace$ is inconsistent. But then by the result that says $\Sigma \vdash \phi$ iff $\Sigma \cup \lbrace \lnot \phi\rbrace$ is inconsistent, it follows that $\Sigma \vdash \phi$. Hence

$$
\Sigma \models \phi \implies \Sigma \vdash \phi
$$

(A lot of these results assume that $\phi$ is a sentence, but it suffices to consider this case only since if it contains free variables we can consider the sentence $\forall x _ 1 \cdots \forall x _ n \phi$. Then if $\Sigma \models \phi$, then also $\Sigma \models \forall x _ 1 \cdots \forall x _ n \phi$. But then by the result for sentences, $\Sigma \vdash \forall x _ 1 \cdots \forall x _ n \phi$ and then we can conclude $\Sigma \vdash \phi$ by **A4** and **MP**).

**Builds on**: ∆godel-completeness-theorem, ∆model-existence-theorem-proof, ∆provability-satisfiability-relationships

^godel-completeness-theorem-proof
<!-- flash-end -->

<!-- flash-start -->
Gödel's Completeness Theorem (∆godel-completeness-theorem) states that if:

- $\mathcal L$ is a first-order language
- $\Sigma \subseteq \mathrm{Sent}(\mathcal L)$
- $\phi \in \mathrm{Form}(\mathcal L)$
- $\Sigma \models \phi$

then:

- $\Sigma \vdash \phi$

Why does it suffice to only prove the case where $\phi$ is a sentence?::

If $\phi$ contains free variables we can consider the sentence $\forall^\ast \phi$.

Then if $\Sigma \models \phi$, then also $\Sigma \models \forall^\ast \phi$.

But then by Gödel's Completeness Theorem for sentences, $\Sigma \vdash \forall^\ast \phi$ and therefore we can conclude $\Sigma \vdash \phi$ by **A4** and **MP**. For reference, **A4** is $(\forall x _ i \alpha \to \alpha[t/x _ i])$, whenever $\alpha[t/x _ i]$ is defined.

**Builds on**: ∆godel-completeness-theorem, ∆sentence-definition

^completeness-sentence-reduction
<!-- flash-end -->

#### Misc
<!-- flash-start -->
You're asked to prove that $\Sigma \vdash \tau$ in a first-order language $\mathcal L$, but you are allowed to assume the completeness theorem. What might be easier instead?::

Showing that $\Sigma \models \tau$, which suffices by completeness.

**Builds on**: ∆godel-completeness-theorem

^use-completeness-for-proofs
<!-- flash-end -->

---
Olly Britton — https://ollybritton.com. Machine-readable index: https://ollybritton.com/llms.txt
