Truth Trees.

Slides:



Advertisements
Similar presentations
Computing Truth Value.
Advertisements

TRUTH TABLES The general truth tables for each of the connectives tell you the value of any possible statement for each of the connectives. Negation.
Chapter 21: Truth Tables.
Logic & Critical Reasoning
Semantics of SL and Review Part 1: What you need to know for test 2 Part 2: The structure of definitions of truth functional notions Part 3: Rules when.
Formal Semantics of S. Semantics and Interpretations There are two kinds of interpretation we can give to wffs: –Assigning natural language sentences.
For Wednesday, read Chapter 3, section 4. Nongraded Homework: Problems at the end of section 4, set I only; Power of Logic web tutor, 7.4, A, B, and C.
Truth Trees Intermediate Logic.
Truth Trees.
Today’s Topics n Review Logical Implication & Truth Table Tests for Validity n Truth Value Analysis n Short Form Validity Tests n Consistency and validity.
PHIL 120: Jan 8 Basic notions of logic
Alpha: Symbolization and Inference Bram van Heuveln Minds and Machines Lab RPI.
The semantics of SL   Defining logical notions (validity, logical equivalence, and so forth) in terms of truth-value assignments   A truth-value assignment:
EE1J2 – Discrete Maths Lecture 5 Analysis of arguments (continued) More example proofs Formalisation of arguments in natural language Proof by contradiction.
Logical and Rule-Based Reasoning Part I. Logical Models and Reasoning Big Question: Do people think logically?
Copyright © Cengage Learning. All rights reserved.
Chapter Six Sentential Logic Truth Trees. 1. The Sentential Logic Truth Tree Method People who developed the truth tree method: J. Hintikka— “model sets”
Chapter Three Truth Tables 1. Computing Truth-Values We can use truth tables to determine the truth-value of any compound sentence containing one of.
Algebra Problems… Solutions Algebra Problems… Solutions © 2007 Herbert I. Gross Set 10 By Herbert I. Gross and Richard A. Medeiros next.
INTRODUCTION TO LOGIC Jennifer Wang Fall 2009 Midterm Review Quiz Game.
1 CMSC 250 Discrete Structures CMSC 250 Lecture 1.
Chapter 3: Semantics PHIL 121: Methods of Reasoning March 13, 2013 Instructor:Karin Howe Binghamton University.
Chapter 3: Introduction to Logic. Logic Main goal: use logic to analyze arguments (claims) to see if they are valid or invalid. This is useful for math.
Today’s Topics Introduction to Proofs Rules of Inference Rules of Equivalence.
Mathematics for Comter I Lecture 2: Logic (1) Basic definitions Logical operators Translating English sentences.
Introduction to Logic Lecture 13 An Introduction to Truth Tables By David Kelsey.
McGraw-Hill ©2004 by The McGraw-Hill Companies, Inc. All rights reserved. Testing Validity With Venn Diagrams The aim of this tutorial is to help you learn.
March 23 rd. Four Additional Rules of Inference  Constructive Dilemma (CD): (p  q) (r  s) p v r q v s.
Logic.
2. The Logic of Compound Statements Summary
Conditional Statements
Knowledge Representation and Reasoning
Truth Tables and Equivalent Statements
Testing Validity With Venn Diagrams
7/20/2018 EMR 17 Logical Reasoning Lecture 7.
Introduction to Logic Lecture 14 The truth functional argument
Critical Reasoning Lecture 16 An Introduction to Truth Tables
{P} ⊦ Q if and only if {P} ╞ Q
Truth Tables How to build them
6.1 Symbols and Translation
Identifying Counterexamples
Truth Functions.
Propositional Calculus: Boolean Algebra and Simplification
Chapter 1 The Foundations: Logic and Proof, Sets, and Functions
Truth Tables Hurley
CS201: Data Structures and Discrete Mathematics I
Logical Forms.
Natural Deduction.
TRUTH TABLES.
Applied Discrete Mathematics Week 1: Logic
TRUTH TABLES continued.
Propositional Logic.
Midterm Discussion.
Computer Security: Art and Science, 2nd Edition
Chapter 3 Introduction to Logic 2012 Pearson Education, Inc.
Lecture 2: Propositional Equivalences
The Logic of Declarative Statements
Introductory Logic PHI 120
Logical and Rule-Based Reasoning Part I
CS201: Data Structures and Discrete Mathematics I
Compounding.
Doing Derivation.
Introducing Natural Deduction
Validity and Soundness, Again
Substitution.
Logical truths, contradictions and disjunctive normal form
The Main Connective (Again)
Starting out with formal logic
Subderivations.
The conditional and the bi-conditional
Presentation transcript:

