HCC Math 0309 Chpt01 Sec04

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 36

Chapter 1

Introduction to Sets and Logic

© McGraw-Hill Education. All rights reserved. Authorized only for instructor use in
the classroom. No reproduction or further distribution permitted without the prior
written consent of McGraw-Hill Education.
Chapter Outline

1.1 Introduction to Set Theory


1.2 Subsets and Set Operations
1.3 Statements and Quantifiers
1.4 Truth Tables

© McGraw-Hill Education
Section 1.4
Truth Tables

© McGraw-Hill Education
Concepts

1. Construct Truth Tables for the Negation,


Disjunction, and Conjunction
2. Construct Truth Tables for the Conditional and
Biconditional
3. Construct Truth Tables for Compound
Statements
4. Use the Hierarchy of Logical Connectives

© McGraw-Hill Education
Concept 1

Construct Truth Tables For the


Negation, Disjunction, and
Conjunction

© McGraw-Hill Education
Truth Tables
A truth table is a diagram in table form that is used
to show when a compound statement is true or false
based on the truth values of the simple statements
that make up the compound statement.

© McGraw-Hill Education
Negation
According to our definition of a statement, a
statement is either true or false, but never both.
Consider the simple statement p = “Today is Tuesday.”
If it is in fact Tuesday, then p is true, and its negation ~p =
“Today is not Tuesday” is false.
If it’s not Tuesday, then p is false and ~p is true.

© McGraw-Hill Education
Truth Values for a Negation
The truth table for the negation of p looks like this.
There are two possible conditions for the statement
p – true or false – and the table tells us that in each
case, the negation ~p has the opposite truth value.

p ~p
T F If statement p is true, its negation is false.
F T If statement p is false, its negation is true.

© McGraw-Hill Education
Truth Values with Two
Simple Statements
If we have a compound statement with two
component statements p and q, there are four
possible combinations of truth values for these two
statements:

p q
1. p and q are both true T T
2. p is true and q is false T F
3. p is false and q is true F T
4. p and q are both false F F

© McGraw-Hill Education
Conjunction (And)
Suppose a friend tells you, “I bought a new computer and a
new iPad.” This compound statement can be symbolically
represented by p ∧ q, where
p = “I bought a new computer.”
q = “I bought a new iPad.”
When would this conjunctive statement be true?
If your friend actually had made both purchases, then of
course the statement would be true.
On the other hand, suppose your friend bought only a new
computer or only a new iPad, or maybe neither of those
things. Then the statement would be false.

© McGraw-Hill Education
Truth Values for a Conjunction
The conjunction p ∧ q is true only when both p and q
are true.
The truth table below summarizes the possibilities for the
conjunction, “I bought a new computer and a new iPad.”
p = “I bought a new computer.”
q = “I bought a new iPad.”

p q p∧q
Bought computer and iPad T T T
Bought computer, not iPad T F F
Bought iPad, not computer F T F
Bought neither F F F
© McGraw-Hill Education
Disjunction (Or)
Suppose your friend actually said, “I bought a new computer
or a new iPad.” This compound statement can be
symbolically represented by p ∨ q, where
p = “I bought a new computer.”
q = “I bought a new iPad.”
When would this disjunctive statement be true?
If your friend actually did buy one or the other, or both, then
this statement would be true.
And if he or she bought neither, then the statement would be
false.

© McGraw-Hill Education
Truth Values for a Disjunction
The disjunction p ∨ q is true when either p or q or
both are true. It is false only when both p and q are
false.
The truth table below summarizes the possibilities for the
disjunction, “I bought a new computer or a new iPad.”
p = “I bought a new computer.”
q = “I bought a new iPad.”
p q p∨q
Bought computer and iPad T T T
Bought computer, not iPad T F T
Bought iPad, not computer F T T
Bought neither F F F
© McGraw-Hill Education
Concept 2

Construct Truth Tables For the


Conditional and Biconditional

© McGraw-Hill Education
Conditional (If…then) (1 of 2)
A conditional statement, which is sometimes called
an implication, consists of two simple statements
using the connective if . . . then. The first component
is called the antecedent. The second component is
called the consequent.
Think about the following simple example: “If the Cubs win
tomorrow, they make the playoffs,” symbolically written p → q,
where
p = “The Cubs win tomorrow.”
q = “They make the playoffs.”

