SLIDE 1
Proofs as Programs Revisited Ryota Akiyoshi Waseda Institute for - - PowerPoint PPT Presentation
Proofs as Programs Revisited Ryota Akiyoshi Waseda Institute for - - PowerPoint PPT Presentation
Proofs as Programs Revisited Ryota Akiyoshi Waseda Institute for Advanced Study Keio University July 27th., 2018 1 / 26 Aim of This Talk The aim is to revisit Schwichtenbergs works by focusing on parameter subsystems of
SLIDE 2
SLIDE 3
Proofs as Programs by Schwichtenberg
▶ Proofs are regarded as programs (Curry=Howard isomorphism) ▶ Schwichtenberg measured the complexity as programs of proofs in
arithmetic.
3 / 26
SLIDE 4
Proofs as Programs by Schwichtenberg
▶ Proofs are regarded as programs (Curry=Howard isomorphism) ▶ Schwichtenberg measured the complexity as programs of proofs in
arithmetic.
▶ Proofs as programs could contain such a “complicated” structures.
3 / 26
SLIDE 5
Proofs as Programs by Schwichtenberg
▶ Proofs are regarded as programs (Curry=Howard isomorphism) ▶ Schwichtenberg measured the complexity as programs of proofs in
arithmetic.
▶ Proofs as programs could contain such a “complicated” structures.
Theorem (Schwichtenberg90)
Let r be a closed term of type N → N in arithmetic. Then, there is m such that all n ≥ m |rn| ≤ GD0Dm+2
1
0(n).
(D0,D1 are the collapsing functions, and G is a slow growing hierarchy.)
3 / 26
SLIDE 6
Proofs as Programs by Schwichtenberg
▶ Proofs as programs could contain such a complicated structures.
|rn| ≤ GD0Dm+2
1
0(n).
4 / 26
SLIDE 7
Proofs as Programs by Schwichtenberg
▶ Proofs as programs could contain such a complicated structures.
|rn| ≤ GD0Dm+2
1
0(n).
▶ Strategy for getting this result:
- 1. Normalize a given term rn and measure the size of it. (We need
D0Dm+2
1
0(n) here. )
- 2. To climb down the “big” tree ordinal by the slow growing
hierarchy using ideas by Wainer-Girard and Arai.
4 / 26
SLIDE 8
Proofs as Programs by Schwichtenberg
▶ Proofs as programs could contain such a complicated structures.
|rn| ≤ GD0Dm+2
1
0(n).
▶ Strategy for getting this result:
- 1. Normalize a given term rn and measure the size of it. (We need
D0Dm+2
1
0(n) here. )
- 2. To climb down the “big” tree ordinal by the slow growing
hierarchy using ideas by Wainer-Girard and Arai.
▶ The bound is sharp. A specific program of ∀x∃yA(x,y) has such a
complexity.
▶ These arguments are implemented in Scheme.
4 / 26
SLIDE 9
Some Literatures
▶ Arai, A slow growing analogue to Buchholz’ proof, 1991. ▶ Buchholz, An independence result for Π1
1-CA+BI, 1987.
▶ Girard, Proof Theory and Logical Complexity, Vol 1, 1987.
(Volume 2 is available: http://girard.perso.math.cnrs.fr/Archives4.html)
▶ Schwichtenberg, Proofs as Programs, 1990. ▶ Schwichtenberg and Wainer, Ordinal Bounds for Programs, 1994.
5 / 26
SLIDE 10
Goal of This Talk
▶ The aim: to revisit S’s works by focusing on parameter subsystems of
Girard’s F.
6 / 26
SLIDE 11
Goal of This Talk
▶ The aim: to revisit S’s works by focusing on parameter subsystems of
Girard’s F.
▶ Two advantages of our approach:
- 1. Our approach is simpler, smoother.
▶ The syntax of F is very simple.
- 2. This talk is about the weakest theory dealing with the type N:
N : ∀α.((α ⇒ α) ⇒ α ⇒ α)
6 / 26
SLIDE 12
Goal of This Talk
▶ The aim: to revisit S’s works by focusing on parameter subsystems of
Girard’s F.
▶ Two advantages of our approach:
- 1. Our approach is simpler, smoother.
▶ The syntax of F is very simple.
- 2. This talk is about the weakest theory dealing with the type N:
N : ∀α.((α ⇒ α) ⇒ α ⇒ α)
- 3. It is possible to extend our result into stronger theories of
inductive definitions, uniformly.
▶ Typical example of the next level is Brouwer’s ordinals:
O : ∀α.((N ⇒ α) ⇒ α) ⇒ (α ⇒ α) ⇒ (α ⇒ α)
▶ This is more direct, too.
▶ Terms in F can be regarded as programs. 6 / 26
SLIDE 13
Another Motivation
▶ Another motivation:
▶ to connect a traditional method called the Ω-rule in proof-theory
with the context of the lambda calculus.
7 / 26
SLIDE 14
Another Motivation
▶ Another motivation:
▶ to connect a traditional method called the Ω-rule in proof-theory
with the context of the lambda calculus.
▶ Examples of this direction:
▶ Terui, “MacNeille completion and Buchholz’ Omega rule for
parameter-free second order logics”, CSL, 2018.
▶ Akiyoshi and Terui, “Strong normalization for the parameter-free
polymorphic lambda calculus based on the Omega-rule”, FSCD, 2016.
▶ Maybe, we could apply this method to another type theories, but I
don’t know...
7 / 26
SLIDE 15
Some Literatures
▶ Akiyoshi, “The Upperbound of the Length of the Reductions in a
Subsystem of Girard’s F”, preprint, 2018.
▶ Akiyoshi, ““Proofs as Programs” in Parameter-Free Fragments of
System F”, submitted, 2018.
▶ Akiyoshi, “A Formalization of Brouwer’s Argument for Bar
Induction”, WoLLIC, 2018.
▶ Terui, “MacNeille completion and Buchholz’ Omega rule for
parameter-free second order logics”, CSL, 2018.
▶ Akiyoshi, “An Ordinal-Free Proof of the Complete Cut-Elimination
Theorem for Π1
1-CA + BI with the ω-rule”, The Mints’ memorial issue
- f the IfCoLog Journal of Logics and their Applications, 2017.
▶ Akiyoshi and Terui, “Strong Normalization for the Parameter-Free
Polymorphic Lambda Calculus Based on the Ω-Rule”, FSCD 2016.
▶ Akiyoshi and Mints, “An Extension of the Omega-Rule”, AML, 2016.
8 / 26
SLIDE 16
Definition of Syntax Definition
The types are defined by: A,B ::= α | A ⇒ B | ∀α.A where ∀α.A is closed and A is ∀-free. Types in this set are “parameter-free”.
Definition
Terms are defined as follows: xA (λxA.MB)A⇒B (MA⇒BNA)B (Λα.MA)∀α.A (M∀α.AB)A[α/B] with the standard proviso.
9 / 26
SLIDE 17
Examples
Examples of types in this language: N := ∀α.(α ⇒ α) ⇒ (α ⇒ α) (natural numbers) T := ∀α.(α ⇒ α ⇒ α) ⇒ (α ⇒ α) (binary trees)
Remark
Girard’s maxim: Peano Arithmetic is (best viewed as) a theory of one inductive definition.
10 / 26
SLIDE 18
Examples
Examples of types in this language: N := ∀α.(α ⇒ α) ⇒ (α ⇒ α) (natural numbers) T := ∀α.(α ⇒ α ⇒ α) ⇒ (α ⇒ α) (binary trees)
Remark
Girard’s maxim: Peano Arithmetic is (best viewed as) a theory of one inductive definition. But, we cannot express the following: L(N) := ∀α.(N ⇒ α ⇒ α) ⇒ (α ⇒ α) (lists over N) O := ∀α.((N ⇒ α) ⇒ α) ⇒ (α ⇒ α) ⇒ (α ⇒ α) (Brouwer ordinals)
Remark
This kind of restriction originally goes back to Gaisi Takeuti’s works in 1950’s. Cf. his “On the fundamental conjecture of GLC I-VI”.
10 / 26
SLIDE 19
Tree Ordinals Definition (Buchholz87)
The tree classes Tσ (σ ≤ 2) are defined as follows:
▶ If α : I → Tσ is a function with I : /
0,{0}, or Tρ for some ρ < σ, then α ∈ Tσ. Some notations.
- 1. 0 for α : /
0 → Tσ,
- 2. β + for α : {0} → Tσ with α(0) = β.
11 / 26
SLIDE 20
Tree Ordinals Definition (Buchholz87)
The tree classes Tσ (σ ≤ 2) are defined as follows:
▶ If α : I → Tσ is a function with I : /
0,{0}, or Tρ for some ρ < σ, then α ∈ Tσ. Some notations.
- 1. 0 for α : /
0 → Tσ,
- 2. β + for α : {0} → Tσ with α(0) = β.
Remark
- 1. T0 is identified with N (the set of natural numbers) ,
- 2. T1 is the set of countable trees.
The operations of addition, multiplication, and exponentiation of trees are defined in the standard way. For example, (α +β)+γ = α +(β +γ),(α ×β)×γ = α ×(β ×γ),etc...
11 / 26
SLIDE 21
Collapsing Functions on Tree Ordinals
Let Ω0 := N, Ω1 := the set of countable tree ordinals.
Definition (Buchholz87, Arai91)
The collapsing functions Dσ : Tv → Tσ+1 for σ < v ≤ 2 are defined as follows:
- 1. Dσ0 := Ωσ,
- 2. Dσ(α +1) := (Dσ(α)×(n+1))n∈ω,
- 3. If ρ ≤ σ, then Dσ((αξ)ξ∈Tρ) := (Dσαξ)ξ∈Tρ,
- 4. If σ < µ +1, then Dσ((αξ)ξ∈Tµ+1) := (Dσαξn)n∈ω where
ξ0 := Ωµ,ξn+1 := Dµαξn.
12 / 26
SLIDE 22
Collapsing Functions on Tree Ordinals
Let Ω0 := N, Ω1 := the set of countable tree ordinals.
Definition (Buchholz87, Arai91)
The collapsing functions Dσ : Tv → Tσ+1 for σ < v ≤ 2 are defined as follows:
- 1. Dσ0 := Ωσ,
- 2. Dσ(α +1) := (Dσ(α)×(n+1))n∈ω,
- 3. If ρ ≤ σ, then Dσ((αξ)ξ∈Tρ) := (Dσαξ)ξ∈Tρ,
- 4. If σ < µ +1, then Dσ((αξ)ξ∈Tµ+1) := (Dσαξn)n∈ω where
ξ0 := Ωµ,ξn+1 := Dµαξn.
Remark
- 1. In the last clause, the point is that the indexes ξn are tree ordinals.
- 2. D00 = ω, D01 = ω2,D0ω = ωω,
12 / 26
SLIDE 23
Collapsing Functions on Tree Ordinals
Let Ω0 := N, Ω1 := the set of countable tree ordinals.
Definition (Buchholz87, Arai91)
The collapsing functions Dσ : Tv → Tσ+1 for σ < v ≤ 2 are defined as follows:
- 1. Dσ0 := Ωσ,
- 2. Dσ(α +1) := (Dσ(α)×(n+1))n∈ω,
- 3. If ρ ≤ σ, then Dσ((αξ)ξ∈Tρ) := (Dσαξ)ξ∈Tρ,
- 4. If σ < µ +1, then Dσ((αξ)ξ∈Tµ+1) := (Dσαξn)n∈ω where
ξ0 := Ωµ,ξn+1 := Dµαξn.
Remark
- 1. In the last clause, the point is that the indexes ξn are tree ordinals.
- 2. D00 = ω, D01 = ω2,D0ω = ωω, ...,D0Ω1 = ε0.
12 / 26
SLIDE 24
Collapsing Functions on Tree Ordinals
Let Ω0 := N, Ω1 := the set of countable tree ordinals.
Definition (Buchholz87, Arai91)
The collapsing functions Dσ : Tv → Tσ+1 for σ < v ≤ 2 are defined as follows:
- 1. Dσ0 := Ωσ,
- 2. Dσ(α +1) := (Dσ(α)×(n+1))n∈ω,
- 3. If ρ ≤ σ, then Dσ((αξ)ξ∈Tρ) := (Dσαξ)ξ∈Tρ,
- 4. If σ < µ +1, then Dσ((αξ)ξ∈Tµ+1) := (Dσαξn)n∈ω where
ξ0 := Ωµ,ξn+1 := Dµαξn.
Remark
- 1. In the last clause, the point is that the indexes ξn are tree ordinals.
- 2. D00 = ω, D01 = ω2,D0ω = ωω, ...,D0Ω1 = ε0.
- 3. In this talk, we identify ordinals with its notations.
12 / 26
SLIDE 25
The Relation |=a M : A
▶ |=a M : A means “a term M has the size or complexity α”.
Definition
The relation |=a M : A for a ∈ T is defined inductively as follows: (Var) If |=a Ni : Bi for i = 1,...,m with 0 ≤ m, then |=a+1 x⃗ N : A, (<1) If |=b M : A and b <1 a, then |=a M : A, (abs) If |=a N : C, then |=a+1 λx.N : B → C, (Abs) If |=a N : B, then |=a+1 λα.N : ∀α.B.
Remark
▶ Idea is to define the “logical” domain over which we can quantify. ▶ In this definition, α could be just a natural number.
13 / 26
SLIDE 26
The Relation ⊢a
m M : A
Definition
The relation ⊢a
m M : A for a ∈ T and m < ω is defined by adding the
following to |=a: (ω+) If the following conditions are satisfied
- i. tp(a) = Ω1, ⊢a−
m N : ∀α.B,
- ii. ∀z ∈ T1∀K ∈ Π1
- 1. |=z K : B(α) implies ⊢a[z]
m Hz : A,
then ⊢a
m ND : A,
(Cut) If ⊢a
m N with lev(N) ≤ m and and there is a sequence of terms⃗
L such that ⊢a
m Li for i = 1,...,n, then ⊢a+1 m
N⃗ L.
Remark
▶ Hz in the formulation of (ω+) could depend on z. ▶ a is a limit of a[0],a[1],..., hence could be infinite.
14 / 26
SLIDE 27
Intuition of the ω+-Rule
▶ Picture of the ω+-rule:
. . . . ∀α.B ... [K : B(α)] B[α/D] S... ∀α.B ⇒ B[α/D] B[α/D] ω+
15 / 26
SLIDE 28
Intuition of the ω+-Rule
▶ Picture of the ω+-rule:
. . . . ∀α.B ... [K : B(α)] B[α/D] S... ∀α.B ⇒ B[α/D] B[α/D] ω+
▶ The right deduction is based on BHK-reading of ⇒:
∀α.B ⇒ B[α/D]
15 / 26
SLIDE 29
Intuition of the ω+-Rule
▶ Picture of the ω+-rule:
. . . . ∀α.B ... [K : B(α)] B[α/D] S... ∀α.B ⇒ B[α/D] B[α/D] ω+
▶ The right deduction is based on BHK-reading of ⇒:
∀α.B ⇒ B[α/D]
▶ We can derive Comprehension using this:
[∀α.B]1 ... [K : B(α)] B[α/D] S... ∀α.B ⇒ B[α/D] B[α/D] ω+ ∀α.B ⇒ B[α/D] → I,1
15 / 26
SLIDE 30
Intuition of the ω+-Rule
▶ We can compare the picture with the definition:
. . . . ∀α.B ... [K : B(α)] B[α/D] S... ∀α.B ⇒ B[α/D] B[α/D] ω+ (ω+) If the following conditions are satisfied
- i. tp(a) = Ω1, ⊢a−
m N : ∀α.B,
- ii. ∀z ∈ T1∀K ∈ Π1
- 1. |=z K : B(α) implies ⊢a[z]
m Hz : B[α/D],
then ⊢a
m ND : B[α/D].
16 / 26
SLIDE 31
Predicative Normalization
The following corresponds to predicative c.e. in infinitary proof-theory.
Lemma
There is an operation D1 on terms such that If ⊢α
m+1 M : A, then ⊢D1a m
D1(M) : A.
- Proof. The argument is more or less the same as the standard one. □
17 / 26
SLIDE 32
Idea of Impredicative Normalization
. . . . B ∀α.B ... [K : B(α)] B[α/D] S... ∀α.B ⇒ B[α/D] B[α/D] ω+
▶ Impredicative Normalization (Collapsing): Elimination of ω+
impredicaticve normalization = taking a subtree
18 / 26
SLIDE 33
Idea of Impredicative Normalization
. . . . B ∀α.B ... [K : B(α)] B[α/D] S... ∀α.B ⇒ B[α/D] B[α/D] ω+
▶ Impredicative Normalization (Collapsing): Elimination of ω+
impredicaticve normalization = taking a subtree
▶ Strategy of normalization by induction on a given derivation:
- 1. Normalize the proof of B. Let d be the result.
18 / 26
SLIDE 34
Idea of Impredicative Normalization
. . . . B ∀α.B ... [K : B(α)] B[α/D] S... ∀α.B ⇒ B[α/D] B[α/D] ω+
▶ Impredicative Normalization (Collapsing): Elimination of ω+
impredicaticve normalization = taking a subtree
▶ Strategy of normalization by induction on a given derivation:
- 1. Normalize the proof of B. Let d be the result.
- 2. Take the subproof of ω+ indexed by d, say hd.
18 / 26
SLIDE 35
Idea of Impredicative Normalization
. . . . B ∀α.B ... [K : B(α)] B[α/D] S... ∀α.B ⇒ B[α/D] B[α/D] ω+
▶ Impredicative Normalization (Collapsing): Elimination of ω+
impredicaticve normalization = taking a subtree
▶ Strategy of normalization by induction on a given derivation:
- 1. Normalize the proof of B. Let d be the result.
- 2. Take the subproof of ω+ indexed by d, say hd.
- 3. (If necessary) normalize hd.
18 / 26
SLIDE 36
Idea of Impredicative Normalization
. . . . B ∀α.B ... [K : B(α)] B[α/D] S... ∀α.B ⇒ B[α/D] B[α/D] ω+
▶ Impredicative Normalization (Collapsing): Elimination of ω+
impredicaticve normalization = taking a subtree
▶ Strategy of normalization by induction on a given derivation:
- 1. Normalize the proof of B. Let d be the result.
- 2. Take the subproof of ω+ indexed by d, say hd.
- 3. (If necessary) normalize hd.
▶ The following is the result:
. . . . hd B(α) B[α/D] S
18 / 26
SLIDE 37
Impredicative Normalization Lemma
There is an operation D0 on terms such that if ⊢a
0 M : A with A ∈ Π1 1, then
|=D0a D0(M) : A.
19 / 26
SLIDE 38
Embedding Theorem Theorem
Let M be a term such that all subterms of it have levels ≤ m. Also, let⃗ y be any sequence of variables such that M ⃗ y is well-typed. Then, there exists k such that ⊢Ω1×k
m
M ⃗ y.
Corollary
If M : A and⃗ y is any sequence of variables such that A is Π1
1 and M
⃗ y is well-typed, then |=D0Dm
1 Ω×n D0Dm
1 (M
⃗ y) : C for some n,C.
20 / 26
SLIDE 39
Slow Growing Hierarchy on Ordinals
Next, we introduce the slow growing hierarchy by which we climb down the set of countable trees (T1).
Definition
Ga : N → N for a ∈ T1 is defined by induction on a:
- 1. G0(n) := 0,
- 2. Ga+1(n) := Ga(n)+1,
- 3. Ga(n) := Ga[n](n) if tp(a) := ω. (when a is limit)
Note that ω[n] = n holds (by the definition).
21 / 26
SLIDE 40
Slow Growing Hierarchy on Ordinals
Next, we introduce the slow growing hierarchy by which we climb down the set of countable trees (T1).
Definition
Ga : N → N for a ∈ T1 is defined by induction on a:
- 1. G0(n) := 0,
- 2. Ga+1(n) := Ga(n)+1,
- 3. Ga(n) := Ga[n](n) if tp(a) := ω. (when a is limit)
Note that ω[n] = n holds (by the definition).
Remark
It holds that Ga+b(n) = Ga(n)+Gb(n). Gk(n) = k,
21 / 26
SLIDE 41
Slow Growing Hierarchy on Ordinals
Next, we introduce the slow growing hierarchy by which we climb down the set of countable trees (T1).
Definition
Ga : N → N for a ∈ T1 is defined by induction on a:
- 1. G0(n) := 0,
- 2. Ga+1(n) := Ga(n)+1,
- 3. Ga(n) := Ga[n](n) if tp(a) := ω. (when a is limit)
Note that ω[n] = n holds (by the definition).
Remark
It holds that Ga+b(n) = Ga(n)+Gb(n). Gk(n) = k, Gω(n) = Gω[n](n) = Gn(n) = n,
21 / 26
SLIDE 42
Slow Growing Hierarchy on Ordinals
Next, we introduce the slow growing hierarchy by which we climb down the set of countable trees (T1).
Definition
Ga : N → N for a ∈ T1 is defined by induction on a:
- 1. G0(n) := 0,
- 2. Ga+1(n) := Ga(n)+1,
- 3. Ga(n) := Ga[n](n) if tp(a) := ω. (when a is limit)
Note that ω[n] = n holds (by the definition).
Remark
It holds that Ga+b(n) = Ga(n)+Gb(n). Gk(n) = k, Gω(n) = Gω[n](n) = Gn(n) = n, GD01(n) = Gω×(n+1)(n) = Gω(n)×(n+1) = n×(n+1).
21 / 26
SLIDE 43
Climbing Down Tree Ordinals
Recall that Ga(4) is a natural number even if a ∈ T1 is infinite.
Lemma
If ⊢a
0 Sm0 with 4 ≤ a ∈ T1, then Sm0 < Ga(4).
22 / 26
SLIDE 44
The Upper Bound Theorem Definition
A function f : N → N is representable in our system if there is a term M : N ⇒ N such that M(Sn0) →∗
β Sk0 iff f(n) = k, where Sk0 is the
Church numeral corresponding to k.
Theorem
Let f be a representable function in our system with M : N ⇒ N. Then, |=D0(d×(n+1)) D0Dm
1 (MSn) : N with d = Dm 1 (Ω×m) for some m. Therefore,
there is m such that for all n ≥ m |D0Dm
1 (MSn)| < GD0Dm+2
1
0(n).
23 / 26
SLIDE 45
Lower Bound Theorem Theorem (Schwichtenberg90)
For any m, we can formally prove in arithmetic: ∀x∃y(D0Dm
1 0)[x]y = 0.
Theorem (Aehlig05, 08)
- 1. The following are equivalent:
1.1 IDc
0 ⊢ ∀x∃yR(x,y),
1.2 HA2
1 ⊢ ∀x.N → ¬∀y(Ny → ¬R(x,y)).
- 2. If HA2
1 ⊢ ∀x.N → ¬∀y(Ny → ¬R(x,y)), then there is a term in our
system computing this function on Church numerals, that is, for every n the term tcn reduced to a Church numeral cl and R(n,l) holds.
Theorem
The function expressed by ∀x∃y(D0Dm
1 0)[x]y = 0 is representable in our
system.
24 / 26
SLIDE 46
Summary
▶ As expected, the complexity of a term of type N ⇒ N is bounded:
|D0Dm
1 (MSn)| < GD0Dm+2
1
0(n).
▶ We can iterate our approach to handle with Brouwer’s ordinals (and
more...) O : ∀α.((N ⇒ α) ⇒ α) ⇒ (α ⇒ α) ⇒ (α ⇒ α)
▶ If we formalized tree ordinals and the slow growing hierarchy, then we
could see the bound in a visible way by considering concrete examples.
▶ We computed the upperbound of the length of β-reductions in our
system, too.
25 / 26
SLIDE 47