natural deduction fitch tf

Report 13 Downloads 181 Views
Natural deduction for truth-functional logic Phil 160 - Boston University

Why natural deduction? • After all, we just found this nice method of truth-tables, which can be used to determine the validity or invalidity of any argument in truth-functional logic! • But there are some problems with truth-tables – They can be very inefficient. The reason is that if you have an argument which contains k atomic formulas, then you’ll need a truthtable with 2k rows – The method of truth-tables doesn’t work for logic as a whole. It is a very special feature of truth-functional logic that all the relevant possible worlds can just be arranged in a list • Instead, the best way to demonstrate validity is proof – A proof is just a series of simple steps, each easily recognizable as valid • Natural deduction is a system of construction of proofs. • That is, when a statement is a logical consequence of others, we’ll use natural deduction to demonstrate this. • The system of natural deduction idealizes good human reasoning. • In fact, we have already done a lot of (informal) examples of natural deduction argumentation—think of the solutions to puzzles about Alice, Bob and Carol.

The plan • A proof is a series of obviously correct steps – but when is a step ‘obviously’ correct?

1

– What if people can’t agree about the correctness of an inference? • To answer this question, we’ll build a system of proof: that is, – identify some basic argument patterns which are clearly correct – these basic patterns are called rules of inference • every step of a proof must follow one of the rules of inference – then, correctness is assured

Natural deduction, the basic idea • Recall that the point of a deductive argument is to show that the conclusion is a logical consequence of the premises – The argument does not show that the premises are true – it just shows that if the premises are true then so is the conclusion • So, you begin a natural deduction proof by assuming the premises • You then apply rules of inference to show that from those premises, further statements logically follow • Recall that at this point, we want natural deduction for truth-functional logic • So, we’ll now go through the various connectives and pick out some patterns which are clearly correct • as a standard of correctness, we will appeal only to the definition of truth!

Rules for conjunction • The easiest connective to handle is conjunction – Recall from the definition of truth that ∗ A ∧ B is true just in case both A and B are true • From the truth-table for conjunction, we can now derive the two basic rules for handling conjunction

2

Conjunction introduction • The truth-table implies that if any two formulas are true, so is their conjunction • So, the definition of truth guarantees that the following pattern of inference is always correct: – Conjunction introduction: from A and B, infer A ∧ B • Or in other words: if you have any two formulas, then you can infer their conjunction • This is the basic way of proving that a conjunction is true Conjunction elimination • Conversely, what if you already know that a conjunction is true and want to find out what follows from it? – then you want an elimination rule • According to the definition of truth, if a conjunction A ∧ B is true, then so are each of A and B. • So, the the following pattern of inference is correct as well: – conjunction elimination: from A ∧ B, infer any of A and B. • or in other words: if you have a conjunction, then you can infer any of its conjuncts. Example of the conjunction rules in action • Clearly the argument A ∧ B, B ∧ C ∴ A ∧ C is valid. • can you prove this using the rules?

1

P ∧Q

2

Q∧R

3

P

∧E, 1

4

R

∧E, 2

5

P ∧R

∧I, 3, 4

• Notice how much faster and clearer than the truth-tables this is. 3

Practice 1. P ∧ Q ∴ Q ∧ P 2. P ∧ (Q ∧ R) ∴ (P ∧ Q) ∧ R 3. P, Q ∴ (P ∧ Q) ∧ P

Conditional • The rules for conditional are somewhat deeper • As before, we want an introduction rule and an elimination rule Conditional elimination (or ‘modus ponens’) • Recall from the truth-table that – the conditional A → B is true just in case either A is false or B is true • so, suppose A → B is true, and also that A is true. Since A isn’t false, therefore B has to be true. • so the following is always valid – conditional elimination (‘modus ponens’): from A → B and A, infer B. • or in other words, given a conditional and its antecedent, you can infer the consequent. Example • Show the validity of P → R, P ∧ Q ∴ Q ∧ R

1

P →R

2

P ∧Q

3

Q

∧E, 2

4

P

∧E, 2

5

R

→E, 1, 4

6

Q∧R

∧I, 3, 5

• for another example, try P ∧ Q → R, P, Q ∴ R. 4

Conditional introduction (or ‘conditional proof’) • For this rule, it’s probably best to begin with an example: show that P ∴ Q → P ∧ Q is valid – intuitively you could argue like this ∗ ‘assume P . For the sake of argument, further assume Q. Then, P ∧ Q would have to be true. So given only P , we have that if Q were true, then P ∧ Q would be true. In other words, P ∴ Q → P ∧ Q is valid.’ ∗ in this reasoning, we wanted to prove a conditional. So for the sake of argument we assumed its antecedent and deduced its consequent. This means the that regardless of whether the antecedent is true we know that the conditional must be true. – the natural deduction method is quite similar: 1

