Assignment # 1
Assignment # 1
Assignment # 1
1. Which of these sentences are propositions? What are the truth values of those that are propositions?
a) Boston is the capital of Massachusetts. b) Miami is the capital of Florida.
c) 2 + 3 = 5. d) 5 + 7 = 10.
e) x + 2 = 11. f) Answer this question.
2. Suppose that Smartphone A has 256MB RAM and 32GB ROM, and the resolution of its camera is 8 MP;
Smartphone B has 288 MB RAM and 64 GB ROM, and the resolution of its camera is 4 MP; and
Smartphone C has 128 MB RAM and 32 GB ROM, and the resolution of its camera is 5 MP.
Express the given statements using Logical Connectives. Also determine the truth value of each of these
propositions.
a) p → q b) ¬q ↔ r c) q →¬r
d) p ∨ q ∨ r e) (p →¬r) ∨ (q →¬r) f) (p ∧ q) ∨ (¬q ∧ r)
1
5. Let p, q, and r be the propositions
p: You get an A on the final exam. q: You do every exercise in this book. r: You get an A in this class.
Write these propositions using p, q, and r and logical connectives.
a) You get an A in this class, but you do not do every exercise in this book.
b) You get an A on the final, you do every exercise in this book, and you get an A in this class.
c) To get an A in this class, it is necessary for you to get an A on the final.
d) You get an A on the final, but you don’t do every exercise in this book; nevertheless, you get an A in this class.
e) Getting an A on the final and doing every exercise in this book is sufficient for getting an A in this class.
f) You will get an A in this class if and only if you either do every exercise in this book or you get an A on the final.
6. Write each of these statements in the form “if p, then q” in English. [Hint: Refer to the list of common ways to
express conditional statements provided in this section.]
a) You send me an e-mail message only if I will remember to send you the address.
b) To be a citizen of this country, it is sufficient that you were born in the United States.
c) If you keep your textbook, it will be a useful reference in your future courses.
d) The Red Wings will win the Stanley Cup if their goalie plays well.
e) That you get the job implies that you had the best credentials.
f) The beach erodes whenever there is a storm.
g) It is necessary to have a valid password to log on to the server.
h) You will reach the summit unless you begin your climb too late.
7. Consider the statement: “If it is sunny tomorrow, then I will go for a walk in the woods.”
a) Describe at least five different ways to write the conditional statement p → q in English.
b) State the converse, inverse and contrapositive of a conditional statement.
c) Given a conditional statement p → q, find the inverse of its inverse, the inverse of its converse, and the
inverse of its contrapositive.
8. Use De Morgan’s laws to find the negation of each of the following statements.
a) Jan is rich and happy. b) Carlos will bicycle or run tomorrow.
c) The fan is slow or it is very hot. d) Akram is unfit and Saleem is injured.
9. The following proposition uses the English connective “or”. Determine from the context whether “or” is intended
to be used in the inclusive or exclusive sense.
a) (p ∧ (¬ (¬p ∨ q))) ∨ (p ∧ q) ≡ p
b) ¬ (p ⟷ q) ≡ (p ⟷ ¬q)
c) ¬p ⟷ q ≡ p ⟷ ¬q
d) (p ∧ q) → (p → q) ≡ T
e) ¬ (p ∨ ¬ (p ∧ q)) ≡ F
2
11. Using Truth table, show that these compound propositions are logically equivalent or not.
a) (p → r) ∧ (q → r) and (p ∨ q) → r
b) (p → q) ∨ (p → r) and p → (q ∨ r)
c) (p → q) → (r → s) and (p → r) → (q → s)
12. Let P(m, n) be the statement “m divides n,” where the domain for both variables consists of all positive integers.
(By “m divides n” we mean that n = km for some integer k.) Determine the truth values of each of these statements.
a) P(4, 5) b) P(2, 4) c) ∀ m ∀ n P(m, n)
d) ∃ m ∀ n P(m, n) e) ∃ n ∀ m P(m, n) f) ∀ n P(1, n)
13. Determine the truth value of each of these statements if the domain of each variable consists of all real numbers.
14. Let F(x, y) be the statement “x can fool y,” where the domain consists of all people in the world. Use quantifiers
to express each of these statements.
a) Everybody can fool Bob. b) Alice can fool everybody.
c) Everybody can fool somebody. d) There is no one who can fool everybody.
e) Everyone can be fooled by somebody.
15. 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++.
b) There is a student at your school who can speak Russian but who doesn’t know C++.
c) Every student at your school either can speak Russian or knows C++.
d) No student at your school can speak Russian or knows C++.
16. Let Q(x, y) be the statement “x has sent an e-mail message to y,” where the domain for both x and y consists of all
students in your class. Express each of these quantifications in English.
a) ∃ x ∃ y Q(x, y) b) ∃ x∀ y Q(x, y) c) ∀ x ∃ y Q(x, y)
d) ∃ y∀ x Q(x, y) e) ∀ y ∃ x Q(x, y) f) ∀ x ∀ y Q(x, y)
17. Let P(x, y) be the statement “Student x has taken class y,” where the domain for x consists of all students in your class
and for y consists of all computer science courses at your school. Express each of these quantifications in English.
a) Alice is a mathematics major. Therefore, Alice is either a mathematics major or a computer science major.
b) Jerry is a mathematics major and a computer science major. Therefore, Jerry is a mathematics major.
c) If it is rainy, then the pool will be closed. It is rainy. Therefore, the pool is closed.
d) If it snows today, the university will close. The university is not closed today. Therefore, it did not snow today.
e) If I go swimming, then I will stay in the sun too long. If I stay in the sun too long, then I will sunburn. Therefore,
if I go swimming, then I will sunburn.
3
19. By using Laws of inference, show that the following statement is valid:
a) If today is Tuesday, I have a test in Mathematics or Economics. If my Economics professor is sick, I will not
have a test in Economics. Today is Tuesday, and my Economics professor is sick. Therefore, I will have a test in
Mathematics.
b) If Ali is a lawyer, then he is ambitious. If Ali is an early riser then he does not like chocolates. If Ali is ambitious
then he is an early riser. Therefore, if Ali is a lawyer then he does not like chocolates.
20. Let U= {1, 2, 3, 4, 5, 6, 7,8}, A = {1, 2, 4, 5}, B = {2, 3, 5, 6}, and C = {4, 5, 6, 7}. Find:
a) (A ∩ B) ∩ 𝑪̅ b) 𝑨̅ ∪ (B ∪ C) c) (A − B) ∩ C d) (A ∩𝑩 ̅
̅) ∪ 𝑪
Draw the Venn diagrams for each of these combinations of the sets A, B and C.
21. Prove or disprove the following expression by using the set identities:
a) (A − (A B)) (B − (A B)) = Φ b) (A − B) ∪ (A B) = A
c) (A − B) – C = (A − C) – B d) (̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅̅
̅ ∪ (𝑩
𝑩 ̅ – 𝐀)) = B
22. a) Suppose that in a bushel of 100 apples there are 20 that have worms in them and 15 that have bruises. Only
those apples with neither worms nor bruises can be sold. If there are 10 bruised apples that have worms in them,
how many of the 100 apples can be sold?
b) In a University of 1000 students, 350 like Computer Science and 450 like Software Engineering. 100 students like
both CS & SE. How many like either of them and how many like neither?
c) In a survey on the gelato preferences of college students, the following data was obtained:
78 like mixed berry, 32 like Irish cream, 57 like tiramisu, 13 like both mixed berry and Irish cream, 21 like both Irish
cream and tiramisu, 16 like both tiramisu and mixed berry, 5 like all three flavors, and 14 like none of these three
flavors. How many students were surveyed?
d) Use set-builder notation and logical equivalences to prove the following. A X (B ∩ C) = (A X B) ∩ (A X C)
23. Let A= {a, b, c, d} and B = {a, b, c, d}. Consider the following functions:
a) f(a) = b, f(b) = a, f(c) = c, f(d) = d b) f(a) = b, f(b) = b, f(c) = d, f(d) = c
c) f(a) = d, f(b) = b, f(c) = c, f(d) = d d) f(a) = c, f(b) = a, f(c) =b, f(d) = d
𝟑 𝟕 𝟑 𝟕
(b) (i) ⌈ ⌉ (ii) ⌊ ⌋ iii) ⌈− ⌉ (iv) ⌊− ⌋
𝟒 𝟖 𝟒 𝟖
𝟏 𝟑 𝟏 𝟓
(v) ⌈𝟑 ⌉ (vi) ⌊− 𝟏 ⌋ (vii) ⌊𝟐 + ⌈ 𝟐 ⌉⌋ (viii) ⌊ 𝟐 . ⌊ 𝟐 ⌋⌋
25. Let ƒ and g be the functions from the set of integers to the set of integers defined by ƒ(a) = 2a + 3 and g(a) = 3a + 2.
(a) What is the composition of ƒ and g? What is the composition of g and ƒ?
(b) Which type of function ƒ and g are?
(c) Are ƒ and g invertible?
4
Assistant Prof:Jamilusmani Submission date : Monday 16th Sep.2024