Packet 3 Supplement, Annotated Versions of Examples 3.2 & 3.3

Total Page:16

File Type:pdf, Size:1020Kb

Packet 3 Supplement, Annotated Versions of Examples 3.2 & 3.3

CSC 224/226 Packet 3 Supplement June 14, 2003

Packet 3 Supplement, Annotated versions of Examples 3.2 & 3.3

In the two following proofs, an understanding of summation is crucial. Please see the Math Skills Review handout on the course notes page.

In a proof by induction, we do the setup, including writing out and proving the basis, and writing the assume and prove statements. The assume statement is like a “given” in a logic proof. The prove statement is our goal, what we wish to know is true at the end of the proof. It is not in itself a proof. So, we assume we know a statement is true for n, and we want to show it is also true for n+1.

In the two following proofs, we set up our proofs, and then the real work begins. In each, we start by writing the LHS of the prove statement, and set it equal to the LHS of the assume statement. Then, we must fix that equation so it’s actually true, by figuring out how the LHS Prove differs from the LHS Assume.

For summations, we must make sure that the starting values and ending values for the summation line up to make sure they are equal.

After we make sure that our equation is true, we can substitute in the RHS Assume for the LHS Assume. Then, our work is only algebra from there, to determine that what we have is equal to the RHS Prove.

Page 1 of 3 CSC 224/226 Packet 3 Supplement June 14, 2003

n Example 3.2: Prove: (6i  2) = n(3n+1) for n in P i1

Basis: For n = 1, ∑(i=1 to 1) (6i-2) = (6*1-2) = 4 (LHS)

n(3n+1) = 1*(3+1) = 4 (RHS); LHS=RHS.

n Assume true for n: (6i  2) = n(3n+1) i1

Prove true for (n+1): n1 (6i  2) = (n+1)[3(n+1)+1] i1 = (n+1)(3n+4) (algebra) = 3n+7n+4 (algebra) Proof: n1 n (LHS Prove) (6i  2) = (6i  2) (LHS Assume) + [6(n+1)-2 (fix top) i1 i1

Here, we write the LHS of the Prove statement in terms of the LHS of the Assume.

Fix top: Our equation is not correct unless our limits of the sums are the same on both sides. Since the start values are the same on both sides, we only have to worry about the top of the summation. On the LHS Prove the summation goes to n+1 while in the LHS Assume it only goes to n. Therefore, to make the two sides equal we must add the (n+1st) term of the summation. This means we plug in n+1 for i to get the last term, (6(n+1)-2), and add it to the LHS Assume.

Next, we substitute the RHS Assume in for LHS Assume: = n(3n+1) (RHS Assume) + [6(n+1)-2] (n+1st) term The rest is algebra: = 3n+n+[6n+6-2] = 3n+7n+4 (RHS Prove) QED, since LHS Prove=RHS Prove, true for n

Page 2 of 3 CSC 224/226 Packet 3 Supplement June 14, 2003

2n 3n(n  1) Example 3.3: Prove: i = n ≥ 1 in 2 2 3(1)(11) 3(2) Basis: n = 1, LHS i = 1+2 = 3, RHS = = 3; LHS = RHS i1 2 2 2n 3n(n 1) Assume true for n: i = in 2 2(n1) 3(n 1)(n  2) Prove true for (n+1): i = (replace all n’s with n+1) in1 2 Proof: 2(n1) 2n2 2n 2n2 n (LHS Prove) i  i = i  i  i in1 in1 in i2n1 in = (LHS Assume + fix top – fix bottom)

Here, we need to write the LHS of the Prove statement in terms of the LHS of the Assume statement. This requires that we make sure that the top and the bottom of the summations are reconciled, so no term is missing and no term is added when it should not be.

Fix top: In this case, the prove summation ends at 2n+2 while the assume ends at 2n. Therefore, we must add all the same terms after 2n up to 2n+2. The next number after 2n is 2n+1, so that is where our “fix top” summation begins. It ends at 2n+2, so we have now fixed the top of the summation to be correct.

Fix bottom: The prove summation starts at n+1 while the assume starts at n. Therefore, we must subtract the nth term from the assume statement so that we start at the (n+1st) term instead.

Next, we substitute in the RHS of the Assume statement, and expand our fix top and bottom summations:

3n(n 1) = (RHS Assume) + (2n+1 + 2n+2) (fix top) - n (fix bottom) 2 3n(n 1) = + 3n + 3 (add fix top +fix bottom) 2

The rest is algebra:

3n(n 1) 2*3(n 1) (n 1)(3n  6) 3(n 1)(n  2) =    (RHS Prove) 2 2 2 2 QED, the statement is true for n ≥ 1 (since LHS Prove=RHS Prove).

Page 3 of 3

Recommended publications