Sets and Logic…. Chapters 5 and 6

Slides:



Advertisements
Similar presentations
Extensible Networking Platform CSE 240 – Logic and Discrete Mathematics Review: Mathematical Induction Use induction to prove that the sum of the.
Advertisements

Lecture ,3.3 Sequences & Summations Proof by Induction.
Review for CS1050. Review Questions Without using truth tables, prove that  (p  q)   q is a tautology. Prove that the sum of an even integer and an.
Section 7.5: Equivalence Relations Def: A relation R on a set A is called an equivalence relation if it is reflexive, symmetric, and transitive. Ex: Let.
Equivalence Relations
CSCI 115 Chapter 6 Order Relations and Structures.
Transitive Closure Theorem 1. Let R be a relation on a set A. Then R  is the transitive closure of R. the reachability relation R * of a relation R on.
Copyright © Cengage Learning. All rights reserved. CHAPTER 5 SEQUENCES, MATHEMATICAL INDUCTION, AND RECURSION SEQUENCES, MATHEMATICAL INDUCTION, AND RECURSION.
3-1: Congruent Figures Honors Geometry.
Induction and recursion
CS 454 Theory of Computation Sonoma State University, Fall 2011 Instructor: B. (Ravi) Ravikumar Office: 116 I Darwin Hall Original slides by Vahid and.
CSE115/ENGR160 Discrete Mathematics 03/22/12 Ming-Hsuan Yang UC Merced 1.
Inductive Proofs Must Have Base Case (value): –where you prove it is true about the base case Inductive Hypothesis (value): –where you state what will.
Chapter 2 Sets, Relations, and Functions SET OPERATIONS The union of A and B.
1 Strong Mathematical Induction. Principle of Strong Mathematical Induction Let P(n) be a predicate defined for integers n; a and b be fixed integers.
Properties of the Integers: Mathematical Induction
Mathematical Maxims and Minims, 1988
Sequences and Series (T) Students will know the form of an Arithmetic sequence.  Arithmetic Sequence: There exists a common difference (d) between each.
Exam 2 Review 8.2, 8.5, 8.6, Thm. 1 for 2 roots, Thm. 2 for 1 root Theorem 1: Let c 1, c 2 be elements of the real numbers. Suppose r 2 -c 1.
Chapter 6 Mathematical Induction
Discrete Mathematics, 1st Edition Kevin Ferland
Numbers, Operations, and Quantitative Reasoning.
CSE 20 Lecture 12 Induction CK Cheng 1. Induction Outlines Introduction Theorem Examples: The complexity calculation – Tower of Hanoi – Merge Sort – Fibonacci.
Mathematical Induction. F(1) = 1; F(n+1) = F(n) + (2n+1) for n≥ F(n) n F(n) =n 2 for all n ≥ 1 Prove it!
1 Introduction to Abstract Mathematics Chapter 4: Sequences and Mathematical Induction Instructor: Hayk Melikya 4.1- Sequences. 4.2,
Week 15 - Wednesday.  What did we talk about last time?  Review first third of course.
8.3 Representing Relations Directed Graphs –Vertex –Arc (directed edge) –Initial vertex –Terminal vertex.
Reading and Writing Mathematical Proofs Spring 2015 Lecture 4: Beyond Basic Induction.
Chapter Mathematical Induction 4.2 Strong Induction and Well-Ordering 4.3 Recursive Definitions and Structural Induction 4.4 Recursive Algorithms.
ICS 253: Discrete Structures I Induction and Recursion King Fahd University of Petroleum & Minerals Information & Computer Science Department.
Mathematical Preliminaries
CompSci 102 Discrete Math for Computer Science March 1, 2012 Prof. Rodger Slides modified from Rosen.
Sets and Subsets Set A set is a collection of well-defined objects (elements/members). The elements of the set are said to belong to (or be contained in)
Introduction to Real Analysis Dr. Weihu Hong Clayton State University 8/27/2009.
Foundations of Discrete Mathematics Chapters 5 By Dr. Dalia M. Gil, Ph.D.
Unit II Discrete Structures Relations and Functions SE (Comp.Engg.)
1 INFO 2950 Prof. Carla Gomes Module Induction Rosen, Chapter 4.
Chapter Relations and Their Properties
Mathematical Induction
CompSci 102 Discrete Math for Computer Science March 13, 2012 Prof. Rodger Slides modified from Rosen.
Relations and Functions ORDERED PAIRS AND CARTESIAN PRODUCT An ordered pair consists of two elements, say a and b, in which one of them, say a is designated.
Chapter 5. Section 5.1 Climbing an Infinite Ladder Suppose we have an infinite ladder: 1.We can reach the first rung of the ladder. 2.If we can reach.
Week 15 - Wednesday.  What did we talk about last time?  Review first third of course.
1 CMSC 250 Discrete Structures CMSC 250 Lecture 41 May 7, 2008.
Week 8 - Wednesday.  What did we talk about last time?  Relations  Properties of relations  Reflexive  Symmetric  Transitive.
3.3 Mathematical Induction 1 Follow me for a walk through...
Chapter 5 1. Chapter Summary  Mathematical Induction  Strong Induction  Recursive Definitions  Structural Induction  Recursive Algorithms.
Dilworth’s theorem and extremal set theory 張雁婷 國立交通大學應用數學系.
1 Partial Orderings Epp, section Introduction An equivalence relation is a relation that is reflexive, symmetric, and transitive A partial ordering.
Hubert Chan (Chapters 1.6, 1.7, 4.1)
Binary Relation: A binary relation between sets A and B is a subset of the Cartesian Product A x B. If A = B we say that the relation is a relation on.
Relations and Their Properties
Partial Orderings: Selected Exercises
Unit-III Algebraic Structures
Advanced Algorithms Analysis and Design
Induction and recursion
Hubert Chan (Chapters 1.6, 1.7, 4.1)
Chapter 5 Induction and Recursion
CS201: Data Structures and Discrete Mathematics I
Chapter 4.2 Notes: Apply Congruence and Triangles
Notes 9.5 – Mathematical Induction
Induction and recursion
Exercise Use mathematical induction to prove the following formula.
Formal Definition and Examples
9.5 Equivalence Relations
Induction Chapter
Advanced Analysis of Algorithms
Lecture 5 Number Theory & Proof Methods
Mathematical Induction
CSE 311 Foundations of Computing I
Presentation transcript:

