Propositional Logic Notes PDF
Propositional Logic Notes PDF
• Eg:
• 1 + 1 = 2.
• Toronto is the capital of Canada.
• What time is it?
• x + 1 = 2.
• Propositional variables (or statement variables): Variables that
represent propositions. The conventional letters used for
propositional variables are p, q, r, s, . . . .
• If the proposition is true, it is denoted by T. If the proposition is false,
it is denoted by F.
• The area of logic that deals with propositions is called the
propositional calculus or propositional logic.
T T T F
T F T T
F T T T
F F F F
Only the contrapositive always has the same truth value as p → q. When two
compound propositions always have the same truth value we call them
equivalent. A conditional statement and its contrapositive are equivalent.
Q. What are the contrapositive, the converse, and the inverse of the
conditional statement
“The home team wins whenever it is raining?”
“q whenever p”
q: The home team wins
p: It is raining.
“The home team wins whenever it is raining?”
“q whenever p”
q: The home team wins
p: It is raining.
Q. Let p be the statement “You can take the flight,” and let q be the statement
“You buy a ticket.”
Then p ↔ q is the statement?
Q. Construct the truth table of the compound proposition
(p ∨¬q) → (p ∧ q).
𝑝∧𝑞
Q. Let p, q, and r be the propositions
p : Grizzly bears have been seen in the area.
q : Hiking is safe on the trail.
r : Berries are ripe along the trail.
Write these propositions using p, q, and r and logical connectives (including
negations).
a) Berries are ripe along the trail, but grizzly bears have not been seen in the
area.
b) Grizzly bears have not been seen in the area and hiking on the trail is safe,
but berries are ripe along the trail.
c) If berries are ripe along the trail, hiking is safe if and only if grizzly bears
have not been seen in the area.
d) It is not safe to hike on the trail, but grizzly bears have not been seen in
the area and the berries along the trail are ripe.
e ) Hiking is not safe on the trail whenever grizzly bears have been seen in
the area and berries are ripe along the trail.
p : Grizzly bears have been seen in the area.
q : Hiking is safe on the trail.
r : Berries are ripe along the trail.
Write these propositions using p, q, and r and logical connectives (including negations).
a) Berries are ripe along the trail, but grizzly bears have not been seen in the area.
𝑟 ∧ ¬𝑝
b) Grizzly bears have not been seen in the area and hiking on the trail is safe, but berries are ripe along the
trail.
¬𝑝 ∧ 𝑞 ∧ 𝑟
c) If berries are ripe along the trail, hiking is safe if and only if grizzly bears have not been seen in the area.
𝑟 → (𝑞 ↔ ¬𝑝)
d) It is not safe to hike on the trail, but grizzly bears have not been seen in the area and the berries along the
trail are ripe.
¬ 𝑞 ∧ ¬𝑝 ∧ 𝑟
e ) Hiking is not safe on the trail whenever grizzly bears have been seen in the area and berries are ripe along
the trail.
𝑝 ∧ 𝑟 → ¬𝑞
Q. Let p, q, and r be the propositions and:
but/nevertheless/however/even
p :You get an A on the final exam. so/inspite/yet/though/still/nonetheless/anyhow/an
q :You do every exercise in this book. yway
Q. The automated reply cannot be sent when the file system is full
a: The automated reply can be sent.
f: The file system is full.
𝑓 → ¬𝑎
System specifications should be consistent, that is, they should not contain
conflicting requirements that could be used to derive a contradiction.
Q. Determine whether these system specifications are consistent:
“The diagnostic message is stored in the buffer or it is retransmitted.”
“The diagnostic message is not stored in the buffer.”
“If the diagnostic message is stored in the buffer, then it is retransmitted.”
p: The diagnostic message is stored in the buffer .
q: The diagnostic message is retransmitted.
𝑝∨𝑞
¬𝑝 p q 𝑝∨𝑞 ¬𝑝 𝑝→𝑞
𝑝→𝑞 T T T F T
T F T F F
F T T T T
F F F T T
Logic Puzzles: Puzzles that can be solved using logical reasoning are known as logic puzzles.
• An island that has two kinds of inhabitants, knights, who always tell the truth, and their opposites,
knaves, who always lie. You encounter two people A and B. What are A and B if A says “B is a
knight” and B says “The two of us are opposite types?”
• Let
• 𝑝 : A is a knight. and ¬𝑝: A is knave
• 𝑞: B is a knight. and¬𝑞: B is knave
Assume A is a knight.
If A is a knight, then he is telling the truth when he says that B is a knight.
However, if B is a knight, then B’s statement that A and B are of opposite types contradicts. We can
conclude that A is not a knight, that is, that p is false.
Assume A is a knave.
If A is a knave, then everything A says is false. A’s statement that B is a knight is a lie. Means that q is
false and B is also a knave. If B is a knave, then B’s statement that A and B are opposite types is a lie
which is consistent with both A and B being knaves.
• We can conclude that both A and B are knaves.
Logic Circuits
• De Morgan laws:
1. ¬(p ∧ q) ≡ ¬p ∨¬q
2. ¬(p ∨ q) ≡ ¬p ∧¬q
Q. Show that ¬(p ∨ q) and ¬p ∧¬q are logically equivalent.
Q. Show that p ∨ (q ∧ r) and (p ∨ q) ∧ (p ∨ r) are logically equivalent.
Equivalence Name
p∧T≡p Identity laws
Logical Equivalences. p∨F≡p
p∨T≡T Domination laws
p∧F≡F
p∨p≡p Idempotent laws
p∧p≡p
¬(¬p) ≡ p Double negation law
p∨q≡q∨p Commutative laws
p∧q≡q∧p
(p ∨ q) ∨ r ≡ p ∨ (q ∨ r) Associative laws
(p ∧ q) ∧ r ≡ p ∧ (q ∧ r)
p ∨ (q ∧ r) ≡ (p ∨ q) ∧ (p ∨ r) Distributive laws
p ∧ (q ∨ r) ≡ (p ∧ q) ∨ (p ∧ r)
¬(p ∧ q) ≡ ¬p ∨¬q De Morgan’s laws
¬(p ∨ q) ≡ ¬p ∧¬q
p ∨ (p ∧ q) ≡ p Absorption laws
p ∧ (p ∨ q) ≡ p
p ∨¬p ≡ T Negation laws
p ∧¬p ≡ F
Logical Equivalences
Involving Conditional Statements.
• p → q ≡ ¬p ∨ q
• p → q ≡ ¬q →¬p
• p ∨ q ≡ ¬p → q
• p ∧ q ≡ ¬(p →¬q)
• ¬(p → q) ≡ p ∧¬q
• (p → q) ∧ (p → r) ≡ p → (q ∧ r)
• (p → r) ∧ (q → r) ≡ (p ∨ q) → r
• (p → q) ∨ (p → r) ≡ p → (q ∨ r)
• (p → r) ∨ (q → r) ≡ (p ∧ q) → r
Logical Equivalences Involving
Biconditional Statements.
• p ↔ q ≡ (p → q) ∧ (q → p)
• p ↔ q ≡ ¬p ↔¬q
• p ↔ q ≡ (p ∧ q) ∨ (¬p ∧¬q)
• ¬(p ↔ q) ≡ p ↔¬q
Q. Show that ¬(p → q) and p ∧¬q are logically equivalent.
(p ∧ q) → (p ∨ q) ≡ ¬(p ∧ q) ∨ (p ∨ q)
≡ (¬p ∨¬q) ∨ (p ∨ q) by the first De Morgan law
≡ (¬p ∨ p) ∨ (¬q ∨ q) by the associative and commutative
laws for disjunction
≡T∨T
≡ T by the domination law
Propositional Satisfiability
A compound proposition is satisfiable if there is an assignment of truth
values to its variables that makes it true. When no such assignments exists,
that is, when the compound proposition is false for all assignments of truth
values to its variables, the compound proposition is unsatisfiable.
Q. Determine whether each of the compound propositions
i. (p ∨¬q) ∧ (q ∨¬r) ∧ (r ∨¬p)
ii. (p ∨ q ∨ r) ∧ (¬p ∨¬q ∨¬r), is satisfiable.
i, When p=T; q=T; r=T; (p ∨¬q) ∧ (q ∨¬r) ∧ (r ∨¬p) will be T, hence it
satisfiable
Q. Show that each of these conditional statements is a tautology
a) (p ∧ q) → p b) p → (p ∨ q)
c) ¬p → (p → q) d) (p ∧ q) → (p → q)
e) ¬(p → q) → p f ) ¬(p → q)→¬q
a) (p ∧ q) → p ≡ ¬ 𝑝 ∧ 𝑞 ∨ 𝑝 ≡ ¬𝑝 ∨ ¬𝑞 ∨ 𝑝 ≡ ¬𝑝 ∨ 𝑝 ∨ ¬𝑞 ≡ 𝑇 ∨ ¬𝑞 ≡ 𝑇
f) ¬(p → q)→¬q ≡ ¬(¬𝑝 ∨ 𝑞) → ¬𝑞 ≡ (𝑝 ∧ ¬𝑞) → ¬𝑞
≡ ¬(𝑝 ∧ ¬𝑞) ∨ ¬𝑞 ≡ ¬𝑝 ∨ 𝑞 ∨ ¬𝑞 ≡ ¬𝑝 ∨ 𝑇 ≡ 𝑇
L.H.S
¬(p ↔ q) ≡ ¬ 𝑝 → 𝑞 ∧ 𝑞 → 𝑝
≡ ¬ ¬𝑝 ∨ 𝑞 ∧ ¬𝑞 ∨ 𝑝
≡ ¬ ¬𝑝 ∧ ¬𝑞 ∨ (¬𝑝 ∧ 𝑝) ∨ (𝑞 ∧ ¬𝑞) ∨ 𝑞 ∧ 𝑝
≡ ¬ ¬𝑝 ∧ ¬𝑞 ∨ 𝐹 ∨ 𝐹 ∨ 𝑞 ∧ 𝑝
≡ ¬ ¬𝑝 ∧ ¬𝑞 ∧ 𝑇 ∧ 𝑇 ∧ ¬ 𝑞 ∧ 𝑝
≡ 𝑝 ∨ 𝑞 ∧ ¬𝑞 ∨ ¬𝑝
≡ ¬𝑝 → 𝑞 ∧ 𝑞 → ¬𝑝
≡ ¬𝑝 ↔ 𝑞
Q. Show that ¬(p ↔ q) and p ↔ ¬ q are logically equivalent.
L.H.S.
p → q ≡ ¬𝑝 ∨ 𝑞
≡ 𝑞 ∨ ¬𝑝
≡ ¬(¬𝑞) ∨ ¬𝑝
≡ ¬q →¬p
Q. Show using truth table, ¬(p ⊕ q) and p ↔ q are logically
equivalent.
Q. Show that ¬(p ⊕ q) and p ↔ q are logically equivalent without
using truth table.
Hint: A ⊕ B=A𝐵+ത 𝐴ҧ B
Q. Determine whether [(p ∨ q) ∧ (¬p ∨ r)] → (q ∨ r) is a tautology or
not.
Q. Show that (p → q) → r and p → (q → r) are not logically equivalent.
Q. Let Q(x, y) denote the statement “x = y + 3.” What are the truth
values of the propositions Q(1, 2) and Q(3, 0)?
Eg: Let P(x) be the statement “x + 1 > x.” What is the truth value of the quantification
∀xP(x), where the domain consists of all real numbers?
• Because P(x) is true for all real numbers x, the quantification ∀xP(x) is true.
Eg: Let Q(x) be the statement “x < 2.” What is the truth value of the quantification
∀xQ(x), where the domain consists of all real numbers?
• Q(x) is not true for every real number x, because, for instance, Q(3) is false. That is,
x = 3 is a counterexample for the statement ∀xQ(x). Thus ∀xQ(x) is false.
• The existential quantification of P(x) is the proposition
“There exists an element x in the domain such that P(x).”
We use the notation ∃xP(x) for the existential quantification of P(x).
Here ∃ is called the existential quantifier.
• Besides the phrase “there exists” we can also express existential
quantification in many other ways, such as by using the words “for
some,” “for at least one,” or “there is.”
• Eg: Let P(x) denote the statement “x > 3.” What is the truth value of
the quantification ∃xP(x), where the domain consists of all real
numbers?
• Because “x > 3” is sometimes true—for instance, when x = 4 the
existential quantification of P(x), which is ∃xP(x), is true.
Statement When True? When False?
∀xP(x) P(x) is true for every x. There is an x for which P(x) is false
∃xP(x) There is an x for which P(x) is true. P(x) is false for every x.
¬∃xP(x) ∀x¬P(x)
¬∀xP(x) ∃x¬P(x)
Q. What are the negations of the statements “There is an honest politician” and “All Americans eat
cheeseburgers”?
Let H(x) denote “x is honest.”
“There is an honest politician” is represented by ∃xH(x), where the domain consists of all politicians.
The negation of this statement is ¬∃xH(x), which is equivalent to ∀x¬H(x).
“Every politician is dishonest.”
In English, the statement “All politicians are not honest” is ambiguous, this statement often means “Not all
politicians are honest.”
• “All Americans eat cheeseburgers”
“There is a person x having the properties that x is a student in this class and x
has visited Mexico.”
S(x): x is a student in this class.
M(x): x has visited Mexico.
∃𝑥(𝑆(𝑥) ∧ 𝑀 𝑥 ), where the domain consist of all people.
Q. “For every student x in this class, x has the property that x has visited Mexico or x has visited
Canada.”
M(x): x has visited Mexico.
C(x): x has visited Canada.
∀𝑥(𝐶(𝑥) ∨ 𝑀 𝑥 ), where domain consist of student in the class.
Q. “For every person x, if x is a student in this class, then x has visited Mexico or x has visited Canada.”
S(x): x is a student in this class.
M(x): x has visited Mexico.
C(x): x has visited Canada.
Q. Let N(x) be the statement “x has visited North Dakota,” where the domain consists of the
students in your school. Express each of these quantifications in English.
a) ∃xN(x) b) ∀xN(x) c) ¬∃xN(x)
d) ∃x¬N(x) e) ¬∀xN(x) f ) ∀x¬N(x)
Q. Translate these statements into English, where C(x) is “x is a comedian” and F(x) is
“x is funny” and the domain consists of all people.
a) ∀x(C(x) → F(x)) b) ∀x(C(x) ∧ F(x))
c) ∃x(C(x) → F(x)) d) ∃x(C(x) ∧ F(x))
a) For every person x, If x is a comedian then x is funny. Or Every comedian is funny.
b) For every person x, x is a comedian and x is funny. Or Every person is a funny
comedian.
c) There exists a person such that if she or he is a comedian, then she or he is funny.
d) There exists a person such that she or he is a comedian and she or he is funny. Or
Some comedians are funny.
Q. Translate these statements into English, where R(x) is “x is a rabbit” and H(x) is “x
hops” and the domain consists of all animals.
a) ∀x(R(x) → H(x)) b) ∀x(R(x) ∧ H(x))
c) ∃x(R(x) → H(x)) d) ∃x(R(x) ∧ H(x))
Q. Let P(x) be the statement “x can speak Russian” and let Q(x) be the statement
“x knows the computer language C++.” Express each of these sentences in terms
of P(x), Q(x), quantifiers, and logical connectives. The domain for quantifiers
consists of all students at your school.
a) There is a student at your school who can speak Russian and who knows C++.
∃x(P(x) ∧ Q(x))
b) There is a student at your school who can speak Russian but who doesn’t know
C++.
∃x(P(x) ∧ ¬Q(x))
c) Every student at your school either can speak Russian or knows C++.
∀x(P(x)∨Q(x))
d) No student at your school can speak Russian or knows C++.
∀x¬(P (x)∨Q(x)) or ¬∃x (P (x)∨Q(x))
Q. Let C(x) be the statement “x has a cat,” let D(x) be the statement “x has a
dog,” and let F(x) be the statement “x has a ferret.” Express each of these
statements in terms of C(x), D(x), F(x), quantifiers, and logical connectives. Let
the domain consist of all students in your class.
a) A student in your class has a cat, a dog, and a ferret.
b) All students in your class have a cat, a dog, or a ferret.
c) Some student in your class has a cat and a ferret, but not a dog.
d) No student in your class has a cat, a dog, and a ferret.
e) For each of the three animals, cats, dogs, and ferrets, there is a student in
your class who has this animal as a pet.
Q. Translate in two ways each of these statements into logical expressions using
predicates, quantifiers, and logical connectives. First, let the domain consist of the
students in your class and second, let it consist of all people.
∀x∃y(x + y = 0)
says that for every real number x there is a real number y such that x + y
= 0. This states that every real number has an additive inverse.
Translate into English the statement
∀x∀y((x > 0) ∧ (y < 0) → (xy < 0)), where the domain for both
variables consists of all real numbers.
For every real number x and for every real number y, if x > 0 and y < 0,
then xy < 0.
This can be stated more succinctly as “The product of positive real
number and a negative real number is always a negative real number.”
Quantifications of Two Variables.
∀x∀yP(x, y) P(x, y) is true for every pair x, y. There is a pair x, y for which P(x, y) is
∀y∀xP(x, y) false.
∀x∃yP(x, y) For every x there is a y for which There is an x such that P(x, y) is false for
P(x, y) is true. every y.
∃x∀yP(x, y) There is an x for which P(x, y) is For every x there is a y for which P(x, y)
true for every y. is false.
∃x∃yP(x, y) There is a pair x, y for which P(x, P(x, y) is false for every pair x, y.
∃y∃xP(x, y) y) is true.
The Order of Quantifiers
Q. Let Q(x, y) denote “x + y = 0.” What are the truth values of the
quantifications ∃y∀xQ(x, y) and ∀x∃yQ(x, y), where the domain for all
variables consists of all real numbers?
∃y∀xQ(x, y): “There is a real number y such that for every real number x, Q(x,
y).”
• No matter what value of y is chosen, there is only one value of x for which x
+ y = 0. The statement ∃y∀xQ(x, y) is false.
∀x∃yQ(x, y): “For every real number x there is a real number y such that Q(x,
y).”
• Given a real number x, there is a real number y such that x + y = 0; namely,
y = −x. Hence, the statement ∀x∃yQ(x, y) is true.
Q. Let Q(x, y, z) be the statement “x + y = z.” What are the truth values of the
statements ∀x∀y∃zQ(x, y, z) and ∃z∀x∀yQ(x, y, z), where the domain of all
variables consists of all real numbers?
• ∀x∀y∃zQ(x, y, z): “For all real numbers x and for all real numbers y there is a
real number z such that x + y = z,” is true.
• ∃z∀x∀yQ(x, y, z): “There is a real number z such that for all real numbers x
and for all real numbers y such that x + y = z,” is false.
Translating Mathematical Statements into
Statements Involving Nested Quantifiers
Q. Translate the statement “The sum of two positive integers is always
positive” into a logical expression.
• “For all positive integers x and y, x + y is positive.”
∀x∀y((x > 0) ∧ (y > 0) → (x +y > 0)), where the domain for both
variables consists of all integers.
∀x∀y(x +y > 0), where the domain for both variables consists of all
positive integers
Q. Translate the statement “Every real number except zero has a multiplicative
inverse.” (A multiplicative inverse of a real number x is a real number y such that
xy = 1.)
• “For every real number x, if x ≠ 0, then there exists a real number y such that
xy = 1.”
• ∀x((x ≠ 0) → ∃y(xy = 1)).
Translating from Nested Quantifiers into English
Q. Translate the statement ∀x(C(x) ∨ ∃y(C(y) ∧ F(x, y))) into English, where
C(x): “x has a computer,”
F(x, y): “x and y are friends,”
and the domain for both x and y consists of all students in your school.
There is a student x such that for all students y and all students z, if x and y
are friends and x and z are friends and y not equal z, then y and z are not
friends.
Translating English Sentences into Logical
Expressions
Q. Express the statement “If a person is female and is a parent, then this person is
someone’s mother” as a logical expression involving predicates, quantifiers with a
domain consisting of all people, and logical connectives.
“For every person x, if person x is female and person x is a parent, then there exists a
person y such that person x is the mother of person y.”
• F(x): “x is female,”
• P(x): “x is a parent,” and
• M(x, y): “x is the mother of y.”
∀x((F (x) ∧ P(x)) → ∃yM(x, y)).
∀x∃y((F (x) ∧ P(x)) → M(x, y)).
Q. Express the statement “Everyone has exactly one best friend” as a logical
expression involving predicates, quantifiers with a domain consisting of all
people, and logical connectives.
To say that x has exactly one best friend means that there is a person y who is
the best friend of x, and furthermore, that for every person z, if person z is not
person y, then z is not the best friend of x.
• B(x, y): “y is the best friend of x,”
∃y(B(x, y) ∧ ∀z((z ≠ y)→¬B(x, z))).
∀x∃y(B(x, y) ∧ ∀z((z ≠ y)→¬B(x, z))).
∀x∃!yB(x, y),
Negating Nested Quantifiers
Q. Express the negation of the statement ∀x∃y(xy = 1) so that no
negation precedes a quantifier.
¬∀x∃y(xy = 1) ≡ ∃x¬∃y(xy = 1)
≡ ∃x∀y¬(xy = 1).
≡ ∃x∀y(xy ≠ 1).
Q. Let W(x, y) mean that student x has visited website y, where the domain for
x consists of all students in your school and the domain for y consists of all
websites. Express each of these statements by a simple English sentence.
b) ∃xW(x, www.imdb.org): There is a student in your school that has visited the website
www.imbd.org.
d) ∃y(W(Ashok, y) ∧W(Cindy, y)): There is a website that Ashok and Cindy have both visited.
• a) Q(1, 1) b) Q(2, 0)
• c) ∀yQ(1, y) d) ∃xQ(x, 2)
• e) ∃x∃yQ(x, y) f ) ∀x∃yQ(x, y)
• g) ∃y∀xQ(x, y) h) ∀y∃xQ(x, y)
• i) ∀x∀yQ(x, y)
Q. Express the negations of each of these statements so that all negation symbols
immediately precede predicates.
a) ∀x∃y∀zT (x, y, z)
b) ∀x∃yP(x, y) ∨ ∀x∃yQ(x, y)
c) ∀x∃y(P(x, y) ∧ ∃zR(x, y, z))
d) ∀x∃y(P(x, y) → Q(x, y))
Universal instantiation is the rule of inference used to conclude that P(c) is true, where c is a particular
member of the domain, given the premise ∀xP(x).
Eg: “All women are wise”. “Lisa is wise,” where Lisa is a member of the domain of all women.
Universal generalization is the rule of inference that states that ∀xP(x) is true, given the premise that P(c) is true for all
elements c in the domain.
Q1. Is the following argument valid?
If you do every problem in this book, then you will learn discrete mathematics.
You learned discrete mathematics. Therefore, you did every problem in this
book.
Let,
p: you do every problem in this book.
q: you will learn discrete mathematics.
The argument
p -> q
q
∴p
It is neither MT nor MP. The argument is invalid.
Q. Every student at your school either can speak Russian or knows C++.
∀x(P(x)∨Q(x))
∀x(P(x) ⊕ Q(x))
https://math.stackexchange.com/questions/3598348/problem-from-kenneth-rosens-
discrete-mathematics-and-its-applications-section
You go to one of your friend’s house and you are asked: “Tea or Coffee”. Here this or is an
exclusive or.
Q. For each of these sentences, determine whether an inclusive or, or an exclusive or, is
intended.
a) Experience with C++ or Java is required. "Inclusive or"
b) Lunch includes soup or salad. “Exclusive or”
c) To enter the country you need a passport or a voter registration card. "Inclusive or"
d) Publish or perish. “Exclusive or”
Distribution of Quantifiers
over Conjunction and Disjunction
a. ∀x[P(x) ∧ Q(x)] ≡ (∀xP(x) ∧ ∀xQ(x))
b. ∀x[P(x) ∨ Q(x)] ≢ (∀xP(x) ∨ ∀xQ(x))
c. ∃x[P(x) ∧ Q(x)] ≢ (∃xP(x) ∧ ∃xQ(x))
d. ∃x[P(x) ∨ Q(x)] ≡ (∃xP(x) ∨ ∃xQ(x))
a) Q(1, 1) b) Q(2, 0)
c) ∀yQ(1, y) d) ∃xQ(x, 2)
e) ∃x∃yQ(x, y) f ) ∀x∃yQ(x, y)
g) ∃y∀xQ(x, y) h) ∀y∃xQ(x, y)
i) ∀x∀yQ(x, y)
Q. Express the negations of each of these statements so that all negation
symbols immediately precede predicates.
a) ∀x∃y∀zT (x, y, z) ∃x ∀y ∃z ¬T (x, y, z)
b) ∀x∃yP(x, y) ∨ ∀x∃yQ(x, y) ∃x ∀y ¬P(x, y) ∧ ∃x ∀y ¬Q(x, y)
c) ∀x∃y(P(x, y) ∧ ∃zR(x, y, z)) ∃x ∀y (¬P(x, y) ∨ ∀z ¬R(x, y, z))
d) ∀x∃y(P(x, y) → Q(x, y)) ∃x∀y(P(x, y)∧¬Q(x, y))
Q4. Determine the truth value of the statement ∀x∃y(xy = 1) if the domain for the variables consists
of
a) the nonzero real numbers.
b) the nonzero integers.
c) the positive real numbers.
Q. “If you have a current password, then you can log onto the network.”
“You have a current password.”
Therefore,
“You can log onto the network.”
Determine whether this is a valid argument.
Let, p: You have a current password.
q: You can log onto the network.
Then, the argument has the form
p→q
p
∴q
We know that when p and q are propositional variables, the statement ((p → q) ∧
p) → q is a tautology (Modus ponens)
Hence, the conclusion is valid.
Q. Show that the premises “It is not sunny this afternoon and it is colder than yesterday,” “We will go swimming only if it is sunny,” “If
we do not go swimming, then we will take a canoe trip,” and “If we take a canoe trip, then we will be home by sunset” lead to the
conclusion “We will be home by sunset.”
Let, p: It is sunny this afternoon; q: It is colder than yesterday; r: We will go swimming;
s: We will take a canoe trip; t: We will be home by sunset.
The premises are:
¬p ∧ q: It is not sunny this afternoon and it is colder than yesterday. r → p: We will go swimming only if it is sunny.
¬r → s: If we do not go swimming, then we will take a canoe trip. s → t: If we take a canoe trip, then we will be
home by sunset.
Conclusion: t: We will be home by sunset
We construct an argument to show that our premises lead to the desired conclusion as follows.
Step Reason
1. ¬p ∧ q Premise
2. ¬p Simplification using (1)
3. r → p Premise
4. ¬r Modus tollens using (2) and (3)
5. ¬r → s Premise
6. s Modus ponens using (4) and (5)
7. s → t Premise
8. t Modus ponens using (6) and (7)
Q5. Show that the premises “If you send me an e-mail message, then I will finish
writing the program,” “If you do not send me an e-mail message, then I will go to
sleep early,” and “If I go to sleep early, then I will wake up feeling refreshed” lead
to the conclusion “If I do not finish writing the program, then I will wake up
feeling refreshed.”
Q6. Show that the hypotheses “Jasmine is skiing or it is not snowing” and “It is
snowing or Bart is playing hockey” imply that “Jasmine is skiing or Bart is playing
hockey.”
The premises
All men are mortal: ∀x (P(x)→Q(x))
Socrates is a man: Q(Socrates)
Sl. No. Steps Reason
Conclusions:
1 ∀x (P(x)→Q(x)) Premise
Socrates is mortal: P(Socrates) 2 ∀x (P(Socrates)→Q(Socrates)) U.I. (1)
3 Q(Socrates) Premise
4 P(Socrates) M.P. (2) (3)
Q4. Use rules of inference to show that the hypotheses “If it does not rain or if it is not foggy, then the
sailing race will be held and the lifesaving demonstration will go on,” “If the sailing race is held, then
the trophy will be awarded,” and “The trophy was not awarded” imply the conclusion “It rained.”
p: It rains. q: It is foggy. r: The sailing race will be held.
s: The lifesaving demonstration will go on. t: The trophy will be awarded.
The premise are: Sl. No. Steps Reason
If it does not rain or if it is not foggy, then 1 (¬p v ¬q) -> (r ^ s) Premise
the sailing race will be held and the lifesaving 2 r -> t Premise