© McGraw-Hill Education
Conditional (If…then) (2 of 2)
We’ll break this down into four cases:
Case 1: The Cubs win tomorrow, and they make the playoffs
(both p and q are true). Since they win and make the playoffs,
the statement is definitely true.
Case 2: The Cubs win tomorrow, but don’t make the playoffs (p
is true, but q is false). Since the Cubs didn’t make the playoffs,
the conditional statement is false.
Case 3: The Cubs lose tomorrow and still make the playoffs (p
is false and q is true). The Cubs still make the playoffs even
though they lost. This is actually true.
Case 4: The Cubs lose tomorrow and don’t make the playoffs (p
and q are both false). Same as Case 3. The statement is only
false if the Cubs win and don’t make the playoffs. Hence, true.

© McGraw-Hill Education
Truth Values for a Conditional
The conditional statement p → q is false only when
the antecedent p is true and the consequent q is
false.
The truth table below summarizes the possibilities for the
conditional, “If the Cubs win tomorrow, they make the
playoffs”.
p = “The Cubs win tomorrow.”
q = “They make the playoffs.” p q p→q
Cubs win, make playoffs T T T
Cubs win, don’t make playoffs T F F
Cubs lose, make playoffs F T T
Cubs lose, don’t make playoffs F F T
© McGraw-Hill Education
Biconditional (If and only if) (1 of 2)
A biconditional statement is really two statements;
it’s the conjunction of two conditional statements. In
symbols, we can write either
p↔q or (p → q) ∧ (q → p).

Since the biconditional is a conjunction, for it to be


true, both of the statements p → q and q → p must
be true.

© McGraw-Hill Education
Biconditional (If and only if) (2 of 2)
We’ll also break p ↔ q down into four cases:
Case 1: both p and q are true. Then both p → q and q → p
are true, and the conjunction (p → q) ∧ (q → p), which is also
p ↔ q, is true as well.
Case 2: p is true and q is false. In this case, the implication
p → q is false, so it doesn’t even matter whether q → p is true
or false – the conjunction has to be false.
Case 3: p is false and q is true. This is Case 2 in reverse. The
implication q → p is false, so the conjunction must be as well.
Case 4: p is false and q is false. According to the truth table
for a conditional statement, both p → q and q → p are true in
this case, so the conjunction is as well.

© McGraw-Hill Education
Truth Values for a Biconditional
The biconditional statement p ↔ q is true when p
and q have the same truth value and is false when
they have opposite truth values.

p q p↔q
T T T
T F F
F T F
F F T

© McGraw-Hill Education
Concept 3

Construct Truth Tables For


Compound Statements

© McGraw-Hill Education
EXAMPLE 1 Constructing a Truth Table
(1 of 3)
Construct a truth table for the statement ~p ∨ q.

SOLUTION
Step 1 Set up a table as shown.
The order in which you list the T’s p q
and F’s doesn’t matter as long as T T
you cover all the possible T F
combinations. For consistency, F T
we’ll always use the order TTFF F F
for p and TFTF for q when these
are the only two letters in the
logical statement.

© McGraw-Hill Education
EXAMPLE 1 Constructing a Truth Table
(2 of 3)
SOLUTION continued
Step 2 Find the truth values for ~p
by negating the values for p, and
put them into a new column,
column 3, marked ~p. p q ~p
Truth values for ~p are opposite T T F
those for p. T F F
F T T
F F T

© McGraw-Hill Education
EXAMPLE 1 Constructing a Truth Table
(3 of 3)
SOLUTION continued
Step 3 Find the truth values for
the disjunction ~p ∨ q.
Use the T and F values for ~p
and q in columns 2 and 3, p q ~p ~p ∨
remembering that a disjunction q
is false only when both T T F T
components are false. T F F F
The truth values for the F T T T
statement ~p ∨ q are found in F F T T
column 4. The statement is only
false when p = T and q = F.
© McGraw-Hill Education
EXAMPLE 2 Constructing a Truth Table
(1 of 3)
Construct a truth table for the statement ~(p → ~q).

SOLUTION
Step 1 Set up a table as in
Example 1. p q ~q
Step 2 Find the truth values for ~q T T F
by negating the values for q, and T F T
put them into a new column F T F
marked ~q. Truth values for ~q are F F T
opposite those for q.

© McGraw-Hill Education
EXAMPLE 2 Constructing a Truth Table
(2 of 3)
SOLUTION continued
Step 3 Find the truth values
for the implication p → ~q,
using the values in columns
1 and 3, remember that an p q ~q p → ~q
implication is false only
T T F F
when the antecedent is true
and the consequent is false.
T F T T
F T F T
F F T T

