SlideShare a Scribd company logo
Proving decidability
of Intuitionistic Propositional Calculus
                 on Coq
           Masaki Hara (qnighy)
       University of Tokyo, first grade
           Logic Zoo 2013 にて
1. Task & Known results
2. Brief methodology of the proof
  1.   Cut elimination
  2.   Contraction elimination
  3.   → 𝐿 elimination
  4.   Proof of strictly-decreasingness
3. Implementation detail
4. Further implementation plan
Task
• Proposition: 𝐴𝑡𝑜𝑚 𝑛 , ∧, ∨, →, ⊥
• Task: Is given propositional formula P provable
  in LJ?
  – It’s known to be decidable. [Dyckhoff]


• This talk: how to prove this decidability on
  Coq
Known results
• Decision problem on IPC is PSPACE complete
  [Statman]
  – Especially, O(N log N) space decision procedure is
    known [Hudelmaier]
• These approaches are backtracking on LJ
  syntax.
Known results
• cf. classical counterpart of this problem is
  co-NP complete.
  – Proof: find counterexample in boolean-valued
    semantics (SAT).
methodology
• To prove decidability, all rules should be
  strictly decreasing on some measuring.
                                 𝑆1 ,𝑆2 ,…,𝑆 𝑁
• More formally, for all rules                   𝑟𝑢𝑙𝑒
                                       𝑆0
  and all number 𝑖 (1 ≤ 𝑖 ≤ 𝑁),
                     𝑆 𝑖 < 𝑆0
   on certain well-founded relation <.
methodology
1.   Eliminate cut rule of LJ
2.   Eliminate contraction rule
3.   Split → 𝑳 rule into 4 pieces
4.   Prove that every rule is strictly decreasing
Sequent Calculus LJ
    Γ⊢𝐺                    𝐴,𝐴,Γ⊢𝐺            Γ⊢𝐴 𝐴,Δ⊢𝐺
•              𝑤𝑒𝑎𝑘                  𝑐𝑜𝑛𝑡𝑟              (𝑐𝑢𝑡)
    𝐴,Γ⊢𝐺                   𝐴,Γ⊢𝐺               Γ,Δ⊢𝐺

•           𝑎𝑥𝑖𝑜𝑚             (𝑒𝑥𝑓𝑎𝑙𝑠𝑜)
    𝐴⊢𝐴                ⊥⊢𝐺
    Γ⊢𝐴    𝐵,Γ⊢𝐺               𝐴,Γ⊢𝐵
•                     →𝐿             (→ 𝑅 )
      𝐴→𝐵,Γ⊢𝐺                 Γ⊢𝐴→𝐵
     𝐴,𝐵,Γ⊢𝐺           Γ⊢𝐴 Γ⊢𝐵
•               ∧𝐿             (∧ 𝑅 )
    𝐴∧𝐵,Γ⊢𝐺             Γ⊢𝐴∧𝐵
    𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺                Γ⊢𝐴             Γ⊢𝐵
•                     ∨𝐿              ∨ 𝑅1            ∨ 𝑅2
       𝐴∨𝐵,Γ⊢𝐺                Γ⊢𝐴∨𝐵           Γ⊢𝐴∨𝐵
•
Sequent Calculus LJ
    Γ⊢𝐺                    𝐴,𝐴,Γ⊢𝐺            Γ⊢𝐴 𝐴,Δ⊢𝐺
•              𝑤𝑒𝑎𝑘                  𝑐𝑜𝑛𝑡𝑟              (𝑐𝑢𝑡)
    𝐴,Γ⊢𝐺                   𝐴,Γ⊢𝐺               Γ,Δ⊢𝐺

•           𝑎𝑥𝑖𝑜𝑚             (𝑒𝑥𝑓𝑎𝑙𝑠𝑜)
    𝐴⊢𝐴                ⊥⊢𝐺
    Γ⊢𝐴    𝐵,Γ⊢𝐺               𝐴,Γ⊢𝐵
•                     →𝐿             (→ 𝑅 )
      𝐴→𝐵,Γ⊢𝐺                 Γ⊢𝐴→𝐵
     𝐴,𝐵,Γ⊢𝐺           Γ⊢𝐴 Γ⊢𝐵
•               ∧𝐿             (∧ 𝑅 )
    𝐴∧𝐵,Γ⊢𝐺             Γ⊢𝐴∧𝐵
    𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺                Γ⊢𝐴             Γ⊢𝐵
•                     ∨𝐿              ∨ 𝑅1            ∨ 𝑅2
       𝐴∨𝐵,Γ⊢𝐺                Γ⊢𝐴∨𝐵           Γ⊢𝐴∨𝐵
• We eliminate cut rule first.
Cut elimination
• 1. Prove these rule by induction on proof structure.
     Γ⊢𝐺           Δ,Δ,Γ⊢𝐺
•          𝑤𝑒𝑎𝑘𝐺            𝑐𝑜𝑛𝑡𝑟𝐺
    Δ,Γ⊢𝐺           Δ,Γ⊢𝐺
    Γ⊢⊥
•        ⊥ 𝑅𝐸
    Γ⊢𝐺
    Γ⊢𝐴∧𝐵        Γ⊢𝐴∧𝐵
•          ∧ 𝑅𝐸1         ∧ 𝑅𝐸2
     Γ⊢𝐴          Γ⊢𝐵
    Γ⊢𝐴→𝐵
•          → 𝑅𝐸
     𝐴,Γ⊢𝐵
       Γ1 ⊢𝐴 𝐴,Δ1 ⊢𝐺1                     Γ2 ⊢𝐵 𝐵,Δ2 ⊢𝐺2
• If                  (𝑐𝑢𝑡 𝐴 )        and                (𝑐𝑢𝑡 𝐵 ) for all
          Γ1 ,Δ1 ⊢𝐺1                         Γ2 ,Δ2 ⊢𝐺2
                                         Γ⊢𝐴∨𝐵 A,Δ⊢𝐺 𝐵,Δ⊢𝐺
    Γ1 , Γ2 , Δ1 , Δ2 , 𝐺1 , 𝐺2 ,   then                       (∨ 𝑅𝐸 )
                                                  Γ,Δ⊢𝐺
Cut elimination
• 2. Prove the general cut rule
             Γ ⊢ 𝐴 𝐴 𝑛 , Δ ⊢ 𝐺
                                𝑐𝑢𝑡𝐺
                 Γ, Δ ⊢ 𝐺
  by induction on the size of 𝐴
  and proof structure of the right hand.
• 3. specialize 𝑐𝑢𝑡𝐺 (n = 1) ■
Cut-free LJ
    Γ⊢𝐺                    𝐴,𝐴,Γ⊢𝐺
•              𝑤𝑒𝑎𝑘                  𝑐𝑜𝑛𝑡𝑟
    𝐴,Γ⊢𝐺                   𝐴,Γ⊢𝐺

•           𝑎𝑥𝑖𝑜𝑚             (𝑒𝑥𝑓𝑎𝑙𝑠𝑜)
    𝐴⊢𝐴                ⊥⊢𝐺
    Γ⊢𝐴    𝐵,Γ⊢𝐺               𝐴,Γ⊢𝐵
