23
Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September 15, 2010 Contents 1 Starting Slate 1 1.1 Putting Formulae in the Workspace .......................... 2 1.2 Removing Formulae from the Workspace ...................... 2 1.3 Connecting Formulae .................................... 4 1.4 The Appearance of Formulae ............................... 4 1.4.1 Formula Identifiers ................................ 4 1.4.2 Rule Correctness Indicators .......................... 6 1.4.3 Justification and Link Color .......................... 6 1.4.4 Formula Assumptions .............................. 7 1.4.5 Improper Conclusions .............................. 7 2 Summary of Proof Systems 7 2.1 Propositional Calculus ................................... 8 2.1.1 Assume ......................................... 8 2.1.2 Conjunction Introduction ............................ 8 2.1.3 Conjunction Elimination ............................ 8 2.1.4 Disjunction Introduction ............................ 9 2.1.5 Disjunction Elimination ............................. 9 2.1.6 Conditional Introduction ............................ 10 2.1.7 Conditional Elimination ............................. 10 2.1.8 Biconditional Introduction ........................... 10 2.1.9 Biconditional Elimination ........................... 10 2.1.10 Negation Introduction .............................. 11 2.1.11 Negation Elimination ............................... 11 2.1.12 Substitution ..................................... 12 2.1.13 PC and PC | = ................................... 12 2.2 Non-Quantified Predicate Calculus .......................... 12 2.2.1 = Introduction .................................... 13 2.2.2 = Elimination .................................... 13 2.2.3 Substitution ..................................... 13 2.2.4 FOL .......................................... 14 2.3 First-Order Logic ....................................... 14

Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

  • Upload
    others

  • View
    0

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

Getting Started With Slate

Joshua Taylor Selmer Bringsjord Micah Clark

September 15, 2010

Contents

1 Starting Slate 11.1 Putting Formulae in the Workspace . . . . . . . . . . . . . . . . . . . . . . . . . . 21.2 Removing Formulae from the Workspace . . . . . . . . . . . . . . . . . . . . . . 21.3 Connecting Formulae . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41.4 The Appearance of Formulae . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

1.4.1 Formula Identifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41.4.2 Rule Correctness Indicators . . . . . . . . . . . . . . . . . . . . . . . . . . 61.4.3 Justification and Link Color . . . . . . . . . . . . . . . . . . . . . . . . . . 61.4.4 Formula Assumptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71.4.5 Improper Conclusions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7

2 Summary of Proof Systems 72.1 Propositional Calculus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8

2.1.1 Assume . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82.1.2 Conjunction Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82.1.3 Conjunction Elimination . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82.1.4 Disjunction Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92.1.5 Disjunction Elimination . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92.1.6 Conditional Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102.1.7 Conditional Elimination . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102.1.8 Biconditional Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . 102.1.9 Biconditional Elimination . . . . . . . . . . . . . . . . . . . . . . . . . . . 102.1.10 Negation Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 112.1.11 Negation Elimination . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 112.1.12 Substitution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 122.1.13 PC ` and PC |= . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12

2.2 Non-Quantified Predicate Calculus . . . . . . . . . . . . . . . . . . . . . . . . . . 122.2.1 = Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 132.2.2 = Elimination . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 132.2.3 Substitution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 132.2.4 FOL ` . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14

2.3 First-Order Logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14

Page 2: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

2.3.0.1 Universal Introduction . . . . . . . . . . . . . . . . . . . . . . . 142.3.0.2 Universal Elimination . . . . . . . . . . . . . . . . . . . . . . . . 142.3.0.3 Existential Introduction . . . . . . . . . . . . . . . . . . . . . . 142.3.0.4 Existential Elimination . . . . . . . . . . . . . . . . . . . . . . . 14

2.4 Modal Logics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152.4.1 Necessity Counting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152.4.2 Modal Rules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