© McGraw-Hill Education
EXAMPLE 2 Constructing a Truth Table
(3 of 3)
SOLUTION continued
Step 4 Find the truth
values for the negation
~(p → ~q) by negating
the values for p → ~q p q ~q p →~q ~(p →~q)
in column 4.
T T F F T
The truth values for T F T T F
~(p → ~q) are in F T F T F
column 5. The F F T T F
statement is true only
when p and q are both
true.
© McGraw-Hill Education
EXAMPLE 3 Constructing a Truth Table
(1 of 3)
Construct a truth table for the statement p ∨ (q → r).

SOLUTION p q r
Step 1 Set up a table as shown. T T T
The order in which you list the T’s T T F
and F’s doesn’t matter as long as T F T
you cover all the possible T F F
combinations. For consistency, F T T
we’ll always use the pattern shown F T F
for 3 letters.
F F T
F F F

© McGraw-Hill Education
EXAMPLE 3 Constructing a Truth Table
(2 of 3)
SOLUTION continued
Step 2 Find the truth value
for the statement in p q r q→r
parentheses, q → r. T T T T
The conditional is true T T F F
unless q is true and r is T F T T
false. T F F T
F T T T
F T F F
F F T T
F F F T

© McGraw-Hill Education
EXAMPLE 3 Constructing a Truth Table
(3 of 3)
SOLUTION continued
Step 3 Find the truth values for
the disjunction p ∨ (q → r),
using the values for p from p q r q → r p ∨ (q →
column 1 and those for q → r r)
from column 4. T T T T T
The disjunction is true unless T T F F T
both p and q → r are false. T F T T T
The truth values for the T F F T T
statement p ∨ (q → r) are found F T T T T
in column 5. The statement is F T F F F
true unless p and r are false F F T T T
while q is true. F F F T T
© McGraw-Hill Education
Concept 4

Use the Hierarchy of Logical


Connectives

© McGraw-Hill Education
Hierarchy of Connectives
We have seen that when we construct truth tables,
we find truth values for statements inside
parentheses first. To avoid having to always use
parentheses, a hierarchy of connectives has been
agreed upon by those who study logic.
1. Negation ~
2. Conjunction ∧ or disjunction ∨
3. Conditional →
4. Biconditional ↔
This hierarchy tells us which connectives should be
done first when there are no parentheses to guide us.
© McGraw-Hill Education
EXAMPLE 4 Using the Hierarchy of
Connectives (1 of 2)
For each, identify the type of statement using the
hierarchy of connectives, and rewrite by using
parentheses to indicate order.
(a) ~p ∨ ~q
(b) p → ~q ∧ r
(c) p ∨ q ↔ q ∨ r
(d) p → q ↔ r

© McGraw-Hill Education
EXAMPLE 4 Using the Hierarchy of
Connectives (2 of 2)
SOLUTION
(a) For ~p ∨ ~q : the negations are higher on the list than the
disjunction; the statement is a disjunction and looks like
(~p) ∨ (~q) with parentheses.
(b) For p → ~q ∧ r : the lowest connective is conditional, so
the statement is a conditional and looks like p → (~q ∧ r)
with parentheses.
(c) For p ∨ q ↔ q ∨ r : the biconditional is lowest on the list;
the statement is a biconditional and looks like
(p ∨ q) ↔ (q ∨ r) with parentheses.
(d) For p → q ↔ r : the biconditional comes last; the
statement is a biconditional and looks like (p → q) ↔ r
with parentheses. © McGraw-Hill Education
EXAMPLE 5 An Application of Truth Tables
(1 of 2)
Use the truth value of each simple statement to
determine the truth value of the compound
statement.
p: The show American Idol ended its 15-season run
in spring of 2016.
q: There are no singing contests left on network TV.
r: Trent Harmon was the winner of the final season.
Statement: p ∨ q → r

© McGraw-Hill Education
EXAMPLE 5 An Application of Truth Tables
(2 of 2)
SOLUTION
Idol did in fact air its last episode on April 7, 2016, so
statement p is true. Statement q, on the other hand, is false,
at least as of this writing. NBC’s The Voice is one singing
show that’s still active, and there are probably others.
Statement r is true, as a little bit of Internet research
indicates.
Now we’ll analyze the compound statement. First, according
to the hierarchy of connectives, the disjunction should be
evaluated: (p ∨ q) → r
Substituting the truth values: (T ∨ F) → T
The disjunction is true, so: T→T
The implication is true. T .
© McGraw-Hill Education

You might also like