•                     →𝐿             (→ 𝑅 )
      𝐴→𝐵,Γ⊢𝐺                 Γ⊢𝐴→𝐵
     𝐴,𝐵,Γ⊢𝐺           Γ⊢𝐴 Γ⊢𝐵
•               ∧𝐿             (∧ 𝑅 )
    𝐴∧𝐵,Γ⊢𝐺             Γ⊢𝐴∧𝐵
    𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺                Γ⊢𝐴             Γ⊢𝐵
•                     ∨𝐿              ∨ 𝑅1            ∨ 𝑅2
       𝐴∨𝐵,Γ⊢𝐺                Γ⊢𝐴∨𝐵           Γ⊢𝐴∨𝐵
•
Cut-free LJ
    Γ⊢𝐺                    𝐴,𝐴,Γ⊢𝐺
•              𝑤𝑒𝑎𝑘                  𝑐𝑜𝑛𝑡𝑟
    𝐴,Γ⊢𝐺                   𝐴,Γ⊢𝐺

•           𝑎𝑥𝑖𝑜𝑚             (𝑒𝑥𝑓𝑎𝑙𝑠𝑜)
    𝐴⊢𝐴                ⊥⊢𝐺
    Γ⊢𝐴    𝐵,Γ⊢𝐺               𝐴,Γ⊢𝐵
•                     →𝐿             (→ 𝑅 )
      𝐴→𝐵,Γ⊢𝐺                 Γ⊢𝐴→𝐵
     𝐴,𝐵,Γ⊢𝐺           Γ⊢𝐴 Γ⊢𝐵
•               ∧𝐿             (∧ 𝑅 )
    𝐴∧𝐵,Γ⊢𝐺             Γ⊢𝐴∧𝐵
    𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺                Γ⊢𝐴             Γ⊢𝐵
•                     ∨𝐿              ∨ 𝑅1            ∨ 𝑅2
       𝐴∨𝐵,Γ⊢𝐺                Γ⊢𝐴∨𝐵           Γ⊢𝐴∨𝐵
• Contraction rule is not strictly decreasing
Contraction-free LJ
•           𝑎𝑥𝑖𝑜𝑚                (𝑒𝑥𝑓𝑎𝑙𝑠𝑜)
    𝐴,Γ⊢𝐴                ⊥,Γ⊢𝐺
    𝐴→𝐵,Γ⊢𝐴   𝐵,Γ⊢𝐺                𝐴,Γ⊢𝐵
•                        →𝐿              (→ 𝑅 )
        𝐴→𝐵,Γ⊢𝐺                   Γ⊢𝐴→𝐵
     𝐴,𝐵,Γ⊢𝐺         Γ⊢𝐴 Γ⊢𝐵
•              ∧𝐿            (∧ 𝑅 )
    𝐴∧𝐵,Γ⊢𝐺           Γ⊢𝐴∧𝐵
    𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺             Γ⊢𝐴               Γ⊢𝐵
•                   ∨𝐿               ∨ 𝑅1            ∨ 𝑅2
       𝐴∨𝐵,Γ⊢𝐺             Γ⊢𝐴∨𝐵             Γ⊢𝐴∨𝐵
Contraction-free LJ
• Implicit weak
  –           𝑎𝑥𝑖𝑜𝑚            (𝑒𝑥𝑓𝑎𝑙𝑠𝑜)
      𝐴,Γ⊢𝐴            ⊥,Γ⊢𝐺
• Implicit contraction
      𝐴→𝐵,Γ⊢𝐴   𝐵,Γ⊢𝐺
  –                      →𝐿
          𝐴→𝐵,Γ⊢𝐺
      Γ⊢𝐴 Γ⊢𝐵
  –           (∧ 𝑅 )
       Γ⊢𝐴∧𝐵
      𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺
  –                 ∨𝐿
         𝐴∨𝐵,Γ⊢𝐺
Contraction-free LJ
• Implicit weak
  –           𝑎𝑥𝑖𝑜𝑚            (𝑒𝑥𝑓𝑎𝑙𝑠𝑜)
      𝐴,Γ⊢𝐴            ⊥,Γ⊢𝐺
• Implicit contraction
      𝐴→𝐵,Γ⊢𝐴   𝐵,Γ⊢𝐺
  –                      →𝐿
          𝐴→𝐵,Γ⊢𝐺
      Γ⊢𝐴 Γ⊢𝐵
  –           (∧ 𝑅 )
       Γ⊢𝐴∧𝐵
      𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺
  –                 ∨𝐿
         𝐴∨𝐵,Γ⊢𝐺
Proof of weak rule
• Easily done by induction ■
Proof of contr rule
• 1. prove these rules by induction on proof
  structure.
      𝐴∧𝐵,Γ⊢𝐺           𝐴∨𝐵,Γ⊢𝐺           𝐴∨𝐵,Γ⊢𝐺
  –              ∧ 𝐿𝐸             ∨ 𝐿𝐸1           (∨ 𝐿𝐸2 )
       𝐴,𝐵,Γ⊢𝐺           𝐴,Γ⊢𝐺             𝐵,Γ⊢𝐺
      𝐴→𝐵,Γ⊢𝐺
  –           (→ 𝑤𝑒𝑎𝑘 )
       𝐵,Γ⊢𝐺
• 2. prove contr rule by induction on proof
  structure.■
Contraction-free LJ
•           𝑎𝑥𝑖𝑜𝑚                (𝑒𝑥𝑓𝑎𝑙𝑠𝑜)
    𝐴,Γ⊢𝐴                ⊥,Γ⊢𝐺
    𝐴→𝐵,Γ⊢𝐴   𝐵,Γ⊢𝐺                𝐴,Γ⊢𝐵
•                        →𝐿              (→ 𝑅 )
        𝐴→𝐵,Γ⊢𝐺                   Γ⊢𝐴→𝐵
     𝐴,𝐵,Γ⊢𝐺         Γ⊢𝐴 Γ⊢𝐵
•              ∧𝐿            (∧ 𝑅 )
    𝐴∧𝐵,Γ⊢𝐺           Γ⊢𝐴∧𝐵
    𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺             Γ⊢𝐴               Γ⊢𝐵
•                   ∨𝐿               ∨ 𝑅1            ∨ 𝑅2
       𝐴∨𝐵,Γ⊢𝐺             Γ⊢𝐴∨𝐵             Γ⊢𝐴∨𝐵
Contraction-free LJ
•           𝑎𝑥𝑖𝑜𝑚                (𝑒𝑥𝑓𝑎𝑙𝑠𝑜)
    𝐴,Γ⊢𝐴                ⊥,Γ⊢𝐺
    𝐴→𝐵,Γ⊢𝐴   𝐵,Γ⊢𝐺                𝐴,Γ⊢𝐵
•                        →𝐿              (→ 𝑅 )
        𝐴→𝐵,Γ⊢𝐺                   Γ⊢𝐴→𝐵
     𝐴,𝐵,Γ⊢𝐺         Γ⊢𝐴 Γ⊢𝐵
•              ∧𝐿            (∧ 𝑅 )
    𝐴∧𝐵,Γ⊢𝐺           Γ⊢𝐴∧𝐵
    𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺             Γ⊢𝐴               Γ⊢𝐵
•                   ∨𝐿               ∨ 𝑅1            ∨ 𝑅2
       𝐴∨𝐵,Γ⊢𝐺             Γ⊢𝐴∨𝐵             Γ⊢𝐴∨𝐵
