You are on page 1of 32

2.

3 EXPLAIN FUNCTION
CLO3: SOLVE RELATED PROBLEMS CRITICALLY USING APPROPRIATE FORMULAE AND CONCEPTS. (C3, A1 )
1

BA202 Discrete Mathematics

LEARNING OUTCOMES
Describe basic constructions. Explain the properties of following functions:
One-to-one functions Onto functions Composition functions Inverse functions

Describe graphs of the Floor and Ceiling functions.

liyana

JMSK , POLITEKNIK BALIK PULAU

BA202 Discrete Mathematics

FUNCTIONS
Let A and B be nonempty sets. A function A to B is an assignment of exactly one element of B to each element of A . Write as : (Function from A to B) Function sometimes called mapping. (Mapping input to output)

liyana

JMSK , POLITEKNIK BALIK PULAU

BA202 Discrete Mathematics

FUNCTIONS

Assignment of grades in Discrete Mathematic Class = + 1

liyana

JMSK , POLITEKNIK BALIK PULAU

BA202 Discrete Mathematics

IS THIS A FUNCTION?

R = { (1,a), (2,b), (3,b), (4, c) R is a function from A to B. Exactly one element in B is assigned to every element of A.
liyana
JMSK , POLITEKNIK BALIK PULAU

BA202 Discrete Mathematics

IS THIS A FUNCTION?

R= {(1,a), (2,b), 3,c)} R is not a function Because 4 belongs to A and 4 is not associated with any element of B. R is only a relation but not a function.
liyana
JMSK , POLITEKNIK BALIK PULAU

BA202 Discrete Mathematics

IS THIS A FUNCTION?