Truth Trees

The Problem with Truth Tables The problem with standard truth tables is that they grow exponentially as the number of sentence letters grows, so… Most of our work is wasted because most of the Ts and Fs we plug in don’t show anything! But indirect truth table only work effectively for rigged examples We need something better: i.e. Truth Trees!

Truth Tree Tests Improved version of Short-Cut Truth Tables We assign truth values to whole sentences (here, by putting them on a branch of the tree) And work to smaller parts to see if we can get a coherent truth value assignment that makes them have those truth values: this ‘grows’ the tree. Consistency: we assign true to each sentence. Validity: we assign true to the premises and the negation of the conclusion. Note: this is an indirect proof (‘reducio’, ‘proof by contradiction’) method!

Short-Cut Truth Tables and Truth Trees Both methods assign truth values to whole sentences and then figure out what truth values of their components produce the assigned truth value—we are, in effect, ‘decomposing’ the sentences in to their parts. Both methods test to see whether it is possible to produce a correct truth value assignment to the sentence letters that gets the assigned truth value for the whole sentences Recall the short cut truth table test for consistency… \\

Short-Cut Truth Tables: Consistency A  B / B  (C  A) / C   B /  A T Write the sentences on one line with slashes between them Assign true to each sentence by writing ‘T’ under its main connective

Short-Cut Truth Tables: Consistency A  B / B  (C  A) / C   B /  A T T T T F Since  A is true, A must be false so this truth value is “forced” on A Assign “forced” truth values. We start with the last sentence because assigning true to the other sentences doesn’t “force” truth values on their parts.

Short-Cut Truth Tables: Consistency A  B / B  (C  A) / C   B /  A F T T F T T F Now that we’ve assigned a truth value to A, other truth values are forced by that: All the other A’s must be false too!

Short-Cut Truth Tables: Consistency A  B / B  (C  A) / C   B /  A F T T T T F T T T F This forces more truth values: Since A is false, to make the first sentence true we have to assign true to B—which makes all the B’s true.

Short-Cut Truth Tables: Consistency A  B / B  (C  A) / C   B /  A F T T T T F T F T T F Since B is true,  B must be false—so yet another truth value is forced

Short-Cut Truth Tables: Consistency A  B / B  (C  A) / C   B /  A F T T T T F F F T F T T F Since  B is false, C must be false in order to make the conditional, C   B, true--so we have another forced truth value: all C’s have to be false

Short-Cut Truth Tables: Consistency A  B / B  (C  A) / C   B /  A F T T T T F F F F T F T T F Now we can complete the truth value assignment—and there’s only one way to do it: by assigning false to C  A, since both of its parts are false.

Short-Cut Truth Tables: Consistency A  B / B  (C  A) / C   B /  A F T T T T F F F F T F T T F But this isn’t a possible truth value assignment because it says that the conditional, B  (C  A), is true even though its antecedent is true and its consequent false. And there’s no way to avoid this since all truth values were forced!

Short-Cut Truth Tables: Consistency A  B / B  (C  A) / C   B /  A F T T T T F F F F T F T T F This shows that there’s no truth value assignment that makes all sentences true Therefore that this set of sentences is inconsistent.

Short-Cut Truth Tables: Consistency A  B / B  (C  A) / C   B /  A F T T T T T T F T T F T T F Note: if you assigned truth values in a different order the problem will pop up in a different place (see Hurley p. 40)—but it will pop up somewhere, like a lump under the carpet!

