1 / 15

Relations Between S ets

Relations Between S ets. Relations. Students Courses. Sam. EC 10. Mary. CS20. The “is-taking” relation. A relation is a set of ordered pairs: {(Sam,Ec10), (Sam, CS20), (Mary, CS20)}. Function: A → B. AT MOST ONE ARROW OUT OF EACH ELEMENT OF A. f.

swain
Download Presentation

Relations Between S ets

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Relations Between Sets

  2. Relations Students Courses Sam EC 10 Mary CS20 The “is-taking” relation A relation is a set of ordered pairs: {(Sam,Ec10), (Sam, CS20), (Mary, CS20)}

  3. Function: A → B AT MOST ONE ARROW OUT OF EACH ELEMENT OF A f domain codomain A B Each element of A is associated with at most one element of B. a ⟼ bf(a) = b

  4. Total Function: A → B EXACTLY ONE ARROW OUT OF EACH ELEMENT OF A f domain codomain A B Each element of A is associated with ONE AND ONLY one element of B. a ⟼ bf(a) = b

  5. A Function that is “Partial,” Not Total f domain codomain R×R R f: R ×R → R f(x,y) = x/y Defined for all pairs (x,y) except when y=0!

  6. A Function that is “Partial,” Not Total f domain codomain R×R R f: R ×R → R f(x,y) = x/y Defined for all pairs (x,y) except when y=0! Or: f is a total function: R×(R-{0})→R

  7. Injective Function “at most one arrow in” codomain f domain A B (∀b∈B)(∃≤1a∈A) f(a)=b

  8. Surjective Function “at least one arrow in” codomain f domain A B (∀b∈B)(∃≥1a∈A) f(a)=b

  9. Bijection = Total + Injective + Surjective “exactly one arrow out of each element of A and exactly one arrow in to each element of B” f domain codomain A B (∀a∈A) f(a) is defined and (∀b∈B)(∃=1a∈A) f(a)=b

  10. Cardinality or “Size” For finite sets, a bijection exists iff A and B have the same number of elements f codomain domain A B

  11. Cardinality or “Size” Use the same as a definition of “same size” for infinite sets: Sets A and B have the same size iff there is a bijection between A and B Theorem: The set of even integers has the same size as the set of all integers [f(2n) = n] …, -4, -3, -2, -1, 0, 1, 2, 3, 4 … …, -8, -6, -4, -2, 0, 2, 4, 6, 8 …

  12. Cardinality or “Size” There are as many natural numbers as integers 0 1 2 3 4 5 6 7 8 … 0, -1, 1, -2, 2, -3, 3, -4, 4 … f(n) = n/2 if n is even, -(n+1)/2 if n is odd Defn: A set is countably infiniteif it has the same size as the set of natural numbers

  13. An Infinite Set May Have the Same Size as a Proper Subset! ⋮ ⋮ 5 5 4 Every room of both hotels is full! Suppose the Sheraton has to be evacuated 4 3 3 2 2 1 1 0 0 Hilton Sheraton

  14. An Infinite Set May Have the Same Size as a Proper Subset! ⋮ ⋮ 5 5 4 Step 1: Tell the resident of room n in the Hilton to go to room 2n This leaves all the odd-numbered rooms of the Hilton unoccupied 4 3 3 2 2 1 1 0 0 Hilton Sheraton

  15. An Infinite Set May Have the Same Size as a Proper Subset! ⋮ ⋮ 5 5 4 Step 2: Tell the resident of room n in the Sheraton to go to room 2n+1 of the Hilton. Everyone gets a room! 4 3 3 2 2 1 1 0 0 Hilton Sheraton

More Related