2.4.2.1 Necessity Introduction . . . . . . . . . . . . . . . . . . . . . . . 172.4.2.2 Necessity Elimination . . . . . . . . . . . . . . . . . . . . . . . . 172.4.2.3 Possibility Introduction . . . . . . . . . . . . . . . . . . . . . . . 172.4.2.4 Possibility Elimination . . . . . . . . . . . . . . . . . . . . . . . 172.4.2.5 Modal Dualities . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

2.4.3 Modal Proof Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 182.4.3.1 T . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 182.4.3.2 K . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 182.4.3.3 S4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 182.4.3.4 S5 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19

ii

Page 3: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

Figure 1: The New Workspace prompt.

Figure 2: A blank Slate.

1 Starting Slate

When Slate is launched, you will be presented with a prompt in which you can choosea proof system for a new workspace or choose to open an existing workspace file.This prompt is shown in Fig. 1.

In this primer, we will begin with a workspace using the propositional calculus,so select Propositional Calculus at the prompt, and press OK. Slate will open an emptyworkspace, a blank slate1 in which arguments will constructed. The workspace willeventually contain logical and meta-logical objects (formulae, proofs, models, &c.)and links between them (premise citations, &c.).

1We stopped apologizing for this pun long ago.

1

Page 4: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

1.1 Putting Formulae in the Workspace

Although Slate’s workspace can hold a number of different kind of things, formulaeare the most important of these, and will be present almost every time Slate is used.To add a formulae to Slate, right-click2 anywhere in the workspace and select NewFormula, or select New Formula from the Edit menu.

A dialog will appear, and ask you to complete enough information to place aformulae on the workspace. The Formula field must be filled in with text conformingto Slate’s input syntax, a parenthesized, prefix syntax for formulae. This syntax issummarized in Table 1. The whole process is shown in Fig. 3. If you know in advancewhat rule will be used to justify the formula, it can be selected now, but the rule canalso be changed later, so it’s not all that important what rule is selected now.

Terms Standard Syntax Slate Syntax

Variables and Constants x , y , z , . . . , a, b, c, . . . x, y, z, . . . , a, b, c, . . .Compound Terms f(. . . ) (f ...)

Formulae Standard Syntax Slate Syntax

Propositional Variables P, Q, R, . . . P, Q, R, . . .Atomic Formula R(. . . ) (R ...)

Equation τ1 = · · ·=τn (= τ1 ...τn)

Negation ¬φ (not φ)Conjunction φ1 ∧ . . .∧φn (and φ1 ... φn)

Disjunction φ1 ∨ . . .∨φn (or φ1 ... φn)

Conditional φ→ψ (if φ ψ)Biconditional φ↔ψ (iff φ ψ)Universal ∀x φ (forall x φ)Existential ∃x φ (exists x φ)Necessity �φ (nec φ)Possibility ◊φ (pos φ)

Table 1: Slate’s input syntax.

1.2 Removing Formulae from the Workspace

Formulae can be removed from the workspace by right clicking and selecting Delete

Formula, as shown in Fig. 4, or by selecting the proposition and selecting Delete

Formula from the Edit menu. Multiple formulae may be deleted at once in the samemanner. In addition, keyboard shortcuts are defined for quickly deleting formulaefrom the workspace.

2On OS X with a single button mouse, click while holding Control.

2

Page 5: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

Figure 3: Adding a formula to the workspace by right-clicking on the workspace,selecting New Formula, and entering a formula in Slate’s input syntax. The OK buttonis not enabled until the input text is complete and correctly formed. The new formulaappears on the Slate workspace.

3

Page 6: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

Figure 4: Remove a formula from the workspace by selecting Delete Formula from itscontext menu.

1.3 Connecting Formulae

An argument is not simply a collection of disconnected formulae standing in no rela-tion to each other; we establish formulae by appealing to other established formulaeand well-defined rules of inference. Thus, we need to add and remove connectionsamong formulae in the workspace.

When a formula in the workspace is selected, clicking on other formulae in theworkspace while holding the Alt key3 will add the latter as a premise of the former.This process is shown in Fig. 5.

