LESSON 4 Fundamentals of Logic
LESSON 4 Fundamentals of Logic
of Logic
Learning Outcomes
• Define a propositional logic and its categories.
p= today is Monday.
q= x + y = 3
Operations / Connectives
Logical Operators
• Compound Statements
• Conjunction Statements
= AND, symbol (˄)
= Ex: p ˄ q (conjunction of p AND q)
Today is Monday and x+y=3.
• Disjunction Statements
= OR, symbol (˅)
= Ex: p ˅ q (disjunction of p OR q)
Today is Monday or x+y=3.
Logical Operators
• Nega%on Statements
= NOT, symbol (¬ or )̴
= Ex: ¬p or p̴ (nega%on of p) (no, not, never)
Today is not Monday.
• Condi%onal Statements
= Implies, (if…then…) If today is Monday then tomorrow is Tuesday.
= Symbol (→) p →q
Today is Monday then x+y=3.
P q
Logical Operators
• Biconditional
= Iff, (if and only if)
I will go to the movie only if it is opening night.
= Symbol (↔)
• Exclusive OR
= XOR, symbol ( ) Today is Monday or x+y=3.
= Ex: p q (p exclusive OR q)
Negation
let p be a proposition
the negation of p, denoted by ¬p is the statement
“ it is not the case that p”
P ¬p
F T
T F
Truth Table for Nega6on
P ¬p
0 1
1 0
•p = 1 + 9 = 10
•q = Baseball is a sport
What is
•¬p
•¬q
•p = 1 + 9 = 10
•q = Baseball is a sport
Q ¬Q
T (1) F(0)
Answer
•¬p = 1 + 9 ≠ 10
•¬q = Baseball is not a sport
Conjunction
Let p and q be propositions.
•p^q ?
•¬p^q ?
•p = three is an even integer
•q = ten is a positive integer
•p ˄ q ?
•¬p ^ q ?
•p = three is an even integer
•q = ten is a positive integer
•p ˅ q ?
•¬p ˅ q ?
•p = three is an even integer
•q = ten is a positive integer
p q pÅq
F F F
F T T
T F T
T T F
Truth Table for Exclusive OR
p q pÅq
0 0 0
0 1 1
1 0 1
1 1 0
Truth Table for XOR
p q ¬p ¬p Å q
0 0 1 1 T
0 1 1 0 F
1 0 0 0 F
1 1 0 1 T
Conditional Statement
Let p and q be propositions.
p q p®q
0 0 1
0 1 1
1 0 0
1 1 1
Truth Table for Conditional
p q ¬p ¬p ® q
0 0 1 0 F
0 1 1 1 T
1 0 0 1 T
1 1 0 1 T
• p = (x+3=9)
• q = (9-3=x)
•p ® q ?
•¬ p ® ¬ q ?
• p = (x+3=9)
• q = (9-3=x)
• p ® q = If x + 3 = 9, then 9 – 3 = x
• ¬ p ® ¬ q = If x + 3 ≠ 9, then 9 – 3 ≠ x
Biconditional Statement
• Let p and q be propositions.
• The biconditional statement p « q is the proposition “ p if
and only if q”.
• The biconditional statement p « q is true when p and q
have the same value, and is false otherwise.
• It is also called bi-implication or double implication
Truth Table for Biconditional
p q p«q
F F T
F T F
T F F
T T T
Truth Table for Biconditional
p q p«q
0 0 1
0 1 0
1 0 0
1 1 1
Other common ways to express p«q
•p « q ?
•¬ p « ¬ q ?
• p = You will pass the exam
• q = You study well