Sets and Logic…. Chapters 5 and 6 An experiment….. Sets and Logic…. Chapters 5 and 6

Chapter 4: Relations Let A and B be sets, then the cartesian product 𝐴×𝐵= (𝑎,𝑏) 𝑎∈𝐴 𝑎𝑛𝑑 𝑏∈𝐵 . Order matters!

Relations Suppose that A and B are sets. We say that any set 𝑅⊆𝐴×𝐵 is a relation from A to B Examples 𝐺= (𝑥,𝑦)∈ℝ×ℝ 𝑦<𝑥

Chapter 5: Functions Let F be a relation from A to B. F is called a function if for every 𝑎∈𝐴 there is exactly one 𝑏∈𝐵 such that 𝑎,𝑏 ∈𝐹. We then write 𝐹:𝐴→𝐵

Functions Alleged Theorem: Suppose f and g are function from A to B. If ∀𝑎∈𝐴(𝑓 𝑎 =𝑔 𝑎 ) then f = g. Ran(f) = 𝑓(𝑎) 𝑎∈𝐴

Composition Let 𝑓:𝐴→𝐵 𝑎𝑛𝑑 𝑔:𝐵→𝐶, then 𝑔∘𝑓:𝐴→𝐶, and for any 𝑎∈𝐴, 𝑔∘𝑓=𝑔 𝑓 𝑎 .

5.2 One to One and Onto Definitions Suppose that 𝑓:𝐴→𝐵. We will say that f is one-to-one if ¬∃ 𝑎 1 ∃ 𝑎 2 ∈𝐴(𝑓( 𝑎 1 )=𝑓( 𝑎 2 )∧ 𝑎 1 ≠ 𝑎 2 ) We say that f is onto if ∀𝑏∈𝐵∃𝑎∈𝐴(𝑓 𝑎 =𝑏)

One to One and Onto Suppose that 𝑓:𝐴→𝐵. 1. f is one-to-one iff ∀ 𝑎 1 ∈𝐴∀ 𝑎 2 ∈𝐴(𝑓 𝑎 1 =𝑓( 𝑎 2 )→ 𝑎 1 = 𝑎 2 ) 2. f is onto iff 𝑅𝑎𝑛 𝑓 =𝐵

Example Let 𝐴=ℝ\{−1} 𝑎𝑛𝑑 𝑓:𝐴→ℝ 𝑏𝑦 𝑓 𝑎 = 2𝑎 𝑎+1 , 𝑓 𝑎 = 2𝑎 𝑎+1 , Then f is one to one but not onto.