To remove a premise from a conclusion, select the conclusion formula, and clickon the conclusion to remove while holding the Alt key. This process is shown in Fig. 6.

1.4 The Appearance of Formulae

You may have noticed by now that some things in the workspace appear in different

colors, for instance, the green check marks (!) and red X’s (%) in Fig. 5, or that linesappear in different colors and thicknesses. These visual properties of formulae andargument links give valuable information about the proof structures in the workspace.We now examine formulae in the workspace in detail, referring to Fig. 7.

1.4.1 Formula Identifiers

Each formula in the workspace has an identifier which is specified in the Name fieldof the new formula prompt or, if left unspecified, is generated automatically by Slate.In Fig. 7, Slate has automatically assigned the identifier 1 to P while the name “Queue”

3Alt is also called Option on OS X.

4

Page 7: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

Figure 5: After adding the sentences P and Q to the workspace as assumptions andP∧Q, citing the∧ introduction rule, we need to connect the conclusion to its premises.We select the conclusion, P∧Q and then, holding Alt, click on the premises P and Q.

Figure 6: To remove R from the premises of P∧Q, select P∧Q and click on R whileholding the Shift key.

5

Page 8: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

Figure 7: A small argument illustrating various graphical properties of formulae inthe workspace.

has been manually specified for Q. Formulae identifiers appear in each formula’s listof in-scope assumptions. For instance, since P∧Q is in the scope of the assumptionsP and Q, its list of in-scope assumptions is {1, Queue}.

1.4.2 Rule Correctness Indicators

Each formula in the workspace is justified by some particular inference rule. If theformula has premises, then the inference rule justifying the formula appears in a boxon the link connecting the formula to its premises. If the formula has no premises,the rule appears within the formula node. To the right of the inference rule, eithera green check mark or red X appears, indicating whether the formula is correctlyjustified by the inference rule the formula’s premises. For instance, in Fig. 7, P iscorrectly justified by Assume, and P∧Q is incorrectly justified by ∧ elimination.

1.4.3 Justification and Link Color

The links in Fig. 7 appear in two thicknesses and two colors: the link connectingP∧Q to its premises is bold and black; the link connecting (P∧Q)∨R to its premiseis bold and blue; and the link connecting Q→ ((P∧Q)∨R) to its premise is thin andblack. When one or more formulae in the workspace is selected, the links of the entireargument structure supporting the selected formulae is displayed with bold links.In large argument structures this can help in tracing arguments back to their roots.When one or more formulae in the workspace is selected, the links of the selected

6

Page 9: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

Figure 8: In the modal logic K, formulae 2 and 3 may not serve as ultimate conclusionsin a proof as their necessity counts are neither 0 nor ∞. To indicate this, theseformulae are drawn with a dashed border.

formulae to their premises are drawn in blue (and are thick, since they are part of theargument structure supporting the selected formulae). This again can help in tracingconclusions back to their premises in large argument structures.

1.4.4 Formula Assumptions

Each formula is within the scope of some set of assumptions. This set of assumptionsis automatically determined by Slate, and when it is non-empty, the identifiers of thein-scope assumptions are shown within the formula’s node. For instance, formulae3 and 4 in Fig. 7 are within the scope of formulae 1 and “Queue.” In addition todisplaying the identifiers of a formula’s in-scope assumption in the formula’s node,when formulae are selected in the workspace, their assumptions are drawn with ared double-lined border. Since formula 4 is selected and its assumptions are 1 and“Queue,” the formula nodes of 1 and “Queue” are drawn with the red double-linedborders.

1.4.5 Improper Conclusions

In some proof systems, certain formulae may arise that would not be proper conclu-sions of a proof. For instance, in the modal logic K, only a formula whose necessitycount4 is 0 or∞may serve as a conclusion of proof. In Fig. 8, the formulae P andP∨Q have necessity count 1, and so cannot be the final conclusion of a K proof. Thisis indicated by their dashed border.

2 Summary of Proof Systems