• This time, → 𝐿 rule is not decreasing
Terminating LJ
          𝐴→𝐵,Γ⊢𝐴   𝐵,Γ⊢𝐺
• Split                         →𝐿   into 4 pieces
              𝐴→𝐵,Γ⊢𝐺
              𝐶,𝐴𝑡𝑜𝑚 𝑛 ,Γ⊢𝐺
   1.                             → 𝐿1
          𝐴𝑡𝑜𝑚 𝑛 →𝐶,𝐴𝑡𝑜𝑚 𝑛 ,Γ⊢𝐺
          𝐵→𝐶,Γ⊢𝐴→𝐵 C,Γ⊢𝐺
   2.                     (→ 𝐿2 )
             𝐴→𝐵 →𝐶,Γ⊢𝐺
          𝐴→ 𝐵→𝐶 ,Γ⊢𝐺
   3.                 (→ 𝐿3 )
           𝐴∧𝐵 →𝐶,Γ⊢𝐺
          𝐴→𝐶,𝐵→𝐶,Γ⊢𝐺
   4.                 (→ 𝐿4 )
           𝐴∨𝐵 →𝐶,Γ⊢𝐺
Correctness of Terminating LJ
• 1. If Γ ⊢ 𝐺 is provable in Contraction-free LJ,
  At least one of these is true:
  – Γ includes ⊥, 𝐴 ∧ 𝐵, or 𝐴 ∨ 𝐵
  – Γ includes both 𝐴𝑡𝑜𝑚(𝑛) and 𝐴𝑡𝑜𝑚 𝑛 → 𝐵
  – Γ ⊢ 𝐺 has a proof whose bottommost rule is not
    the form of
     𝐴𝑡𝑜𝑚 𝑛 →𝐵,𝐴𝑡𝑜𝑚 𝑛 ,Γ⊢𝐴𝑡𝑜𝑚 𝑛   𝐵,𝐴𝑡𝑜𝑚 𝑛 ,Γ⊢𝐺
                                                (→ 𝐿 )
               𝐴𝑡𝑜𝑚 𝑛 →𝐵,𝐴𝑡𝑜𝑚(𝑛),Γ⊢𝐺

• Proof: induction on proof structure
Correctness of Terminating LJ
• 2. every sequent provable in Contraction-free
  LJ is also provable in Terminating LJ.
• Proof: induction by size of the sequent.
  – Size: we will introduce later
Terminating LJ
•            𝑎𝑥𝑖𝑜𝑚             (𝑒𝑥𝑓𝑎𝑙𝑠𝑜)
    𝐴,Γ⊢𝐴              ⊥,Γ⊢𝐺
         𝐶,𝐴𝑡𝑜𝑚 𝑛 ,Γ⊢𝐺                     𝐵→𝐶,Γ⊢𝐴→𝐵 C,Γ⊢𝐺
•                               → 𝐿1                         → 𝐿2
     𝐴𝑡𝑜𝑚 𝑛 →𝐶,𝐴𝑡𝑜𝑚 𝑛 ,Γ⊢𝐺                    𝐴→𝐵 →𝐶,Γ⊢𝐺
    𝐴→ 𝐵→𝐶 ,Γ⊢𝐺               𝐴→𝐶,𝐵→𝐶,Γ⊢𝐺
•                    → 𝐿3                    → 𝐿4
     𝐴∧𝐵 →𝐶,Γ⊢𝐺                𝐴∨𝐵 →𝐶,Γ⊢𝐺
     𝐴,Γ⊢𝐵         𝐴,𝐵,Γ⊢𝐺          Γ⊢𝐴 Γ⊢𝐵
•            →𝑅               ∧𝐿            (∧ 𝑅 )
    Γ⊢𝐴→𝐵         𝐴∧𝐵,Γ⊢𝐺            Γ⊢𝐴∧𝐵
    𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺              Γ⊢𝐴             Γ⊢𝐵
•                 ∨𝐿                ∨ 𝑅1            ∨ 𝑅2
       𝐴∨𝐵,Γ⊢𝐺              Γ⊢𝐴∨𝐵           Γ⊢𝐴∨𝐵
Proof of termination
• Weight of Proposition
  –   𝑤    𝐴𝑡𝑜𝑚 𝑛 = 1
  –   𝑤   ⊥ =1
  –   𝑤   𝐴 → 𝐵 = 𝑤 𝐴 + 𝑤 𝐵 +1
  –   𝑤   𝐴∧ 𝐵 = 𝑤 𝐴 + 𝑤 𝐵 +2
  –   𝑤   𝐴∨ 𝐵 = 𝑤 𝐴 + 𝑤 𝐵 +1
• 𝐴 < 𝐵 ⇔ 𝑤 𝐴 < 𝑤(𝐵)
Proof of termination
• ordering of Proposition List
  – Use Multiset ordering (Dershowitz and Manna
    ordering)
Multiset Ordering
• Multiset Ordering: a binary relation between
  multisets (not necessarily be ordering)
• 𝐴> 𝐵⇔                                Not empty



      A

      B
Multiset Ordering
• If 𝑅 is a well-founded binary relation, the
  Multiset Ordering over 𝑅 is also well-founded.

• Well-founded: every element is accessible
• 𝐴 is accessible : every element 𝐵 such that
  𝐵 < 𝐴 is accessible
Multiset Ordering
Proof
• 1. induction on list
• Nil ⇒ there is no 𝐴 such that 𝐴 < 𝑀 Nil,
  therefore it’s accessible.
• We will prove: 𝐴𝑐𝑐 𝑀 𝐿 ⇒ 𝐴𝑐𝑐 𝑀 (𝑥 ∷ 𝐿)
Multiset Ordering
• 2. duplicate assumption
• Using 𝐴𝑐𝑐(𝑥) and 𝐴𝑐𝑐 𝑀 (𝐿), we will prove
   𝐴𝑐𝑐 𝑀 𝐿 ⇒ 𝐴𝑐𝑐 𝑀 (𝑥 ∷ 𝐿)
• 3. induction on 𝑥 and 𝐿
  – We can use these two inductive hypotheses.
     1. ∀𝐾 𝑦, 𝑦 < 𝑥 ⇒ 𝐴𝑐𝑐 𝑀 𝐾 ⇒ 𝐴𝑐𝑐 𝑀 (𝑦 ∷ 𝐾)
     2. ∀𝐾, 𝐾 < 𝑀 𝐿 ⇒ 𝐴𝑐𝑐 𝑀 𝐾 ⇒ 𝐴𝑐𝑐 𝑀 (𝑥 ∷ 𝐾)
Multiset Ordering
• 4. Case Analysis
• By definition, 𝐴𝑐𝑐 𝑀 (𝑥 ∷ 𝐿) is equivalent to
          ∀𝐾, 𝐾 < 𝑀 (𝑥 ∷ 𝐿) ⇒ 𝐴𝑐𝑐 𝑀 (𝐾)
• And there are 3 patterns:
   1.   𝐾 includes 𝑥
   2.   𝐾 includes 𝑦s s.t. 𝑦 < 𝑥, and 𝐾 minus all such 𝑦 is
      equal to 𝐿
   3. 𝐾 includes 𝑦s s.t. 𝑦 < 𝑥, and 𝐾 minus all such 𝑦 is
      less than 𝐿