Truth Trees In doing a truth tree we start in the same way: by assigning truth values to whole sentences and then working backward until we’ve assigned truth values to all sentence letters. We do this by ‘growing’ a tree-structure according to tree rules which ‘decompose’ sentences into their constituent sentence letters. The tree rules represent the ways in which the sentence forms to which they apply are made true—so, e.g. p  q is made true by either p’s being true or q’s being true p • q is made true by both p and q being true

Why? p  q is made true by either p’s being true or q’s being true In both cases where p is true, p v q is true. In both cases where q is true, p v q is true.

Why? p • q is made true by both p’p and q being true We can construct tree rules from the characteristic truth tables for the connectives in this way!

Tree Rules DN   p p OR p  q p q AND p • q p q The rule for Double Negation is: rewrite, erasing two ’s Sentences that are basically OR’s are represented as branching structures Sentences that are basically AND’s are represented by non-branching structures. We understand conditionals and biconditionals as basically OR’s and AND’s OR p  q p q AND p • q p q

Conjunction and Disjunction p v q p q p • q p q Truth Truth Truth To make p • q true, Truth has to flow through both p and q So we represent conjunction by a non- branching rule To make p v q true, all we need is truth flowing through one of its parts So we represent disjunction by a branching rule

Conditional and Biconditional Conditional and biconditional are actually ‘extras’ in our language: we can say everything they say just in terms of conjunction, disjunction and negation. p  q is equivalent to either  p OR q so we formulate the tree rule for conditional as a branching OR rule p  q is equivalent to either (p AND q) OR ( p AND  q) so we formulate the tree rule for biconditional as a branching OR rule with ANDs on both branches. To see why this is so, consider the truth tables for conditional and for biconditional

Truth Tables for the Connectives p  p T F p q p • q p  q p  q p  q T F p  q is true if either p is false or q is true so it’s logically equivalent to  p v q You can prove this by testing the two sentences for equivalence!

Truth Tables for the Connectives p  p T F p q p • q p  q p  q p  q T F p  q is true if either both p and q are true or both p and q are false. So it’s equivalent to (p • q) v ( p •  q) Note: we’re helping ourselves to the idea that saying p is false is the same thing as saying  p—which is ok given the truth table for 

Conditional and Biconditional p  q  p q p  q p  p q  q Truth Truth Truth Truth To make p  q true, Truth has to flow through either  p or q  p says p is false so this says what makes p  q is p being false or q being true p  q says either p • q or  p •  q so it’s a branching rule with conjunctions on both branches Truth has to either flow through both p and q or through both  p and  q

Negation of Conditional and Biconditional  (p  q) p  q  (p  q) p  p  q q Truth Truth Truth  (p  q) says p  q is false What makes a conditional false is true antecedent, false consequent So we represent this as a conjunction of p and  q  (p  q) says that p and q have opposite truth value Truth has to either flow through p and  q or through  p and q

Negation of Disjunction and Conjunction  (p v q)  p  q  (p • q)  p  q Truth Truth Truth  (p v q) is equivalent to  p •  q by DeMorgan’s Law So we represent  (p  q) by this non-branching rule  (p • q) is equivalent to  p v  q by DeMorgan’s Law So we represent  (p • q) by this branching rule

Double Negation   p p The double negation rule is obvious! Truth The double negation rule is obvious! p is equivalent to   p so, a fortiori, p makes   p true.

Truth trees are upside down To represent the truth value assignment that makes a sentence true we want to show truth flowing up the tree—like sap from the roots Except in this case truth flows upward from the branches! T T T

How to Grow a Truth Tree We use the rules to grow the tree downward. We apply the tree rules to each sentence successively to ‘decompose’ it into simpler sentences that make it true… …and we decompose those sentences into even simpler sentences… …until we get down to sentences that can’t be decomposed any further, that is Sentence letters and negations of sentence letters Then the tree is complete.

Growing a Truth Tree to Test Consistency P  Q  P • Q Q Write the sentences to be tested in a vertical column: these are the initial sentences We’re looking for a truth value assignment that will make all of them true (if there is one) So we start by considering truth value assignments that make each of them true individually And see if we can put them together

