You are on page 1of 2
CS21001 Discrete Structures, Autumn 2006 Mid-semester examination r Duration: 2 sqotal marks: 100 September 15, 2006 (AN): $-302 (1B) | Answer all questions | Let p41 be propositions, and (ix), 62(w), I(x) be predicutes, a) Prove that (pV q) => (pA q) is logically equivalent to p +> 4 (b) Prove that (p Aq) > (pV q) is a tautology. (@) What is the contrapositive of Var[P(z)}'=» Ax (Q(x) v R(x}? (@) Write in English the converse of the following assertion; “ICT wake up early, I attend the lecture, unless { have a headache.” (© Write in English the negation of the following, assertion: “The sum of any two odd integers is an even integer" Lot in be the value returned by the following C function upon input 1, (Assume that © supports arbitrarily big integers, so that no overflow occurs during arithmetic operations.) unsigned int a ( unsigned int n ) ¢ unsigned int sum, 4) Af (n == 0) return 1) gum = 07 flor (4m0) deny 444) gum += a(d)y jows that: ao ; 0} Ay = {0,1,2}, ‘ a By = {1}, 0,2}. : CQ = {0,1,2,3,4,5,6,7,8}, Bo ={1,3,4,5,7}, C2 = {0,2,6,8}. Let, denote the size of Cy, s, the sum of elements of B, 6, = 4,92 = 143444547 = 20, and ty = 042464 (a) Prove that ry, = 2” for all n > 0. \d ty, the sum of elements of C,. For example, = 16. (b) Deduce that ty satisfies the recurrence relation: to = 0, tn i Bina + 5 xo" for all n> 1 (©) Solve the above recurrence relation in order to derive that fn = 3(6" ) for all n > 0. (@_ Conclude that s,, = }(9" — 6" — 3" + 2") foralln > 0. Letk EN, S = {1,2,...,k}.and A= P(S) \ (0), where P(S) denotes the power set of S, and (denotes the empty set. In other words, the set A comprises all non-empt yy subsets of {1,2,-..,k}- For each a € A denote by min(a) the smallest element of a (notice that here a is a set). (@) Define a relation pon A as follows: @ p b if and only if min(a) = min(b)- Prove that p is an equivalence relation on A. : “it (b) What is the si (©) Define a relation

You might also like