Slate supports a number of proof systems each of which is characterized by thetype of formula that it accepts and by its set of inference rules. The full details ofthese proof systems are covered elsewhere, but we provide here a listing of the proofsystems that Slate supports ‘out of the box,’ and their formulae and inference rules.

4Necessity counting in modal logics is discussed elsewhere. Here it suffices to know that a necessitycount is a non-negative integer or∞.

7

Page 10: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

The input syntax for formulae is given in Table 1, and is consistent throughout theproof systems in Slate summarized here.

2.1 Propositional Calculus

The formulae of the propositional calculus are propositional variables and formulaebuilt up from them using the boolean connectives ∧, ∨,→,↔, and ¬.

The rules of the propositional calculus are Assume, introduction and eliminationrules for each of the connectives, PC `, and PC |=.

For most rules of the propositional calculus, the in-scope assumptions of theconclusion of a rule are simply the union of the in-scope assumptions of the premises.For rules where this is not the case, we use the notation Γ `P to indicate that P is inthe scope of assumptions Γ. We will use the notation Γ,Σ as shorthand for Γ∪Σ, andΓ,Q for Γ,{Q}.

2.1.1 Assume

{P} `P Assume

1. P

{1} Assume !

Figure 9: An assumption introduced by Assume.

2.1.2 Conjunction Introduction

From P1, . . . , Pn , under assumptions Γ1, . . . , Γn , respectively, P1 ∧ . . .∧Pn may beinferred under the assumptions Γ1, . . . ,Γn .

Γ1 `P1 . . . Γn `Pn

Γ1, . . . ,Γn `P1 ∧ . . .∧Pn∧ intro

2.1.3 Conjunction Elimination

From a conjunction P1 ∧ . . .Pn , any individual conjunct Pi may be inferred. Pi is inthe scope of the same assumptions that the conjunction P1 ∧ . . .∧Pn was.

P1 ∧ . . .∧Pn

Pi∧ elim

8

Page 11: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

! intro !

! elim !! elim !

3. P

{1}

4. Q ! P

{1}

1. P ! Q

{1} Assume !

2. Q

{1}

Figure 10: Conjunction introduction and elimination are used to prove Q∧P fromP∧Q.

2.1.4 Disjunction Introduction

From Pi the disjunction P1 ∨ . . .∨Pn may be inferred.

Pi

P1 ∨ . . .∨Pn∨ intro

2.1.5 Disjunction Elimination

This rule is also known as proof by cases. From a disjunction P1 ∨ . . . ∨Pn underassumptions Γ0 and n proofs of some conclusion Q from assumptions Γi ,Pi , infer Qunder the assumptions Γ0, . . . ,Γn .

Γ0 `P1 ∨ . . .∨Pn Γ1,P1 `Q . . . Γn ,Pn `QΓ0, . . . ,Γn `Q

∨ elim

! elim !

! intro !! intro !

5. Q ! P

{4}

3. Q ! P

{2}

6. Q ! P

{1}

2. P

{2} Assume !

4. Q

{4} Assume !

1. P ! Q

{1} Assume !

Figure 11: The disjunction introduction and elimination rules are used to prove Q∨Pfrom P∨Q.

9

Page 12: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

2.1.6 Conditional Introduction

From Q under the scope of assumptions Γ,P, infer P→Q under the scope of assump-tions Γ.

Γ,P `QΓ `P→Q

→ intro

2.1.7 Conditional Elimination

This rule is also known as modus ponens. From P and a conditional P→Q, infer Q.

P P→QQ

→ elim

! intro !

! intro !

! elim !

5. P ! ((P ! Q) ! Q)

4. (P ! Q) ! Q

{2}

3. Q

{1,2}

1. P ! Q

{1} Assume !

2. P

{2} Assume !

Figure 12: Conditional introduction and elimination are used in proving the theoremP→ ((P→Q)→Q).

2.1.8 Biconditional Introduction