Growing a Truth Tree to Test Consistency √ ~ P Q Apply tree rules to each sentence to which they apply, checking sentences when they’ve had rules applied to them We start with non-branching rules to keep the tree from getting too big.

Growing a Truth Tree to Test Consistency √ √ ~ P Q ~ P Q Now we apply the rule for conditional to P  Q writing the result at the bottom the tree The tree stops growing because no further rules can be applied.

Growing a Truth Tree to Test Consistency √ √ ~ P Q ~ P Q A ‘branch’ is the result of tracing from each sentence at the bottom of the tree all the way up to the top There are 2 (overlapping) branches on this tree: the initial sentences are on both branches.

Growing a Truth Tree to Test Consistency √ √ ~ P Q ~ P Q Each branch wants to represent a truth value assignment to the initial sentences which we can read off as follows: If a sentence letter occurs on a branch, TRUE is assigned to that sentence letter; if the negation of a sentence letter occurs, FALSE is assigned to that sentence letter.

Growing a Truth Tree to Test Consistency √ √ ~ P Q ~ P Q On this tree, both branches assign FALSE to P and TRUE to Q So each branch represents the same truth value assignment, viz. The truth value assignment represented by the row of the truth table in which all sentences got true, remember…

Testing Sets of Sentences for Consistency P  Q /  P • Q / Q T T T F T F T T T F F F T F F F P is FALSE; Q is TRUE F T T T F T T T F T F T F F F F Consistent or inconsistent? Consistent We constructed this row of the truth table on the truth tree without wasting time doing the other rows that didn’t matter!

But what if things were different? √ P  Q √ P • Q P Q ~ P Q X The left branch doesn’t represent a truth value assignment because it assigns both TRUE and FALSE to P! So we say that branch is ‘closed’ and indicate that by putting an X at the bottom

Open and Closed Trees A completed tree is open if it has at least one open branch. A completed tree is closed if it has no open branches, i.e. if all of its branches are closed. Consistency only requires the some (i.e. at least one) truth value assignment make all the sentences true so If the tree is open, then the initial sentences are consistent If the tree is closed, then the initial sentences are inconsistent

Summing up so far So now we can do two things: We can determine whether a set of sentences is consistent or inconsistent Open tree – consistent Closed tree – inconsistent And if the sentences are consistent we can determine which truth value assignment(s) makes them all true by reading the the open branch(es) But what if a set of sentences is inconsistent?

But what if things were different? √ P  Q Initial Sentences P ~Q ~ P Q X X This tree is closed so the initial sentences are inconsistent. There is no truth value assignment that makes all initial sentences true.

So what should I be able to do? Know the tree rules and how how they are derived Be able to invent a tree rule for a symbol if given its characteristic truth table Grow a truth tree Determine what a completed truth tree tells you about the consistency or inconsistency of initial sentences If the initial sentences are consistent, determine which truth value assignment makes them all true Given a completed tree, determine what its initial sentences are.

Growing a Truth Tree to Test Validity (P  Q)  R  R  P Write out the argument vertically, premises first and then conclusion The truth tree test for validity is an indirect proof method (aka reductio, proof by contradiction): we want to show that it’s not possible for all the premises to be true and the conclusion false. So we ask: ‘What if the premises were true and the conclusion were false?’

Growing a Truth Tree to Test Validity (P  Q)  R negation of the conclusion  R   P To ask that question, we negate the conclusion, grow a tree, and see what happens. When we test an argument for validity, we call the premises + the negation of the conclusion, the sentences above, the initial sentences. We then test these initial sentences for consistency by growing a truth tree from them.

Growing a Truth Tree to Test Validity (P  Q)  R negation of the conclusion  R   P We know that: If the premises + negation of conclusion are consistent the argument is invalid. If the premises + negation of conclusion are inconsistent the argument is valid. So by testing these sentences for consistency, we can determine whether the argument is valid or invalid!

How does this show validity or invalidity? P1 / P2 / . . . Pn // ~ C T T T T When we say that the premises + the negation of the conclusion are consistent we’re saying that there’s a truth value assignment (row of truth table) in which all these sentences are true. Please run this by me again

