Docsity

14 Problems Final Exam - Discrete Structures | CS 2800, Exams of Discrete Structures and Graph Theory

Toggle sidebar
bg1
CS280, Spring 2004: Final
This exam is out of 70; the amount for each question is as marked. Clearly explain your
reasoning. (Remember, we can’t read your mind! Besides, it gives us a chance to give you
partial credit.) Don’t forget to put your name and student number on each blue book you use.
You can answer the questions in any order, just as long as you mark clearly which question
you’re answering. A good strategy is to do the ones you find easiest first.
Exams should be available next Tuesday or Wednesday; your grades will be posted on the
CMS then too. You can pick up your exam in 4146 Upson after they’re graded. We’ll send out
a message when that’s done.
Good luck!
1. [4 points] Which of the following relations on {0,1,2,3}is an equivalence relation. (If it is,
explain why. If it isn’t, explain why not.) Just saying “Yes” or “No” with no explanation
gets 0 points.)
(a) {(0,0,),(1,1),(2,2),(3,3)}
(b) {(0,0),(0,1),(1,0),(1,1)}.
2. [5 points] Recall that a composite nis a Carmichael number if for any brelatively prime to
n,bn−1≡1 (mod n). Show that 1105 is a Carmichael number. [Hint: 1105 = 5 ·13 ·17.]
3. [4 points] Consider any six natural numbers n1, . . . , n6. Show that the sum of some
subsequence of consecutive numbers is divisible by 6 (e.g., perhaps n3+n4+n5is divisible
by 6, or n4itself is divisible by 6, or n2+n3is divisible by 6). [Hint: Look at the sums
0, n1,n1+n2,n1+n2+n3, . . . , n1+n2+· ·· +n6, and think in terms of mod 6.]
4. [5 points] What is the coefficient of x25 in the binomial expansion of (2x−3
x2)58? (There’s
no need to simplify the expression.)
5. [5 points] Prove that 3n≥n3for all n≥3.
6. [3 points] How many 5-card hands have exactly 3 kings?
7. [4 points] A committee of 7 is to be chosen from 8 men and 9 women. How many contain
either Alice or Bob, but not both? [You do not have to simplify the expression that you
get.]
8. [5 points] There are Ndifferent types of coupons. Each time a coupon collector obtains
a coupon it is equally likely to be any one of those. What is the probability that the
collector needs more than k(k > N ) coupons to complete his collection (have at least
one of each type of coupon)? (You do not have to simplify the expression that you get.)
[Hint: In other words, what is the probability that at least one type coupon is missing
among the first kcoupons.]
1
pf3

Partial preview of the text

Download 14 Problems Final Exam - Discrete Structures | CS 2800 and more Exams Discrete Structures and Graph Theory in PDF only on Docsity!

CS280, Spring 2004: Final

This exam is out of 70; the amount for each question is as marked. Clearly explain your reasoning. (Remember, we can’t read your mind! Besides, it gives us a chance to give you partial credit.) Don’t forget to put your name and student number on each blue book you use. You can answer the questions in any order, just as long as you mark clearly which question you’re answering. A good strategy is to do the ones you find easiest first.

Exams should be available next Tuesday or Wednesday; your grades will be posted on the CMS then too. You can pick up your exam in 4146 Upson after they’re graded. We’ll send out a message when that’s done.

Good luck!

  1. [4 points] Which of the following relations on { 0 , 1 , 2 , 3 } is an equivalence relation. (If it is, explain why. If it isn’t, explain why not.) Just saying “Yes” or “No” with no explanation gets 0 points.)

(a) {(0, 0 , ), (1, 1), (2, 2), (3, 3)} (b) {(0, 0), (0, 1), (1, 0), (1, 1)}.

  1. [5 points] Recall that a composite n is a Carmichael number if for any b relatively prime to n, bn−^1 ≡ 1 (mod n). Show that 1105 is a Carmichael number. [Hint: 1105 = 5 · 13 · 17.]
  2. [4 points] Consider any six natural numbers n 1 ,... , n 6. Show that the sum of some subsequence of consecutive numbers is divisible by 6 (e.g., perhaps n 3 +n 4 +n 5 is divisible by 6, or n 4 itself is divisible by 6, or n 2 + n 3 is divisible by 6). [Hint: Look at the sums 0, n 1 , n 1 + n 2 , n 1 + n 2 + n 3 ,... , n 1 + n 2 + · · · + n 6 , and think in terms of mod 6.]
  3. [5 points] What is the coefficient of x^25 in the binomial expansion of (2x − (^) x^32 )^58? (There’s no need to simplify the expression.)
  4. [5 points] Prove that 3n^ ≥ n^3 for all n ≥ 3.
  5. [3 points] How many 5-card hands have exactly 3 kings?
  6. [4 points] A committee of 7 is to be chosen from 8 men and 9 women. How many contain either Alice or Bob, but not both? [You do not have to simplify the expression that you get.]
  7. [5 points] There are N different types of coupons. Each time a coupon collector obtains a coupon it is equally likely to be any one of those. What is the probability that the collector needs more than k (k > N ) coupons to complete his collection (have at least one of each type of coupon)? (You do not have to simplify the expression that you get.) [Hint: In other words, what is the probability that at least one type coupon is missing among the first k coupons.]
  1. [10 points] For each of the following clearly answer yes or no (no justification is needed nor will it help you). If you answer correctly you get +1 but if you give the wrong answer you get -1 points. A skipped item earns 0 points. In any case the overall grade for this particular problem will not be less than zero.

(a) If A and B are disjoint events then they are independent. (b) If A and B are independent events, then so are A and B. (c) A sum of Bernoulli random variables is a binomial random variable. (d) If X and Y are independent then V (X + Y ) = V (X) + V (Y ). (e) If a is a real number and X is a random variable, then V (aX) = aV (X). (f) If X and Y are not independent then E(X + Y ) 6 = E(X) + E(Y ). (g) If A and B are independent events then Pr(A ∪ B) = Pr(A) + Pr(B). (h) Suppose that you have a coin that has probability .2 of landing heads, and you toss it 100 times. Let X be the number of times that the coin lands heads. Then P r(X ≥ 60) ≤ 1 /100. (i) Let Tn be the number of times a fair coin lands heads after being flipped n times. Then lim n→∞ Pr

Tn n

∣ <.^01

(j) Taking Tn as above,

nlim→∞ Pr

∣∣^2 T √n^ −^ n n

  1. [4 points] There are three cards. The first is red on both sides; the second is black on both sides; and the third is red on one side and black on the other side. A card is randomly selected and randomly placed on the table. The color that we see is red. What is the probability that the hidden side is black?
  2. [4 points] Two fair dice are rolled. What is the probability at least one lands on 6 given that the dice land on different numbers?
  3. [5 points]

Input: n (a positive integer) factorial ← 1 i ← 1 while i < n do i ← i + 1 factorial ← i ∗ factorial

Prove that the program terminates with factorial = n! given input n, using an appropriate loop invariant.