22
CSE 20 – Discrete Mathematics Dr. Cynthia Bailey Lee Dr. Shachar Lovett Peer Instruction in Discrete Mathematics by Cynthia Lee is licensed under a Creative Commons Attribution- NonCommercial - ShareAlike 4.0 International License . Based on a work at http://peerinstruction4cs.org . Permissions beyond the scope of this license may be available at http://peerinstruction4cs.org .

CSE 20 – Discrete Mathematics

  • Upload
    austin

  • View
    35

  • Download
    0

Embed Size (px)

DESCRIPTION

- PowerPoint PPT Presentation

Citation preview

Page 1: CSE 20 – Discrete Mathematics

CSE 20 – Discrete MathematicsDr. Cynthia Bailey LeeDr. Shachar Lovett

                          Peer Instruction in Discrete Mathematics by Cynthia Leeis licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.Based on a work at http://peerinstruction4cs.org.Permissions beyond the scope of this license may be available at http://peerinstruction4cs.org.

Page 2: CSE 20 – Discrete Mathematics

2

Today’s Topics:1. Countably infinitely large sets2. Uncountable sets

“To infinity, and beyond!” (really, we’re going to go beyond infinity)

Page 3: CSE 20 – Discrete Mathematics

3

Set Theory and Sizes of Sets How can we say that two sets are the

same size? Easy for finite sets (count them)--what

about infinite sets? Georg Cantor (1845-1918), who invented

Set Theory, proposed a way of comparing the sizes of two sets that does not involve counting how many things are in each Works for both finite and infinite

SET SIZE EQUALITY: Two sets are the same size if there is a bijective

(injective and surjective) function mapping from one to the other

Intuition: neither set has any element “left over” in the mapping

Page 4: CSE 20 – Discrete Mathematics

4

Injective and Surjective

f is:a) Injectiveb) Surjectivec) Bijective (both (a) and (b))d) Neither

Sequences of a’sNatural

numbers

1234…

aaaaaaaaaa

f

Page 5: CSE 20 – Discrete Mathematics

5

Can you make a function that maps from the domain Natural Numbers, to the co-domain Positive Evens?

A. Yes and my function is bijectiveB. Yes and my function is not bijectiveC. No (explain why not)

Positive evens

Natural numbers

1234…

2468…

Page 6: CSE 20 – Discrete Mathematics

6

Can you make a function that maps from the domain Natural Numbers, to the co-domain Positive Evens?

f(x)=2x

Natural numbers

1234…

2468…

f

Positive evens

Page 7: CSE 20 – Discrete Mathematics

7

Can you make a function that maps from the domain Natural Numbers, to the co-domain Positive Odds?

A. Yes and my function is bijectiveB. Yes and my function is not bijectiveC. No (explain why not)

Positive odds

Natural numbers

1234…

1357…

Page 8: CSE 20 – Discrete Mathematics

8

Can you make a function that maps from the domain Natural Numbers, to the co-domain Positive Odds?

f(x)=2x-1

Natural numbers

1234…

1357…

f

Positive odds

Page 9: CSE 20 – Discrete Mathematics

9

Countably infinite size sets So |ℕ| = |Even|, even though it seems

like it should be |ℕ| = 2|Even| Also, |ℕ| = |Odd| Another way of thinking about this is

that two times infinity is still infinity

Does that mean that all infinite size sets are of equal size?

Page 10: CSE 20 – Discrete Mathematics

10

It gets even weirder:Rational Numbers (for simplicity we’ll do ratios of natural numbers, but the same is true for all Q)

1/1 1/2 1/3 1/4 1/5 1/6 …2/1 2/2 2/3 2/4 2/5 2/6 …3/1 3/2 3/3 3/4 3/5 3/6 …4/1 4/2 4/3 4/4 4/5 4/6 …5/1 5/2 5/3 5/4 5/5 5/6 ...6/1 6/2 6/3 6/4 6/5 6/6… … … … … … …

ℚ+ ℕ

Page 11: CSE 20 – Discrete Mathematics

11

It gets even weirder:Rational Numbers (for simplicity we’ll do ratios of natural numbers, but the same is true for all Q)

1/1 1/2 1/3 1/4 1/5 1/6 …2/1 2/2 2/3 2/4 2/5 2/6 …3/1 3/2 3/3 3/4 3/5 3/6 …4/1 4/2 4/3 4/4 4/5 4/6 …5/1 5/2 5/3 5/4 5/5 5/6 ...6/1 6/2 6/3 6/4 6/5 6/6… … … … … … …

ℚ+ ℕ

Is there a bijection from the natural

numbers to Q+?

A. YesB. No

Page 12: CSE 20 – Discrete Mathematics

12

It gets even weirder:Rational Numbers (for simplicity we’ll do ratios of natural numbers, but the same is true for all Q)

1/1 1 1/2 2 1/3 4 1/4 6 1/5 10

1/6 …

2/1 3 2/2 x 2/3 7 2/4 x 2/5 2/6 …3/1 5 3/2 8 3/3 x 3/4 3/5 3/6 …4/1 9 4/2 x 4/3 4/4 4/5 4/6 …5/1 11

5/2 5/3 5/4 5/5 5/6 ...

6/1 6/2 6/3 6/4 6/5 6/6… … … … … … …

ℚ+ ℕ

Page 13: CSE 20 – Discrete Mathematics

13

Sizes of Infinite Sets The number of Natural Numbers is equal to the number

of positive Even Numbers, even though one is a proper subset of the other! |ℕ| = |E+|, not |ℕ| = 2|E+|

