Beruflich Dokumente
Kultur Dokumente
Reasoning
[Binary Operations]
LOGIC
PROPOSITION
the science of reasoning
Proposition
Examples:
You are a
Thomasian.
Examples:
Smoking is
addictive.
LOGIC the science of reasoning
Proposition
Examples:
Staying late at
night increases
the risk of brain
LOGIC
cancer. the science of reasoning
Proposition
Examples:
Twice an
integer is
always an even
LOGIC
integer. the science of reasoning
Proposition
Examples:
Twice a number
is always an
even number.
LOGIC the science of reasoning
Proposition
Is this a proposition?
Where do you
live?
LOGIC the science of reasoning
Proposition
Is this a proposition?
Thrice a
number
LOGIC the science of reasoning
Proposition
Is this a proposition?
LISTEN!
Is this a proposition?
IU is
beautiful.
LOGIC the science of reasoning
Proposition
Is this a proposition?
SMART.
LOGIC the science of reasoning
Proposition symbols
IU is
beautiful.
LOGIC p
the science of reasoning
Proposition symbols
IU is not
beautiful.
LOGIC ~p
the science of reasoning
Proposition symbols
SMART.
p
LOGIC the science of reasoning
Negation symbol
~p
LOGIC
NOT SMART.
the science of reasoning
Negation symbol
NOT
LOGIC
Some reference use ¬ to denote negation.
thesame
~ p is the science
asof¬ reasoning
p.
TRUTH TABLE
a tabular
representation of
all the
combinations of
values for inputs
and their
corresponding the science of reasoning
outputs
TRUTH TABLE
p ~p
T F
F T
the science of reasoning
Compound propositions
pq
a proposition
formed by
combining two or
s r
more simple
LOGIC
propositions
the science of reasoning
Compound propositions
Examples:
I am a Thomasian.
LOGIC
p the science of reasoning
Compound propositions
Examples:
q
LOGIC
I enjoy flooded areas.
the science of reasoning
Compound propositions
Examples:
p LOGIC
q
I am a Thomasian. I enjoy flooded area
Examples:
and
p LOGIC
^ q
I am a Thomasian I enjoy flooded area.
Examples:
or
p LOGIC
v q
I am a Thomasian I enjoy flooded area.
Examples:
If thenI enjoy flooded area.
p LOGIC
q
I am a Thomasian
→
the science of reasoning
Conjunction (AND)
false.
Conjunction
p ∧ q is true if and only if both p and q are true. Otherwise,
false.
p q p∧q
T LOGIC
T T
T F F
F T F
the science of reasoning
F F F
Conjunction
Construct the truth table for ~p ∧ q
p q ~p ~ p ∧ q
T LOGIC
T F F
T F F F
F T T T
the science of reasoning
F F T F
Conjunction
Construct the truth table for ~p ∧ ~q
p q ~p ~q ~p ∧ ~q
T
T
T
F
F
F
LOGIC F
T
F
F
F T T F F
the science of reasoning
F F T T T
Conjunction
Construct the truth table for ~(p ∧ q)
p q p ∧ q ~(p∧q)
T TLOGIC T F
T F F T
F T F T
the science of reasoning
F F F T
Disjunction (OR)
Let p and q be propositions.
The disjunction p or q,
LOGIC
denoted by p v q is the
proposition.
p v q is true when one of the
proposition or the
both is oftrue.
science reasoning
Otherwise, false.
Disjunction (OR)
p v q is false if and only if both of p and q is false.
Otherwise, true.
p q pvq
T LOGIC
T T
T F T
F T T
the science of reasoning
F F F
Disjunction
Construct the truth table for p v ~q
p q ~q p v ~q
T LOGIC
T F T
T F T T
F T F F
the science of reasoning
F F T T
Disjunction
Construct the truth table for ~p v ~q
p q ~p ~q ~pv~q
T
T
T
F
LOGIC F
F
F
T
F
T
F T T F T
the science of reasoning T
F F T T
Disjunction
Construct the truth table for ~(p v q)
p q p v q ~(p v q)
T
T
T
F
LOGIC T
T
F
F
F T T F
the science of reasoning
F F F T
~p ∧ ~q is exactly
the the same
science as ~(p v q)
of reasoning
~(p ∧ q) is exactly the same
the science as ~p v ~q
of reasoning
De Morgan’s Law
De Morgan’s Law
~p ∧ ~q ≡ ~(p v q)
~p v ~q ≡ ~(p ∧ q)
Exclusive disjunction (Exactly OR)
p ⊕ q is true when exactly one of p and q is true.
Otherwise, false.
p q p⊕q
T T F
T F T
F T T
F F F
Exclusive Disjunction
Construct the truth table for ~p ⊕ q
p q ~p ~p ⊕ q
T
T
T
F
LOGIC F
F
T
F
F T T F
the science of reasoning
F F T T
NAND (not and)
p NAND q or p|q is false when both p and q are true.
Otherwise, true.
p q p|q
T LOGIC
T F
T F T
F T T
the science of reasoning
F F T
NAND (not and)
Construct the truth table for p|~q
p q ~q p|~q
T LOGIC
T F T
T F T F
F T F T
the science of reasoning
F F T T
NOR (not or)
p NOR q or p↓q is true when both p and q are false.
Otherwise, false.
p q p↓q
T LOGIC
T F
T F F
F T F
the science of reasoning
F F T
NOR (not or)
Construct the truth table for p↓~q
p q ~q p↓~q
T LOGIC
T F F
T F T F
F T F T
the science of reasoning
F F T F
TRY THIS!
Construct the truth table for ~(p ⊕ ~q) ∧ r
p q ~q (p ⊕ ~q) ~(p ⊕ ~q) r ~(p ⊕ ~q) ∧ r
T T F T F T T
T F T F T T T
F T F F T T T
F F T T F T T
T T F T F F F
T F T F T F T
F T F F the science
T of reasoning
F T
F F T T F F F
TRY THIS!
Construct the truth table for ~(p ⊕ ~q) ∧ r
p q ~q
~q (p ⊕ ~q) ~(p ⊕ ~q) r ~(p ⊕ ~q) ∧ r
T T F T F T T
T F T F T T T
F T F F T T T
F F T T F T T
T T F T F F F
T F T F T F T
F T F F the science
T of reasoning
F T
F F T T F F F
TRY THIS!
Construct the truth table for ~(p ⊕ ~q) ∧ r
p q ~q ⊕⊕
(p(p ~q)
~q) ~(p ⊕ ~q) r ~(p ⊕ ~q) ∧ r
T T F T F T T
T F T F T T T
F T F F T T T
F F T T F T T
T T F T F F F
T F T F T F T
F T F F the science
T of reasoning
F T
F F T T F F F
TRY THIS!
Construct the truth table for ~(p ⊕ ~q) ∧ r
p q ~q (p ⊕ ~q) ~(p ⊕
~(p ⊕ ~q)
~q) r ~(p ⊕ ~q) ∧ r
T T F T F T T
T F T F T T T
F T F F T T T
F F T T F T T
T T F T F F F
T F T F T F T
F T F F the science
T of reasoning
F T
F F T T F F F
TRY THIS!
Construct the truth table for ~(p ⊕ ~q) ∧ r
p q ~q (p ⊕ ~q) ~(p ⊕ ~q) r ⊕ ~q)
~(p ⊕
~(p ∧ rr
~q) ∧
T T F T F T F
T F T F T T T
F T F F T T T
F F T T F T F
T T F T F F F
T F T F T F F
F T F F the science
T of reasoning
F F
F F T T F F F
TRY THIS!
Is (p v q) ∧ r ≡ (p ∧ r) v (q ∧ r)?
TRY THIS!
Is (p v q) ∧ r ≡ (p ∧ r) v (q ∧ r)?
p q pvq r (p v q) ∧ r p∧r q∧r (p ∧ r) v (q ∧ r)
T T T T T T T T
T F T T T T F T
F T T T T F T T
F F F T F F F F
T T T F F F F F
T F T F F F F F
F T T F F the science
F ofF reasoning F
F F F F F F F F
TRY THIS!
Is (p v q) ∧ r ≡ (p ∧ r) v (q ∧ r)?
p q pvq r (p v q) ∧ r p∧r q∧r (p ∧ r) v (q ∧ r)
T T T T T T T T
T F T T T T F T
F T T T T F T T
F F F T F F F F
T T T F F F F F
T F T F F F F F
F T T F F the science
F ofF reasoning F
F F F F F F F F
TRY THIS!
Is (p v q) ∧ r ≡ (p ∧ r) v (q ∧ r)?
p q pvq r q)q)∧ ∧
(p(pv v rr p∧r q∧r (p ∧ r) v (q ∧ r)
T T T T T T T T
T F T T T T F T
F T T T T F T T
F F F T F F F F
T T T F F F F F
T F T F F F F F
F T T F F F
the science ofF reasoning F
F F F F F F F F
TRY THIS!
Is (p v q) ∧ r ≡ (p ∧ r) v (q ∧ r)?
p q pvq r (p v q) ∧ r pp ∧∧ rr q∧r (p ∧ r) v (q ∧ r)
T T T T T T T T
T F T T T T F T
F T T T T F T T
F F F T F F F F
T T T F F F F F
T F T F F F F F
F T T F F the science
F ofF reasoning F
F F F F F F F F
TRY THIS!
Is (p v q) ∧ r ≡ (p ∧ r) v (q ∧ r)?
p q pvq r (p v q) ∧ r p∧r qq∧∧r r (p ∧ r) v (q ∧ r)
T T T T T T T T
T F T T T T F T
F T T T T F T T
F F F T F F F F
T T T F F F F F
T F T F F F F F
F T T F F the science
F F reasoning F
of
F F F F F F F F
TRY THIS!
Is (p v q) ∧ r ≡ (p ∧ r) v (q ∧ r)?
p q pvq r (p v q) ∧ r p∧r q∧r (p ∧ r) v (q ∧ r)
T T T T T T T T
T F T T T T F T
F T T T T F T T
F F F T F F F F
T T T F F F F F
T F T F F F F F
F T T F F the science
F ofF reasoning F
F F F F F F F F
LOGIC
CONDITIONAL
STATEMENTS
→
the science of reasoning
Conditional Statement
p→q
p is called the hypothesis,
LOGIC
the premise or the antecedent.
LOGIC
p→q
LOGIC
If p 𝑡ℎ𝑒𝑛 q.
p is sufficient for q.
q if p.
q is necessary for
the science p.
of reasoning
p implies q.
Conditional Statement
p→q
LOGIC
If p 𝑡ℎ𝑒𝑛 q.
q when p.
q follows from p.
the science of reasoning
Conditional Statement
p → q is true on the condition the p holds.
p q p→q
T LOGIC
T T
T F F
F T T
the science of reasoning
F F T
Conditional Statment
If I am a pharmacists 𝑡ℎ𝑒𝑛 I know
drugs/medicine.
p→q p q p→q
T T T
p: I am Pharmacists.
the science of reasoning
q: I know drugs/medicine.
T F F
F T T
F F T
Conditional Statement
If I understand the lesson 𝑡ℎ𝑒𝑛 I can pass the
exam.
p→q p q p→q
T T T
p: I understand the lesson.
T F F
q: I can pass the exam.
F
the science of reasoning T T
F F T
Conditional Statement
Construct a truth table for ~p→~q
p q ~p ~q ~p→~q
T T F F T
T F F T T
F T T F F
the science of reasoning
F F T T T
Conditional Statement
Note that:
q → p is the converse of p → q.
~q → ~p is the contrapositive of p → q.
~p → ~q is the inverse of p → q.
the science of reasoning
Bi-conditional Statement
p ↔ q is true when both (p and q) statements are the same.
p q p↔q
T T T The “if and only if”
T F F statement.
F T F
the science of reasoning
F F T
Bi-conditional Statement
Construct a truth table for p ↔ ~q.
p q ~q p↔~q
T T F F
T F T T
F T F T
the science of reasoning
F F T F
Exercise:
p: You smoke.
q: You have lung cancer.
the science of reasoning
If you smoke, then you will have lung cancer.
p→q
You have lung cancer.
q
Therefore, you smoke.
the science of reasoning
∴p
p→q q p
[(p → q) ∧ (q → r)] → (p → r)
Truth table
[(p → q) ∧ (q → r)] → (p → r)
p q p→q r q→r [(p → q) ∧ (q→r)] p→r [(p → q) ∧ (q → r)] → (p → r)
T T T T T T T T
T F F T T F T T
F T T T T T T T
F F T T T T T T
T T T F F F F T
T F F F T F F T
F T T F F F
the science ofTreasoning T
F F T F T T T T
Truth table
[(p → q) ∧ (q → r)] → (p → r)
p q p→q r q→r [(p → q) ∧ (q→r)] p→r [(p → q) ∧ (q → r)] → (p → r)
T T T T T T T T
T F F T T F T T
F T T T T T T T
F F T T T T T T
T T T F F F F T
T F F F T F F T
F T T F F F
the science ofTreasoning T
F F T F T T T T
Truth table
[(p → q) ∧ (q → r)] → (p → r)
p q p→q r q→r [(p → q) ∧ (q→r)] p→r [(p → q) ∧ (q → r)] → (p → r)
T T T T T T T T
T F F T T F T T
F T T T T T T T
F F T T T T T T
T T T F F F F T
T F F F T F F T
F T T F F F
the science ofTreasoning T
F F T F T T T T
Truth table
[(p → q) ∧ (q → r)] → (p → r)
p q p→q r q→r [(p → q) ∧ (q→r)] p→r [(p → q) ∧ (q → r)] → (p → r)
T T T T T T T T
T F F T T F T T
F T T T T T T T
F F T T T T T T
T T T F F F F T
T F F F T F F T
F T T F F F
the science ofTreasoning T
F F T F T T T T
Truth table
[(p → q) ∧ (q → r)] → (p → r)
p q p→q r q→r [(p → q) ∧ (q→r)] p→r [(p → q) ∧ (q → r)] → (p → r)
T T T T T T T T
T F F T T F T T
F T T T T T T T
F F T T T T T T
T T T F F F F T
T F F F T F F T
F T T F F F
the science ofTreasoning T
F F T F T T T T
Truth table
[(p → q) ∧ (q → r)] → (p → r)
p q p→q r q→r [(p → q) ∧ (q→r)] p→r [(p → q) ∧ (q → r)] → (p → r)
T T T T T T T T
T F F T T F T T
F T T T T T T T
F F T T T T T T
T T T F F F F T
T F F F T F F T
F T T F F F
the science ofTreasoning T
F F T F T T T T
Is this a valid argument?
If it rains nonstop, then UST will be flooded.
If is UST is flooded, then there will be
no classes.
It rains nonstop, then there will be no
classes
Mathematics in the Modern World – UNIT 2
END OF UNIT 2