Gödel's Second Incompleteness Theorem

Recall that inside we can do basic set theory and primitive recursion. Many inductive notions and functions on them are defined in or using the fixpoint construction.

We work inside an arbitrary model of .

Coding of Terms and Formulae

Term

Define as follows.

is a quasi-quotation.

is (if is a finite set) and monotone. Let be a fixpoint of . It is since satisfies strong finiteness. Define the function inductively on meaning the largest bounded variable that appears in the term. Define .

Formula

Similarly, Define :

is and monotone. Let be a fixpoint of and define

The function is defined inductively on meaning the largest bounded variable that appears in the formula.

and are again since satisfies strong finiteness.

Formalized Provability

Let be -definable theory. Define :

is a shift of a formula . is a image of shift of . Take fixpoint .

Following holds for all formula (not coded one) and finite set .

  • Sound:
    lemma LO.Arith.Language.Theory.Provable.sound :
        (T.codeIn ℕ).Provable ⌜p⌝ → T ⊢! p 
    
  • D1:
    theorem LO.Arith.provable_of_provable :
        T ⊢! p → (T.codeIn V).Provable ⌜p⌝ 
    
  • D2:
  • Formalized -completeness: Let be a -sentence.
    theorem LO.Arith.sigma₁_complete (hσ : Hierarchy 𝚺 1 σ) :
        V ⊧ₘ₀ σ → T.Provableₐ (⌜σ⌝ : V)
    

Now assume that is a theory of arithmetic stronger than and be a theory of arithmetic stronger than . The following holds, thanks to the completeness theorem.

Second Incompleteness Theorem

Assume that is -definable and stronger than .

Fixpoint Lemma

Since the substitution is , There is a formula such that, for all formula with only one variable and ,

holds. (overline denotes the (formalized) numeral of )

Define a sentence for formula (with one variable) as follows.

Lemma:

  • Proof.
theorem LO.FirstOrder.Arith.diagonal (θ : Semisentence ℒₒᵣ 1) :
    T ⊢!. fixpoint θ ⭤ θ/[⌜fixpoint θ⌝]

Main Theorem

Define Gödel sentence :

Lemma: Gödel sentence is undecidable, i.e., if is consistent, and if .

lemma goedel_unprovable
    (T : Theory ℒₒᵣ) [𝐈𝚺₁ ≼ T] [T.Delta1Definable] [System.Consistent T] :
    T ⊬ ↑𝗚

lemma not_goedel_unprovable
    (T : Theory ℒₒᵣ) [𝐈𝚺₁ ≼ T] [T.Delta1Definable] [ℕ ⊧ₘ* T] :
    T ⊬ ∼↑𝗚

Define formalized incompleteness sentence :

Lemma:

lemma consistent_iff_goedel
    (T : Theory ℒₒᵣ) [𝐈𝚺₁ ≼ T] [T.Delta1Definable] :
    T ⊢! ↑𝗖𝗼𝗻 ⭤ ↑𝗚

Theorem: cannot prove its own consistency, i.e., if is consistent. Moreover, is undecidable from if .

theorem goedel_second_incompleteness
    (T : Theory ℒₒᵣ) [𝐈𝚺₁ ≼ T] [T.Delta1Definable] [System.Consistent T] :
    T ⊬ ↑𝗖𝗼𝗻 

theorem inconsistent_undecidable
    (T : Theory ℒₒᵣ) [𝐈𝚺₁ ≼ T] [T.Delta1Definable] [ℕ ⊧ₘ* T] :
    System.Undecidable T ↑𝗖𝗼𝗻