P

2

Q

3

P ∧Q

4

P →Q

∧I, 1, 2 →I, 3

• Now here’s the rule: – conditional introduction: having proved B under a temporary assumption of A, you can infer A → B outright Practice 1. 2. 3. 4. 5. 6. 7. 8. 9. 10.

P ∴Q→P ∧Q P → Q, P → R ∴ P → Q ∧ R P → Q, Q → R ∴ P → R P →R∴P ∧Q→R P, Q → R ∴ P ∧ Q → P ∧ R P ∧ Q → R ∴ P → (Q → R) P → (Q → R) ∴ P ∧ Q → R P → (Q → R) ∴ Q → (P → R) P → Q ∴ P → (P → Q) ∴P →P

• Why is the rule of conditional introduction valid? This is slightly trickier. But here is the idea. 5

– Suppose that you’ve shown B to follow from the formula A plus some zero or more other formulas X . ∗ Now suppose toward a contradiction that X , A ∴ B is not valid. ∗ Then there is a possible world W where all of X are true but A → B is false. ∗ So in W, all of X , A are true while B is false. ∗ Hence W is a countermodel to X , A ∴ B, contradicting our assumption that B follows from X , A.

Disjunction • Like conditional, disjunction consists of an easy rule and an interesting one Disjunction introduction • The definition of truth says that if a formula is true, then so is its disjunction with any other formula • So here is the rule: – Disjunction introduction: given A, infer A ∨ B for any B whatsoever • This is an rather permissive rule, which weirds some people out – but, note that it only goes on one direction! Disjunction elimination • Suppose that you’ve got a disjunction A ∨ B. – then you don’t know which of A and B is true! – either was enough to prove it – So what else can you learn if you just know A ∨ B? • We saw the solution earlier: proof by cases. • Let’s consider an example: show the validity of P, Q∨R ∴ (P ∧Q)∨(P ∧R) – you might argue informally like this: ‘We are given P and Q ∨ R. Now further suppose for the sake of argument that Q is true. Then, P ∧ Q must be true, so that (P ∧ Q) ∨ (P ∧ R) is true. On the other hand, suppose for the sake of argument that R is true. Then P ∧ R is true, so (P ∧ Q) ∨ (P ∧ R) must be true again. So (P ∧ Q) ∨ (P ∧ R) has got to be true in any case!’ 6

– Formally the argument is very similar: 1

P

2

Q∨R

3

Q

4

P ∧Q

∧I, 1, 3

5

(P ∧ Q) ∨ (P ∧ R)

∨I, 4

6

R

7

P ∧R

∧I, 1, 6

8

(P ∧ Q) ∨ (P ∧ R)

∨I, 7

9

(P ∧ Q) ∨ (P ∧ R)

∨E, 2, 5, 8

• Now here’s the rule: – Disjunction elimination: Suppose that you already got A∨B. Suppose you prove C from the temporary assumption of A, and that you also prove C from the temporary assumption of B. Then you can infer C outright. Practice 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11.

P ∧Q∴P ∨Q P ∧ Q ∴ (P ∨ R) ∧ (Q ∨ R) (P ∧ R) ∨ (Q ∧ R) ∴ R (P ∧ Q) ∨ (R ∧ S) ∴ P ∨ R P →Q∴P →Q∨R P ∨Q→R∴P →R P ∨ Q, P → R, Q → R ∴ P → R P → R, Q → R ∴ P ∨ Q → R P ∨Q∴Q∨P (P ∨ Q) ∨ R ∴ P ∨ (Q ∨ R) (P ∨ Q) ∧ (P ∨ R) ∴ P ∨ (Q ∨ R)

• Note that you can give an argument for the soundness of disjunction elimination which is similar to the one we gave for conditional introduction. – Suppose that X , A ∴ C and X , B ∴ C are both valid. ∗ Toward a contradiction, further suppose that X , A ∨ B ∴ C is not valid. 7

∗ Then there is a possible world W such that W |= X and W |= A ∨ B, and yet W 6|= C. ∗ Since X , A ∴ C is valid and W |= X yet W 6|= C, it follows that W 6|= A. ∗ Likewise, X , B ∴ C is valid and W |= X yet W 6|= C, and therefore W 6|= B. ∗ Thus W 6|= A and W 6|= B. Hence W 6|= A ∨ B, a contradiction! – Hence X , A ∨ B ∴ C must be valid.

