BurhanuddinShabbir
5,137 views
15 slides
Nov 02, 2016
Slide 1 of 15
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
About This Presentation
What are function and it's type in discret mathematics
Size: 2.29 MB
Language: en
Added: Nov 02, 2016
Slides: 15 pages
Slide Content
Functions
MAtHEMAtics
SIR SYED UNIVERSITY OF ENGINEERING
& TECHNOLOGY
1
GROUP MEMBERS
•Burhanuddin Shabbir (2015-CS-101)
•Muzzamil Jaffri (2015-CS-105)
•Umair Abdul Rahman (2015-CS-77)
•Hasnain Ahmed (2015-CS-300)
•Hussain Ansari (2015-CS-78)
2
Definition of Functions
•Given any sets A, B, a function f from (or “mapping”)
A to B (f:A®B) is an assignment of exactly one
element f(x)ÎB
to each element xÎA.
3
Graphical Representations
•Functions can be represented graphically in several
ways:
4
• •
A
B
a
b
f
f
•
•
•
•
•
•
•
•
•
x
y
Plot
Graph
Like Venn diagrams
A B
Some Function Terminology
•If f:A®B, and f(a)=b (where aÎA & bÎB), then:
•A is the domain of f.
•B is the codomain of f.
•b is the image of a under f.
•a is a pre-image of b under f.
•In general, b may have more than one pre-
image.
•The range RÍB of f is {b | $a f(a)=b }.
5
Range vs. Codomain
•Suppose that: “f is a function mapping students in
this class to the set of grades {A,B,C,D,E}.”
•At this point, you know f’s codomain is:
__________, and its range is ________.
•Suppose the grades turn out all As and Bs.
•Then the range of f is _________, but its codomain
is __________________.
6
{A,B,C,D,E} unknown!
{A,B}
still {A,B,C,D,E}!
One-to-One Functions
•A function is one-to-one (1-1), or injective, or an injection,
iff every element of its range has only one pre-image.
•Only one element of the domain is mapped to any given
one element of the range.
•Domain & range have same cardinality. What about
codomain?
•Formally: given f:A®B
“x is injective” :º (" x1,x2 Î X,if F(x1)=F(x2)then x1=x2)
7
One-to-One Illustration
•Graph representations of functions that are (or not) one-to-
one:
8
•
•
•
•
•
•
•
•
•
One-to-one
•
•
•
•
•
•
•
•
•
Not one-to-one
•
•
•
•
•
•
•
•
•
Not even a
function!
Onto (Surjective) Functions
•A function f:A®B is onto or surjective or a surjection iff
its range is equal to its codomain ("bÎB, $aÎA: f(a)=b).
•An onto function maps the set A onto (over, covering) the
entirety of the set B, not just over a piece of it.
•e.g., for domain & codomain R, x
3
is onto, whereas x
2
isn’t. (Why not?)
•Formally: given f:A®B
“x is surjective” :º ("yÎY $ xÎX such that F(x)=y)
9
Illustration of Onto
•Some functions that are or are not onto their
codomains:
10
Onto
(but not 1-1)
•
•
•
•
•
•
•
•
•
Not Onto
(or 1-1)
•
•
•
•
•
•
•
•
•
Both 1-1
and onto
•
•
•
•
•
•
•
•
1-1 but
not onto
•
•
•
•
•
•
•
•
•
ARROW DIAGRAM OF ONTO &
ONE TO ONE FUNCTION
11
Bijections
•A function f is a one-to-one correspondence, or a bijection,
or reversible, or invertible, iff it is both one-to-one and
onto.
12
THE PIGEONHOLE PRINCIPLE
13
•In mathematics, the pigeonhole principle states
that if n items are put into m containers, with n >
m, then at least one container must contain more
than one item. This theorem is exemplified in real
life by truisms like "there must be at least two left
gloves or two right gloves in a group of three
gloves".