The number of Rational Numbers is equal to the number of Natural Numbers |ℕ| = |ℚ+|, not |ℚ+| ≈ |ℕ|2

But it gets even weirder than that: It might seem like Cantor’s definition of “same size” for

sets is overly broad, so that any two sets of infinite size could be proven to be the “same size” Actually, this is not so

Page 14: CSE 20 – Discrete Mathematics

14Thm. |ℝ| != |ℕ|Proof by contradiction: Assume |ℝ| = |ℕ|, so a bijective function f exists between ℕ and ℝ.• Want to show: no matter how f is designed (we don’t

know how it is designed so we can’t assume anything about that), it cannot work correctly.

• Specifically, we will show a number z in ℝ that can never be f(n) for any n, no matter how f is designed.

• Therefore f is not surjective, a contradiction.

Natural numbers

1234…

???z?…

f

Real numbers

Page 15: CSE 20 – Discrete Mathematics

15

n f(n)1 .100000…2 .333333…3 .314159…… …

• We construct z as follows:• z’s nth digit is the nth digit of f(n), PLUS ONE*

(*wrap to 1 if the digit is 9)• Below is an example f

What is z in this example? a) .244…b) .134…c) .031…d) .245…

Thm. |ℝ| != |ℕ|Proof by contradiction: Assume |ℝ| = |ℕ|, so a bijective function f exists between ℕ and ℝ.

Page 16: CSE 20 – Discrete Mathematics

16

n f(n)1 .d11

d12d13

d14…

2 .d21d22

d23d24

…3 .d31

d32d33

d34…

… …

What is z?a) .d11

d12d13

…b) .d11

d22d33

…c) .[d11

+1] [d22+1] [d33

+1]

…d) .[d11

+1] [d21+1] [d31

+1]

Thm. |ℝ| != |ℕ|Proof by contradiction: Assume |ℝ| = |ℕ|, so a bijective function f exists between ℕ and ℝ.• We construct z as follows:• z’s nth digit is the nth digit of f(n), PLUS ONE*

(*wrap to 1 if the digit is 9)• Below is a generalized f

Page 17: CSE 20 – Discrete Mathematics

17

n f(n)1 .d11

d12d13

d14…

2 .d21d22

d23d24

…3 .d31

d32d33

d34…

… …

• How do we reach a contradiction?• Must show that z cannot be f(n) for any

n• How do we know that z ≠ f(n) for any n?a) We can’t know if z =

f(n) without knowing what f is and what n is

b) Because z’s nth digit differs from n‘s nth digit

c) Because z’s nth digit differs from f(n)’s nth digit

Thm. |ℝ| != |ℕ|Proof by contradiction: Assume |ℝ| = |ℕ|, so a bijective function f exists between ℕ and ℝ.

Page 18: CSE 20 – Discrete Mathematics

Thm. |ℝ| != |ℕ|• Proof by contradiction: Assume |ℝ| = |ℕ|, so a

correspondence f exists between N and ℝ.• Want to show: f cannot work correctly.

• Let z = [z’s nth digit = (nth digit of f(n)) + 1]. • Note that zℝ, but nℕ, z != f(n).

• Therefore f is not surjective, a contradiction.

• So |ℝ| ≠ |ℕ|• |ℝ| > |ℕ|

Page 19: CSE 20 – Discrete Mathematics

Diagonalization

19

n f(n)1 .d11

d12d13

d14d15

d16d17

d18d19

…2 .d21

d22d23

d24d25

d26d27

d28d29

…3 .d31

d32d33

d34d35

d36d37

d38d39

…4 .d41

d42d43

d44d45

d46d47

d48d49

…5 .d51

d52d53

d54d55

d56d57

d58d59

…6 .d61

d62d63

d64d65

d66d67

d68d69

…7 .d71

d72d73

d74d75

d76d77

d78d79

…8 .d81

d82d83

d84d85

d86d87

d88d89

…9 .d91

d92d93

d94d95

d96d97

d98d99

…… …

Page 20: CSE 20 – Discrete Mathematics

20

Some infinities are more infinite than other infinities• Natural numbers are called countable

• Any set that can be put in correspondence with ℕ is called countable (ex: E+, ℚ+).

• Equivalently, any set whose elements can be enumerated in an (infinite) sequence a1,a2, a3,…

• Real numbers are uncountable• Any set for which cannot be enumerated by a sequence

a1,a2,a3,… is called “uncountable”

• But it gets even weirder…• There are more than two categories!

Page 21: CSE 20 – Discrete Mathematics

21

Some infinities are more infinite than other infinities|ℕ| is called 0א

o |E+| = |ℚ| = 0א

|ℝ| is maybe 1אo Although we just proved that |ℕ| < |ℝ|, and nobody has

ever found a different infinity between |ℕ| and |ℝ|, mathematicians haven’t proved that there are not other infinities between |ℕ| and |ℝ|, making |ℝ| = 2א or greater

o In fact, it can be proved that such theorems can never be proven…

Sets exist whose size is 3א, 2א, 1א, 0א …An infinite number of aleph numbers!

o An infinite number of different infinities

Page 22: CSE 20 – Discrete Mathematics

22

Famous People: Georg Cantor (1845-1918) His theory of set size, in particular

transfinite numbers (different infinities) was so strange that many of his contemporaries hated it Just like many CSE 20 students!

“scientific charlatan” “renegade” “corrupter of youth”

“utter nonsense” “laughable” “wrong” “disease” “I see it, but I don't believe it!” –Georg

Cantor himself

“The finest product of mathematical genius and one of the supreme achievements of purely intellectual human activity.” –David Hilbert