• Each pattern is proved using the Inductive
  Hypotheses.
Decidability
• Now, decidability can be proved by induction
  on the size of sequent.
Implementation Detail
•
IPC Proposition (Coq)
 Inductive PProp:Set :=
• | PPbot : PProp
   | PPatom : nat -> PProp
   | PPimpl : PProp -> PProp -> PProp
   | PPconj : PProp -> PProp -> PProp
   | PPdisj : PProp -> PProp -> PProp.
Cut-free LJ (Coq)
 Inductive LJ_provable : list PProp -> PProp -> Prop :=
• | LJ_perm P1 L1 L2 :
      Permutation L1 L2 ->
      LJ_provable L1 P1 ->
      LJ_provable L2 P1
   | LJ_weak P1 P2 L1 :
      LJ_provable L1 P2 ->
      LJ_provable (P1::L1) P2
   | LJ_contr P1 P2 L1 :
      LJ_provable (P1::P1::L1) P2 ->
      LJ_provable (P1::L1) P2
 …
Exchange rule
• Exchange rule :
               Γ, 𝐴, 𝐵, Δ ⊢ 𝐺
                              𝑒𝑥𝑐ℎ
               Γ, 𝐵, 𝐴, Δ ⊢ 𝐺
  is replaced by more useful
            Γ⊢ 𝐺
              ′ ⊢ 𝐺
                       𝑝𝑒𝑟𝑚𝑢𝑡𝑎𝑡𝑖𝑜𝑛
            Γ
  where Γ, Γ′ are permutation
Permutation Compatibility (Coq)
Instance LJ_provable_compat :
  Proper
   (@Permutation _==>eq==>iff)
   LJ_provable.


• Allows rewriting over Permutation equality
Permutation solver (Coq)
• Permutation should be solved automatically
Ltac perm :=
 match goal with
…
Further implementation plan
•
Further implementation plan
• Refactoring (1) : improve Permutation-
  associated tactics
  – A smarter auto-unifying tactics is needed
  – Write tactics using Objective Caml
• Refactoring (2) : use Ssreflect tacticals
  – This makes the proof more manageable
Further implementation plan
• Refactoring (3) : change proof order
  – Contraction first, cut next
  – It will make the proof shorter
• Refactoring (4) : discard Multiset Ordering
  – If we choose appropriate weight function of
    Propositional Formula, we don’t need Multiset
    Ordering. (See [Hudelmaier])
  – It also enables us to analyze complexity of this
    procedure
Further implementation plan
• Refactoring (5) : Proof of completeness
  – Now completeness theorem depends on the
    decidability
• New Theorem (1) : Other Syntaxes
  – NJ and HJ may be introduced
• New Theorem (2) : Other Semantics
  – Heyting Algebra
Further implementation plan
• New Theorem (3) : Other decision procedure
  – Decision procedure using semantics (if any)
  – More efficient decision procedure (especially
     𝑂(𝑁 log 𝑁)-space decision procedure)
• New Theorem (4) : Complexity
  – Proof of PSPACE-completeness
Source code
• Source codes are:
• https://github.com/qnighy/IPC-Coq
おわり
1. Task & Known results
2. Brief methodology of the proof
  1.   Cut elimination
  2.   Contraction elimination
  3.   → 𝐿 elimination
  4.   Proof of strictly-decreasingness
3. Implementation detail
4. Further implementation plan
References
• [Dyckhoff] Roy Dyckhoff, Contraction-free Sequent
  Calculi for Intuitionistic Logic, The Journal of Symbolic
  Logic, Vol. 57, No.3, 1992, pp. 795 – 807
• [Statman] Richard Statman, Intuitionistic Propositional
  Logic is Polynomial-Space Complete, Theoretical
  Computer Science 9, 1979, pp. 67 – 72
• [Hudelmaier] Jörg Hudelmaier, An O(n log n)-Space
  Decision Procedure for Intuitionistic Propositional Logic,
  Journal of Logic and Computation, Vol. 3, Issue 1, pp.
  63-75

More Related Content

Similar to Proving Decidability of Intuitionistic Propositional Calculus on Coq

Bounded arithmetic in free logic
Bounded arithmetic in free logicBounded arithmetic in free logic
Bounded arithmetic in free logicYamagata Yoriyuki
 
Bounded arithmetic in free logic
Bounded arithmetic in free logicBounded arithmetic in free logic
Bounded arithmetic in free logic
Yamagata Yoriyuki
 
Quadratic form and functional optimization
Quadratic form and functional optimizationQuadratic form and functional optimization
Quadratic form and functional optimization
Junpei Tsuji
 
Generalized Intersection over Union: A Metric and A Loss for Bounding Box Reg...
Generalized Intersection over Union: A Metric and A Loss for Bounding Box Reg...Generalized Intersection over Union: A Metric and A Loss for Bounding Box Reg...
Generalized Intersection over Union: A Metric and A Loss for Bounding Box Reg...
Sungchul Kim
 
Regularisation & Auxiliary Information in OOD Detection
Regularisation & Auxiliary Information in OOD DetectionRegularisation & Auxiliary Information in OOD Detection
Regularisation & Auxiliary Information in OOD Detection
kirk68
 
Blow up in a degenerate keller--segel system(Eng.)
Blow up in a degenerate keller--segel system(Eng.)Blow up in a degenerate keller--segel system(Eng.)
Blow up in a degenerate keller--segel system(Eng.)
Takahiro Hashira
 
PR 113: The Perception Distortion Tradeoff
PR 113: The Perception Distortion TradeoffPR 113: The Perception Distortion Tradeoff
PR 113: The Perception Distortion Tradeoff
Taeoh Kim
 
Page rank - from theory to application
Page rank - from theory to applicationPage rank - from theory to application
Page rank - from theory to application
GAYO3
 
Enzymes
EnzymesEnzymes
Basic calculus (i)
Basic calculus (i)Basic calculus (i)
Basic calculus (i)
Farzad Javidanrad
 
Differential Geometry for Machine Learning
Differential Geometry for Machine LearningDifferential Geometry for Machine Learning
Differential Geometry for Machine Learning
SEMINARGROOT
 
Geometry Theorems 1 REMC Tutoring
Geometry Theorems 1 REMC TutoringGeometry Theorems 1 REMC Tutoring
Geometry Theorems 1 REMC Tutoring
REMCTutoring
 
2018 Geometri Transformasi Perkalian 5 Isometri Kelompok 3 Rombel 3
2018 Geometri Transformasi Perkalian 5 Isometri Kelompok 3 Rombel 32018 Geometri Transformasi Perkalian 5 Isometri Kelompok 3 Rombel 3
2018 Geometri Transformasi Perkalian 5 Isometri Kelompok 3 Rombel 3
Yosia Adi Setiawan
 
On a certain family of meromorphic p valent functions
On a certain family of meromorphic p  valent functionsOn a certain family of meromorphic p  valent functions
On a certain family of meromorphic p valent functionsAlexander Decker
 
Милан Циркович. Антропная тень
Милан Циркович. Антропная теньМилан Циркович. Антропная тень
Милан Циркович. Антропная тень
avturchin
 