Γ,P `Q Σ,Q `PΓ,Σ `P↔Q

↔ intro

2.1.9 Biconditional Elimination

P P↔QQ

↔ elimQ P↔Q

P↔ elim

10

Page 13: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

! intro !

! elim !! elim !

6. Q ! P

{1}

5. P

{1,4}

3. Q

{1,2}

4. Q

{4} Assume !

1. P ! Q

{1} Assume !2. P

{2} Assume !

Figure 13: Biconditional introduction and elimination rules are used to prove Q↔Pfrom P↔Q.

2.1.10 Negation Introduction

If under the assumption of some formulaφ bothψ and ¬ψ can be derived, derive¬φ from the other assumptions from whichψ and ¬ψ followed.

Γ,φ `ψ Σ,φ ` ¬ψΓ,Σ ` ¬φ ¬ intro

2.1.11 Negation Elimination

If under the assumptions of some formula ¬φ bothψ and ¬ψ can be derived, deriveφ from the other assumptions from whichψ and ¬ψ followed.

Γ,¬φ `ψ Σ,¬φ ` ¬ψΓ,Σ `φ ¬ elim

¬ elim !

! elim !

¬ intro !

! elim !

8. B

{6,7}

9. C

{2,6}

5. ¬A

{1,2}

7. ¬C

{7} Assume !

6. ¬C ! B

{6} Assume !

2. ¬B

{2} Assume !

3. A

{3} Assume !

4. B

{1,3}

1. A ! B

{1} Assume !

Figure 14: Negation introduction and elimination rules.

11

Page 14: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

2.1.12 Substitution

This rule justifies a formula produced by uniform substitution of propositional vari-ables of a theorem. (A theorem must be in the scope of no assumptions.)

; `φ; `φσ Substitution

Substitution !

! intro "

Substitution "

" intro "

1. P

{1} Assume "

2. P ! Q

{1}

3. P " (P ! Q)

4. A " (A ! B)

5. A ! B

{1}

Figure 15: Substitution justifies A→ (A ∨B) from P→ (P ∨Q) since the latter is atheorem. A∨B does not follow from P∨Q by Substitution, however, for the latter isnot a theorem.

2.1.13 PC ` and PC |=

These rules justify a conclusion from a set premises if the conclusion is derivablefrom or a consequence of the premises, respectively.

P1 . . . Pn

QPC `

P1 . . . Pn

QPC |=

2.2 Non-Quantified Predicate Calculus

The non-quantified predicate calculus is similar to the propositional calculus, but hasdifferent atomic formulae, and adds several rules. In the predicate calculus, a term isa variable, constant, or the application of a function symbol to one or more terms,and an atomic formula is a propositional variable, an equation, or an application of apredicate or relation symbol to one or more terms.

The non-quantified predicate calculus has introduction and elimination rules forequality, an enhanced version of Substitution, and an provability rule FOL `.

12

Page 15: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

Figure 16: When PC ` is used to justify an inference, the resulting proof can be viewedby selecting View Artefact from the formula’s context menu. This resolution-styleproof was produced by SNARK when PC `was used to justify ¬P from (P→Q)∧ (Q→R)∧¬R.

Figure 17: When PC |= is used to justify an inference and the conclusion is not aconsequence of the premises, a counterexample can be viewed by selecting View

Artefact from the formula’s context menu. This counterexample was produced whenPC |=was incorrectly used to justify P from (P→Q)∧ (Q→R)∧¬R.

2.2.1 = Introduction

For any term τ, = introduction may be used to introduce the equation τ= · · ·=τ.

τ= · · ·=τ = intro

2.2.2 = Elimination

Given an equation t1 = · · ·= tn and a formulaφ,= elimination may be used to inferany variantφ′ ofφ in which any t i has been replaced by any t j .

t1 = · · ·= tn φ

φ′= elim

2.2.3 Substitution

This rule is modified to allow uniform substitution for any names (variables, con-stants, function symbols, and relation symbols) in theorems.

13

Page 16: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

2.2.4 FOL `

This rule is used to justify a conclusion which is derivable using the rules of first-orderlogic from its premises. As with PC `, proofs may be examined by selecting View