Negation • Things have been awfully ‘positive’ so far. . . – what about negation? • Here, the nicest approach is actually to introduce a new formula ⊥ – you can think of this the statement ‘round square amphibious pigs are flying in a vacuum’, or as ‘that’s crazy!’, or simply as P ∧ ¬P – thus, ⊥ is just another formula we’ve added to the language – crucially, it is false at all possible worlds ∗ so, for example, P → ⊥ is equivalent to ¬P ∗ what is P ∨ ⊥ equivalent to? • We will introduce rules for negation as rules for introducing and eliminating absurdity

Absurdity intro and elim • Again let’s consider an example: ¬P ∴ ¬(P ∧ Q). – Informally you could argue like this. ‘We are given ¬P . Toward a contradiction, suppose for the sake of argument that P ∧ Q. Well, then P . That is a contradiction! So given ¬P , we must conclude ¬(P ∧ Q)’. – And the formal argument is almost exactly the same: 1

¬P

2

P ∧Q

3

P

∧E, 2

4



⊥I, 1, 3

5

¬(P ∧ Q) 8

⊥E, 4

• One of the rules used in this argument is easy to state: – absurdity introduction: suppose that you’ve deduced ⊥ from A. Then infer ¬A. • The elimination rule has two sides. The first we’ve seen already: – suppose you’ve shown that A implies ⊥. Then infer ¬A, outside the assumption of A. • But that’s not all. Notice that absurdity elimination is also negation introduction; so it’s useful if there’s a negation we want to prove – But what if we have a negation, and are trying to get something new out of it? – For example, consider ¬(¬P ∨ ¬Q) ∴ P . ∗ intuitively this should seem valid: the premise says that none of ¬P and ¬Q is true, which is just to say P and Q must both be true. ∗ since we want to prove P , we begin by assuming ¬P and then go for ⊥ 1

¬(¬P ∨ ¬Q)

2

¬P

3

¬P ∨ ¬Q

4



5

⊥I, 1, 3 ⊥E, 4

P

• The principle we used here is this: – suppose you’ve shown that ¬A implies ⊥. Then infer A, outside the assumption of ¬A. • The two principles can be combined elegantly, if we add another idea: – let A be a formula. If A has the form ¬B, then the opposite of A is B. Otherwise, the opposite of A is ¬A. – Let’s write A? for the opposite of A. • Now here is the elimination rule for absurdity: – absurdity elimination having deduced absurdity from a temporary assumption of A? , then infer A outright • Proofs by absurdity can get a bit tricky. 9

– For example, consider ¬(P ∧ Q) ∴ ¬P ∨ ¬Q – intuitively, this should be valid: if P ∧ Q is false, then P, Q aren’t both true, which means that at least one of ¬P and ¬Q is true. – But how to prove this? ∗ To prove a disjunction we seem to need to prove a disjunct ∗ but ¬(P ∧ Q) ∴ ¬P is not valid! . . . So what to do? ∗ The trick is to assume the opposite of what we want to prove, and go for absurdity. ∗ Having assumed ¬(¬P ∨ ¬Q), we will aim to prove P ∧ Q ∗ To that end, we introduce further assumption of ¬P toward the inner goal of another absurdity! ∗ Similarly for ¬Q.

1 2

¬(P ∧ Q) ¬(¬P ∨ ¬Q)

3

¬P

4

¬P ∨ ¬Q

∨I, 3

5



⊥I, 2, 4

6

⊥E, 5

P

7

¬Q

8

¬P ∨ ¬Q

∨I, 7

9



⊥I, 2, 8

10

Q

⊥E, 9

11

P ∧Q

∧I, 6, 10

12



⊥I, 1, 11

13

¬P ∨ ¬Q

⊥E, 12

Practice 1. 2. 3. 4. 5. 6.

P → Q, ¬Q ∴ ¬P P, ¬Q ∴ ¬(P → Q) ¬(P ∧ Q), P ∴ ¬Q ¬(P ∨ Q) ∴ ¬P P ∨ Q → R, ¬R ∴ ¬Q P → (Q → R) ∴ ¬R → (P → ¬Q) 10

7. 8. 9. 10.

¬P, ¬Q ∴ ¬(P ∨ Q) ¬P ∴ P → ⊥ P → ⊥ ∴ ¬P ∴ P ∨ ¬P

Biconditional • As the name suggests, you can think of a biconditional as two conditionals: – A ↔ B is equivalent to A → B and B → A • The inference rules for biconditional just treat it like that conjunction of conditionals: – Biconditional introduction: if you’ve deduced B from A and also deduced A from B, then infer A ↔ B. – Biconditional elimination: suppose you’re given A ↔ B. Given A as well, infer B. Conversely also given B, infer A. • For example, consider P ↔ Q, Q ↔ R ∴ P ↔ R – here, you just slog away. . . 1

P ↔Q

2

Q↔R

3

P

4

Q

↔E, 1, 3

5

R

↔E, 2, 4

6

R

7

Q

↔E, 2, 6

8

