Functions (Mappings). Definitions A function (or mapping)  from a set A to a set B is a rule that assigns to each element a of A exactly one element.

Slides:



Advertisements
Similar presentations
Functions Rosen 1.8.
Advertisements

More Functions and Sets
Equivalence Relations
Cayley Theorem Every group is isomorphic to a permutation group.
Basic Properties of Relations
1.  We have studied groups, which is an algebraic structure equipped with one binary operation. Now we shall study rings which is an algebraic structure.
Functions Section 2.3 of Rosen Fall 2008
Discrete Structures Chapter 5 Relations and Functions Nurul Amelina Nasharuddin Multimedia Department.
EE1J2 - Slide 1 EE1J2 – Discrete Maths Lecture 8 Equivalence relations on sets Function between sets Types of function.
EE1J2 - Slide 1 EE1J2 – Discrete Maths Lecture 12 Number theory Mathematical induction Proof by induction Examples.
Functions Goals Introduce the concept of function Introduce injective, surjective, & bijective functions.
1 Section 1.8 Functions. 2 Loose Definition Mapping of each element of one set onto some element of another set –each element of 1st set must map to something,
1 Section 7.1 Relations and their properties. 2 Binary relation A binary relation is a set of ordered pairs that expresses a relationship between elements.
Chapter 7 Functions Dr. Curry Guinn. Outline of Today Section 7.1: Functions Defined on General Sets Section 7.2: One-to-One and Onto Section 7.3: The.
Section 1.8: Functions A function is a mapping from one set to another that satisfies certain properties. We will first introduce the notion of a mapping.
Functions Definition A function from a set S to a set T is a rule that assigns to each element of S a unique element of T. We write f : S → T. Let S =
Functions. Recall Relation Let A and B be two sets. A relation between A and B is a collection of ordered pairs (a, b) such that a  A and b  B.
2.1 Sets 2.2 Set Operations 2.3 Functions ‒Functions ‒ Injections, Surjections and Bijections ‒ Inverse Functions ‒Composition 2.4 Sequences and Summations.
FUNCTION Discrete Mathematics Asst. Prof. Dr. Choopan Rattanapoka.
Finite Groups & Subgroups. Order of a group Definition: The number of elements of a group (finite or infinite) is called its order. Notation: We will.
1.5 Functions and Logarithms. One-to-One Functions Inverses Finding Inverses Logarithmic Functions Properties of Logarithms Applications …and why Logarithmic.
AP CALCULUS AB Chapter 1: Prerequisites for Calculus Section 1.5: Functions and Logarithms.
Foundations of Discrete Mathematics Chapter 3 By Dr. Dalia M. Gil, Ph.D.
Functions. Copyright © Peter Cappello2 Definition Let D and C be nonempty sets. A function f from D to C, for each element d  D, assigns exactly 1 element.
Fall 2015 COMP 2300 Discrete Structures for Computation Donghyun (David) Kim Department of Mathematics and Physics North Carolina Central University 1.
Discrete Mathematics and Its Applications Sixth Edition By Kenneth Rosen Copyright  The McGraw-Hill Companies, Inc. Permission required for reproduction.
10/26/20151 … and the following mathematical appetizer is about… Functions.
Mathematics for Computing Lecture 8: Functions Dr Andrew Purkiss-Trew Cancer Research UK
FUNCTIONS.
Chap. 5 Relations and Functions. Cartesian Product For sets A, B the Cartesian product, or cross product, of A and B is denoted by A ╳ B and equals {(a,
Functions Section 2.3 of Rosen Spring 2012 CSCE 235 Introduction to Discrete Structures Course web-page: cse.unl.edu/~cse235 Questions: Use Piazza.
MSU/CSE 260 Fall Functions Read Section 1.8.
Dr. Eng. Farag Elnagahy Office Phone: King ABDUL AZIZ University Faculty Of Computing and Information Technology CPCS 222.
1 Discrete Structures – CNS 2300 Text Discrete Mathematics and Its Applications (5 th Edition) Kenneth H. Rosen Chapter 1 The Foundations: Logic, Sets,
Functions1 Elementary Discrete Mathematics Jim Skon.
Chapter 1 SETS, FUNCTIONs, ELEMENTARY LOGIC & BOOLEAN ALGEBRAs BY: MISS FARAH ADIBAH ADNAN IMK.
321 Section, Week 3 Natalie Linnell. Functions A function from A to B is an assignment of exactly one element of B to each element of A. We write f(a)
1.4 Sets Definition 1. A set is a group of objects . The objects in a set are called the elements, or members, of the set. Example 2 The set of positive.
Example Prove that: “IF 3n + 2 is odd, then n is odd” Proof by Contradiction: -p = 3n + 2 is odd, q = n is odd. -Assume that ~(p  q) is true OR -(p 
Chapter 9 Functions Let A and B be nonempty sets. A function f from A to B, written f: A  B is a relation from A to B with the property that every element.
Basic Structures: Functions Muhammad Arief download dari
April 14, 2015Applied Discrete Mathematics Week 10: Equivalence Relations 1 Properties of Relations Definition: A relation R on a set A is called transitive.
Mathematical Induction
Functions Section 2.3. Section Summary Definition of a Function. – Domain, Cdomain – Image, Preimage Injection, Surjection, Bijection Inverse Function.
11 DISCRETE STRUCTURES DISCRETE STRUCTURES UNIT 5 SSK3003 DR. ALI MAMAT 1.
 R  A×B,R is a relation from A to B , DomR  A 。  (a,b)  R (a, c)  R  (a,b)  R (a, c)  R unless b=c  function  DomR=A , (everywhere)function.
11 DISCRETE STRUCTURES DISCRETE STRUCTURES UNIT 5 SSK3003 DR. ALI MAMAT 1.
Introduction to Real Analysis Dr. Weihu Hong Clayton State University 8/27/2009.
Sets Definition: A set is an unordered collection of objects, called elements or members of the set. A set is said to contain its elements. We write a.
UNIT - 2.  A binary operation on a set combines two elements of the set to produce another element of the set. a*b  G,  a, b  G e.g. +, -, ,  are.
CSC102 - Discrete Structures Functions
One-to-One Functions (Section 3.7, pp ) and Their Inverses
CS Lecture 14 Powerful Tools     !. Build your toolbox of abstract structures and concepts. Know the capacities and limits of each tool.
1 Functions CS 202 Epp section ??? Aaron Bloomfield.
Chapter 7 – Radical Equations and Inequalities 7.2 – Inverse Functions and Relations.
FUNCTIONS COSC-1321 Discrete Structures 1. Function. Definition Let X and Y be sets. A function f from X to Y is a relation from X to Y with the property.
A function is a rule f that associates with each element in a set A one and only one element in a set B. If f associates the element b with the element.
Inverse of Transcendental Functions 1- Inverse of Trigonometric Functions 2- Inverse of Exponential Functions 3- Inverse of Hyperbolic Functions.
Functions – Page 1CSCI 1900 – Discrete Structures CSCI 1900 Discrete Structures Functions Reading: Kolman, Section 5.1.
Properties of Groups Proposition 1: Let (G,  ) be a group. i.The inverse element of any element of G is unique. Remark: In view of i., we may use the.
1 Lecture 5 Functions. 2 Functions in real applications Curve of a bridge can be described by a function Converting Celsius to Fahrenheit.
Section 2.3. Section Summary  Definition of a Function. o Domain, Cdomain o Image, Preimage  One-to-one (Injection), onto (Surjection), Bijection 
Chapter 2 1. Chapter Summary Sets The Language of Sets - Sec 2.1 – Lecture 8 Set Operations and Set Identities - Sec 2.2 – Lecture 9 Functions and sequences.
FUNCTIONS.
Inverse Functions Objective: To find and identify inverse functions.
Prepared By Meri Dedania (AITS) Discrete Mathematics by Meri Dedania Assistant Professor MCA department Atmiya Institute of Technology & Science Yogidham.
Applied Discrete Mathematics Week 9: Equivalence Relations
Elementary Properties of Groups
Relations and Their Properties
Functions.
Presentation transcript:

Functions (Mappings)

Definitions A function (or mapping)  from a set A to a set B is a rule that assigns to each element a of A exactly one element b of B. The set A is called the domain of , and B is called the range of . If  assigns b to a, then b is called the image of a under . The subset of B comprising all the images of elements of A is called the image of A under 

Notation  A –> B means  is a mapping from set A to set B.  (a) = b or  : a –> b means that function  maps element a to element b (i.e. the image of a is b).

Example 1 Let  : R –> R be given by  (x) = sin(x). The image of  /2 under  is 1 The image of R under  is [-1,1]. domain of  is R range of  is R  (R) = [-1,1]

Example 2  : Q –> Z given by  : p/q –> p+q  (1/2) = = 3  (2/4) = = 6 Since 1/2 = 2/4, but  (1/2) ≠  (2/4)  is not a function!

To prove a rule is a function Assume x 1 = x 2 Show  (x 1 ) =  (x 2 ) In this case we say that  is well-defined.

Show  is well-defined Let  :Z –> Z be given by  (n) = n 2 mod 2 Suppose n 1 = n 2.  (n 1 )–  (n 2 ) = n 1 2 mod 2 –n 2 2 mod 2 = (n 1 – n 2 )(n 1 +n 2 ) mod 2 = 0 since (n 1 – n 2 ) = 0 So  (n 1 ) =  (n 2 ) Therefore,  is well-defined.

Composition of functions Let  : A –> B and  : B –> C. The composition  is the mapping from A to C defined by  (a) =  (  (a)). AB C a  (a)  (a)   

Order matters! When we compose  and , we must write  Unless A = C,  does not make sense. AB C a  (a)  (a)   

One to one functions A function from a set A is called one- to-one if Note: This is the converse to the well- defined condition.

Show not one-to-one Show  :R –> R given by  (x) = x 2 is not one–to–one.  (–2)= 4 =  (2), but –2 ≠ 2 So  is not one-to-one.

Show one-to-one Show  :[0,∞) –> R given by  (x) = x 2 is one– to–one. Suppose  (x 1 )=  (x 2 ). Then 0 =  (x 1 )–  (x 2 ) = x 1 2 –x 2 2 = (x 1 –x 2 )(x 1 +x 2 ) So either (x 1 –x 2 ) = 0 or (x 1 +x 2 ) = 0 If (x 1 –x 2 ) = 0, then x 1 = x 2 If (x 1 +x 2 ) = 0, then x 1 = x 2 = 0 since the domain is [0,∞) In either case, x 1 = x 2, so  is one-to-one.

Onto functions A function  from a set A to a set B is said to be onto B if each element of B is the image of at least one element of A.

Show not onto Show  :[0,∞) –> R given by  (x) = x 2 is not onto. Suppose –1 =  (x) for some x in [0,∞). Then -1 = x 2 ≥ 0 This counterexample shows  is not onto.

Show onto Show  :[0,∞) –> [0,∞) given by  (x) = x 2 is onto. Proof: Choose any number b ≥ 0. Let a = √b. Then  (a) = (√b) 2 = b. So  is onto.

Properties of functions Given  :A–>B,  :B–>C, and  :C–>D, then 1.  (  ) = (  ) . (Associativity) 2.If  and  are one-to-one, then  is one-to-one. 3.If  and  are onto, then  is onto. 4.If  is one-to-one and onto, then there is a function  -1 from B to A such that  -1  (a)=a for all a in A and  -1 (b)=b for all b in B.

Proof of Associativity Choose any a in A. Let b =  (a), c =  (b), and d =  (c). Notice that  (a) = c and  (b) = d. Then (  )  (a) =  (b) = d Also,  (  )(a) =  (c) = d Since (  )  (a) =  (  )(a) for all a in A, (  )  =  (  )

Prove one-to-one Suppose  (x 1 ) =  (x 2 ) Set y 1 =  (x 1 ) and y 2 =  (x 2 ). Then  (y 1 ) =  (y 2 ) Since  is one-to-one, y 1 =y 2 But then  (x 1 ) =  (x 2 ). Since  is one-to-one, x 1 = x 2. Therefore,  is one-to-one.

Prove onto Choose any c in C Since  is onto, there is a b in B with  (b)=c. Since  is onto, there is an a in A with  (a)=b. Then  (a) =  (b) = c Therefore,  is onto.

Proof of inverse functions The proof consists of three steps. 1.Construct the inverse function. 2.Show that the inverse is well-defined. 3.Show that the inverse function has the required cancellation properties.

1. Construction Given  :A->B is one-to-one and onto. Choose any b in B. Since  is onto, there is an a in A with  (a)=b. Set  -1 (b) = a.

2. Well-defined Suppose b 1 = b 2 in B. Let a 1 =  -1 (b 1 ) and a 2 =  -1 (b 2 ) Then  (a 1 ) = b 1 = b 2 =  (a 2 ) Since  is one-to-one, a 1 = a 2 That is,  -1 (b 1 ) =  -1 (b 2 ) Therefore,  -1 is well-defined.

3. Cancellation Choose any a in A. Set b = f(a) and note that  -1 (b) = a. Then  -1  (a) =  -1 (b) = a, and  -1 (b) =  (a) = b. Since  -1 is well-defined and the cancellation laws hold, we are done.