Artefact from a correctly justified formula’s context menu.

Substitution != elim !

4. R(f(c)) ! ¬R(f(c))3. P(b) ! ¬P(b)

{1}

1. a = b

{1} Assume !

2. P(a) ! ¬P(a)

PC ! !

5. b = b = b

= intro !

Figure 18: Use of equality introduction and elimination and the modified Substitu-tion rules.

2.3 First-Order Logic

The formulae and rules of first-order logic are just those of the non-quantified predi-cate calculus along with universal and existential quantifications and introductionand introduction and elimination rules for these quantifiers.

2.3.0.1 Universal Introduction From a formula φ universal introduction maybe used to infer ∀x φ, provided that x does not appear free in any of the in-scopeassumptions ofφ.

Γ `φΓ ` ∀x φ

∀ intro

2.3.0.2 Universal Elimination From the universal quantification ∀x φ, any in-stance ofφmay be inferred wherein x is uniformly replaced by some term t , providedthat no name free in t becomes bound in the process.

∀x φ

φ{x → t } ∀ elim

2.3.0.3 Existential Introduction

φ

∃x φ ∃ intro

2.3.0.4 Existential Elimination From an existential ∃x φ depending on assump-tions Γ and from ψ depending on assumptions Σ an instance of φ whose witnessdoes not appear free inψ, inferψ in the scope of Γ,Σ.

Γ ` ∃x φ Σ,φ{x → t } `ψΓ,Σ `ψ ∃ elim

14

Page 17: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

FOL ! !

! elim !

! intro !

" intro !

# elim !

# intro !

8. #y (P(y) " Q(y))

{4}

7. #y (P(y) " Q(y))

{5}

6. P(b) " Q(b)

{5}

5. P(b)

{5} Assume !

4. #x P(x)

{4} Assume !

3. P(b) " ¬P(b)

2. !x (P(x) " ¬P(x))

1. P(a) " ¬P(a)

PC ! !

10. Q(a)

{9}

9. P(a) $ !x (P(x) % Q(x))

{9} Assume !

Figure 19: Universal and existential introduction and elimination rules along withFOL `.

2.4 Modal Logics

Slate supports six of the most common modal logics, K, T (sometimes called M),S4, and S5. Slate’s proof systems for these logics are mostly in the same style, andintroduce a necessity-count associated with each formula in the workspace (muchlike the propositional calculus and its derivatives have a notion of in-scope assump-tions). The differences between the modal proof systems is primarily in the way thatnecessity counts are computed. For all the modal logics, the formulae are those ofthe propositional calculus along with those formed by necessity and possibility.

2.4.1 Necessity Counting

In the modal proof systems in Slate, each formula is a associated with a necessitycount which captures ‘how necessary’ the formula is. The necessity count determineshow many times necessity introduction may be applied to the formula. In presentingthe modal rules, we indicate thatφ has necessity count n by writingφ (�n ). Necessitycounts are either a non-negative integer or∞, and we adopt the convention that∞−1=∞+1=∞.

By default, a formula justified by some rule R, unless R is one that affects thenecessity count (necessity introduction and elimination), the necessity count of theformula is the minimum of the necessity counts of its nearest ‘ancestors’ not in thescope of any assumption discharged by R, where a branch with no such ancestorcount as∞. This definition is likely not at all transparent, and an example will helpto make it clear.

Consider the argument structure in Fig. 20. Q is derived using conditional elimi-nation from P and P→Q. Conditional elimination discharges no assumptions, sothe nearest ‘ancestors’ not in the scope of any discharged assumption are simplythe premises P and P→Q. The necessity count of P is 1 and of P→Q is 2, and

15

Page 18: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

the minimum of 1 and 2 is 1, so the necessity count of Q is 1. Formula justified byrules that do not discharge assumptions, and which are not necessity introductionor elimination have as their necessity count the minimum of the necessity count oftheir premises.

