A Materialist Dialectica Pierre-Marie Pdrot 17th September 2015 A - - PowerPoint PPT Presentation

a materialist dialectica
SMART_READER_LITE
LIVE PREVIEW

A Materialist Dialectica Pierre-Marie Pdrot 17th September 2015 A - - PowerPoint PPT Presentation

. . . . . . . . . . . . . . . . A Materialist Dialectica Pierre-Marie Pdrot 17th September 2015 A Materialist Dialectica 17/09/2015 . . . . . . . . . . . . . . . . . . . . . . . . 1 / 44 PPS/ r 2


slide-1
SLIDE 1

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

A Materialist Dialectica

Pierre-Marie Pédrot

PPS/πr2

17th September 2015

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 1 / 44

slide-2
SLIDE 2

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Part I.

« How Gödel became a computer scientist out of remorse »

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 2 / 44

slide-3
SLIDE 3

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Logic? « The LOGICIST approach »

From Axioms, applying valid Rules, derive a Conclusion.

Socrates is a man. All men are mortal. Thus Socrates is mortal. All cats are mortal. Socrates is mortal. Thus Socrates is a cat. A B B C A C

As long as rules are correct, you should be safe. Special emphasis on ensuring that they are indeed correct.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 3 / 44

slide-4
SLIDE 4

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Logic? « The LOGICIST approach »

From Axioms, applying valid Rules, derive a Conclusion.

Socrates is a man. All men are mortal. Thus Socrates is mortal. All cats are mortal. Socrates is mortal. Thus Socrates is a cat. ⊢ A → B ⊢ B → C ⊢ A → C

As long as rules are correct, you should be safe. Special emphasis on ensuring that they are indeed correct.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 3 / 44

slide-5
SLIDE 5

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Logic? « The LOGICIST approach »

From Axioms, applying valid Rules, derive a Conclusion.

Socrates is a man. All men are mortal. Thus Socrates is mortal. All cats are mortal. Socrates is mortal. Thus Socrates is a cat. ⊢ A → B ⊢ B → C ⊢ A → C

As long as rules are correct, you should be safe. Special emphasis on ensuring that they are indeed correct.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 3 / 44

slide-6
SLIDE 6

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Logic: a long tradition of failure

  • 3XX. Aristotle predicts 50 years too late that Socrates had to die.

Socrates is a man, all men are mortal, thus Socrates is mortal.

  • 1641. Descartes proves that God and unicorns exist.

God is perfect, perfection implies existence, thus God exists.

  • 1901. Russell shows that there is no set of all sets.

No one shall expel us from the Paradise that Cantor has created.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 4 / 44

slide-7
SLIDE 7

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Logic: a long tradition of failure

  • 3XX. Aristotle predicts 50 years too late that Socrates had to die.

Socrates is a man, all men are mortal, thus Socrates is mortal.

  • 1641. Descartes proves that God and unicorns exist.

God is perfect, perfection implies existence, thus God exists.

  • 1901. Russell shows that there is no set of all sets.

No one shall expel us from the Paradise that Cantor has created.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 4 / 44

slide-8
SLIDE 8

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Logic: a long tradition of failure

  • 3XX. Aristotle predicts 50 years too late that Socrates had to die.

Socrates is a man, all men are mortal, thus Socrates is mortal.

  • 1641. Descartes proves that God and unicorns exist.

God is perfect, perfection implies existence, thus God exists.

  • 1901. Russell shows that there is no set of all sets.

No one shall expel us from the Paradise that Cantor has created.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 4 / 44

slide-9
SLIDE 9

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Logic: Fall of Logicism

1931: Gödel’s incompleteness theorem

Assume a set of rules S which is

1 Expressive enough 2 Consistent 3 Mechanically checkable

then

1 There is a sentence which is neither provable nor disprovable in 2 The consistency of

is neither provable nor disprovable in

Quis ipsos custodiet custodes?

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 5 / 44

slide-10
SLIDE 10

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Logic: Fall of Logicism

1931: Gödel’s incompleteness theorem

Assume a set of rules S which is

1 Expressive enough 2 Consistent 3 Mechanically checkable

then

1 There is a sentence which is neither provable nor disprovable in S 2 The consistency of S is neither provable nor disprovable in S

Quis ipsos custodiet custodes?

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 5 / 44

slide-11
SLIDE 11

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Logic: Fall of Logicism

1931: Gödel’s incompleteness theorem

Assume a set of rules S which is

1 Expressive enough 2 Consistent 3 Mechanically checkable

then

1 There is a sentence which is neither provable nor disprovable in S 2 The consistency of S is neither provable nor disprovable in S

Quis ipsos custodiet custodes?

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 5 / 44

slide-12
SLIDE 12

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Logic: Rise of Computer Science I

« Rather than trusting rules, let us trust experiments. » You need constructive logic

From a proof of ∃x. A[x] be able to recover a witness t and a proof of A[t].

Suspicious principles

A ∨ ¬A ¬¬A → A ((A → B) → A) → A Excluded Middle Reductio ad Absurdum Peirce’s Law

