Intuitionistic.Sequent: the sequent calculus for ILL
- Γ ⊢ C is the full calculus, which includes cut;
- Γ ⊢cf C is the cut-free calculus.
Reserved Notation "Γ ⊢[ c ] A" (at level 80, c at level 0, no associativity, format "Γ ⊢[ c ] A").
The rules
- ax uses exactly one hypothesis, with nothing left over.
- Multiplicative rules with two premises (tensorR, lolliL, cut) split the context Γ ++ Δ between the premises. Each resource goes to exactly one of them.
- Additive rules with two premises (withR, plusL) copy the context into both premises. This is fine because only one premise will ever "run".
- topR consumes any context, and zeroL proves anything.
- ⊥ has no rules. It behaves like an atom that every model must interpret somehow.
- The four ! rules are the only place where structural reasoning
comes back:
- bangR (promotion): !A can be built only if every hypothesis is banged (‼Σ). A reusable proof may use only reusable resources;
- bangD (dereliction): take one copy of A out of !A;
- bangW (weakening): a !A may be thrown away;
- bangC (contraction): a !A may be duplicated.
------ ax Γ ⊢ A A,Δ ⊢ C Γ ⊢ C Γ ≡ₚ Γ'
A ⊢ A ------------------ cut ---------------- ex
Γ,Δ ⊢ C Γ' ⊢ C
----- 𝟙R Γ ⊢ C
⊢ 𝟙 ------------ 𝟙L
𝟙,Γ ⊢ C
Γ ⊢ A Δ ⊢ B A,B,Γ ⊢ C A,Γ ⊢ B
-------------- ⊗R ------------ ⊗L ------------ ⊸R
Γ,Δ ⊢ A ⊗ B A⊗B,Γ ⊢ C Γ ⊢ A ⊸ B
Γ ⊢ A B,Δ ⊢ C Γ ⊢ A Γ ⊢ B A,Γ ⊢ C B,Γ ⊢ C
---------------- ⊸L -------------- &R ------------ &L₁ ------------ &L₂
A⊸B,Γ,Δ ⊢ C Γ ⊢ A & B A&B,Γ ⊢ C A&B,Γ ⊢ C
------- ⊤R Γ ⊢ A Γ ⊢ B A,Γ ⊢ C B,Γ ⊢ C
Γ ⊢ ⊤ ----------- ⊕R₁ ----------- ⊕R₂ ------------------ ⊕L
Γ ⊢ A ⊕ B Γ ⊢ A ⊕ B A⊕B,Γ ⊢ C
---------- 𝟘L ‼Σ ⊢ A A,Γ ⊢ C Γ ⊢ C !A,!A,Γ ⊢ C
𝟘,Γ ⊢ C -------- !R ---------- !D ---------- !W ------------ !C
‼Σ ⊢ !A !A,Γ ⊢ C !A,Γ ⊢ C !A,Γ ⊢ C
Inductive ill (c : bool) : list iformula -> iformula -> Prop := (* identity and cut *) | ax A : [A] ⊢[c] A | cut Γ Δ A C : c = true -> Γ ⊢[c] A -> A :: Δ ⊢[c] C -> Γ ++ Δ ⊢[c] C (* structure: only exchange is unrestricted *) | ex Γ Γ' C : Γ ≡ₚ Γ' -> Γ ⊢[c] C -> Γ' ⊢[c] C (* multiplicatives *) | oneR : [] ⊢[c] 𝟙 | oneL Γ C : Γ ⊢[c] C -> 𝟙 :: Γ ⊢[c] C | tensorR Γ Δ A B : Γ ⊢[c] A -> Δ ⊢[c] B -> Γ ++ Δ ⊢[c] A ⊗ B | tensorL Γ A B C : A :: B :: Γ ⊢[c] C -> A ⊗ B :: Γ ⊢[c] C | lolliR Γ A B : A :: Γ ⊢[c] B -> Γ ⊢[c] A ⊸ B | lolliL Γ Δ A B C : Γ ⊢[c] A -> B :: Δ ⊢[c] C -> A ⊸ B :: Γ ++ Δ ⊢[c] C (* additives *) | withR Γ A B : Γ ⊢[c] A -> Γ ⊢[c] B -> Γ ⊢[c] A & B | withL1 Γ A B C : A :: Γ ⊢[c] C -> A & B :: Γ ⊢[c] C | withL2 Γ A B C : B :: Γ ⊢[c] C -> A & B :: Γ ⊢[c] C | topR Γ : Γ ⊢[c] ⊤ | plusR1 Γ A B : Γ ⊢[c] A -> Γ ⊢[c] A ⊕ B | plusR2 Γ A B : Γ ⊢[c] B -> Γ ⊢[c] A ⊕ B | plusL Γ A B C : A :: Γ ⊢[c] C -> B :: Γ ⊢[c] C -> A ⊕ B :: Γ ⊢[c] C | zeroL Γ C : 𝟘 :: Γ ⊢[c] C (* exponentials *) | bangR Σ A : ‼Σ ⊢[c] A -> ‼Σ ⊢[c] !A | bangD Γ A C : A :: Γ ⊢[c] C -> !A :: Γ ⊢[c] C | bangW Γ A C : Γ ⊢[c] C -> !A :: Γ ⊢[c] C | bangC Γ A C : !A :: !A :: Γ ⊢[c] C -> !A :: Γ ⊢[c] C where "Γ ⊢[ c ] A" := (ill c Γ A) : ill_scope. Notation "Γ ⊢ A" := (ill true Γ A) (at level 80, no associativity) : ill_scope. Notation "Γ ⊢cf A" := (ill false Γ A) (at level 80, no associativity) : ill_scope.
cut is the only rule that mentions c. In the cut-free calculus its
side condition false = true can never be met. So every cut-free proof
is also a proof, with or without cut.
c: bool
Γ: list iformula
A: iformulaΓ ⊢cf A → Γ ⊢[c] A(* [discriminate] refutes the cut case. Every other rule is re-applied to the induction hypotheses; [eauto using ill] finds the matching constructor. *) induction 1; try discriminate; eauto using ill. Qed.c: bool
Γ: list iformula
A: iformulaΓ ⊢cf A → Γ ⊢[c] A
Exchange, conveniently
c: bool
Γ, Γ': list iformula
C: iformulaΓ ⊢[c] C → Γ ≡ₚ Γ' → Γ' ⊢[c] Cintros; eapply ex; eauto. Qed. Ltac ex_to G := apply (ex' (Γ := G)); [| solve_Permutation].c: bool
Γ, Γ': list iformula
C: iformulaΓ ⊢[c] C → Γ ≡ₚ Γ' → Γ' ⊢[c] C
Structural rules for banged contexts
Any number of !-formulas can be thrown away.
c: bool
Σ, Γ: list iformula
C: iformulaΓ ⊢[c] C → ‼Σ ++ Γ ⊢[c] Cinduction Σ; simpl; auto using bangW. Qed.c: bool
Σ, Γ: list iformula
C: iformulaΓ ⊢[c] C → ‼Σ ++ Γ ⊢[c] C
Two copies of a banged context can be contracted to one.
c: bool
Σ, Γ: list iformula
C: iformula‼Σ ++ ‼Σ ++ Γ ⊢[c] C → ‼Σ ++ Γ ⊢[c] Cc: bool
Σ, Γ: list iformula
C: iformula‼Σ ++ ‼Σ ++ Γ ⊢[c] C → ‼Σ ++ Γ ⊢[c] Cc: bool
Σ: list iformula
C: iformula∀ Γ : list iformula, ‼Σ ++ ‼Σ ++ Γ ⊢[c] C → ‼Σ ++ Γ ⊢[c] Cc: bool
A: iformula
Σ: list iformula
C: iformula
IH: ∀ Γ : list iformula, ‼Σ ++ ‼Σ ++ Γ ⊢[c] C → ‼Σ ++ Γ ⊢[c] C
Γ: list iformula
H: ‼(A :: Σ) ++ ‼(A :: Σ) ++ Γ ⊢[c] C‼(A :: Σ) ++ Γ ⊢[c] C(* park [!A] in [Γ] and use [IH] on [‼Σ]; then contract the two [!A]s and rearrange into [H] *)c: bool
A: iformula
Σ: list iformula
C: iformula
IH: ∀ Γ : list iformula, ‼Σ ++ ‼Σ ++ Γ ⊢[c] C → ‼Σ ++ Γ ⊢[c] C
Γ: list iformula
H: !A :: ‼Σ ++ !A :: ‼Σ ++ Γ ⊢[c] C!A :: ‼Σ ++ Γ ⊢[c] Cc: bool
A: iformula
Σ: list iformula
C: iformula
IH: ∀ Γ : list iformula, ‼Σ ++ ‼Σ ++ Γ ⊢[c] C → ‼Σ ++ Γ ⊢[c] C
Γ: list iformula
H: !A :: ‼Σ ++ !A :: ‼Σ ++ Γ ⊢[c] C‼Σ ++ !A :: Γ ⊢[c] Cc: bool
A: iformula
Σ: list iformula
C: iformula
IH: ∀ Γ : list iformula, ‼Σ ++ ‼Σ ++ Γ ⊢[c] C → ‼Σ ++ Γ ⊢[c] C
Γ: list iformula
H: !A :: ‼Σ ++ !A :: ‼Σ ++ Γ ⊢[c] C‼Σ ++ ‼Σ ++ !A :: Γ ⊢[c] Cc: bool
A: iformula
Σ: list iformula
C: iformula
IH: ∀ Γ : list iformula, ‼Σ ++ ‼Σ ++ Γ ⊢[c] C → ‼Σ ++ Γ ⊢[c] C
Γ: list iformula
H: !A :: ‼Σ ++ !A :: ‼Σ ++ Γ ⊢[c] C!A :: ‼Σ ++ ‼Σ ++ Γ ⊢[c] Cc: bool
A: iformula
Σ: list iformula
C: iformula
IH: ∀ Γ : list iformula, ‼Σ ++ ‼Σ ++ Γ ⊢[c] C → ‼Σ ++ Γ ⊢[c] C
Γ: list iformula
H: !A :: ‼Σ ++ !A :: ‼Σ ++ Γ ⊢[c] C!A :: !A :: ‼Σ ++ ‼Σ ++ Γ ⊢[c] Cexact H. Qed.c: bool
A: iformula
Σ: list iformula
C: iformula
IH: ∀ Γ : list iformula, ‼Σ ++ ‼Σ ++ Γ ⊢[c] C → ‼Σ ++ Γ ⊢[c] C
Γ: list iformula
H: !A :: ‼Σ ++ !A :: ‼Σ ++ Γ ⊢[c] C!A :: ‼Σ ++ !A :: ‼Σ ++ Γ ⊢[c] C
A derived rule
c: bool
A, B: iformula[A ⊸ B; A] ⊢[c] Bapply (lolliL _ [A] []); apply ax. Qed.c: bool
A, B: iformula[A ⊸ B; A] ⊢[c] B
Examples
Section Examples. Variables A B C : iformula.
⊗ is commutative.
A, B, C: iformula[A ⊗ B] ⊢cf B ⊗ AA, B, C: iformula[A ⊗ B] ⊢cf B ⊗ A(* [A; B] ⊢ B ⊗ A: split the context as [B] ++ [A] *)A, B, C: iformula[A; B] ⊢cf B ⊗ Aapply tensorR; apply ax. Qed.A, B, C: iformula[B] ++ [A] ⊢cf B ⊗ A
Currying: ⊗ is left adjoint to ⊸.
A, B, C: iformula[A ⊗ B ⊸ C] ⊢cf A ⊸ B ⊸ CA, B, C: iformula[A ⊗ B ⊸ C] ⊢cf A ⊸ B ⊸ CA, B, C: iformula[B; A; A ⊗ B ⊸ C] ⊢cf Capply lolliL; [apply tensorR |]; apply ax. Qed.A, B, C: iformulaA ⊗ B ⊸ C :: ([A] ++ [B]) ++ [] ⊢cf C
The coffee machine: one euro, your choice of drink. Under withR
both branches receive the same context, so the single euro is
"shared" by the two branches. Only one branch will ever run.
The machine is offered as a choice (euro ⊸ coffee) & (euro ⊸
tea). Two separate machines euro ⊸ coffee; euro ⊸ tea would not
work: each branch would have a machine left over, and nothing can
discard it.
A, B, C, euro, coffee, tea: iformula[(euro ⊸ coffee) & (euro ⊸ tea); euro] ⊢cf coffee & teaapply withR; [apply withL1 | apply withL2]; apply lolli_mp. Qed.A, B, C, euro, coffee, tea: iformula[(euro ⊸ coffee) & (euro ⊸ tea); euro] ⊢cf coffee & tea
!A can be duplicated: the controlled form of contraction.
A, B, C: iformula[!A] ⊢cf !A ⊗ !AA, B, C: iformula[!A] ⊢cf !A ⊗ !AA, B, C: iformula[!A; !A] ⊢cf !A ⊗ !Aapply tensorR; apply ax. Qed.A, B, C: iformula[!A] ++ [!A] ⊢cf !A ⊗ !A
!A can be thrown away: the controlled form of weakening.
A, B, C: iformula[!A; B] ⊢cf Bapply bangW, ax. Qed.A, B, C: iformula[!A; B] ⊢cf B
The exponential isomorphism !(A & B) ⊣⊢ !A ⊗ !B turns additive
structure into multiplicative structure.
A, B, C: iformula[!(A & B)] ⊢cf !A ⊗ !BA, B, C: iformula[!(A & B)] ⊢cf !A ⊗ !BA, B, C: iformula[!(A & B); !(A & B)] ⊢cf !A ⊗ !B(* promotion: the context [!(A & B)] is ‼[A & B] *) apply tensorR; apply (bangR _ [A & B]), bangD; [apply withL1 | apply withL2]; apply ax. Qed.A, B, C: iformula[!(A & B)] ++ [!(A & B)] ⊢cf !A ⊗ !BA, B, C: iformula[!A ⊗ !B] ⊢cf !(A & B)A, B, C: iformula[!A ⊗ !B] ⊢cf !(A & B)A, B, C: iformula[!A; !B] ⊢cf !(A & B)A, B, C: iformula‼[A; B] ⊢cf A & BA, B, C: iformula[!A; !B] ⊢cf A & BA, B, C: iformula[!A; !B] ⊢cf AA, B, C: iformula[!A; !B] ⊢cf BA, B, C: iformula[!A; !B] ⊢cf AA, B, C: iformula[A; !B] ⊢cf Aapply bangW, ax.A, B, C: iformula[!B; A] ⊢cf Aapply bangW, bangD, ax. Qed.A, B, C: iformula[!A; !B] ⊢cf B
Double-negation introduction holds. Its converse ∼∼A ⊢ A does
not; see Comparison.v.
A, B, C: iformula[A] ⊢cf ∼∼Aapply lolliR, lolli_mp. Qed.A, B, C: iformula[A] ⊢cf ∼∼A
A use of cut: chaining two linear implications.
Intuitionistic/CutElim.v shows the cut could be avoided.
A, B, C: iformula[A ⊸ B; B ⊸ C; A] ⊢ CA, B, C: iformula[A ⊸ B; B ⊸ C; A] ⊢ CA, B, C: iformula[A ⊸ B; A] ++ [B ⊸ C] ⊢ CA, B, C: iformula[B; B ⊸ C] ⊢ Capply lolli_mp. Qed. End Examples.A, B, C: iformula[B ⊸ C; B] ⊢ C