When �P→Q is inferred from P by conditional introduction, the assumption�P is discharged. As a result, the ‘nearest’ ancestors are formula number 5, Pl i f Qwith an assumption count of 2, and from the branch starting from the assumption�P there is no nearest ancestor, so we take the value∞. The minimum of∞ and 2 isof course 2 and this is the necessity count of�P→Q. Formulae justified by rules thatdischarge assumptions get their necessity counts by following the argument backwardand finding the nearest ancestors not in the scope of a discharged assumption. Anybranch which is completely eliminated contributes∞.

As a special case assumption discharging, correctly justified formulae in the scopeof no assumptions (which are theorems) will always have necessity count∞.

! elim !

! elim !

! intro !

! elim !

! elim !

! intro !! intro !

! intro !

8. !!(P ! Q) ! Q

{1} 1!

7. !P ! Q

{3} 2!

10. !P ! (!!(P ! Q) ! Q)

"!

9. !!(P ! Q) ! (!P ! Q)

"!

6. Q

{1,3} 1!

2. P

{1} 1!

1. !P

{1} Assume !

5. P ! Q

{3} 2!

4. !(P ! Q)

{3} 1!

3. !!(P ! Q)

{3} Assume !

Figure 20: An argument illustrating the subleties of necessity counting in light ofassumption discharging rules.

16

Page 19: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

2.4.2 Modal Rules

We will first present the basic forms of the modal rules, and we will then continue todescribe the slight variations in rules and in necessity counting that distinguish thevarious modal systems.

2.4.2.1 Necessity Introduction From a formulaφwith a non-zero necessity countnecessity introduction permits deriving�φ with a necessity count one less than thatofφ.

φ (�n )φ (�n −1)

� intro

2.4.2.2 Necessity Elimination From a formula�φ with a necessity count n , inferφ with necessity count one greater than n .

�φ (�n )φ (�n +1) � elim

2.4.2.3 Possibility Introduction From a formula φ, infer ◊φ with the same ne-cessity count.

φ

◊φ ◊intro

2.4.2.4 Possibility Elimination The structure of possibility elimination is ratherlike first-order logic’s existential elimination. From a possibility ◊φ and a derivationofψ in the scope of an assumptionφ, where the conditionalφ→ψ, were it derivedby conditional introduction, would have an infinite necessity count, derive ◊ψ.

◊φ ψ

◊ψ ◊ elim

Possibility elimination is intended to the capture line of reasoning that says “φ ispossible, and ψ necessarily implies φ, therefore ψ is possible.” The actual formof possibility elimination presented here removes the need to derive the necessaryconditional �(ψ→φ), but requires the same conditions.

2.4.2.5 Modal Dualities The modalities � and ◊ can be defined in terms of eachother as follows.

◊φ ≡ ¬�¬φ�φ ≡ ¬◊¬φ

The Modal Dualities rule allows inferring any formula from a premise that is equiva-lent modulo these definitional equivalents (and double negations).

17

Page 20: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

Modal Dualities !

! elim !

! intro !

! intro !

" intro !

! intro !" elim !

" elim !

5. "("P ! Q)

{1}

4. "P ! Q

{1} 1"

1. ""P

{1} Assume !

2. "P

{1} 1"

3. P

{1} 2"

6. P

{6} Assume !

7. !P

{6}

11. !P

{11} Assume !

8. P

{8} Assume !

9. P ! Q

{8}

10. !(P ! Q)

{11}

12. "P " ¬!Q

{12} Assume !

13. ¬!¬P " "¬Q

{12}

Figure 21: The modal rules.

2.4.3 Modal Proof Systems

2.4.3.1 T The modal system T is the simplest modal system. The modal rules allbehave exactly as specified above; there are no special cases in the application of therules or in necessity counting. All formulae are proper conclusions, regardless of theirnecessity count. T has the property that for any formulaφ, �φ→φ is a theorem.

! elim !

2. !

{1} 1!

1. !!

{1} Assume !

