

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!


Math 184A Second Exam Solutions 26 February 2001
b 1 = b 2 = 1, b 3 = 2, b 4 = 5, b 5 = 14, b 6 = 42, b 7 = 132.
Cn(k) =
1 if k = 1, 2 Cn− 1 (k − 1) if 1 < k ≤ n, 0 if k > n.
(a) Tabulate values of Cn(k) for 1 ≤ k ≤ n ≤ 4. Ans. This is straightforward. (b) State and prove a simple formula for Cn(k) that does not involve a recursion. Ans. You can guess from (a) that Cn(k) = 2k−^1 for 1 ≤ k ≤ n and zero otherwise. This can proved by induction. Should we induct on n or k? Either will work However, since the answer does not depend on n and “Cn(k) = 1 if k = 1” looks like an initial condition, it may be somewhat easier to induct on k. (It is.) As noted, this is the base case. For k in the range 2 ≤ k ≤ n, we have
Cn(k) = 2Cn− 1 (k − 1) by the given formula, = 2 × 2 k−^2 by A(k − 1), = 2k−^1.
Math 184A Second Exam Solutions 26 February 2001
(b) Find a constant P > 1 /4 such that the following statement is true for n > 1 about those binary trees with n leaves. “In more than P bn of them, the left subtree contains at most 2 leaves.”
Ans. From bN < 4 bN − 1 at N = n and N = n − 1, we have bn < 4 bn− 1 < 42 bn− 2. Thus bn− 2 > bn/16. Reasoning as in (a), the number of such trees is greater than
b 1 bn− 1 + b 2 bn− 2 = bn− 1 + bn− 2 < bn/4 + bn/16 = 4bn/ 16.
Thus P can have any value such that 1/ 4 < P ≤ 5 /16.