From 1931, Gödel tried to atone for his incompleteness theorem Constructivizing non-constructive principles

1

Double-negation translation (1933)

2

Dialectica (’30s, published in 1958)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 6 / 44

slide-13
SLIDE 13

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Logic: Rise of Computer Science II

Gödel focussed on intuitionistic logic.

The mathematician A constructive logic Advocated by Brouwer for philosophical reasons (1920’s) Without the aforementioned suspicious axioms The computer scientist Proofs are dynamic objects rather than static applications of rules (Gentzen ’33, Prawitz ’65) Witness extraction algorithmically recoverable From a proof one can extract a program (Kleene ’49)

Curry-Howard isomorphism (1960’s) Intuitionistic proofs are

  • calculus programs

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 7 / 44

slide-14
SLIDE 14

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Logic: Rise of Computer Science II

Gödel focussed on intuitionistic logic.

The mathematician A constructive logic Advocated by Brouwer for philosophical reasons (1920’s) Without the aforementioned suspicious axioms The computer scientist Proofs are dynamic objects rather than static applications of rules (Gentzen ’33, Prawitz ’65) Witness extraction algorithmically recoverable From a proof one can extract a program (Kleene ’49)

Curry-Howard isomorphism (1960’s) Intuitionistic proofs are λ-calculus programs

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 7 / 44

slide-15
SLIDE 15

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

The beloved λ-calculus

The niftiest programming language of them all! Terms t ::= x | λx. t | t u | . . . Types A ::= α | A → B | . . . (x : A) ∈ Γ Γ ⊢ x : A Γ, x : A ⊢ B Γ ⊢ λx. t : A → B Γ ⊢ t : A → B Γ ⊢ u : A Γ ⊢ t u : B (λx. t) u →β t[x := u] Type derivations are proofs, compatible with β-reduction: If Γ ⊢ t : A and t →β r then Γ ⊢ r : A.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 8 / 44

slide-16
SLIDE 16

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Which logic for which programs?

Standard members of each community will complain.

The mathematician “This logic is crappy, it does not feature the following principles I am acquainted with.” Either A or not A hold. Every bounded monotone sequence has a limit. Two sets with same elements are equal. Every formula is equivalent to its prenex form. … The computer scientist “This language is crappy, it does not feature the following structures I am ac- quainted with.” printf("Hello world") x <- 42 while true { … } goto #considered_harmful fork() …

INTUITIONISTIC LOGIC FUNCTIONAL LANGUAGE

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 9 / 44

slide-17
SLIDE 17

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Which logic for which programs?

Standard members of each community will complain.

The mathematician “This logic is crappy, it does not feature the following principles I am acquainted with.” Either A or not A hold. Every bounded monotone sequence has a limit. Two sets with same elements are equal. Every formula is equivalent to its prenex form. … The computer scientist “This language is crappy, it does not feature the following structures I am ac- quainted with.” printf("Hello world") x <- 42 while true { … } goto #considered_harmful fork() …

INTUITIONISTIC LOGIC FUNCTIONAL LANGUAGE

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 9 / 44

slide-18
SLIDE 18

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

A new hope

What Curry-Howard takes, it gives back. New axioms Programming primitives Logical encoding Program translation

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 10 / 44

slide-19
SLIDE 19

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

A new hope

What Curry-Howard takes, it gives back. New axioms ∼ Programming primitives ⇕ ⇕ Logical encoding ∼ Program translation

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 10 / 44

slide-20
SLIDE 20

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

The prototypical example: Classical logic

We can implement classical logic through this scheme.

New axiom ((A → B) → A) → A

Used by your next-door mathematician

∼ Programming primitives callcc

From Scheme, though a bit arcane

⇕ ⇕ Logical encoding double-negation translation

Gödel already did that by the 30’s

∼ Program translation continuation-passing style

The dullest JS programmer uses this Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 11 / 44

slide-21
SLIDE 21

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Classical logic as a logical translation

Gödel-like presentation

Translation from classical logic into intuitionistic logic. A, B ::= α | A → B | A × B | ⊥ A+ ≡ A− → ⊥ α− ≡ α → ⊥ (A → B)− ≡ A+ × B− . . . x x x t x t t u t u

1 If ⊢

t A then ⊢ t A+.

2 There is a proof of ⊢ (((A → B) → A) → A)+. 3 If t

u then t u . (Untyped!)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 12 / 44

slide-22
SLIDE 22

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Classical logic as a program translation

Curry-Howard presentation

Translation from λ-calculus + cc into λ-calculus. A, B ::= α | A → B | A × B | ⊥ A+ ≡ A− → ⊥ α− ≡ α → ⊥ (A → B)− ≡ A+ × B− . . . x• ≡ λω. x ω (λx. t)• ≡ λ(x, ω).t• ω (t u)• ≡ λω. t•(u•, ω) . . .

1 If ⊢ t : A then ⊢ t• : A+. 2 ⊢ cc• : (((A → B) → A) → A)+. 3 If t ≡β u then t• ≡β u•. (Untyped!) Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 12 / 44