R= {(1,a), (1,b), (2,c), (3,c), (4,c) Not function Because 1 belongs to A and 1 is associated with two element of B.
liyana
JMSK , POLITEKNIK BALIK PULAU

BA202 Discrete Mathematics

IS THIS A FUNCTION?

f(x) = {(1,2), (2,3), (3,4)} Funtion Exactly one element in y is associated with every element in x
liyana
JMSK , POLITEKNIK BALIK PULAU

BA202 Discrete Mathematics

TERMS IN FUNCTON
Everywhere defined Domain Codomain Range Image Pre-image/Inverse image

liyana

JMSK , POLITEKNIK BALIK PULAU

BA202 Discrete Mathematics

EVERYWHERE DEFINED
Let f be a function from A to B. Then we say that f is everywhere defined function if Dom(f) = A. In other words, all domain are used.

Everywhere defined

Not everywhere defined


liyana
JMSK , POLITEKNIK BALIK PULAU

10

BA202 Discrete Mathematics

TERMS IN FUNCTION

f is a function from A to B represented by the diagram above: Domain : All element in A


{ Adam, Chou, Ali, Steven, Jacob }

Codomain : All element in B


Codomain : { A, B, C, D, E }

Range : Element in B that associated with element in A


{ A, B, C, E }

liyana

JMSK , POLITEKNIK BALIK PULAU

11

BA202 Discrete Mathematics

TERMS IN FUNCTION

Image : If f(a) = b, the image of a is b f(Adam) = A


The image of Adam is A The image of Jacob is E

Pre-image or inverse image


Pre-image of A are Adam and Steven Pre-image of B is Ali Tambah objek
liyana

JMSK , POLITEKNIK BALIK PULAU

12

BA202 Discrete Mathematics

PROPERTIES OF FUNCTION
One to One Onto Composition Inverse

liyana

JMSK , POLITEKNIK BALIK PULAU

13

BA202 Discrete Mathematics

ONE TO ONE FUNCTION


Function that assign one value in the domain to one value in codomain and Never assign the same value of codomain to two different domain elements. Also known as injective.

liyana

JMSK , POLITEKNIK BALIK PULAU

14

BA202 Discrete Mathematics

ONTO FUNCTION
All element in the domain is assigned to element in domain All elements in codomain has assignment Also known as surjective.

liyana

JMSK , POLITEKNIK BALIK PULAU

15

BA202 Discrete Mathematics

ONE TO ONE CORRESPONDENCE


A function is one to one correspondence if the function satisfy the properties below:
one to one and onto

Also known as bijection.

liyana

JMSK , POLITEKNIK BALIK PULAU

16

BA202 Discrete Mathematics

INVERSE
To define Inverse Function, the function has to be one to one correspondence. A function is not invertible if it is not a one -to-one correspondence, because the inverse of such function does not exist.
It is not a function c is element in the domain but not associated with any element in codomain element a is assigned to two different element in codomain
liyana
JMSK , POLITEKNIK BALIK PULAU

inverse

17

BA202 Discrete Mathematics

INVERSE
To obtain the inverse function, simply reversing the direction of each arrow. For example :
= {(1,a), (2,c), (3,b)} 1 = { (a, 1), (c,2), (b,3) }

liyana

JMSK , POLITEKNIK BALIK PULAU

18

BA202 Discrete Mathematics

INVERSE
= 2 5. Find 1 () .

Let

= 2 5
2 = + 5 =
+5 2 +5 2

1 =

liyana

JMSK , POLITEKNIK BALIK PULAU

19

BA202 Discrete Mathematics

INVERSE
= 2 2 + 5. Find 1 (2) Let = 2 2 + 5 2 2 = 5 2 = =
5 2 5 2 5 2

1 2 =

52 2

= 1.5 = 1.2247

1 =

liyana

JMSK , POLITEKNIK BALIK PULAU

20

BA202 Discrete Mathematics

INVERSE
= + 10. 1 = 12. . Let = + 10 = 10 1 = 10 10 = 12 = 12 + 10 = 22

liyana

JMSK , POLITEKNIK BALIK PULAU

21

BA202 Discrete Mathematics

EXERCISES
Find inverse of = 3 2. Find 1 5 of function = ( 3) 2 Function = 1 = 10
3

2 . 3

Find the value of when

liyana

JMSK , POLITEKNIK BALIK PULAU

22

BA202 Discrete Mathematics

COMPOSITE
Combination of two functions. If we have two functions, f(x) and g(x) the composite of f(x) and g(x) can be denote as : fg(x) f g

liyana

JMSK , POLITEKNIK BALIK PULAU

23

BA202 Discrete Mathematics

COMPOSITE
= 2 + 5 = 3 = 3 = 2 3 + 5 = 2 6 + 5 = 2 1

= 2 + 5 = 2 + 5 3 = 2 + 2
liyana
JMSK , POLITEKNIK BALIK PULAU

24

BA202 Discrete Mathematics

EXERCISES
Given = 4 2 1 and = 3 + 2. Find each of the followings:

i. ii. (5) iii. 1 ()

liyana

JMSK , POLITEKNIK BALIK PULAU

25

BA202 Discrete Mathematics

COMPOSITE
= 2 = 2 4 + 8 Find ()

= 2 4 + 8 2 = 2 4 + 8 Assume = 2 = + 2 = ( + 2) 2 4 + 2 + 8 2 + 4 = 2 + 4
liyana
JMSK , POLITEKNIK BALIK PULAU

26

BA202 Discrete Mathematics

EXERCISE
= 2 = 3 5 Find Solve the equation = 1

liyana

JMSK , POLITEKNIK BALIK PULAU

27

BA202 Discrete Mathematics

GRAPH FUNCTION
Two important function in discrete Mathematics:
Floor Function Ceiling Function

liyana

JMSK , POLITEKNIK BALIK PULAU

28

BA202 Discrete Mathematics

FLOOR FUNCTION
The floor function rounds x down to the closest integer less than or equal to x. Example :
1.5 = 1 1.5 = 2 7 =7 6.9 = 6

liyana

JMSK , POLITEKNIK BALIK PULAU

29

BA202 Discrete Mathematics

FLOOR FUNCTION
Draw a graph for =

liyana

JMSK , POLITEKNIK BALIK PULAU

30

BA202 Discrete Mathematics

CEILING FUNCTION
The ceiling function round x up to the closest integer greater than or equal to x Example :
0.5 = 1 1 =1 2.1 = 3

liyana

JMSK , POLITEKNIK BALIK PULAU

31

BA202 Discrete Mathematics

CEILING FUNCTION
Draw a graph for =

liyana

JMSK , POLITEKNIK BALIK PULAU

32

You might also like