Mathematics of nyquist plot [autosaved] [autosaved]
Mathematics of nyquist plot [autosaved] [autosaved]Mathematics of nyquist plot [autosaved] [autosaved]
Mathematics of nyquist plot [autosaved] [autosaved]
Asafak Husain
 
Network theory
Network theoryNetwork theory
Network theoryeshwayne
 

Similar to Proving Decidability of Intuitionistic Propositional Calculus on Coq (19)

Bounded arithmetic in free logic
Bounded arithmetic in free logicBounded arithmetic in free logic
Bounded arithmetic in free logic
 
Bounded arithmetic in free logic
Bounded arithmetic in free logicBounded arithmetic in free logic
Bounded arithmetic in free logic
 
Quadratic form and functional optimization
Quadratic form and functional optimizationQuadratic form and functional optimization
Quadratic form and functional optimization
 
Generalized Intersection over Union: A Metric and A Loss for Bounding Box Reg...
Generalized Intersection over Union: A Metric and A Loss for Bounding Box Reg...Generalized Intersection over Union: A Metric and A Loss for Bounding Box Reg...
Generalized Intersection over Union: A Metric and A Loss for Bounding Box Reg...
 
Regularisation & Auxiliary Information in OOD Detection
Regularisation & Auxiliary Information in OOD DetectionRegularisation & Auxiliary Information in OOD Detection
Regularisation & Auxiliary Information in OOD Detection
 
Blow up in a degenerate keller--segel system(Eng.)
Blow up in a degenerate keller--segel system(Eng.)Blow up in a degenerate keller--segel system(Eng.)
Blow up in a degenerate keller--segel system(Eng.)
 
PR 113: The Perception Distortion Tradeoff
PR 113: The Perception Distortion TradeoffPR 113: The Perception Distortion Tradeoff
PR 113: The Perception Distortion Tradeoff
 
Page rank - from theory to application
Page rank - from theory to applicationPage rank - from theory to application
Page rank - from theory to application
 
Enzymes
EnzymesEnzymes
Enzymes
 
Basic calculus (i)
Basic calculus (i)Basic calculus (i)
Basic calculus (i)
 
Differential Geometry for Machine Learning
Differential Geometry for Machine LearningDifferential Geometry for Machine Learning
Differential Geometry for Machine Learning
 
Geometry Theorems 1 REMC Tutoring
Geometry Theorems 1 REMC TutoringGeometry Theorems 1 REMC Tutoring
Geometry Theorems 1 REMC Tutoring
 
2018 Geometri Transformasi Perkalian 5 Isometri Kelompok 3 Rombel 3
2018 Geometri Transformasi Perkalian 5 Isometri Kelompok 3 Rombel 32018 Geometri Transformasi Perkalian 5 Isometri Kelompok 3 Rombel 3
2018 Geometri Transformasi Perkalian 5 Isometri Kelompok 3 Rombel 3
 
On a certain family of meromorphic p valent functions
On a certain family of meromorphic p  valent functionsOn a certain family of meromorphic p  valent functions
On a certain family of meromorphic p valent functions
 
Милан Циркович. Антропная тень
Милан Циркович. Антропная теньМилан Циркович. Антропная тень
Милан Циркович. Антропная тень
 
Mathematics of nyquist plot [autosaved] [autosaved]
Mathematics of nyquist plot [autosaved] [autosaved]Mathematics of nyquist plot [autosaved] [autosaved]
Mathematics of nyquist plot [autosaved] [autosaved]
 
Sets
SetsSets
Sets
 
1sem4 and 5
1sem4 and 51sem4 and 5
1sem4 and 5
 
Network theory
Network theoryNetwork theory
Network theory
 

Recently uploaded

UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6
DianaGray10
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
ControlCase
 
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
Neo4j
 
Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
Uni Systems S.M.S.A.
 
Mind map of terminologies used in context of Generative AI
Mind map of terminologies used in context of Generative AIMind map of terminologies used in context of Generative AI
Mind map of terminologies used in context of Generative AI
Kumud Singh
 
GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
Guy Korland
 
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
SOFTTECHHUB
 
20240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 202420240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 2024
Matthew Sinclair
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
Quotidiano Piemontese
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
Alan Dix
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to ProductionGenerative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Aggregage
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
Matthew Sinclair
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
 
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
James Anderson
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
Neo4j
 
GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...
ThomasParaiso2
 
UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5
DianaGray10
 
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdfUni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems S.M.S.A.
 
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdfFIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance
 

Recently uploaded (20)

UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6UiPath Test Automation using UiPath Test Suite series, part 6
UiPath Test Automation using UiPath Test Suite series, part 6
 
PCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase TeamPCI PIN Basics Webinar from the Controlcase Team
PCI PIN Basics Webinar from the Controlcase Team
 
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
 
Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
 
Mind map of terminologies used in context of Generative AI
Mind map of terminologies used in context of Generative AIMind map of terminologies used in context of Generative AI
Mind map of terminologies used in context of Generative AI
 
GraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge GraphGraphRAG is All You need? LLM & Knowledge Graph
GraphRAG is All You need? LLM & Knowledge Graph
 
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
 
20240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 202420240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 2024
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to ProductionGenerative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to Production
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
 
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
 
GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...
 
UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5
 
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdfUni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdf
 
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdfFIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
 