slide-23
SLIDE 23

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

More is less

You lose part of your soul in the encoding. If there is an intuitionistic proof of ⊢ A ∨ B then ⊢ A or ⊢ B. There are classical proofs of ⊢ A ∨ B s.t. neither ⊢ A nor ⊢ B. You may want something more fjne-grained...

Dialectica.

(Gödel, 1958)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 13 / 44

slide-24
SLIDE 24

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

More is less

You lose part of your soul in the encoding. If there is an intuitionistic proof of ⊢ A ∨ B then ⊢ A or ⊢ B. There are classical proofs of ⊢ A ∨ B s.t. neither ⊢ A nor ⊢ B. You may want something more fjne-grained...

Dialectica.

(Gödel, 1958)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 13 / 44

slide-25
SLIDE 25

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

What is Dialectica?

A realizability translation

D from HA into HA

Targets System T (simply-typed

  • calculus + integers + sequences)

Preserves intuitionistic content ( ) But ofgers two additional semi-classical principles: n P n MP n P n I m Q m IP m I Q m

« Markov’s principle » « Independence of premise »

(P decidable, I irrelevant)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 14 / 44

slide-26
SLIDE 26

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

What is Dialectica?

A realizability translation (−)D from HA into HAω Targets System T (simply-typed λ-calculus + integers + sequences) Preserves intuitionistic content (∨ + ∃) But ofgers two additional semi-classical principles: n P n MP n P n I m Q m IP m I Q m

« Markov’s principle » « Independence of premise »

(P decidable, I irrelevant)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 14 / 44

slide-27
SLIDE 27

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

What is Dialectica?

A realizability translation (−)D from HA into HAω Targets System T (simply-typed λ-calculus + integers + sequences) Preserves intuitionistic content (∨ + ∃) But ofgers two additional semi-classical principles: ¬(∀n ∈ N. ¬P n) MP ∃n ∈ N. P n I → ∃m ∈ N. Q m IP ∃m ∈ N. I → Q m

« Markov’s principle » « Independence of premise »

(P decidable, I irrelevant)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 14 / 44

slide-28
SLIDE 28

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

The Good Old Gödel’s translation

⊢ A → ⊢ AD ≡ ∃⃗

  • u. ∀⃗
  • x. AD[⃗

u,⃗ x]

(−)D essentially commutes with the connectives except for the arrow A B D uA vB xA yB AD uA xA BD vB yB A B D uA vB b xA yB AD uA xA if b BD vB yB if b A B D f uA yB AD uA uA yB BD f uA yB

1 If

HA A then HA

AD.

2 MP and IP are provable through

D.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 15 / 44

slide-29
SLIDE 29

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

The Good Old Gödel’s translation

⊢ A → ⊢ AD ≡ ∃⃗

  • u. ∀⃗
  • x. AD[⃗

u,⃗ x]

(−)D essentially commutes with the connectivesexcept for the arrow (A ∧ B)D ≡ ∃⃗ uA, ⃗

  • vB. ∀⃗

