Discrete Mathematics Assignment-01
Discrete Mathematics Assignment-01
6. Here,
Smartphone A, RAM = 256MB, ROM = 32GB, Camera Resolution = 8MP.
Smartphone B, RAM = 288MB, ROM = 64GB, Camera Resolution = 4MP.
Smartphone C, RAM = 128MB, ROM = 32GB, Camera Resolution = 5MP.
a) Smartphone B has the most RAM of these three smartphones. True
b) Smartphone C has more ROM or a higher resolution camera than Smartphone B.
True
c) Smartphone B has more RAM, more ROM, and a higher resolution camera than
Smartphone A. False
d) If Smartphone B has more RAM and more ROM than Smartphone C, then it also has
a higher resolution camera. False
e) Smartphone A has more RAM than Smartphone B if and only if Smartphone B has
more RAM than Smartphone A. False
7. Here,
Acme Computer’s,
Annual revenue = 138 billion dollars
Net profit = 8 billion dollars
Nadir Software’s,
Annual revenue = 87 billion dollars
Net profit = 5 billion dollars
Quixote Media’s,
Annual revenue = 111 billion dollars
Net profit = 13 billion dollars
a) Quixote Media had the largest annual revenue. FALSE
b) Nadir Software had the lowest net profit and Acme Computer had the largest annual
revenue. TRUE
c) Acme Computer had the largest net profit or Quixote Media had the largest net profit.
TRUE
d) If Quixote Media had the smallest net profit, then Acme Computer had the largest
annual revenue. TRUE
e) Nadir Software had the smallest net profit if and only if Acme Computer had the
largest annual revenue. TRUE
11. Given that,
p: It is below freezing.
q: It is snowing.
a) It is below freezing and snowing. Writing this proposition using logical
connectives/Translation: p q
b) It is below freezing but not snowing. Translation: p q
c) It is not below freezing and it is not snowing. Translation: p q
d) It is either snowing or below freezing (or both). Translation: p q
e) If it is below freezing, it is also snowing. Translation: p q
f) Either it is below freezing or it is snowing, but it is not snowing if it is below freezing.
Translation: (p q) (p q)
g) That it is below freezing is necessary and sufficient for it to be snowing. Translation:
pq
13. Given,
p: You drive over 65 miles per hour.
q: You get a speeding ticket.
a) You do not drive over 65 miles per hour. Translation: p
b) You drive over 65 miles per hour, but you do not get a speeding ticket. Translation:
p q
c) You will get a speeding ticket if you drive over 65 miles per hour. Translation: p q
d) If you do not drive over 65 miles per hour, then you will not get a speeding ticket.
Translation: p q
e) Driving over 65 miles per hour is sufficient for getting a speeding ticket. Translation:
pq
f) You get a speeding ticket, but you do not drive over 65 miles per hour. Translation:
q p
g) Whenever you get a speeding ticket, you are driving over 65 miles per hour.
Translation: q p
15. The given propositions are following:
p: Grizzly bears have been seen in the area.
q: Hiking is safe on the trail.
r: Berries are ripe along the trail.
a) Berries are ripe along the trail, but grizzly bears have not been seen in the area.
Translation: r p
b) Grizzly bears have not been seen in the area and hiking on the trail is safe, but berries
are ripe along the trail. Translation: p q r
c) If berries are ripe along the trail, hiking is safe if and only if grizzly bears have not
been seen in the area. Translation: r (q p)
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. Translation: q p r
e) For hiking on the trail to be safe, it is necessary but not sufficient that berries not be
ripe along the trail and for grizzly bears not to have been seen in the area. Translation:
q (r p)
f) Hiking is not safe on the trail whenever grizzly bears have been seen in the area and
berries are ripe along the trail. Translation: (p r) q
21. When the logical connective "or" is an inclusive disjunction, it means that either
one or both of the statements are true. In contrast, when "or" is an exclusive disjunction, it
means that only one of the statements can be true, but not both.
Let's analyze the sentences:
Book ChatGPT Gemini
a) Inclusive or: It is a) To take discrete a) To take discrete
allowable to take discrete mathematics, you must have mathematics, you must have
mathematics if you have had taken calculus or a course in taken calculus or a course in
calculus or computer computer science. computer science.
science, or both.
Exclusive or: It is allowable Inclusive or: You must have Inclusive Or: You need to
to take discrete mathematics taken calculus, or you must have taken both calculus and
if you have had calculus or have taken a course in computer science, or at least
computer science, but not if computer science, or you one of them.
you have had both. must have taken both. Exclusive Or: You can only
Most likely the inclusive or Exclusive or: You must have have taken calculus or
is intended. taken calculus, or you must computer science, not both.
have taken a course in Intended Meaning: This is
computer science, but not likely an inclusive or. Most
both. universities require at least
Intended meaning: It seems one of these prerequisites,
that the intended meaning is not both necessarily.
an inclusive or, suggesting
that having taken either
calculus or a course in
computer science is
sufficient for taking discrete
mathematics.
b) Inclusive or: You can b) When you buy a new car b) When you buy a new car
take the rebate, or you can from Acme Motor from Acme Motor
get a low-interest loan, or Company, you get $2000 Company, you get $2000
you can get both the rebate back in cash or a 2% car back in cash or a 2% car
and a low-interest loan. loan. loan.
Exclusive or: You can take
the rebate, or you can get a Inclusive or: You get $2000 Inclusive Or: You get both
low-interest loan, but you back in cash, or you get a the cash and the 2% loan
cannot get both the rebate 2% car loan, or you get both. (unlikely).
and a low-interest loan. Exclusive or: You get $2000 Exclusive Or: You get either
Most likely the exclusive or back in cash, or you get a the cash or the 2% loan, but
is intended. 2% car loan, but not both. not both.
Intended meaning: The Intended Meaning: This is
intended meaning seems to likely an exclusive or. The
be an exclusive or, offer is one or the other, not
suggesting that the buyer both.
can choose either the
cashback offer or the 2% car
loan, but not both.
c) Inclusive or: You can c) Dinner for two includes c) Dinner for two includes
order two items from two items from column A or two items from column A or
column A and none from three items from column B. three items from column B.
column B, or three items
from column B and none Inclusive or: You can Inclusive Or: You can
from column A, or five choose two items from choose both two items from
items including two from column A, or you can A and three items from B for
column A and three from choose three items from your dinner.
column B. column B, or you can Exclusive Or: You can
Exclusive or: You can order choose a combination of choose either two items
two items from column A or items from both columns. from A or three items from
three items from column B, Exclusive or: You can B, but not both.
but not both. choose two items from Intended Meaning: This is
Almost certainly the column A, or you can likely an inclusive or. The
exclusive or is intended. choose three items from menu allows you to choose
column B, but not both. from various combinations,
Intended meaning: It's likely not just one option.
that the intended meaning is
an exclusive or, implying
that you can only choose
items from one column, not
both.
d) Inclusive or: More than 2 d) School is closed if more d) School is closed if more
feet of snow or windchill than 2 feet of snow falls or if than 2 feet of snow falls or if
below −100, or both, will the wind chill is below -100. the wind chill is below
close school. −100.
Exclusive or: More than 2 Inclusive or: School is
feet of snow or windchill closed if more than 2 feet of Inclusive Or: School closes
below −100, but not both, snow falls, or school is if both conditions happen
will close school. closed if the wind chill is (unlikely) or if at least one
Certainly, the inclusive or is below -100, or school is happens.
intended. closed if both conditions are Exclusive Or: School closes
met. if only one of the conditions
Exclusive or: School is occurs, not both.
closed if more than 2 feet of Intended Meaning: This is
snow falls, or school is likely an inclusive or.
closed if the wind chill is School is more likely to
below -100, but not both. close if any of the severe
Intended meaning: The weather conditions occur.
intended meaning is an
inclusive or, suggesting that
either condition is sufficient
for the school to be closed.
22. Let's express each statement in the form "if p, then q" in English:
a) If you want to get promoted, then you need to wash the boss’s car. (Necessary
condition)
b) If there are winds from the south, then there will be a spring thaw.
(Implication)
c) If you bought the computer less than a year ago, then the warranty is good.
(Sufficient condition)
d) If Willy cheats, then he gets caught. (Cause and effect)
e) If you pay a subscription fee, then you can access the website. (Necessary
condition)
f) If you know the right people, then you will get elected. (Implication)
g) If Carol is on a boat, then she gets seasick. (Cause and effect)
25. Let's express each proposition in the form "p if and only if q" in English:
a) You buy an ice cream cone if and only if it is hot outside.
b) You win the contest if and only if you hold the only winning ticket.
c) You get promoted if and only if you have connections.
d) Your mind will decay if and only if you watch television.
e) The train runs late if and only if it is a day, I take the train.
27. Let's state the converse, contrapositive, and inverse of each conditional statement:
a) If it snows today, I will ski tomorrow.
Converse: “I will ski tomorrow only if it snows today.”
Contrapositive: “If I do not ski tomorrow, then it will not have snowed today.”
Inverse: “If it does not snow today, then I will not ski tomorrow.”
b) I come to class whenever there is going to be a quiz.
Converse: “If I come to class, then there will be a quiz.”
Contrapositive: “If I do not come to class, then there will not be a quiz.”
Inverse: “If there is not going to be a quiz, then I don’t come to class.”
c) A positive integer is a prime only if it has no divisors other than 1 and itself.
Converse: “A positive integer is a prime if it has no divisors other than 1 and
itself.”
Contrapositive: “If a positive integer has a divisor other than 1 and itself, then
it is not prime.”
Inverse: “If a positive integer is not prime, then it has a divisor other than 1
and itself.”
[From: Answers to Odd-Numbered Exercises —
a) Converse: “I will ski tomorrow only if it snows today.”
Contrapositive: “If I do not ski tomorrow, then it will not have snowed today.”
Inverse: “If it does not snow today, then I will not ski tomorrow.”
b) Converse: “If I come to class, then there will be a quiz.”
Contrapositive: “If I do not come to class, then there will not be a quiz.”
Inverse: “If there is not going to be a quiz, then I don’t come to class.”
c) Converse: “A positive integer is a prime if it has no divisors other than 1 and itself.”
Contrapositive: “If a positive integer has a divisor other than 1 and itself, then it is not
prime.”
Inverse: “If a positive integer is not prime, then it has a divisor other than 1 and
itself.”]
40. Given compound proposition, (p q) (q r) (r p)
i. When, p, q and r are all true:
Here, p, q and r all are false.
Therefore, p q, q r and r p are all true.
Consequently, their conjunction (p q) (q r) (r p) is true as well.
ii. When, p, q and r are all false:
Here, p, q and r all are true.
Therefore, p q, q r and r p are all true.
Consequently, their conjunction (p q) (q r) (r p) is true as well.
Otherwise, if p, q and r do not have the same truth value, at least one of the disjuncts in each
conjunction p q, q r and r p will be false making the entire conjunction false.
Hence, the expression (p q) (q r) (r p) is true when p, q and r have the same
truth value, and it is false otherwise.
43. Let's find the bitwise OR(|), bitwise AND(&), and bitwise XOR(^) of each pair of
bit strings:
a) 1011110, 0100001
Bitwise OR: 1011110∨0100001=1111111
Bitwise AND: 1011110∧0100001=0000000
Bitwise XOR: 1011110 0100001=1111111
b) 11110000, 10101010
Bitwise OR: 11110000∨10101010=11111010
Bitwise AND: 11110000∧10101010=10100000
Bitwise XOR: 1111000010101010 =01011010
c) 0001110001, 1001001000
Bitwise OR: 00011100001∨10010010000=10011110001
Bitwise AND: 00011100001∧10010010000=00010000000
Bitwise XOR: 0001110000110010010000=1000111000
d) 1111111111, 0000000000
Bitwise OR: 1111111111 | 0000000000 = 1111111111
Bitwise AND: 1111111111 & 0000000000 = 0000000000
Bitwise XOR: 1111111111 ^ 0000000000 = 1111111111
These are the results of performing the bitwise OR(|), bitwise AND(&), and bitwise XOR(^)
operations on each pair of bit strings.