0% found this document useful (0 votes)
17 views

Functions

Uploaded by

Tormis Neil Mayo
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
17 views

Functions

Uploaded by

Tormis Neil Mayo
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 26

FUNCTIONS ‘-

1
• In discrete mathematics, a function is a
relation that associates each element from
one set called the (domain) to exactly one
element in another set ‘- called the
(codomain).

Note: neque digni


and in aliquet nisl
et a umis varius. 2
• Definition: A from set to set , denoted , is an assignment of
each element of A to exactly one element of .

• We writeif is the unique element of assigned to the


elementof .
‘-
• Functions are also
called mappings

Note: neque digni


and in aliquet nisl
et a umis varius. 3
Given a function
𝑓
• A is called the domain of a 𝒃= 𝒇 ( 𝒂)

• B is called the codomain of A B

𝑓
• F is a mapping from to
• If ‘-
• then b is called the image of a under
• is called the preimage of
• The range (or image) of f is the set of all images of points in A.
We denote it by
4
Example
• The domain ofis
• The codomain of is
A B
• The image ofis a
x
‘- b
• The preimage ofis y
c
• The preimage of is z
d
• The range/image of is

5
Representing functions
• Functions may be specified in different ways:
1. An explicit statement of the assignment.
• Students and grades example.
2. A formula ‘-

3. A computer program
• A java program that when given an integer , product
the Fibonacci Number.

6
Injections

• Definitions : A functionis one-to-one, or


injective, if implies that for all and
‘- in the domain
of

7
INJECTIONS NOT INJECTIONS

A B A B A B

a x a x a x

b v b v b v
‘-
y c y c y
c

d z d z d

8
Surjections

• Definitions: A function from to is called onto or


surjective, if f for every element there
‘-
exists an element
with

9
SURJECTION NOT SURJECTION

A B A B A B
a x a x a x

b v b v b v
‘-
c y c y c y

d d z z

10
Injections + Surjections
‘-
=
Bijections

11
Bijections
• Definitions : A function is a one-to-one
correspondence, or a bijection,‘- if it is both one-to-
one and onto (surjective and injective)
• Invertible

12
BIJECTION NOT BIJECTION

A B A B
a x
a x

b v
b v ‘-
y c y
c
d z
d z

13
Showing that f is/is not injective or
surjective
• Consider a function
• is injective if:

• is not injective if: ‘-

• is surjective iff:

• is not surjective if:


14
Inverse Functions
• Definition : Let be a bidirection from . Then the inverse of f, denoted is the function
from to defined as

−1
𝑓 ( 𝑏)
‘-
𝑎= 𝑓
−1
(𝑏) 𝑏= 𝑓 (𝑎)

A B

• No inverse exists unless is a bijection

15
• Example 1:
• Let be the function from

• Is invertible and if so what is ‘-its inverse?


• Solution
• is invertible because it is a bijection
• reverses the correspondence given b
• (3)
16
• Example 2:
• Let be such that
• Is invertible, and if so, what is it inverse?
• Solution ‘-
• The function is not invertible because it is
not one-to-one

17
• Example 3:
• Let be such that
• Is invertible and if so what is its inverse?
• Solution
‘-
• The function is invertible because it is a
bijection
• reverse the correspondence:

18
Composition
• Definition: Let The composition of with , denoted is the function from defined by

‘-

19
g f
A B C A C
a h
v
b
i
w ‘-
c
j
x
d
y

20
• Example: if
then

‘-
and
+1

21
Graphs of Functions
• Let be a function from the set to the set The graph of the function is the set
of ordered pairs

‘-

22
Some Important Functions
• The floor function, denoted

is the largest integer less than or equal to


• The ceiling function, denoted
‘-
• Examples:

23
‘-

24
Factorial Function
• Definition: denoted by is the product of the first positive
integers:

‘-
• Examples:

y
25
THANK YOU! ‘-

26

You might also like