How does this show validity or invalidity? P1 / P2 / . . . Pn // ~ C T T T T F If there’s a row in which all the premises and the negation of the conclusion are true then in that very row all the premises are true and the conclusion itself is false. So the argument is invalid! Please run this by me again

How does this show validity or invalidity? P1 / P2 / . . . Pn / ~ C T T T T Inconsistent: there’s no row like this Now suppose that the premises + the negation of the conclusion are inconsistent. This means that there’s no row in which the premises and the negation of the conclusion are all true. Please run this by me again

How does this show validity or invalidity? P1 / P2 / . . . Pn // ~ C T T T T F Valid: there’s no row like this So there’s no row in which all the premises are true and the conclusion itself is false. So the argument is valid! Please run this by me again

Summing Up: Testing for Validity Using the tree method, we test for validity by testing the initial sentences—premises + negation of conclusion for consistency. If the initial sentences are consistent the argument is invalid. If the initial sentences are inconsistent the argument is valid. So now let’s try it!

Growing a Truth Tree to Test Validity (P  Q)  R negation of the conclusion  R   P We’re going to test these initial sentences for consistency. If the tree closes, they’re inconsistent, so the argument is valid. If the tree is open, they’re consistent, so the argument is invalid.

Growing a Truth Tree to Test Validity (P  Q)  R We apply the double negation rule to this sentence, check it, and write the result at the bottom of the tree  R √   P P

Growing a Truth Tree to Test Validity √(P  Q)  R We apply the rule for conditional to this sentence, check it, and write the result at the bottom of the tree  R √   P P  (P  Q) R Are there any problems? We check both branches to see whether either of them includes a sentence and its negation. Note: a sentence is on a branch if it occurs on a line by itself—not just as part of a longer sentence.

Growing a Truth Tree to Test Validity √(P  Q)  R  R √   P P  (P  Q) R X We’ve got a problem: R and  R are on the same branch, so that branch stops growing and closes. We show that the branch is closed by putting an X at the bottom.

Growing a Truth Tree to Test Validity √(P  Q)  R  R √   P P Now we apply the negation of a disjunction rule to this sentence √ (P  Q) R P Q X The tree is now finished growing because each sentence to which a rule could be applied has been checked—showing that the appropriate rule has been applied to it. Is there a problem?

Growing a Truth Tree to Test Validity √(P  Q)  R  R √   P P √ (P  Q) R P Q X X Yes! The remaining branch includes P and  P so it closes, and we show that by putting an X at the bottom of the branch. The tree is now complete and it is closed—so the argument is valid!

What would an invalid argument look like? √(P • Q)  R  R √   P P √ (P • Q) R P Q X This tree has finished growing but is open so the argument is invalid. We can also determine some more things about this argument by ‘reading’ its truth tree…

What’s the conclusion? √(P • Q)  R  R √   P P √ (P • Q) R P Q X Reading from top down, we look for the last sentence that wasn’t the result of applying a tree rule. That sentence is the negation of the conclusion, viz. ‘  P’ So the conclusion of this argument is  P

Are the initial sentences consistent or inconsistent? √(P • Q)  R  R √   P P √ (P • Q) R P Q X The initial sentences (the premises + negation of the conclusion of the argument) are consistent. The open path represents a truth value assignment that makes all the initial sentences true.

What truth value assignment makes all initial sentences true? √(P • Q)  R  R √   P P √ (P • Q) R P Q X If a sentence letter appears on an open path, that truth value assignment assigns TRUE to that sentence letter. If the negation of a sentence letter appears, it assigns FALSE to that sentence letter

What truth value assignment makes all initial sentences true? √(P • Q)  R  R √   P P √ (P • Q) R P Q X So, the truth value assignment that makes all initial sentences true is… P – TRUE; Q – TRUE; R – FALSE

The initial sentences are consistent ( P • Q )  R /  P T F

So the argument is invalid ( P • Q )  R /  // P T F

So we’ve saved ourselves lots of work… And can go home and relax!