Proving Decidability of Intuitionistic Propositional Calculus on Coq

  • 1. Proving decidability of Intuitionistic Propositional Calculus on Coq Masaki Hara (qnighy) University of Tokyo, first grade Logic Zoo 2013 にて
  • 2. 1. Task & Known results 2. Brief methodology of the proof 1. Cut elimination 2. Contraction elimination 3. → 𝐿 elimination 4. Proof of strictly-decreasingness 3. Implementation detail 4. Further implementation plan
  • 3. Task • Proposition: 𝐴𝑡𝑜𝑚 𝑛 , ∧, ∨, →, ⊥ • Task: Is given propositional formula P provable in LJ? – It’s known to be decidable. [Dyckhoff] • This talk: how to prove this decidability on Coq
  • 4. Known results • Decision problem on IPC is PSPACE complete [Statman] – Especially, O(N log N) space decision procedure is known [Hudelmaier] • These approaches are backtracking on LJ syntax.
  • 5. Known results • cf. classical counterpart of this problem is co-NP complete. – Proof: find counterexample in boolean-valued semantics (SAT).
  • 6. methodology • To prove decidability, all rules should be strictly decreasing on some measuring. 𝑆1 ,𝑆2 ,…,𝑆 𝑁 • More formally, for all rules 𝑟𝑢𝑙𝑒 𝑆0 and all number 𝑖 (1 ≤ 𝑖 ≤ 𝑁), 𝑆 𝑖 < 𝑆0 on certain well-founded relation <.
  • 7. methodology 1. Eliminate cut rule of LJ 2. Eliminate contraction rule 3. Split → 𝑳 rule into 4 pieces 4. Prove that every rule is strictly decreasing
  • 8. Sequent Calculus LJ Γ⊢𝐺 𝐴,𝐴,Γ⊢𝐺 Γ⊢𝐴 𝐴,Δ⊢𝐺 • 𝑤𝑒𝑎𝑘 𝑐𝑜𝑛𝑡𝑟 (𝑐𝑢𝑡) 𝐴,Γ⊢𝐺 𝐴,Γ⊢𝐺 Γ,Δ⊢𝐺 • 𝑎𝑥𝑖𝑜𝑚 (𝑒𝑥𝑓𝑎𝑙𝑠𝑜) 𝐴⊢𝐴 ⊥⊢𝐺 Γ⊢𝐴 𝐵,Γ⊢𝐺 𝐴,Γ⊢𝐵 • →𝐿 (→ 𝑅 ) 𝐴→𝐵,Γ⊢𝐺 Γ⊢𝐴→𝐵 𝐴,𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∧𝐿 (∧ 𝑅 ) 𝐴∧𝐵,Γ⊢𝐺 Γ⊢𝐴∧𝐵 𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∨𝐿 ∨ 𝑅1 ∨ 𝑅2 𝐴∨𝐵,Γ⊢𝐺 Γ⊢𝐴∨𝐵 Γ⊢𝐴∨𝐵 •
  • 9. Sequent Calculus LJ Γ⊢𝐺 𝐴,𝐴,Γ⊢𝐺 Γ⊢𝐴 𝐴,Δ⊢𝐺 • 𝑤𝑒𝑎𝑘 𝑐𝑜𝑛𝑡𝑟 (𝑐𝑢𝑡) 𝐴,Γ⊢𝐺 𝐴,Γ⊢𝐺 Γ,Δ⊢𝐺 • 𝑎𝑥𝑖𝑜𝑚 (𝑒𝑥𝑓𝑎𝑙𝑠𝑜) 𝐴⊢𝐴 ⊥⊢𝐺 Γ⊢𝐴 𝐵,Γ⊢𝐺 𝐴,Γ⊢𝐵 • →𝐿 (→ 𝑅 ) 𝐴→𝐵,Γ⊢𝐺 Γ⊢𝐴→𝐵 𝐴,𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∧𝐿 (∧ 𝑅 ) 𝐴∧𝐵,Γ⊢𝐺 Γ⊢𝐴∧𝐵 𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∨𝐿 ∨ 𝑅1 ∨ 𝑅2 𝐴∨𝐵,Γ⊢𝐺 Γ⊢𝐴∨𝐵 Γ⊢𝐴∨𝐵 • We eliminate cut rule first.
  • 10. Cut elimination • 1. Prove these rule by induction on proof structure. Γ⊢𝐺 Δ,Δ,Γ⊢𝐺 • 𝑤𝑒𝑎𝑘𝐺 𝑐𝑜𝑛𝑡𝑟𝐺 Δ,Γ⊢𝐺 Δ,Γ⊢𝐺 Γ⊢⊥ • ⊥ 𝑅𝐸 Γ⊢𝐺 Γ⊢𝐴∧𝐵 Γ⊢𝐴∧𝐵 • ∧ 𝑅𝐸1 ∧ 𝑅𝐸2 Γ⊢𝐴 Γ⊢𝐵 Γ⊢𝐴→𝐵 • → 𝑅𝐸 𝐴,Γ⊢𝐵 Γ1 ⊢𝐴 𝐴,Δ1 ⊢𝐺1 Γ2 ⊢𝐵 𝐵,Δ2 ⊢𝐺2 • If (𝑐𝑢𝑡 𝐴 ) and (𝑐𝑢𝑡 𝐵 ) for all Γ1 ,Δ1 ⊢𝐺1 Γ2 ,Δ2 ⊢𝐺2 Γ⊢𝐴∨𝐵 A,Δ⊢𝐺 𝐵,Δ⊢𝐺 Γ1 , Γ2 , Δ1 , Δ2 , 𝐺1 , 𝐺2 , then (∨ 𝑅𝐸 ) Γ,Δ⊢𝐺
  • 11. Cut elimination • 2. Prove the general cut rule Γ ⊢ 𝐴 𝐴 𝑛 , Δ ⊢ 𝐺 𝑐𝑢𝑡𝐺 Γ, Δ ⊢ 𝐺 by induction on the size of 𝐴 and proof structure of the right hand. • 3. specialize 𝑐𝑢𝑡𝐺 (n = 1) ■
  • 12. Cut-free LJ Γ⊢𝐺 𝐴,𝐴,Γ⊢𝐺 • 𝑤𝑒𝑎𝑘 𝑐𝑜𝑛𝑡𝑟 𝐴,Γ⊢𝐺 𝐴,Γ⊢𝐺 • 𝑎𝑥𝑖𝑜𝑚 (𝑒𝑥𝑓𝑎𝑙𝑠𝑜) 𝐴⊢𝐴 ⊥⊢𝐺 Γ⊢𝐴 𝐵,Γ⊢𝐺 𝐴,Γ⊢𝐵 • →𝐿 (→ 𝑅 ) 𝐴→𝐵,Γ⊢𝐺 Γ⊢𝐴→𝐵 𝐴,𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∧𝐿 (∧ 𝑅 ) 𝐴∧𝐵,Γ⊢𝐺 Γ⊢𝐴∧𝐵 𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∨𝐿 ∨ 𝑅1 ∨ 𝑅2 𝐴∨𝐵,Γ⊢𝐺 Γ⊢𝐴∨𝐵 Γ⊢𝐴∨𝐵 •
  • 13. Cut-free LJ Γ⊢𝐺 𝐴,𝐴,Γ⊢𝐺 • 𝑤𝑒𝑎𝑘 𝑐𝑜𝑛𝑡𝑟 𝐴,Γ⊢𝐺 𝐴,Γ⊢𝐺 • 𝑎𝑥𝑖𝑜𝑚 (𝑒𝑥𝑓𝑎𝑙𝑠𝑜) 𝐴⊢𝐴 ⊥⊢𝐺 Γ⊢𝐴 𝐵,Γ⊢𝐺 𝐴,Γ⊢𝐵 • →𝐿 (→ 𝑅 ) 𝐴→𝐵,Γ⊢𝐺 Γ⊢𝐴→𝐵 𝐴,𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∧𝐿 (∧ 𝑅 ) 𝐴∧𝐵,Γ⊢𝐺 Γ⊢𝐴∧𝐵 𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∨𝐿 ∨ 𝑅1 ∨ 𝑅2 𝐴∨𝐵,Γ⊢𝐺 Γ⊢𝐴∨𝐵 Γ⊢𝐴∨𝐵 • Contraction rule is not strictly decreasing
  • 14. Contraction-free LJ • 𝑎𝑥𝑖𝑜𝑚 (𝑒𝑥𝑓𝑎𝑙𝑠𝑜) 𝐴,Γ⊢𝐴 ⊥,Γ⊢𝐺 𝐴→𝐵,Γ⊢𝐴 𝐵,Γ⊢𝐺 𝐴,Γ⊢𝐵 • →𝐿 (→ 𝑅 ) 𝐴→𝐵,Γ⊢𝐺 Γ⊢𝐴→𝐵 𝐴,𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∧𝐿 (∧ 𝑅 ) 𝐴∧𝐵,Γ⊢𝐺 Γ⊢𝐴∧𝐵 𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∨𝐿 ∨ 𝑅1 ∨ 𝑅2 𝐴∨𝐵,Γ⊢𝐺 Γ⊢𝐴∨𝐵 Γ⊢𝐴∨𝐵
  • 15. Contraction-free LJ • Implicit weak – 𝑎𝑥𝑖𝑜𝑚 (𝑒𝑥𝑓𝑎𝑙𝑠𝑜) 𝐴,Γ⊢𝐴 ⊥,Γ⊢𝐺 • Implicit contraction 𝐴→𝐵,Γ⊢𝐴 𝐵,Γ⊢𝐺 – →𝐿 𝐴→𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 – (∧ 𝑅 ) Γ⊢𝐴∧𝐵 𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺 – ∨𝐿 𝐴∨𝐵,Γ⊢𝐺
  • 16. Contraction-free LJ • Implicit weak – 𝑎𝑥𝑖𝑜𝑚 (𝑒𝑥𝑓𝑎𝑙𝑠𝑜) 𝐴,Γ⊢𝐴 ⊥,Γ⊢𝐺 • Implicit contraction 𝐴→𝐵,Γ⊢𝐴 𝐵,Γ⊢𝐺 – →𝐿 𝐴→𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 – (∧ 𝑅 ) Γ⊢𝐴∧𝐵 𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺 – ∨𝐿 𝐴∨𝐵,Γ⊢𝐺
  • 17. Proof of weak rule • Easily done by induction ■
  • 18. Proof of contr rule • 1. prove these rules by induction on proof structure. 𝐴∧𝐵,Γ⊢𝐺 𝐴∨𝐵,Γ⊢𝐺 𝐴∨𝐵,Γ⊢𝐺 – ∧ 𝐿𝐸 ∨ 𝐿𝐸1 (∨ 𝐿𝐸2 ) 𝐴,𝐵,Γ⊢𝐺 𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺 𝐴→𝐵,Γ⊢𝐺 – (→ 𝑤𝑒𝑎𝑘 ) 𝐵,Γ⊢𝐺 • 2. prove contr rule by induction on proof structure.■
  • 19. Contraction-free LJ • 𝑎𝑥𝑖𝑜𝑚 (𝑒𝑥𝑓𝑎𝑙𝑠𝑜) 𝐴,Γ⊢𝐴 ⊥,Γ⊢𝐺 𝐴→𝐵,Γ⊢𝐴 𝐵,Γ⊢𝐺 𝐴,Γ⊢𝐵 • →𝐿 (→ 𝑅 ) 𝐴→𝐵,Γ⊢𝐺 Γ⊢𝐴→𝐵 𝐴,𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∧𝐿 (∧ 𝑅 ) 𝐴∧𝐵,Γ⊢𝐺 Γ⊢𝐴∧𝐵 𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∨𝐿 ∨ 𝑅1 ∨ 𝑅2 𝐴∨𝐵,Γ⊢𝐺 Γ⊢𝐴∨𝐵 Γ⊢𝐴∨𝐵
  • 20. Contraction-free LJ • 𝑎𝑥𝑖𝑜𝑚 (𝑒𝑥𝑓𝑎𝑙𝑠𝑜) 𝐴,Γ⊢𝐴 ⊥,Γ⊢𝐺 𝐴→𝐵,Γ⊢𝐴 𝐵,Γ⊢𝐺 𝐴,Γ⊢𝐵 • →𝐿 (→ 𝑅 ) 𝐴→𝐵,Γ⊢𝐺 Γ⊢𝐴→𝐵 𝐴,𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∧𝐿 (∧ 𝑅 ) 𝐴∧𝐵,Γ⊢𝐺 Γ⊢𝐴∧𝐵 𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∨𝐿 ∨ 𝑅1 ∨ 𝑅2 𝐴∨𝐵,Γ⊢𝐺 Γ⊢𝐴∨𝐵 Γ⊢𝐴∨𝐵 • This time, → 𝐿 rule is not decreasing
  • 21. Terminating LJ 𝐴→𝐵,Γ⊢𝐴 𝐵,Γ⊢𝐺 • Split →𝐿 into 4 pieces 𝐴→𝐵,Γ⊢𝐺 𝐶,𝐴𝑡𝑜𝑚 𝑛 ,Γ⊢𝐺 1. → 𝐿1 𝐴𝑡𝑜𝑚 𝑛 →𝐶,𝐴𝑡𝑜𝑚 𝑛 ,Γ⊢𝐺 𝐵→𝐶,Γ⊢𝐴→𝐵 C,Γ⊢𝐺 2. (→ 𝐿2 ) 𝐴→𝐵 →𝐶,Γ⊢𝐺 𝐴→ 𝐵→𝐶 ,Γ⊢𝐺 3. (→ 𝐿3 ) 𝐴∧𝐵 →𝐶,Γ⊢𝐺 𝐴→𝐶,𝐵→𝐶,Γ⊢𝐺 4. (→ 𝐿4 ) 𝐴∨𝐵 →𝐶,Γ⊢𝐺
  • 22. Correctness of Terminating LJ • 1. If Γ ⊢ 𝐺 is provable in Contraction-free LJ, At least one of these is true: – Γ includes ⊥, 𝐴 ∧ 𝐵, or 𝐴 ∨ 𝐵 – Γ includes both 𝐴𝑡𝑜𝑚(𝑛) and 𝐴𝑡𝑜𝑚 𝑛 → 𝐵 – Γ ⊢ 𝐺 has a proof whose bottommost rule is not the form of 𝐴𝑡𝑜𝑚 𝑛 →𝐵,𝐴𝑡𝑜𝑚 𝑛 ,Γ⊢𝐴𝑡𝑜𝑚 𝑛 𝐵,𝐴𝑡𝑜𝑚 𝑛 ,Γ⊢𝐺 (→ 𝐿 ) 𝐴𝑡𝑜𝑚 𝑛 →𝐵,𝐴𝑡𝑜𝑚(𝑛),Γ⊢𝐺 • Proof: induction on proof structure
  • 23. Correctness of Terminating LJ • 2. every sequent provable in Contraction-free LJ is also provable in Terminating LJ. • Proof: induction by size of the sequent. – Size: we will introduce later
  • 24. Terminating LJ • 𝑎𝑥𝑖𝑜𝑚 (𝑒𝑥𝑓𝑎𝑙𝑠𝑜) 𝐴,Γ⊢𝐴 ⊥,Γ⊢𝐺 𝐶,𝐴𝑡𝑜𝑚 𝑛 ,Γ⊢𝐺 𝐵→𝐶,Γ⊢𝐴→𝐵 C,Γ⊢𝐺 • → 𝐿1 → 𝐿2 𝐴𝑡𝑜𝑚 𝑛 →𝐶,𝐴𝑡𝑜𝑚 𝑛 ,Γ⊢𝐺 𝐴→𝐵 →𝐶,Γ⊢𝐺 𝐴→ 𝐵→𝐶 ,Γ⊢𝐺 𝐴→𝐶,𝐵→𝐶,Γ⊢𝐺 • → 𝐿3 → 𝐿4 𝐴∧𝐵 →𝐶,Γ⊢𝐺 𝐴∨𝐵 →𝐶,Γ⊢𝐺 𝐴,Γ⊢𝐵 𝐴,𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • →𝑅 ∧𝐿 (∧ 𝑅 ) Γ⊢𝐴→𝐵 𝐴∧𝐵,Γ⊢𝐺 Γ⊢𝐴∧𝐵 𝐴,Γ⊢𝐺 𝐵,Γ⊢𝐺 Γ⊢𝐴 Γ⊢𝐵 • ∨𝐿 ∨ 𝑅1 ∨ 𝑅2 𝐴∨𝐵,Γ⊢𝐺 Γ⊢𝐴∨𝐵 Γ⊢𝐴∨𝐵
  • 25. Proof of termination • Weight of Proposition – 𝑤 𝐴𝑡𝑜𝑚 𝑛 = 1 – 𝑤 ⊥ =1 – 𝑤 𝐴 → 𝐵 = 𝑤 𝐴 + 𝑤 𝐵 +1 – 𝑤 𝐴∧ 𝐵 = 𝑤 𝐴 + 𝑤 𝐵 +2 – 𝑤 𝐴∨ 𝐵 = 𝑤 𝐴 + 𝑤 𝐵 +1 • 𝐴 < 𝐵 ⇔ 𝑤 𝐴 < 𝑤(𝐵)
  • 26. Proof of termination • ordering of Proposition List – Use Multiset ordering (Dershowitz and Manna ordering)
  • 27. Multiset Ordering • Multiset Ordering: a binary relation between multisets (not necessarily be ordering) • 𝐴> 𝐵⇔ Not empty A B
  • 28. Multiset Ordering • If 𝑅 is a well-founded binary relation, the Multiset Ordering over 𝑅 is also well-founded. • Well-founded: every element is accessible • 𝐴 is accessible : every element 𝐵 such that 𝐵 < 𝐴 is accessible
  • 29. Multiset Ordering Proof • 1. induction on list • Nil ⇒ there is no 𝐴 such that 𝐴 < 𝑀 Nil, therefore it’s accessible. • We will prove: 𝐴𝑐𝑐 𝑀 𝐿 ⇒ 𝐴𝑐𝑐 𝑀 (𝑥 ∷ 𝐿)
  • 30. Multiset Ordering • 2. duplicate assumption • Using 𝐴𝑐𝑐(𝑥) and 𝐴𝑐𝑐 𝑀 (𝐿), we will prove 𝐴𝑐𝑐 𝑀 𝐿 ⇒ 𝐴𝑐𝑐 𝑀 (𝑥 ∷ 𝐿) • 3. induction on 𝑥 and 𝐿 – We can use these two inductive hypotheses. 1. ∀𝐾 𝑦, 𝑦 < 𝑥 ⇒ 𝐴𝑐𝑐 𝑀 𝐾 ⇒ 𝐴𝑐𝑐 𝑀 (𝑦 ∷ 𝐾) 2. ∀𝐾, 𝐾 < 𝑀 𝐿 ⇒ 𝐴𝑐𝑐 𝑀 𝐾 ⇒ 𝐴𝑐𝑐 𝑀 (𝑥 ∷ 𝐾)
  • 31. Multiset Ordering • 4. Case Analysis • By definition, 𝐴𝑐𝑐 𝑀 (𝑥 ∷ 𝐿) is equivalent to ∀𝐾, 𝐾 < 𝑀 (𝑥 ∷ 𝐿) ⇒ 𝐴𝑐𝑐 𝑀 (𝐾) • And there are 3 patterns: 1. 𝐾 includes 𝑥 2. 𝐾 includes 𝑦s s.t. 𝑦 < 𝑥, and 𝐾 minus all such 𝑦 is equal to 𝐿 3. 𝐾 includes 𝑦s s.t. 𝑦 < 𝑥, and 𝐾 minus all such 𝑦 is less than 𝐿 • Each pattern is proved using the Inductive Hypotheses.
  • 32. Decidability • Now, decidability can be proved by induction on the size of sequent.
  • 34. IPC Proposition (Coq) Inductive PProp:Set := • | PPbot : PProp | PPatom : nat -> PProp | PPimpl : PProp -> PProp -> PProp | PPconj : PProp -> PProp -> PProp | PPdisj : PProp -> PProp -> PProp.
  • 35. Cut-free LJ (Coq) Inductive LJ_provable : list PProp -> PProp -> Prop := • | LJ_perm P1 L1 L2 : Permutation L1 L2 -> LJ_provable L1 P1 -> LJ_provable L2 P1 | LJ_weak P1 P2 L1 : LJ_provable L1 P2 -> LJ_provable (P1::L1) P2 | LJ_contr P1 P2 L1 : LJ_provable (P1::P1::L1) P2 -> LJ_provable (P1::L1) P2 …
  • 36. Exchange rule • Exchange rule : Γ, 𝐴, 𝐵, Δ ⊢ 𝐺 𝑒𝑥𝑐ℎ Γ, 𝐵, 𝐴, Δ ⊢ 𝐺 is replaced by more useful Γ⊢ 𝐺 ′ ⊢ 𝐺 𝑝𝑒𝑟𝑚𝑢𝑡𝑎𝑡𝑖𝑜𝑛 Γ where Γ, Γ′ are permutation
  • 37. Permutation Compatibility (Coq) Instance LJ_provable_compat : Proper (@Permutation _==>eq==>iff) LJ_provable. • Allows rewriting over Permutation equality
  • 38. Permutation solver (Coq) • Permutation should be solved automatically Ltac perm := match goal with …
  • 40. Further implementation plan • Refactoring (1) : improve Permutation- associated tactics – A smarter auto-unifying tactics is needed – Write tactics using Objective Caml • Refactoring (2) : use Ssreflect tacticals – This makes the proof more manageable
  • 41. Further implementation plan • Refactoring (3) : change proof order – Contraction first, cut next – It will make the proof shorter • Refactoring (4) : discard Multiset Ordering – If we choose appropriate weight function of Propositional Formula, we don’t need Multiset Ordering. (See [Hudelmaier]) – It also enables us to analyze complexity of this procedure
  • 42. Further implementation plan • Refactoring (5) : Proof of completeness – Now completeness theorem depends on the decidability • New Theorem (1) : Other Syntaxes – NJ and HJ may be introduced • New Theorem (2) : Other Semantics – Heyting Algebra
  • 43. Further implementation plan • New Theorem (3) : Other decision procedure – Decision procedure using semantics (if any) – More efficient decision procedure (especially 𝑂(𝑁 log 𝑁)-space decision procedure) • New Theorem (4) : Complexity – Proof of PSPACE-completeness
  • 44. Source code • Source codes are: • https://github.com/qnighy/IPC-Coq
  • 45. おわり 1. Task & Known results 2. Brief methodology of the proof 1. Cut elimination 2. Contraction elimination 3. → 𝐿 elimination 4. Proof of strictly-decreasingness 3. Implementation detail 4. Further implementation plan
  • 46. References • [Dyckhoff] Roy Dyckhoff, Contraction-free Sequent Calculi for Intuitionistic Logic, The Journal of Symbolic Logic, Vol. 57, No.3, 1992, pp. 795 – 807 • [Statman] Richard Statman, Intuitionistic Propositional Logic is Polynomial-Space Complete, Theoretical Computer Science 9, 1979, pp. 67 – 72 • [Hudelmaier] Jörg Hudelmaier, An O(n log n)-Space Decision Procedure for Intuitionistic Propositional Logic, Journal of Logic and Computation, Vol. 3, Issue 1, pp. 63-75