Inverses of Functions Suppose that 𝑓:𝐴→𝐵 is one to one and onto, then 𝑓 −1 :𝐵→𝐴. Suppose f is a function from A to B and 𝑓 −1 is a function from B to A. Then 𝑓 −1 ∘𝑓= 𝑖 𝐴 and 𝑓∘ 𝑓 −1 = 𝑖 𝐵 .

More Inverses Theorem. Suppose 𝑓:𝐴→𝐵. 1. If there is a function 𝑔:𝐵→𝐴, such that 𝑔∘𝑓= 𝑖 𝐴 then f is one to one 2. If there is a function 𝑔: 𝐵→𝐴, such that 𝑓∘𝑔= 𝑖 𝐵 then f is onto.

Inverses Theorem. Suppose 𝑓:𝐴→𝐵. Then the following statements are equivalent 1. f is one to one and onto 2. 𝑓 −1 :𝐵→𝐴. 3. There is a function 𝑔:𝐵→𝐴 such that 𝑔∘𝑓= 𝑖 𝐴 𝑎𝑛𝑑 𝑓∘𝑔= 𝑖 𝐵 .

Inverses Theorem: Suppose 𝑓:𝐴→𝐵, 𝑔:𝐵→𝐴, 𝑔∘𝑓= 𝑖 𝐴 , 𝑎𝑛𝑑 𝑓∘𝑔= 𝑖 𝐵 . Then 𝑔= 𝑓 −1 .

Examples Let 𝐴=ℝ\ 0 𝑎𝑛𝑑 𝐵=ℝ\ 2 , and define 𝑓:𝐴→𝐵 𝑏𝑦 𝑓= 1 𝑥 +2. Show that f is one-to-one and onto and find 𝑓 −1 . Let 𝐴=ℝ, 𝑎𝑛𝑑 𝐵= 𝑥𝜖ℝ|𝑥≥0 , 𝑙𝑒𝑡 𝑓= 𝑥 2 .

Basic Induction To prove that ∀𝑛≥𝐾∈ℕ 𝑃 𝑛 , 1. Prove P(K) 2. Prove for ∀𝑛≥𝐾𝜖ℕ(𝑃(𝑛)→𝑃(𝑛+1)

Example Prove that for every n, 𝑘=0 𝑛 2 𝑘 = 2 𝑛+1 −1

Examples Let R be a partial order on A. Prove that every finite nonempty set 𝐵⊆𝐴 has an R-minimal element.

Let 𝑅⊆𝐴×𝐴 R is a Partial Order on A if it is reflexive, transitive, and antisymmetric. It is a Total Order on A if it is a partial order and in addition ∀𝑥∀𝑦𝜖𝐴(𝑥𝑅𝑦∨𝑦𝑅𝑥)

Fun and Games with Triangles For all 𝑛≥3, if n distinct points on a circle are connected in consecutive order with straight lines, then the interior angles of the resulting polygon add up to 𝑛−2 180°.

Fun and Games with tiles Theorem: For any positive integer n, a 2 𝑛 × 2 𝑛 square grid with any one square removed can be covered with L-shaped tiles.

Recursion ∀𝑛∈ℕ, 𝑙𝑒𝑡 𝑓 𝑛+1 =𝑔 𝑓 𝑛 Ex: ∀𝑛∈ℕ, 𝑓 𝑛+1 = 𝑛+1 𝑓 𝑛 .

Example Prove that for every 𝑛≥4, 𝑛!> 2 𝑛 . Define a sequence, 𝑎 0 =0; ∀𝑛∈ℕ, 𝑎 𝑛+1 =2 𝑎 𝑛 +1. Find a formula and prove its correctness.

Example For every 𝑥>−1 and every natural number n, (1+𝑥) 𝑛 ≥1+𝑛𝑥.

Strong Induction Simple Induction… Prove P(k) Prove for n>k, 𝑃 𝑛−1 →𝑃 𝑛 Strong Induction….. ∀𝑛[(∀𝑘<𝑛𝑃 𝑘 )→𝑃(𝑛)]

Examples Theorem: For all natural number n and m, if m>0, then there are q and r such that n = mq+r. ( q is the quotient, and r is the remainder )

Example Theorem: Every integer n>1 is either a prime or a product of primes.

Example Theorem: Every non-empty set of natural numbers has a smallest element. Theorem: 2 is irrational. I.e. there are no integers p and q such that 2 = 𝑝 𝑞 .