Docsity

Homework 7 Solved Questions - Constructing Proofs | CS 1050, Assignments of Computer Science

Toggle sidebar
bg1
1
121
23... 1
n(n1) 1
k(k1) n
n1
k1
n
.
1
121
111
2.
1
k(k1) n1
(n1) 1
k1
n1
.
k
3
11(11)
2




k1
1
2
.
k
3
n(n1)
2




k1
n
2
.
1
k(k1) n
n1
k1
n
CS1050 HW 7 Answer Key
There are 100 points total over the entire homework. Use mathematical induction
for each problem.
Section 3.3, pp. 253-254, 6, 8, 12, 18, 20
6) [20 points]
Inspection gives the following formula:
Prove the formula using induction.
Basis Step: So the formula holds for n = 1.
Inductive Step: Assume that
is true for n 1. We must show that the formula holds for n+1. Thus
we need to show
Using the inductive assumption, it follows that
We have shown that the formula holds for n+1, thus completing the proof for all n 1.
8) [20 points]
Using induction, prove
for n 1.
Basis Step:
n
2
2n1
(n1)(n2) (n1)(n1)
(n1)(n2)
(n1)
(n2) .
n(n2)
(n1)(n2) 1
(n1)(n2)
pf3
pf4

Partial preview of the text

Download Homework 7 Solved Questions - Constructing Proofs | CS 1050 and more Assignments Computer Science in PDF only on Docsity!

n(n  1 )

k(k  1 )

n

k 1 n^ ^1

n

k(k  1 )

n  1

k 1 (n^ ^1 )^ ^1

n 1

k 3  1 

k 1  1

2 . k 3  n(n  1 ) 2

k 1  n

2 .

k(k  1 )

n

k 1 n^ ^1

n

**CS1050 HW 7 Answer Key There are 100 points total over the entire homework. Use mathematical induction for each problem. Section 3.3, pp. 253-254, 6, 8, 12, 18, 20

  1. [20 points]** Inspection gives the following formula: Prove the formula using induction. Basis Step: So the formula holds for n = 1. Inductive Step: Assume that is true for n  1. We must show that the formula holds for n+1. Thus we need to show Using the inductive assumption, it follows that We have shown that the formula holds for n+1, thus completing the proof for all n  1. 8) [20 points] Using induction, prove for n  1. Basis Step:

n^2  2 n  1 (n  1 )(n  2 )

(n  1 )(n  1 ) (n  1 )(n  2 )  (n  1 ) (n  2 )

k(k  1 )

k 1 n 1

k(k  1 )

(n  1 )(n  2 )

k 1 n

n

n  1

(n  1 )(n  2 )

n(n  2 ) (n  1 )(n  2 )

(n  1 )(n  2 )

k 3  n(n  1 ) 2

k 1  n

2 k 3  (n  1 )(n  2 ) 2

k 1  n 1

2 .

k

3

 k

3

 (n  1 )

3

n(n  1 )

2 k  1 n

k 1 n 1

 (n^ ^1 )

3 Inductive Step: Assume that is true for n  1. We must show that the formula is true for n+1; that is, we must show Using the inductive assumption, it follows that This shows that the formula holds for n+1, completing the proof for all n  1. 12) [20 points] Prove that 3n^ < n! whenever n is a positive integer greater than 6. Basis Step: The inequality holds for n = 7; 3^7 = 2187 < 7! = 5040. Inductive Step: Assume that 3n^ < n! is true for n. We must show that it is then true for n+1. That is, we must show that 3n+1^ < (n+1)!. Starting from the inductive assumption, multiply both sides by 3. 3  3 n^ < 3n! Since we know that n+1 will always be greater than 3 because n > 6, we can replace 3 on the right side by n+1 to get 3  3 n^ < (n+1)n! 3 n+1^ < (n+1)! This shows that the formula holds for n+1, completing the proof for all n > 6.

n^2 (n  1 )^2 4

4 (n  1 )^2 (n  1 ) 4

(n  1 )^2 (n^2  4 n  4 ) 4

(n  1 )

2

(n  2 )

2

2

(n  1 )(n  2 )

2

20) [20 points] Prove that 3 divides n^3 + 2n whenever n is a nonnegative integer. Basis Step: The statement is true for n = 0, because 3 divides 0. Inductive Step: Assume that 3 divides n^3 + 2n for an arbitrary n. We must then show that this is true for n+1; that is, 3 divides (n+1)^3 + 2(n+1). By arithmetic, (n+1)^3 + 2(n+1) = (n^3 + 3n^2 + 3n +1) + (2n + 2), = (n^3 + 2n) + (3n^2 + 3n + 3), = (n^3 + 2n) + 3(n^2 + n + 1). Three divides the first term on the RHS by the inductive assumption. Three divides the second term by the definition of divisibility (because this term is 3 times an integer). It follows from this that 3 divides (n+1)^3 + 2(n+1). This shows the proposition holds for n+1, thus completing the proof for all n>0.