1. An island is populated by knights who always tell the truth, knaves who always lie,
and normals who can either lie or tell the truth. You encounter three people, A, B, and
C. You know one of these people is a knight, one is a knave, and one is a normal
MATH11/CS11. FINAL. VERSION 2.
1. The police have three suspects for the murder of Mr. Cooper: Mr. Smith, Mr. Jones,
and Mr. Williams. All suspects declare that they did not kill Cooper. Smith also states that
Cooper was a friend of Jones and that William
HOMEWORK SET 3. PREDICATES AND QUANTIFIERS (BOOK: CHAPTER 4)
1. Let P (x) be the statement x spends more than five hours every weekday in class,
where the domain for x consists of all students. Express each of these quantifications in
English.
a) 9xP (x)
HOMEWORK SET 5. FUNCTIONS AND CARDINALITY
1. Consider these functions from the set of students in a discrete mathematics class. Under what
conditions is the function injective if it assigns to a student his or her
a)
b)
c)
d)
mobile phone number.
student
HOMEWORK SET 1. PROPOSITIONAL CALCULUS
1. Let p and q be the propositions The election is decided and The votes have been
counted, respectively. Express each of the following compound propositions as an English sentence.
a) p
b) p q
c) p q
d) q p
e) q p
f
HOMEWORK SET 1. SOLUTIONS OF SELECTED PROBLEMS.
1. Let p and q be the propositions The election is decided and The votes have been
counted, respectively. Express each of the following compound propositions as an English sentence.
a) p
b) p q
c) p q
d) q p
HOMEWORK SET 5. INTRODUCTION TO NUMBER THEORY
1.
a)
b)
c)
d)
Let a, b, c, d be integers. Prove the following statements.
If a | b and b | c then a | c
If a | b and b | a then a = b or a = b.
If a | c and b | d then ab | cd.
Suppose that c 6= 0. Then a | b
HOMEWORK SET 4. MATHEMATICAL INDUCTION. SETS AND SET OPERATIONS
1
, n 1 (so, f1 = 2, f2 = 32 , f3 = 35 etc.)
Define a sequence fn , n 0 by f0 = 1 and fn = 1 + fn1
Fn+2
Prove that f (n) =
for all n N where Fn is the nth Fibonacci number (F0 = 0, F1 = F2 =
HOMEWORK SET 2. EQUIVALENCES AND ARGUMENTS
1.
Use truth tables to verify that p (q r) (p q) r and p (q r) (p q) (p r).
2. Show that each of the following propositions is a tautology. You can use truth tables
or properties of logical operators.
a) (p q) p
HOMEWORK SET 3. PREDICATES AND QUANTIFIERS
1. Let P (x) be the statement x spends more than five hours every weekday in class,
where the domain for x consists of all students. Express each of these quantifications in
English.
a) xP (x)
b) xP (x)
c) xP (x)
HOMEWORK SET 5. INTRODUCTION TO NUMBER THEORY
1.
a)
b)
c)
d)
Let a, b, c, d be integers. Prove the following statements.
If a | b and b | c then a | c
If a | b and b | a then a = b or a = b.
If a | c and b | d then ab | cd.
Suppose that c 6= 0. Then a | b
HOMEWORK SET 4. MATHEMATICAL INDUCTION. SETS AND SET OPERATIONS
Fn+2
for all
Fn+1
n N where Fn is the nth Fibonacci number (F0 = 0, F1 = 1 etc)
Remark. The sequence fn provides approximations for the so called golden ratio, (1 + 5)/2. For
example, f100 ap
HOMEWORK SET 6. CARTESIAN PRODUCTS AND MAPS
1. A database is storing information about flights. For each flight it stores the airline code, the
flight number, the origin, the destination, the departure time and the arrival time. Describe an
entry in that
HOMEWORK SET 6. CARTESIAN PRODUCTS AND MAPS
1. A database is storing information about flights. For each flight it stores the airline code, the
flight number, the origin, the destination, the departure time and the arrival time. Describe an
entry in that
MATH11/CS11. MIDTERM II
1. A particular brand of shirt has a male version and a female version. The male version
comes in four sizes and 5 colors. The female version comes in six sizes and 8 colors. How
many different types of this shirt are made?
Solutio
MATH11/CS11. FINAL
L.1 An island is populated by knights who always tell the truth, knaves who always
lie, and normals who can either lie or tell the truth. You encounter three people, A, B, and
C. You know one of these people is a knight, one is a knave,
HOMEWORK SET 1. SOLUTIONS OF SELECTED PROBLEMS.
8. Are these system specifications consistent? If the file system is not locked, then new
messages will be queued. If the file system is not locked, then the system is functioning
normally, and conversely. I
HOMEWORK SET 4. SETS AND SET OPERATIONS (BOOK: CHAPTER 1)
1.
For each of the following sets, determine whether 2 is its element. Do the same for cfw_2.
a) cfw_x Z : x > 1
b) cfw_x Z | x = y 2 for some y Z
c) cfw_2, cfw_2
d) cfw_2, cfw_2
e) cfw_2, cfw_2, c
HOMEWORK SET 2. EQUIVALENCES AND ARGUMENTS (BOOK: CHAPTER 4)
1. Show that each of the following propositions is a tautology. You can use truth tables
or properties of logical operators.
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
HOMEWORK SET 5. FUNCTIONS AND CARDINALITY
1. Consider these functions from the set of students in a discrete mathematics class. Under what
conditions is the function injective if it assigns to a student his or her
a)
b)
c)
d)
mobile phone number.
student
HOMEWORK SET 7. CARDINALITY AND COUNTING
1. Assuming that no person has more than 1,000,000 hairs on their head and that the population
of Los Angeles is 4,030,904, show that there are at least five people in Los Angeles with the same
number of hairs on t
HOMEWORK SET 8. COUNTING PERMUTATIONS AND SUBSETS
1. How many ways are there for eight men and five women to stand in a line so that no two
women stand next to each other?
2.
a)
b)
c)
d)
How many bit strings of length 10 contain
Exactly three 0s?
At least
HOMEWORK SET 6. CARDINALITY AND COUNTING
1. A particular brand of shirt comes in 8 colors, has a male version and a female version, and
comes in four sizes for each sex. How many different types of this shirt are made?
2. A palindrome is a string whose re
HOMEWORK SET 8. COUNTING PERMUTATIONS AND SUBSETS
1. How many ways are there for eight men and five women to stand in a line so that no two
women stand next to each other?
Solution. There are 8! way to position men. Once the men are positioned, there are
HOMEWORK SET 7. CARDINALITY AND COUNTING
1. Assuming that no person has more than 1,000,000 hairs on their head and that the population
of Los Angeles is 4,030,904, show that there are at least five people in Los Angeles with the same
number of hairs on t
MATH11/CS11. QUIZ 2
1. Give an example of a function f : N N which is bijective but not equal to the
identity function. Explain why your example works.
Solution. We can take f : N N defined by f (0) = 1, f (1) = 0 and f (n) = n if n > 1. This
function is
HOMEWORK SET 6. CARDINALITY AND COUNTING
1. A particular brand of shirt comes in 8 colors, has a male version and a female version, and
comes in four sizes for each sex. How many different types of this shirt are made?
Solution. We can think of a type of
MATH11/CS11. QUIZ 2
1. Give an example of a function f : N N which is injective but not surjective. Explain
why your example works.
Solution. Define f : N N by f (n) = n + 1. It is injective since if f (n) = f (n0 ) then
n + 1 = n0 + 1 and so n = n0 . It
HOMEWORK SET 8. COUNTING PERMUTATIONS AND SUBSETS
1. How many ways are there for eight men and five women to stand in a line so that no two
women stand next to each other?
Solution. There are 8! way to position men. Once the men are positioned, there are
HOMEWORK SET 3. PREDICATES AND QUANTIFIERS (BOOK: CHAPTER 4)
1. Let P (x) be the statement x spends more than five hours every weekday in class,
where the domain for x consists of all students. Express each of these quantifications in
English.
a) xP (x)
b