xA, ⃗

  • yB. AD[⃗

uA,⃗ xA] ∧ BD[⃗ vB,⃗ yB] (A ∨ B)D ≡ ∃⃗ uA, ⃗ vB, b. ∀⃗ xA, ⃗ yB. { AD[⃗ uA,⃗ xA] if b = 0 BD[⃗ vB,⃗ yB] if b ̸= 0 (A → B)D ≡ ∃ ⃗ f, ⃗ φ. ∀⃗ uA, ⃗

  • yB. AD[⃗

uA, ⃗ φ ⃗ uA ⃗ yB] → BD[ ⃗ f ⃗ uA,⃗ yB]

1 If ⊢HA A then ⊢HAω AD. 2 MP and IP are provable through (−)D. Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 15 / 44

slide-30
SLIDE 30

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Successes and failures

Dialectica has been used a lot Bar recursion (Spector ’62) Dialectica categories (De Paiva 89’) Proof mining (Oliva, Kohlenbach 2000’s) Yet, a reputation of complexity and an aura of mystery.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 16 / 44

slide-31
SLIDE 31

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Successes and failures

Dialectica has been used a lot Bar recursion (Spector ’62) Dialectica categories (De Paiva 89’) Proof mining (Oliva, Kohlenbach 2000’s) Yet, a reputation of complexity and an aura of mystery.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 16 / 44

slide-32
SLIDE 32

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

In this Thesis

« Dialectica does not fit in the Curry-Howard paradigm. »

(U. Kohlenbach, TYPES 2013, 25th April 2013.)

New axiom MP + IP ∼ Programming primitives

  • bserve variable use

⇕ ⇕ Logical encoding Dialectica ∼ Program translation CPS-like accumulating stacks

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 17 / 44

slide-33
SLIDE 33

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

In this Thesis

« Dialectica does not fit in the Curry-Howard paradigm. »

(U. Kohlenbach, TYPES 2013, 25th April 2013.)

New axiom

  • MP

∼ Programming primitives

  • bserve variable use

⇕ ⇕ Logical encoding Dialectica ∼ Program translation CPS-like accumulating stacks

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 17 / 44

slide-34
SLIDE 34

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Contributions

Part II: Reformulation of Dialectica as an untyped program translation Part III: Description of its computational content in a classical realizability style Epilogue: Extension to dependent type theories Study of variants (call-by-value, classical-by-name, ) (Ch. 10) Study of relationship with similar translations (Ch. 12) A more canonical call-by-need with control (Ch. 5) A lot of delightful Coq hacking! (not in the manuscript)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 18 / 44

slide-35
SLIDE 35

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Contributions

Part II: Reformulation of Dialectica as an untyped program translation Part III: Description of its computational content in a classical realizability style Epilogue: Extension to dependent type theories Study of variants (call-by-value, classical-by-name, . . .) (Ch. 10) Study of relationship with similar translations (Ch. 12) A more canonical call-by-need with control (Ch. 5) A lot of delightful Coq hacking! (not in the manuscript)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 18 / 44

slide-36
SLIDE 36

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Contributions

Part II: Reformulation of Dialectica as an untyped program translation Part III: Description of its computational content in a classical realizability style Epilogue: Extension to dependent type theories Study of variants (call-by-value, classical-by-name, . . .) (Ch. 10) Study of relationship with similar translations (Ch. 12) A more canonical call-by-need with control (Ch. 5) A lot of delightful Coq hacking! (not in the manuscript)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 18 / 44

slide-37
SLIDE 37

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Contributions

Part II: Reformulation of Dialectica as an untyped program translation Part III: Description of its computational content in a classical realizability style Epilogue: Extension to dependent type theories Study of variants (call-by-value, classical-by-name, ) (Ch. 10) Study of relationship with similar translations (Ch. 12) A more canonical call-by-need with control (Ch. 5) A lot of delightful Coq hacking! (not in the manuscript)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 18 / 44

slide-38
SLIDE 38

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Part II.

« Reverse engineering Gödel's hacks »

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 19 / 44

slide-39
SLIDE 39

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Types, types, Types! (De Paiva, ’89)

Witness Counter Orthogonality

A proof u ⊩ A is a term ⊢ u : W(A) such that ∀x : C(A). u ⊥A x

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 20 / 44

slide-40
SLIDE 40

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Cleaning up

Gödel used System T + sequences as a target. We use true datatypes!

W C A → B { W(A) → W(B) W(A) → C(B) → C(A) W(A) × C(B) A × B W(A) × W(B) C(A) × C(B) A + B W(A) × W(B) × B C(A) × C(B)

Coming from a linear decomposition due to De Paiva and Hyland (1989). We restrict to propositional logic (for now).

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 21 / 44

slide-41
SLIDE 41

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Cleaning up

Gödel used System T + sequences as a target. We use true datatypes!

W C A → B { W(A) → W(B) W(A) → C(B) → C(A) W(A) × C(B) A × B W(A) × W(B) { W(A) × W(B) → C(A) W(A) × W(B) → C(B) A + B W(A) + W(B) { W(A) → C(A) W(B) → C(B)

Coming from a linear decomposition due to De Paiva and Hyland (1989). We restrict to propositional logic (for now).

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 21 / 44

slide-42
SLIDE 42

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

A scrutiny into the term translation

Γ ⊢ t : A − →        W(Γ) ⊢ t• : W(A) W(Γ) ⊢ tx1 : C(A) → C(Γ1) . . . W(Γ) ⊢ txn : C(A) → C(Γn) t is essentially t, except x t x t x tx tx depends on two families of terms

A

A @A A A A A s.t. u

A

@u

A

u

A

u

A

(resp. @) is used when weakening occurs (resp. duplication)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 22 / 44

slide-43
SLIDE 43

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

A scrutiny into the term translation

Γ ⊢ t : A − →        W(Γ) ⊢ t• : W(A) W(Γ) ⊢ tx1 : C(A) → C(Γ1) . . . W(Γ) ⊢ txn : C(A) → C(Γn) t• is essentially t, except (λx. t)• ≡ (λx. t•, λx π. tx π) tx depends on two families of terms ∅A : C(A) @A : C(A) → C(A) → W(A) → C(A) s.t. u ⊥A π1 @u

A π2

↔ u ⊥A π1 ∧ u ⊥A π2 ∅ (resp. @) is used when weakening occurs (resp. duplication)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 22 / 44

slide-44
SLIDE 44

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Almost there

If ⊢ t : A then

1 ⊢ t• : W(A). 2 For all π : C(A), t• ⊥A π.

There exists t and t s.t. t t but t t . We would need equations that do not hold, such as

@t

A A A @t A

because they are defjned in a quite ad-hoc, non parametric way.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 23 / 44

slide-45
SLIDE 45

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Almost there

If ⊢ t : A then

1 ⊢ t• : W(A). 2 For all π : C(A), t• ⊥A π.

There exists t1 and t2 s.t. t1 ≡β t2 but t1• ̸≡β t2•. We would need equations that do not hold, such as

π @t

A ∅A

≡β π ≡β ∅A @t

A π

because they are defjned in a quite ad-hoc, non parametric way.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 23 / 44

slide-46
SLIDE 46

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

The usual suspects

As we have just seen, the problem appears because of @ and ∅. Actually already criticized because it requires decidability of ⊥. Solved by the Diller-Nahm variant using fjnite sets (1974) They are Gödel’s workarounds defjned in a very hackish way We use a similar trick by using fjnite multisets. The desired equations hold naturally and parametrically.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 24 / 44

slide-47
SLIDE 47

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

The usual suspects

As we have just seen, the problem appears because of @ and ∅. Actually already criticized because it requires decidability of ⊥. Solved by the Diller-Nahm variant using fjnite sets (1974) They are Gödel’s workarounds defjned in a very hackish way We use a similar trick by using fjnite multisets. The desired equations hold naturally and parametrically.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 24 / 44

slide-48
SLIDE 48

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Revising the translation

Before After ∅A : C(A) ∅A : M C(A) @A : C(A) → C(A) → W(A) → C(A) @A : M C(A) → M C(A) → M C(A) { W(A) → W(B) W(A) → C(B) → C(A) { W(A) → W(B) W(A) → C(B) → M C(A)        W(Γ) ⊢ t• : W(A) W(Γ) ⊢ tx1 : C(A) → C(Γ1) . . . W(Γ) ⊢ txn : C(A) → C(Γn)          W(Γ) ⊢ t• : W(A) W(Γ) ⊢ tx1 : C(A) → M C(Γ1) . . . W(Γ) ⊢ txn : C(A) → M C(Γn) ⊥ . . .

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 25 / 44

slide-49
SLIDE 49

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Finally!

x• ≡ x (λx. t)• ≡ { λx. t• λx π. tx π (t u)• ≡ (fst t•) u• xx yx y t x y tx t u x snd t u > > = ux @ tx u

1 If

t A then

t A . For all A , t

A

.

2 If t

t then t t

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 26 / 44

slide-50
SLIDE 50

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Finally!

x• ≡ x (λx. t)• ≡ { λx. t• λx π. tx π (t u)• ≡ (fst t•) u• xx ≡ λπ. {π} yx y t x y tx t u x snd t u > > = ux @ tx u

1 If

t A then

t A . For all A , t

A

.

2 If t

t then t t

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 26 / 44

slide-51
SLIDE 51

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Finally!

x• ≡ x (λx. t)• ≡ { λx. t• λx π. tx π (t u)• ≡ (fst t•) u• xx ≡ λπ. {π} yx ≡ λπ. ∅ y t x y tx t u x snd t u > > = ux @ tx u

1 If

t A then

t A . For all A , t

A

.

2 If t

t then t t

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 26 / 44

slide-52
SLIDE 52

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Finally!

x• ≡ x (λx. t)• ≡ { λx. t• λx π. tx π (t u)• ≡ (fst t•) u• xx ≡ λπ. {π} yx ≡ λπ. ∅ (λy. t)x ≡ λ(y, π). tx π t u x snd t u > > = ux @ tx u

1 If

t A then

t A . For all A , t

A

.

2 If t

t then t t

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 26 / 44

slide-53
SLIDE 53

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Finally!

x• ≡ x (λx. t)• ≡ { λx. t• λx π. tx π (t u)• ≡ (fst t•) u• xx ≡ λπ. {π} yx ≡ λπ. ∅ (λy. t)x ≡ λ(y, π). tx π (t u)x ≡ λπ.   (snd t•) u• π > > = ux @ tx (u•, π)  

1 If

t A then

t A . For all A , t

A

.

2 If t

t then t t

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 26 / 44

slide-54
SLIDE 54

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Finally!

x• ≡ x (λx. t)• ≡ { λx. t• λx π. tx π (t u)• ≡ (fst t•) u• xx ≡ λπ. {π} yx ≡ λπ. ∅ (λy. t)x ≡ λ(y, π). tx π (t u)x ≡ λπ.   (snd t•) u• π > > = ux @ tx (u•, π)  

1 If ⊢ t : A then

⊢ t• : W(A). For all π : C(A), t• ⊥A π.

2 If t1 ≡β t2 then t1• ≡β t2• Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 26 / 44

slide-55
SLIDE 55

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

A note on orthogonality

The orthogonality can be expressed in this setting. Yet it is no more useful for now. The Gödel-style Dialectica used Friedmann’s trick for ∅0: W(0) ≡ 1 and C(0) ≡ 1 You needed to rule out invalid proofs of W(0). Not the case anymore with multisets, W(0) ≡ 0. Soundness for free!

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 27 / 44

slide-56
SLIDE 56

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Part III.

« When Krivine meets Gödel »

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 28 / 44

slide-57
SLIDE 57

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

You are here

New axiom ? ∼ Programming primitives ? ⇕ ⇕ Logical encoding Program translation Revised Dialectica ∼ Something involving    multisets counters free variables

What is actually doing the translation as a program? What rôle on earth have the counters?

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 29 / 44

slide-58
SLIDE 58

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

You are here

New axiom ? ∼ Programming primitives ? ⇕ ⇕ Logical encoding Program translation Revised Dialectica ∼ Something involving    multisets counters free variables

What is actually doing the translation as a program? What rôle on earth have the counters?

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 29 / 44

slide-59
SLIDE 59

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Stay on the scene

Let us introduce you to the Krivine Abstract Machine (KAM). Closures c ::= (t, σ) Environments σ ::= ∅ | σ + (x := c) Stacks π ::= ε | c · π Processes p ::= ⟨c | π⟩ Push t u t u Pop x t c t x c Grab x x c c Garbage x y c x The Krivine Abstract Machine™

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 30 / 44

slide-60
SLIDE 60

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Stay on the scene

Let us introduce you to the Krivine Abstract Machine (KAM). Closures c ::= (t, σ) Environments σ ::= ∅ | σ + (x := c) Stacks π ::= ε | c · π Processes p ::= ⟨c | π⟩ Push ⟨(t u, σ) | π⟩ → ⟨(t, σ) | (u, σ) · π⟩ Pop x t c t x c Grab x x c c Garbage x y c x The Krivine Abstract Machine™

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 30 / 44

slide-61
SLIDE 61

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Stay on the scene

Let us introduce you to the Krivine Abstract Machine (KAM). Closures c ::= (t, σ) Environments σ ::= ∅ | σ + (x := c) Stacks π ::= ε | c · π Processes p ::= ⟨c | π⟩ Push t u t u Pop ⟨(λx. t, σ) | c · π⟩ → ⟨(t, σ + (x := c)) | π⟩ Grab x x c c Garbage x y c x The Krivine Abstract Machine™

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 30 / 44

slide-62
SLIDE 62

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Stay on the scene

Let us introduce you to the Krivine Abstract Machine (KAM). Closures c ::= (t, σ) Environments σ ::= ∅ | σ + (x := c) Stacks π ::= ε | c · π Processes p ::= ⟨c | π⟩ Push t u t u Pop x t c t x c Grab ⟨(x, σ + (x := c)) | π⟩ → ⟨c | π⟩ Garbage x y c x The Krivine Abstract Machine™

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 30 / 44

slide-63
SLIDE 63

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Stay on the scene

Let us introduce you to the Krivine Abstract Machine (KAM). Closures c ::= (t, σ) Environments σ ::= ∅ | σ + (x := c) Stacks π ::= ε | c · π Processes p ::= ⟨c | π⟩ Push t u t u Pop x t c t x c Grab x x c c Garbage ⟨(x, σ + (y := c)) | π⟩ → ⟨(x, σ) | π⟩ The Krivine Abstract Machine™

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 30 / 44

slide-64
SLIDE 64

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Stay on the scene

Let us introduce you to the Krivine Abstract Machine (KAM). Closures c ::= (t, σ) Environments σ ::= ∅ | σ + (x := c) Stacks π ::= ε | c · π Processes p ::= ⟨c | π⟩ Push ⟨(t u, σ) | π⟩ → ⟨(t, σ) | (u, σ) · π⟩ Pop ⟨(λx. t, σ) | c · π⟩ → ⟨(t, σ + (x := c)) | π⟩ Grab ⟨(x, σ + (x := c)) | π⟩ → ⟨c | π⟩ Garbage ⟨(x, σ + (y := c)) | π⟩ → ⟨(x, σ) | π⟩ The Krivine Abstract Machine™

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 30 / 44

slide-65
SLIDE 65

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

A word on the KAM

The KAM is call-by-name, implementing linear head reduction Used amongst other things to do classical realizability (Krivine ’02) Features stacks and environments as fjrst-class objects In particular, typing can be extended to stacks and environments ⊢ π : A⊥ σ ⊢ Γ Double-negation and forcing already explained through the KAM

Double-negation using callcc (Griffjn ’90, Krivine ’03) Forcing using a monotonous global variable (Miquel ’11)

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 31 / 44

slide-66
SLIDE 66

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

What has been seen cannot be unseen

C(A → B) ≡ W(A) × C(B)

x t c t x c

Counters are stacks! Dialectica gives access to stacks!

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 32 / 44

slide-67
SLIDE 67

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

What has been seen cannot be unseen

C(A → B) ≡ W(A) × C(B)

x t c t x c

Counters are stacks! Dialectica gives access to stacks!

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 32 / 44

slide-68
SLIDE 68

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

What has been seen cannot be unseen C(A → B) ≡ W(A) × C(B) x t c t x c

Counters are stacks! Dialectica gives access to stacks!

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 32 / 44

slide-69
SLIDE 69

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

What has been seen cannot be unseen

C(A → B) ≡ W(A) × C(B)

x t c t x c

Counters are stacks! Dialectica gives access to stacks!

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 32 / 44

slide-70
SLIDE 70

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

What has been seen cannot be unseen

C(A → B) ≡ W(A) × C(B)

⟨(λx. t, σ) | c · π⟩ → ⟨(t, σ + (x := c)) | π⟩

Counters are stacks! Dialectica gives access to stacks!

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 32 / 44

slide-71
SLIDE 71

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

What has been seen cannot be unseen

C(A → B) ≡ W(A) × C(B)

⟨(λx. t, σ) | c · π⟩ → ⟨(t, σ + (x := c)) | π⟩

Counters are stacks! Dialectica gives access to stacks!

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 32 / 44

slide-72
SLIDE 72

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

What has been seen cannot be unseen

C(A → B) ≡ W(A) × C(B)

⟨(λx. t, σ) | c · π⟩ → ⟨(t, σ + (x := c)) | π⟩

Counters are stacks! Dialectica gives access to stacks!

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 32 / 44

slide-73
SLIDE 73

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Closures all the way down

Let:

a term ⃗ x : Γ ⊢ t : A a closure σ ⊢ Γ a stack ⊢ π : A⊥ (i.e. π• : C(A))

Then txi x

i m

are the stacks encountered by xi while evaluating t , i.e. t xi . . . . . . xi

m m

The

x translation tracks the uses of x as delimited continuations.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 33 / 44

slide-74
SLIDE 74

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Closures all the way down

Let:

a term ⃗ x : Γ ⊢ t : A a closure σ ⊢ Γ a stack ⊢ π : A⊥ (i.e. π• : C(A))

Then (txi{⃗ x := σ•}) π• : M C(Γi) ≡ {ρ1; . . . ; ρm} are the stacks encountered by xi while evaluating ⟨(t, σ) | π⟩, i.e. ⟨(t, σ) | π⟩ − →∗ ⟨(xi, σ1) | ρ1⟩ . . . . . . − →∗ ⟨(xi, σm) | ρm⟩ The (−)x translation tracks the uses of x as delimited continuations.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 33 / 44

slide-75
SLIDE 75

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Look around you xx ≡ λπ. {π} yx ≡ λπ. ∅ (λy. t)x ≡ λ(y, π). tx π (t u)x ≡ λπ.   (snd t•) u• π > > = ux @ tx (u•, π)  

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 34 / 44

slide-76
SLIDE 76

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

A little issue

The stacks produced by the KAM are ordered by sequentiality. The Dialectica produces multisets of stacks without regard to order.

Not possible to fjx easily (or at all?) A defect of linear logic ?

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 35 / 44

slide-77
SLIDE 77

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

A little issue

The stacks produced by the KAM are ordered by sequentiality. The Dialectica produces multisets of stacks without regard to order.

Not possible to fjx easily (or at all?) A defect of linear logic ?

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 35 / 44

slide-78
SLIDE 78

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Revisiting MP + IP

In the historical presentation: IP essentially obtained by ∅ + realizability MP is more magical W(MP) ∼ = N → N mp := λx. x In the revised Dialectica: Not a realizability and no no IP The historical realizer of the MP takes another fmavour

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 36 / 44

slide-79
SLIDE 79

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Revisiting MP + IP

In the historical presentation: IP essentially obtained by ∅ + realizability MP is more magical W(MP) ∼ = N → N mp := λx. x In the revised Dialectica: Not a realizability and no ∅ ⇝ no IP The historical realizer of the MP takes another fmavour

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 36 / 44

slide-80
SLIDE 80

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

MP?

1 First issue:

W(¬A) ∼ = ¬W(A) Need to weaken ¬A into ∼ A ≡ A → ⊥ where W(⊥) ≡ 1 C(⊥) ≡ 1 ()̸⊥⊥() (no rule for ⊥)

2 Second issue:

A A A A You need the orthogonality to ensure that the returned multiset is classically not empty!

f A A A u A f A u u

A 3 If A has a decidable orthogonality then this is equivalent to

A A u A f A u u

A

4 Extract using

_ and enjoy (if A is fjrst-order). u A f

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 37 / 44

slide-81
SLIDE 81

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

MP?

1 First issue:

W(¬A) ∼ = ¬W(A) Need to weaken ¬A into ∼ A ≡ A → ⊥ where W(⊥) ≡ 1 C(⊥) ≡ 1 ()̸⊥⊥() (no rule for ⊥)

2 Second issue: W(∼∼ A) ∼

= (W(A) → M C(A)) → M W(A) You need the orthogonality to ensure that the returned multiset is classically not empty!

f ⊩ ∼∼ A ↔ ∀ϕ : W(A) → M C(A). ¬(∀u : W(A) ∈ f ϕ. ¬(∀π : C(A) ∈ ϕ u. u ⊥A π))

3 If A has a decidable orthogonality then this is equivalent to

A A u A f A u u

A

4 Extract using

_ and enjoy (if A is fjrst-order). u A f

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 37 / 44

slide-82
SLIDE 82

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

MP?

1 First issue:

W(¬A) ∼ = ¬W(A) Need to weaken ¬A into ∼ A ≡ A → ⊥ where W(⊥) ≡ 1 C(⊥) ≡ 1 ()̸⊥⊥() (no rule for ⊥)

2 Second issue: W(∼∼ A) ∼

= (W(A) → M C(A)) → M W(A) You need the orthogonality to ensure that the returned multiset is classically not empty!

f ⊩ ∼∼ A ↔ ∀ϕ : W(A) → M C(A). ¬(∀u : W(A) ∈ f ϕ. ¬(∀π : C(A) ∈ ϕ u. u ⊥A π))

3 If A has a decidable orthogonality then this is equivalent to

∀φ : W(A) → M C(A). ∃u : W(A) ∈ f φ. ∀π : C(A) ∈ φ u. u ⊥A π

4 Extract using

_ and enjoy (if A is fjrst-order). u A f

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 37 / 44

slide-83
SLIDE 83

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

MP?

1 First issue:

W(¬A) ∼ = ¬W(A) Need to weaken ¬A into ∼ A ≡ A → ⊥ where W(⊥) ≡ 1 C(⊥) ≡ 1 ()̸⊥⊥() (no rule for ⊥)

2 Second issue: W(∼∼ A) ∼

= (W(A) → M C(A)) → M W(A) You need the orthogonality to ensure that the returned multiset is classically not empty!

f ⊩ ∼∼ A ↔ ∀ϕ : W(A) → M C(A). ¬(∀u : W(A) ∈ f ϕ. ¬(∀π : C(A) ∈ ϕ u. u ⊥A π))

3 If A has a decidable orthogonality then this is equivalent to

∀φ : W(A) → M C(A). ∃u : W(A) ∈ f φ. ∀π : C(A) ∈ φ u. u ⊥A π

4 Extract using φ ≡ λ_. ∅ and enjoy (if A is fjrst-order).

∃u : W(A) ∈ f φ

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 37 / 44

slide-84
SLIDE 84

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Comparison with historical Dialectica

We’ve got rid of IP: it’s not a bug, it’s a feature! MP has a clearer meaning now.

The delimited continuation part extracts argument access to functions We made explicit a crawling over fjnite multisets that were hard-wired into @ in the historical version

In particular we may do fancier things now

Counting the number of accesses of a function to a variable More ...?

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 38 / 44

slide-85
SLIDE 85

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Epilogue.

« You're not done yet. »

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 39 / 44

slide-86
SLIDE 86

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Dependently-typed Dialectica

This translation naturally lifts to dependent types W(Πx : A. B) ≡ Πx : W(A).W(B) × (C(B) → M W(A)) C(Πx : A. B) ≡ Σx : W(A).C(B) What about dependent elimination?

Hints in this thesis Actually solved after the manuscript was submitted (kudos to Andrej) Essentially make C(A) highly depend on some value u : W(A) Decomposes through CBPV (Levy ’01)

Diffjcult to implement in practice?

Computational implementation of multisets? We should be using HITs (HoTT Book) TODO: Write an implementation of Dialectica in Coq

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 40 / 44

slide-87
SLIDE 87

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Intuitionism is the new linear

Dialectica is the prototypical model of LL « Double-glueing, le mot est lâché ! » Towards a « free model » of LL in LJ? « A new linear logic: intuitionistic logic » Delimited continuations and dependency probably needed Linear logic is not about linearity

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 41 / 44

slide-88
SLIDE 88

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Intuitionistic enough translations

Dialectica shares common properties with (intuitionistic) forcing. In particular, W(−) commutes with positives. This is a moral requirement to preserve dependent elimination. Occurs strikingly often with commutative / idempotent monads.

Forcing (a monotonous reader monad on ) Intuitionistic CPS (similar but with stacks) Dialectica (a rich writer on A ) Sheafjfjcation (?)

Probably something deep there

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 42 / 44

slide-89
SLIDE 89

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Intuitionistic enough translations

Dialectica shares common properties with (intuitionistic) forcing. In particular, W(−) commutes with positives. This is a moral requirement to preserve dependent elimination. Occurs strikingly often with commutative / idempotent monads.

Forcing (a monotonous reader monad on ) Intuitionistic CPS (similar but with stacks) Dialectica (a rich writer on A ) Sheafjfjcation (?)

Probably something deep there

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 42 / 44

slide-90
SLIDE 90

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Intuitionistic enough translations

Dialectica shares common properties with (intuitionistic) forcing. In particular, W(−) commutes with positives. This is a moral requirement to preserve dependent elimination. Occurs strikingly often with commutative / idempotent monads.

Forcing (a monotonous reader monad on (P, ≤)) Intuitionistic CPS (similar but with stacks) Dialectica (a rich writer on C(A) → M C(Γ)) Sheafjfjcation (?)

Probably something deep there

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 42 / 44

slide-91
SLIDE 91

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Conclusion

We demystifjed Gödel’s Dialectica translation. Actually using concepts inexistents at the time of Gödel:

Computational content of proofs Stacks Explicit substitutions

We described computationally the contents of Markov’s principle. This presentation allows for a lot of extensions and future work.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 43 / 44

slide-92
SLIDE 92

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Scribitur ad narrandum, non ad probandum

Thanks for your attention.

Pierre-Marie Pédrot (PPS/πr2) A Materialist Dialectica 17/09/2015 44 / 44