Download Induction Proofs in Mathematics and Computer Science and more Assignments Health sciences in PDF only on Docsity! CS313K: Logic, Sets and Functions Fall 2008 Problem Set 2: Proofs by Induction Induction is a useful proof method in mathematics and computer science. When we want to prove by induction that some statement containing a variable n is true for all nonnegative values of n, we do two things. First we prove the statement when n = 0; this part of the proof is called the basis. Then we prove the statement for n + 1 assuming that it is true for n; this part of the proof is called the induction step. (The assumption that the statement is true for n, which is used in the induction step, is called the induction hypothesis.) Once we have completed both the basis and the induction step, we can conclude that the statement holds for all nonnegative values of n. Indeed, according to the basis, in holds for n = 0. From this fact, according to the induction step, we can conclude that it holds for n = 1. From this fact, according to the induction step, we can conclude that it holds for n = 2. And so on. Here is an example of the use of induction. Problem. Prove that for all nonnegative integers n 1 + 2 + . . . + n = n(n + 1) 2 . Solution. Basis. When n = 0, the formula turns into 0 = 0(0 + 1) 2 , which is correct. Induction step. Assume that 1 + 2 + . . . + n = n(n + 1) 2 . We need to prove that 1 + 2 + . . . + n + (n + 1) = (n + 1)(n + 2) 2 . 1 Using the induction hypothesis, we calculate: 1 + 2 + . . . + n + (n + 1) = n(n + 1) 2 + (n + 1) = n(n + 1) + 2(n + 1) 2 = (n + 1)(n + 2) 2 . 2.1. Prove by induction that for all nonnegative integers n 12 + 22 + . . . + n2 = n(n + 1)(2n + 1) 6 . 2.2. Prove by induction that for all nonnegative integers n 13 + 23 + . . . + n3 = n2(n + 1)2 4 . 2.3. Calculate the values of the expression 1 1 · 2 + 1 2 · 3 + · · ·+ 1 n · (n + 1) for several values of n and guess what a formula for this sum can be. Prove your formula by induction. So far we used induction to prove equalities. Induction can be also used to prove inequalities. Here is an example. Problem. Prove that for all nonnegative integers n, 2n > n. Solution. Basis. When n = 0, the formula turns into 1 > 0, which is correct. Induction step. Assume that 2n > n. We need to prove that 2n+1 > n + 1. This can be done as follows, using the induction hypothesis and then the fact that 2n ≥ 1: 2n+1 = 2n + 2n > n + 2n ≥ n + 1. So far we used induction to prove statements about nonnegative integers. Statements about positive integers can be proved by induction in a similar way, except that the basis corresponds to n = 1; also, in the induction step we may assume that n ≥ 1. Similarly, if we want to prove a statement about all integers beginning with 2 then the basis corresponds to n = 2, and so on. 2