* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Download Lec12SeqSum05
Brouwer–Hilbert controversy wikipedia , lookup
Infinitesimal wikipedia , lookup
List of first-order theories wikipedia , lookup
Mathematical proof wikipedia , lookup
Peano axioms wikipedia , lookup
Elementary mathematics wikipedia , lookup
List of prime numbers wikipedia , lookup
Collatz conjecture wikipedia , lookup
Real number wikipedia , lookup
Georg Cantor's first set theory article wikipedia , lookup
Lecture 13 3.2,3.3 Sequences & Summations Proof by Induction Cardinality definition: Two sets have the same cardinality if and only if there is a one-to-one correspondence between them. This is simple for finite sets, but what if a set has infinite elements? definition: A set that is finite or has the same cardinality as the set of positive integers (Z+) is called countable. Example: Consider the sequence {an}, an = n^2, n={1,2,3,4...} Naively speaking, there seem to be much less elements in {an} than in Z+ (since we skip a lot). Infinity is weird! Here is the one-to-one mapping: 1 2 3 4 5 6 7 ... infinity (intuitively: you can enumerate them) 1 4 9 16 25 36 49 ... cardinality Now what about the positive rational numbers: p/q with p,q integer, q not 0 ? 1/1 2 /1 3 /1 4 /1 1/ 2 2 / 2 3 / 2 4 / 2 1/ 3 2 / 3 3 / 3 4 / 3 skip 1/ 4 2 / 4 3 / 4 4 / 4 1 2 1 ½ 3 4 5 6 7 8 9 2 3 1/3 ¼ 2/3 3/2 4 10 5 set of positive rational numbers are countable, in fact the set of all rational numbers is countable : 4 countable quadrants. cardinality That was amazing? Now check this out: a proof that the real numbers are not countable! When a prove seems impossible, try to prove a contradiction. First this: unions of countable sets are countable intersections of countable sets are countable a subset of a countable set is countable. Prove: assume that the reals are countable, the reals in (0,1) are countable (since it is a subset), Thus there is a sequence that counts all reals as follows: 1: r1 = 0.d11 d12 d12 d14 ... 2: r2 = 0.d21 d22 d23 d24 ... 3: r3 = 0.d31 d32 d33 d34 ... etc. construct the number: r = 0.c1 c2 c3 c4 ... with ci=4 if dii not 4 ci = 5 if dii = 4 This is guaranteed to be different than any real in the list, so it isn’t in the list, so the list is not complete. contradiction! real in [0,1] are uncountable all reals are uncountable. 3.3 Mathematical Induction If we want to prove propositions P(k) for all positive integers, we may use inductions. First we prove: P(1) is true. Then we prove P(k) P(k+1). So, is P(100) true? yes, use “modus ponens” 99 times. P(1) P(1)P(2) ____________ P(2) P(2)P(3) ___________ P(3) until P(100). formally: [ P(1) k ( P(k ) P(k 1))] nP(n) Examples prove that the sum of the first n odd positive integers is n^2. n=1: 1 = 1. assume it’s true for some k. 1+3+5+...+2k-1 = k^2 is true. add 2k+1 on each side: 1+3+5+...+2k-1 + 2k+1= k^2 + 2k + 1 1+3+5+...+2(k+1)-1 = (k+1)^2 Examples Prove that n < 2^n for positive integers n. P(1): 1 < 2 Inductive step: assume P(k) is correct, prove P(k+1) is correct. k < 2^k k+1 < 2^k + 1 < 2^k + 2^k = 2^(k+1) Note: we could of course also start our induction at another integer b. Example: Prove that 2^n < n! for integers n>= 4 . P(4) = 2^4 = 16 < 4! = 4 3 2 1 = 24. Induction: assume 2^k < k! 2 x 2^k < 2 x k! 2^(k+1) < (k+1) x k! (recall k > = 4). 2^(k+1) < (k+1)! Strong Induction induction (I): [ P(1) k ( P(k ) P(k 1))] nP(n) strong induction (SI): [ P(1) k ( P(1) P(2) ... P( k ) P( k 1))] nP( n) they are equivalent Strong Induction Example: Consider the game where there are 2 piles of n matches. Each player picks an arbitrary number of matches from one pile. The one who gets the last matches wins. Proposition: The player who starts second can always win. P(1): 2 piles with 1 match each. Second player always wins. Assume player 2 wins when we have 2 piles of k matches. Can player 2 win when we have 2 piles of k+1 matches? Player 1 will have to take between 1 and k+1 matches from 1 pile. If he picks k+1 matches, player 2 wins by grabbing all matches from the other pile. If he picks between 1 and k matches, player two takes the same amount from the other pile reducing the problem to a smaller equivalent problem. Strong Induction player 2 always wins Examples Proposition: every positive integer n>2 can be written as the product of primes. P(2): product of itself (it’s prime). Assume k can be written as a product of primes. Can we prove it for k+1? two cases: k+1 = prime (thus it is a product of one number – itself). k+1 = a x b However since both a and b < k+1 and >= 2, we know that a and b can be written as the product of primes a x b is a product of primes.