Figure 22: A proof in T of the formula�φ→φ. This would not be a proof in K, for in Kproper conclusions must have a necessity count of 0 or∞, but hereφ has a necessitycount of 1.

2.4.3.2 K K is more restrictive than T. The propositional inference rules may onlybe applied to formula in T that have the same necessity count, and only formulaewith necessity counts of 0 or∞ are proper conclusions. Though K is rather restrictive,it has the property that every theorem is necessary (often known as the rule of neces-sitation), and the property that�(A→B)→(�A→�B) (often known as distributivity).

2.4.3.3 S4 S4 is like T, but any formula whose primary logical system is �, i.e.,any formula �φ is automatically assigned an infinite necessity count. This property

18

Page 21: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

! intro !

! intro !

! intro !

! elim ! ! elim !

! elim ! ! intro !

4. A

{3} 1!

2. A ! B

{1} 1!

1. !(A ! B)

{1} Assume !

3. !A

{3} Assume !

6. !B

{1,3}

7. !A ! !B

{1} 1!

5. B

{1,3} 1!

8. !(A ! B) ! (!A ! !B)

"!

9. P # ¬P

PC " ! "!

10. !(P # ¬P)

"!

Figure 23: K proofs of necessity distributivity and of necessitation.

means that S4 admits a proof of the formula

�φ→��φ.

2.4.3.4 S5 S5 is just like S4, except that all modal formulae, i.e., necessities andpossibilities, are assigned infinite necessity counts. This means that in addition tohaving �φ→��φ as a theorem, S5 also has

◊φ→�◊φ.

19

Page 22: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

Index

= introduction, 13∃ elimination, 14∃ introduction, 14∀ elimination, 14∀ introduction, 14∧ elimination, 8∧ introduction, 8→ elimination, 10→ introduction, 10↔ elimination, 10↔ introduction, 10� counting, 15� elimination, 17� introduction, 17¬ elimination, 11¬ introduction, 11∨ elimination, 9∨ introduction, 9◊ elimination, 17◊ introduction, 17%, 6!, 6

Assume, 8assumptions, 7

in-scope, 7

biconditional elimination, 10biconditional introduction, 10border

dashed, 7

check mark, 6colors

green, 6red, 6

conclusionsimproper, 7

conditional elimination, 10conditional introduction, 10conjunction elimination, 8conjunction introduction, 8counterexample, 13

countermodel, 13

detachment, 10disjunction elimination, 9disjunction introduction, 9distributivity

of �, 18

elimination rulesbiconditional, 10conditional, 10conjunction, 8disjunction, 9existential, 14necessity, 17negation, 11possibility, 17universal, 14

equality introduction, 13existential elimination, 14existential introduction, 14

first-order logic, 14FOL `, 14formulae

adding, 2, 3appearance, 4assumptions, 7border, 7identifiers, 4removing, 2, 4

green

!, 6

improper conclusions, 7in-scope assumptions, 7input syntax, 2introduction rules

biconditional, 10conditional, 10conjunction, 8disjunction, 9equality, 13

20

Page 23: Getting Started With Slate - Computer Sciencetayloj/DOCS/SlatePrimer_20100915.pdf · 9/15/2010  · Getting Started With Slate Joshua Taylor Selmer Bringsjord Micah Clark September

existential, 14necessity, 17negation, 11possibility, 17universal, 14

K, 18

linkblack, 6blue, 6thick, 6thin, 6

M, 18Modal Dualities, 17modal logics, 15–19modus ponens, 10

necessitation, 18necessity counting, 15necessity elimination, 17necessity introduction, 17negation elimination, 11negation introduction, 11non-quantified predicate calculus, 12–14

PC |=, 12PC `, 12possibility elimination, 17possibility introduction, 17premises

adding, 4removing, 4

proof by cases, 9propositional calculus, 8–12

redborder, 7%, 6

S4, 18S5, 19SNARK, 13Substitution, 12, 13

T, 18

universal elimination, 14universal introduction, 14

%, 6

21