CS 1050B Supplementary Exercises for Chapter 1 and 4: Proofs and Recurrence Relations, Assignments of Computer Science

Supplementary exercises for cs 1050b students studying chapter 1 (logic and proofs) and chapter 4 (induction and recursion) of rosen's discrete mathematics text. The exercises cover various topics such as proving irrational numbers, mathematical induction, and recursive sequences.

Typology: Assignments

Pre 2010

Uploaded on 08/05/2009

koofers-user-fxt
koofers-user-fxt 🇺🇸

10 documents

1 / 3

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
CS 1050B: Constructing Proofs
Supplementary Exercises 3 : Comprehensive
Nov 29, 2006
Rosen Chapter 1 : Logic and Proofs
1. Chapter 1 Supplementary P.40
Assuming the truth of the theorem that states that nis irrational whenever nis a positive
integer that is not a perfect square, prove that 2 + 3 is irrational.
2. 1.7 P.34
Prove that between every two rational numbers there is an irrational number.
Chapter 4 : Induction and Recursion
Chapter 7 : Recurrence Relations
3. Chapter 4 Supplementary P.4
Use mathematical induction to show that
1
1·3+1
3·5+· ·· +1
(2n1)(2n+ 1) =n
2n+ 1
whenever nis a positive integer.
4. 4.2 P.12
Use strong induction to show that every positive integer ncan be written as a sum of distinct
power of two, that is, as a sum of a subset of the integers 20= 1,21= 2,22= 4, and so on.
[Hint :For the inductive step, separately consider the case where k+ 1 is even and where it is
odd. When it is even, note that (k+ 1)/2 is an integer.]
5. Give a recursive definition of the sequence an,n= 1,2,3,··· if
a) an= 5
b) an= 10n
c) an=n+ (1)n
d) an=n!(n2+ 2)
(This was the first problem from quiz 1. Check out the solution if you are stuck. We
are expecting that you will be able to write up the solution in the same way during the
final exam.)
6. Find the solution to each of these recurrence relations and initial conditions. Use an iterative
approach
1
pf3

Partial preview of the text

Download CS 1050B Supplementary Exercises for Chapter 1 and 4: Proofs and Recurrence Relations and more Assignments Computer Science in PDF only on Docsity!

CS 1050B: Constructing Proofs

Supplementary Exercises 3 : Comprehensive

Nov 29, 2006

Rosen Chapter 1 : Logic and Proofs

  1. Chapter 1 Supplementary P. Assuming the truth of the theorem that states that

n is irrational whenever n is a positive integer that is not a perfect square, prove that

3 is irrational.

2. 1.7 P.

Prove that between every two rational numbers there is an irrational number.

Chapter 4 : Induction and Recursion

Chapter 7 : Recurrence Relations

  1. Chapter 4 Supplementary P. Use mathematical induction to show that 1 1 · 3

(2n − 1)(2n + 1)

n 2 n + 1

whenever n is a positive integer.

  1. 4.2 P. Use strong induction to show that every positive integer n can be written as a sum of distinct power of two, that is, as a sum of a subset of the integers 2^0 = 1, 21 = 2, 22 = 4, and so on. [Hint:For the inductive step, separately consider the case where k + 1 is even and where it is odd. When it is even, note that (k + 1)/2 is an integer.]
  2. Give a recursive definition of the sequence an, n = 1, 2 , 3 , · · · if

a) an = 5 b) an = 10n c) an = n + (−1)n d) an = n!(n^2 + 2) (This was the first problem from quiz 1. Check out the solution if you are stuck. We are expecting that you will be able to write up the solution in the same way during the final exam.)

  1. Find the solution to each of these recurrence relations and initial conditions. Use an iterative approach

a) an = an− 1 + 2n + 3, a 0 = 4 b) an = 2an− 1 − 1 , a 0 = 1 c) an = 2nan− 1 , a 0 = 1

7. 7.3 P.

Suppose that the votes of n people for different candidates (where there can be more than two candidates) for a particular office are the elements of a sequence. A person wins the election if this person receives a majority of the votes.

a) Devise a divide-and-conquer algorithm that determines whether a candidate received a majority and, if so, determine who this candidate is. [Hint: Assume that n is even and split the sequence of votes into two sequences, each with n/2 elements. Note that a candidate could not have received a majority of votes without receiving a majority of votes in at least one of the two halves.] b) Use the Master Theorem to estimate the number of comparisons needed by the algorithm you devised in part 1.

Chapter 5 : Counting

Chapter 6 : Discrete Probability

  1. Chapter 5 Supplementary P. Show that if five points are picked in the interior of a square with a side length of 2, then at least two of these points are no farther than

2 apart.

  1. Chapter 5 Supplementary P. How many different arrangements are there of eight people seated at a round table, where two arrangements are considered the same if one can be obtained from the other by a rotation?
  2. Chapter 6 Supplementary P. This problem appeared in the second supplementary set. If you have not done this problem, I strongly recommend you to finish it by yourself.

Solution: See supplementary 2 solution key.

  1. Let’s play cards

a) How many ways are there to pick out 5 cards (a 5-card hand) in a 52-card deck? b) How many 5-card hands are there that contains no pairs? c) What is the probability that a 5-card hand contains no pairs?

  1. What is the expected value when a $1 lottery ticket is bought in which the purchaser wins exactly $10 million if the ticket contains the six winning numbers chosen from the set { 1 , 2 , 3 , · · · , 50 } and the purchaser wins nothing otherwise?

Rosen Chapter 3 : Number Theory