P

↔E, 1, 7

9

P ↔R

Practice 1. 2. 3. 4. 5. 6.

P ↔ Q ∴ (P → Q) ∧ (Q → P ) (P → Q) ∧ (Q → P ) ∴ P ↔ Q P ↔Q∴Q↔P P ↔ Q ∴ ¬P ↔ ¬Q P ↔ Q, R → S ∨ P ∴ R → S ∨ Q P ↔ Q, (R → P ) → S ∴ (R → Q) → S 11

↔I, 5, 8

7. P ↔ Q, P → Q ∨ R ∴ Q → P ∨ R 8. P ↔ Q, ¬(S ∨ P ) → Q) ∨ (S → R ∧ P ) ∴ ¬(S ∨ Q) → P ) ∨ (S → R ∧ Q) (don’t actually do this, but how do I know that it’s valid?)

Derived Rules • We’ve now got a complete system of rules for natural deduction in truthfunctional logic – Completeness means that if an argument is valid, then its validity can be demonstrated using those rules alone – So that’s nice! • As a practical matter, proofs using just the rules we’ve got so far can be pretty long and tedious • So we will now introduce a bunch of further rules which aren’t essential, but which make life easier – A derived rule is a rule which doesn’t let us prove anything we couldn’t prove already – If something is proved using derived rules, then it could be proved using just basic ones, and so has to be valid. Modus Tollens • If you do a lot of natural deduction using just basic rules, you will find that this pattern shows up all the time: 1

A→B

2

¬B

3

A

4

B

5



6

¬B

• After a while this gets tedious and boring, and a general principle is clear: – given a conditional and the negation of its consequent, you can always deduce the negation of the antecedent • So our first derived rule is this: – modus tollens: given a conditional and the negation of its consequent, infer the negation of the antecedent 12

Double negation rules • There are a seemingly obvious pair of argument-schemes we have not yet legitimated: A ∴ ¬¬A, and ¬¬A ∴ A – But given any formula A, you can always deduce ¬¬A, like this: 1

A

2

¬A

3



4

¬¬A

⊥I, 1, 2 ⊥E, 3

– and conversely given ¬¬A you can deduce A: 1

¬¬A

2

¬A

3



4

A

⊥I, 1, 2 ⊥E, 3

• Summarizing these in a rule we get – double negation: from A, infer ¬¬A, and vice versa. Excluded middle • There is a version of proof by cases which sometimes comes in handy: – Suppose you know that something follows from A and also follows from ¬A – Then it must be true outright! • Why? How can we justify this? – First demonstrate the validity of ∴ A ∨ ¬A, then use disjunction elimination. • So the rule is this: – having deduced B from A and also having deduced B from ¬A, infer B outright.

13

Reiteration • Suppose that you’re building an argument – you began by assuming the premises – then you added some temporary assumptions too – within the scope of the temporary assumptions, you can always assert what follows from the original premises – after all, if it follows from the premises, then it must follow from the premises plus the temporary assumptions • so if you’ve proved something, you ought to be able to reiterate it within the scope of any further assumptions • The basic rules of natural deduction legitimate this practice: 1

A

2

B

3

A∧B

∧I, 1, 2

4

A

∧E, 3

• it is ok if you think that this ‘justification’ a bit sneaky • but, the principle is really wired into the system – and in any case, it is obviously correct • so here is the rule: • reiteration: if you’ve already recorded some statement as a premise or conclusion within the scope of the lines | · · · |, then reiterate that statement within the scope of that | · · · | plus any further lines. Ex Falso Quodlibet • Consider the argument P, ¬P ∴ Q – is it valid? ∗ Well, suppose it’s not valid ∗ then there’s a world where all premises are true while the conclusion is false ∗ so there’s a world where both P and ¬P are true ∗ that’s absurd! – therefore, P, ¬P ∴ Q is valid • Similarly, consider ⊥ ∴ P – is it valid? 14

∗ suppose not ∗ then some world makes ⊥ true and P false ∗ but ⊥ is false by definition! – so, yes it is definitely valid • There is a more general principle here: – from a contradiction, everything follows • Can this reasoning be carried out using natural deduction? Yes! 1



2

¬A

3



4

reiteration, 2

A

⊥E, 4

• so here’s the rule: – EFQ: having deduced ⊥, infer any other formula A Disjunctive syllogism • This is a very natural principle involving disjunction and negation – Suppose you know that A ∨ B is true but also that ¬A is true – Then at least one of A and B is true while A is not true – So B must be true • It is easy to justify, given the rules we’ve derived already: 1

A∨B

2

¬A

3

A

4



⊥I, 2, 3

5

B

EFQ, 4

6

B

7

B

8

reiteration, 6

B

∨E, 1, 5, 7

15