# Thinking Mathematically by Robert Blitzer

Document Sample

```					  Thinking
Mathematically
Chapter 3
Logic
Thinking
Mathematically
Section 1
Statements, Negations, and
Quantified Statements
Statements
A statement is a sentence that is either true or false,
but not both at the same time.
Examples
“Miami is a city in Florida” is a true statement.
“Two plus two equals five” is a false statement.
“Today is Friday” is a statement that is
sometimes true and sometimes false, but never
both true and false at the same time.
“Go to the grocery store” is not a statement. It
is a command and is neither true nor false.
Negation of Statements
The negation of a statement is another statement that
has the opposite truth value. That is, when a
statement is true its negation is false and when the
statement is false its negation is true.
Examples
“Miami is not a city in Florida” is the negation
of the statement “Miami is a city in Florida”.
“Two plus two is not equal to five” is the negation
of the statement “Two plus two equals five”.
Be careful! “Two plus two equals four” is a true
statement but it is not the negation of “Two plus two
equals five”.
Symbolic Statements
Just as x can be used as a name for a number, a
symbol such as p can be used as a name for a
statement.
When p is used as a name for a statement the symbols
~p are used as a name for the negation of p.
Examples
Let p stand for “Miami is a city in Florida.”
Then ~p is the statement “Miami is not a city in
Florida.”
Quantified Statements
A quantified statement is one that says something
about all, some, or none of the objects in a collection.

Examples
“All students in the college are taking history.”
“Some students are taking mathematics.”
“No students are taking both mathematics and
history.”
Equivalent Statements
In any language there are many ways to say the same
thing. The different linguistic constructions of a
statement are considered equivalent.
Example
“All students in the college are taking history.”
“Every student in the college is taking history.”
Example
“Some students are taking mathematics.”
“At least one student is taking mathematics.”
Negating Quantified Statements
The negation of a statement about all objects is not
all. Not all can often be expressed by some are not.

Examples
p : All students in the college are taking history.
~p : Some students in the college are not taking
history.
Negating Quantified Statements
The negation of a statement about some objects is not
some. Not some can often be expressed by none or not
any.
Examples
p : Some students are taking mathematics.
~p : None of the students are taking mathematics.
Negating Quantified Statements
The negation of a statement about all objects is not
all. Not all can often be expressed by some are not.

The negation of a statement about some objects is not
some. Not some can often be expressed by none or not
any.
Statement               Negation of statement
All A are B                   No A are B

Some A are B                   Some A are not B
Thinking
Mathematically
Section 2
Compound Statements and
Connectives
Compound Statements
Simple statements can be connected with and,
either … or, if … then, or if and only if. These more
complicated statements are called compound statements.
Examples
“Miami is a city in Florida” is a true statement.
“Atlanta is a city in Florida” is a false statement.
“Either Miami is a city in Florida or Atlanta is a city
in Florida” is a compound statement that is true.
“Miami is a city in Florida and Atlanta is a city in
Florida” is a compound statement that is false.
And Statements
When two statements are represented by p and q
the compound and statement is p  q.
p: Harvard is a college.
q: Disney World is a college.
p  q: Harvard is a college and Disney World is a
college.
p  ~q: Harvard is a college and Disney World is
not a college.
Either ... or Statements
When two statements are represented by p and q
the compound either ... or statement is p  q.
p: The bill receives majority approval.
q: The bill becomes a law.
p  q: The bill receives majority approval or the
bill becomes a law.
p  ~q: The bill receives majority approval or the
bill does not become a law.
The Two Meanings of Or
• Compound statements involving the word or
are a bit harder to understand.
• There are two meanings:
• 1. Exclusive or: At a Chinese Restaurant, the
lunch menu says: "Choose one from column A
or one from column B."
• You can only choose one item, so you are not
allowed to choose from both columns.
The Two Meanings of Or
• Compound statements involving the word or
are a bit harder to understand.
• There are two meanings:
• 2. Inclusive or: "A good teacher should be
either smart or funny." Here, you are implying
that it's possible for a good teacher to be both
smart AND funny, but at least one of these
characteristics should be true.
The Two Meanings of Or
In this class, we will use the word or to be the
inclusive or: one or the other or both!
If ... then Statements
When two statements are represented by p and q
the compound if ... then statement is: p  q.
p: Ed is a poet.
q: Ed is a writer.
p  q: If Ed is a poet, then Ed is a writer.
q  p: If Ed is a writer, then Ed is a poet.
~q  ~p: If Ed is not a writer, then Ed is not a
Poet
If and only if Statements
When two statements are represented by p and q the
compound if and only if statement is: p  q.
p: The word I'm thinking of is "set".
q: The word has 464 meanings.
p  q: The word I'm thinking of is "set" if and only if
the word has 464 meanings.
~q  ~p: The word I'm thinking of does not have 464
meanings if and only if the word is not "set".
Translating sentences into
symbolic expressions
• Words such as and, but, or, either,
neither, if, then, and so on are used in
ordinary sentences and have meanings in
logic.
• Example:
– He went to the store but didn't buy anything.
Translating sentences into
symbolic expressions
He went to the store but didn't buy anything.
He went to the store and didn't buy anything.
He went to the store yet he didn't buy anything.
Although he went to the store,
He went to the store ; nevertheless,
Translating symbolic
expressions into sentences
• If he goes home, it is not true that
he missed his curfew or that
he will be late for work tomorrow.
– p: he goes home
– q: he missed his curfew
– r: he will be late for work tomorrow.

p  ~( q ∨ r )
Symbolic Logic
Statements of Logic
Name        Symbolic Form   Meaning
Negation         ~p           not
Conjunction      pq          and
Disjunction      pq          or
Conditional      pq          if..then
Biconditional    pq          is the same as
Thinking
Mathematically
Section 3
Truth Tables for Negation,
Conjunction, and Disjunction
Truth Tables - Negation
If a statement is true then its negation is false
and if the statement is false then its negation
is true. This can be represented in the form
of a table called a truth table.

p     ~p
T     F
F     T
Truth Tables - Conjunction
The conjunction of two statements is true
only when both of them are true. This can
be represented in the form of a truth table
in the following way.
p      q     pq
T      T      T
T      F      F
F      T      F
F      F      F
Truth Tables - Disjunction
The disjunction of two statements is false
only when both of them are false. This can
be represented in the form of a truth table
in the following way.
p      q     pq
T      T      T
T      F      T
F      T      T
F      F      F
Constructing a Truth Table
Construct a truth table for (p  ~q)  q.

p      q     ~q    p  ~q         (p  ~q)  q
T      T      F       F                 T
T      F      T       T                 T
F      T      F       F                 T
F      F      T       F                 F

does this look familiar?
Constructing a Truth Table
Construct a truth table for ( p  ~q)  (~p  q )

p   q   ~p ~q (p  ~q)   (~p  q)   (p  ~q)  (~p  q)

T   T   F   F    F          F              F

T   F   F   T    T          F              T
F   T   T   F    F          T              T

F   F   T   T    F          F              F
Section Quiz
Construct a truth table for (p  q)  (~p  ~q)

p   q   ~p ~q (p  q)   (~p  ~q) (p  q)  (~p  ~q)

T   T   F   F    T          F            T

T   F   F   T    F          F            F
F   T   T   F    F          F            F

F   F   T   T    F          T            T
Section Quiz
Construct a truth table for (p  q)  ~r

p   q   r   ~r (p  q)   (p  q)  ~r
T   T   T   F     T          T
T   T   F   T     T          T
T   F   T   F     F          F
T   F   F   T     F          T
F   T   T   F     F          F
F   T   F   T     F          T
F   F   T   F     F          F
F   F   F   T     F          T
Section Quiz
• For each of the following 10 expressions,
write down the value of the expression:
• For example
2. F ∨F F ∧
3. ~(~F)F F
10. ∨ ∨F ∨
1. T TF∧∨T F T
•
5.
4.
9.
6.
8.
7.
• =T
Solutions
1.   T ∧ F = F
2.   F ∨ F = F
3.   T ∧ T ∧ T = T
4.   F ∨ T =T
5.   T ∧ F =F
6.   ~(~F) = F
7.   F ∧ F =F
8.   T∨F∨F =T
9.   T ∧ T =T
10.   F ∨ F =F
Section Quiz
• Construct a truth table for ~p ∨ q
p q ~q    ~p ∨ q          p q ~q     ~p ∨ q   p q ~q    ~p ∨ q
T T   F     T            T T     T     T      T T   F     T
T F F       T            T F F         T      T F   T     T
F T   T     F            F T     T     T      F T   F     F
F F   T     T            F F F         F      F F   T     T

p q ~q      ~p ∨ q
T T    F      T
T F F         T
F T    T      F
F F    T      T
Thinking
Mathematically
Section 4
Truth Tables for the Conditional
and Biconditional
Conditional Statements
The truth table for implication (→) is
p        q    p→ q
T        T     T
T        F     F
F        T     T
F        F     T

This one is difficult to understand.
Let's try anyway.
Conditional Statements
The truth table for implication (→) is
p      q      p→ q
T      T       T
T      F       F
F      T       T
F      F       T
Suppose I say, "If it rains tomorrow, I'll
be carrying an umbrella."
p: it is raining tomorrow
q: I'm carrying an umbrella
Conditional Statements
The truth table for implication (→) is
p   q      p→ q
T   T       T       No. I told
T   F       F       the truth
F   T       T
F   F       T

The next day, it's raining. You look out
your window and there I am, keeping dry
under an umbrella.
Did I lie?
Conditional Statements
The truth table for implication (→) is
p   q      p→ q
T   T       T       I sure did!
T   F       F
F   T       T
F   F       T

The next day, it's raining. You look out
your window and there I am, soaking wet
without an umbrella.
Did I lie?
Conditional Statements
The truth table for implication (→) is
p   q      p→ q
T   T       T       Not really.
T   F       F
F   T       T       I never said
F   F       T       what I'd do if it
didn't rain.
The next day, it's sunny. You look out your
window and there I am, holding an
umbrella.
Did I lie?
Conditional Statements
The truth table for implication (→) is
p   q      p→ q
T   T       T       Not really.
T   F       F
F   T       T       I never said
F   F       T       what I'd do if it
didn't rain.
The next day, it's sunny. You look out your
window and there I am, without an
umbrella.
Did I lie?
Conditional Statements
The truth table for implication (→) is
p        q        p→ q
T        T         T
T        F         F
F        T         T
F        F         T
 p is called the precedent (or hypothesis)
 q is called the consequent (or consequence)
 An implication is false if and only if the precedent is
true and the consequent is false.
Biconditional Statements
The truth table for the biconditional, "if
and only if", (↔) is
p     q      p↔q
T     T       T
T     F       F
F     T       F
F     F       T
This operator can be viewed in two ways:
- A two-way implication: p → q and q → p
Biconditional Statements
The truth table for the biconditional, "if
and only if", (↔) is
p     q      p↔q
T     T       T
T     F       F
F     T       F
F     F       T
This operator can be viewed in two ways:
- The concept of "has exactly the same
truth table as" or "is equivalent to"
Biconditional Statements
• Look at the truth tables below:

p   q   q↔p      p   q   pq qp   pq /\ qp
T   T    T       T   T    T   T        T
T   F    F       T   F    F   T        F
F   T    F       F   T    T   F        F
F   F    T
F   F    T   T        T
Section Quiz
• For each of the following 10 expressions,
write down the value of the expression:
• For example
1. T TT TTF
10. ∨ ∧F
2. F ⟷ ~F
•       ⟷
F
3. ~(~T)FF
5.
6.
9.
8.
4.
7.
• =T
Solutions
1.   T  F = F
2.   F ⟷ F = T
3.   T ∧ T = T
4.   F  T = T
5.   T ∧ ~F = T
6.   ~(~T) = T
7.   F  F =T
8.   T⟷F = F
9.   T ∧ T =T
10.   T  F = F
Thinking
Mathematically
Section 5
Equivalent Statements, Variations
of Conditional Statements, and
DeMorgan’s Laws
Equivalent Statements
 We saw at the end of a previous lecture
that the truth table for (p /\ ~q) \/ q was the
same as the one for p \/ q .
 Whenever two statements have the same
truth table values, we say they are
equivalent.
Equivalent Statements
Two statements are equivalent if they have
the same truth values.
p      q     pq       p    q   ~p   ~pq
T      T      T        T    T   F      T
T      F      T        T    F   F      T
F      T      T        F    T   T      T
F      F      F        F    F   T      F

So the statements pq and ~pq are equivalent.
They mean the same thing!
Equivalent Statements
Whoa!!!! The statements p  q and
~p  q mean the same thing??????????
Equivalent Statements
The statements p  q and ~p  q are equivalent.
They mean do the same thing!
•Why?
• In order for p  q to be true, either p or q or
maybe both have to true. That means that if p is
false, we would need for q to be true.
• If p is false, then q is true.
• If ~p is true, then q is true.
• If not p then q.
• ~p  q
The Contrapositive
The statements p  q and ~q  ~p are
equivalent. They are contrapositives.
p      q     pq     p    q   ~p   ~q
~q   ~q  ~p
~q  ~p
T      T      T      T    T   F    F       T
T      F      F      T    F   F    TT      F
F      T      T      F    T   T     F      T
F      F      T      F
F    F
F   T
T    TT      T

For example, "If it rains tomorrow, I'll take my
umbrella" means exactly the same thing as "If I don't
take my umbrella tomorrow, it's because it isn't
raining."
The Contrapositive
The statements p  q and ~q  ~p are
equivalent. They are contrapositives.
For example, "If it rains tomorrow, I'll take my umbrella"
means exactly the same thing as "If I don't take my
umbrella tomorrow, it's because it isn't raining."

Think about it. The original statement says that on the
condition that it's raining, I'll definitely take an umbrella.
So if you see me not carrying an umbrella, then it can't be
raining!
Converse and Inverse
q  p is the converse of p  q.
~p  ~q is the inverse of p  q.
The converse and inverse are contrapositives
of each other and are equivalent.
p      q    qp     p    q   ~p   ~q ~p~q
T      T     T      T    T   F    F    T
T      F     T      T    F   F    T    T
F      T     F      F    T   T    F    F
F      F     T
F    F   T    T    T
Conditional Statements
Let p and q be statements.

Name             Symbolic Form
Conditional         pq
Converse            qp
Inverse            ~p  ~q
Contrapositive     ~q  ~p
Conditional Statements
Conditional: If it rains tomorrow, I'll take my umbrella.
Converse: If I have my umbrella tomorrow, it will be raining.
Inverse: If it doesn't rain tomorrow, I won't take my umbrella.
Contrapositive: If I don't have my umbrella tomorrow, it
won't be raining.
DeMorgan's Laws
• The statements ~(p ∧ q) and ~p ∨ ~q are
equivalent. This is one of two DeMorgan's Laws.
• ~(p ∧ q) says "It is false that p and q are true"
• ~p ∨ ~q says "Either p is not true or q is not true"
• These are the same because if it is false that p and
q are both true, then either p has to be false or q
has to be false.
DeMorgan's Laws
• The statements ~(p ∧ q) and ~p ∨ ~q are
equivalent. This is one of two
DeMorgan's Laws.

p   q   pq ~(pq)    p   q   ~p   ~q   ~p~q
T   T    T    F       T   T   F    F      F
T   F    F    T       T   F   F    T      T
F   T    F    T       F   T   T    F      T
F   F    F    T       F   F   T    T      T
DeMorgan's Laws
• The statement ~(p\/q) and ~p/\~q are
equivalent. This is the other
DeMorgan's Law.

p   q   pq ~(pq)     p    q   ~p   ~q   ~p~q
T   T    T    F        T    T   F    F      F
T   F    T    F        T    F   F    T      F
F   T    T    F        F    T   T    F      F
F   F    F    T        F    F   T    T      T
Another equivalence
• The statements p→q and ~p  q are
equivalent.

p   q p→q             p   q   ~p   ~p\/q
T   T  T              T   T   F     T
T   F  F              T   F   F     F
F   T  T              F   T   T     T
F   F   T     T
F   F  T
Another equivalence
• The statements p→q and ~p  q are
equivalent.
• If p is true (p), that means that ~p is
false.
• So, in order for ~p  q to be true, if p
is true (in other words, ~p is false),
the other half of ~p  q, namely q,
must be true. If p then q.
Thinking
Mathematically
Section 6
Arguments and Truth Tables
Arguments
There are two parts to an argument.
The first part consists of a collection of
statements called the premises.
The second part is a statement called the
conclusion.
Symbolically the argument is the conditional
statement whose if part is the conjunction of
all the premises and whose then part is the
conclusion.
An Example of an Argument
p                     q
pq        If I get an A on the final I will pass the course.
p          I got an A on the final.
q         I will pass the course
The argument is “If I get an A on the final I will
pass the course and I got an A on the final.
Therefore I will pass the course.”
[(p  q) /\ p]  q
An Example of an Argument
pq           If I get an A on the final I will pass the course.
p             I got an A on the final.
q            I will pass the course

The argument says that getting an A on the final will assure
me of passing the course. Since I did get an A, the professor
has to give me a passing grade (or else he lied to me.)
We can show that this argument makes sense by showing that
the corresponding truth table is a tautology.

A tautology is a logical statement that is always true; its
truth table has T on all lines.
Valid Arguments
Valid arguments are tautologies. That is, they
are always true.
pq          If I get an A on the final I will pass the course.
p            I got an A on the final.
q           I will pass the course
[(p  q) /\ p]  q
p   q pq (pq)p q [(pq)p]q tautology !!!
T   T T      T    T      T
this is a valid
T   F F      F    F      T       argument !!!
F   T T      F    T      T
F   F T      F    F      T
Another Example of an Argument
pq         If I get an A on the final I will pass the course.
q           I passed the course !!!
p          I must have gotten an A on the final
[(p  q) /\ q]  p
p    q   pq (pq)q        p [(pq)q]p not a
tautology !!!
T    T    T     T           T      T
T    F    F     F           T      T      not a valid
F    T    T     T           F      F      argument !!!
F    F    T     F           F      T
Evaluating Real Arguments
• Step 1: Assign variables (p, q, r, …) to each basic
• Step 2: For each premise in the argument, write the
corresponding logical expression.
• Step 3: Write the corresponding logical expression
for the conclusion.
• Step 4: Connect all the premise expressions with .
Connect that big expression with the conclusion
expression with .
• Step 5: Construct the truth table for the overall
expression.
• Step 6: If the expression is a tautology, it is a valid
argument.
Another Example:
• Here's a real-world argument. Is it a valid
argument?
–   If I go out, I'll go to the store.
–   If I go to the store, I will buy some chips.
–   I'm not going out.
–   Therefore, I won't be buying chips.
Another Example:
p            q
•   If I go out, I'll go to the store.
•   If I go to the store, I will buy some chips.
•   I'm not going out.               r
•   Therefore, I won't be buying chips.

Step 1: Assign variables (p, q, r, …) to each basic statement
Another Example:
• If I go out, I'll go to the store.  q
p
• If I go to the store, I will buy some chips.
qr
• I'm not going out.                  ~p
• Therefore, I won't be buying chips.    ~r
[(p  q)  (q  r)  ~p]  ~r
For each premise in the argument,
Step 2:3: Write the corresponding logical write the
Step Connect all the premise expressions with .
Step 4:
corresponding logical expression.
expression big expression with
Connect that for the conclusion. the conclusion
expression with .
Step 6: If the expression is atable for the overall expression.
Step 5: Construct the truth tautology, it is a valid argument.
p q r p  q q  r ~p [(p  q)        ~r [(p  q)  (q  r)  ~p] ~r
 (q  r)
 ~p
T T T     T     T    F       F       F                   T
T T F     T     F    F       F       T                   T
T F T     F     T    F       F       F                   T
T F F     F     T    F       F       T                   T
F T T     T     T    T       T       F                   F
F T F     T     F    T       F       T
F F T     T     T    T       T       F
F F F     T     T    T       T       T

not a tautology. not valid
Another Example:
• If it is not sunny, it is either overcast or it's
the evening.
• If it's the evening, it can't be overcast.
• If it's overcast, I will wear a raincoat.
• It's not the evening.
• Therefore, I am wearing a raincoat.
Another Example:
•   p: it is sunny.
•   q: it is overcast.
•   r: it is the evening.
•   s: I am wearing a raincoat.
Another Example:
• If it is not sunny, it is either overcast or it's
the evening. ~p(qr)
• If it's the evening, it can't be overcast. r~q
• If it's overcast, I will wear a raincoat. qs
• It's not the evening. ~r
• Therefore, I am wearing a raincoat. s
• [(~p(qr))  (r~q)  (qs)  ~r]  s
First half of truth table. Other half is when p is false
p   q   r    s   ~p(qr)   r~q   qs    ~r   [(~p(qr))  (r~q)   [(~p(qr)) 
 (qs)  ~r]          (r~q)
 (qs)  ~r]  s

T T T T               T       F     T     F           F                    T
T T T F               T       F     F     F           F                    T
T T F T               T       T     T     T           T                    T
T   T   F    F        T       T     F     T           F                    T
T   F   T    T        T       T     T     F           F                    T
T   F   T    F        T       T     T     F           F                    T
T   F   F    T        T       T     T     T           T                    T
T   F   F    F        T       T     T     T           T                    F

not a tautology. not valid
~p is F
Section Quiz
• I'll either get my hair cut or I won't go
outside.
• I'm not getting my hair cut
• I won't go outside.

• Is this a valid argument?
p: get haircut
Section Quiz          q: go outside

• I'll either get my hair cut or I won't go
outside.       p  ~q
• I'm not getting my hair cut.        ~p
• Therefore, I won't go outside. ~q
[(p  ~q)  ~p]  ~q

• Is this a valid argument?
Section Quiz
Is this a valid argument?

yes
~q
p   q   ~p   ~q p  ~q (p  ~q)~p   [(p~q)~p]~q
T   T   F    F    T         F        F      T
T   F   F    T    T         F        T      T
F   T   T    F    F         F        F      T
F   F   T    T    T         T        T      T
Section Quiz
• Which of the following is a tautology?
–   a) p  ~p
–   b) p  ~p
–   c) p → ~p
–   d) p ↔ ~p

```
DOCUMENT INFO
Shared By:
Categories:
Tags:
Stats:
 views: 11 posted: 9/2/2011 language: English pages: 81