Functions
Functions
A. Musopole
College of Medicine
[email protected]
At a hospital you are responsible for the dispensary. Every month you
have to purchase at least one unit of a particular medicine but the
number must not exceed 5. The cost, in Malawi Kwacha, of a unit of
that medicine is 20. Thus if you purchase 1 unit, two units, three
units, four units, or five units the cost will be 20, 40, 60, 80, or 100
respectively.
In this case we have two sets {1, 2, 3, 4, 5} and {20, 40, 60, 80, 100}.
When you want to obtain the cost of purchasing some units of the
medicine, you will have to use the number of units as the input, and
obtain the cost, which will be the output in this case. Thus the input
set is {1, 2, 3, 4, 5}, while {20, 40, 60, 80, 100} is the output set.
We are relating the set {1, 2, 3, 4, 5} to the set {20, 40, 60, 80, 100}.
We have
1→20, 2→40, 3→60, 4→80, and 5→100.
1 20
2 40
3 60
4 80
5 100
The set of all inputs for a mapping is called the domain and the set
of all ouputs is called the codomain. In the example we have
considered the domain is {1, 2, 3, 4, 5}, while the codomain is
{20, 40, 60, 80, 100}.
(a) Not injective (b) Injective (c) Not injective (d) Injective
Figure: Examples.
(a) Not surjective (b) Not surjective (c) Surjective (d) Surjective
Figure: Examples.
(a) Not bijective (b) Not bijective (c) Not bijective (d) Bijective
Figure: Examples.
For x = 2 we have
The codomain and range are both on the output side, but they are, to
some extent, different.
The codomain is the set of values that could possibly come out (some
may not come out/ may not be mapped to). While the range is the
set of values that actually do come out (the images).
1. For each function below, determine the domain and the range.
(a) f (y ) = 2y − 10
2
(b) g (x) = x 2+6
(c) h(z) = 2|z| where z∈Z
2. For each case below, determine input values that will make it a
function.
(a) v (x) = x1 + 20
3
(b) f (y ) = 2y −10
3
(c) h(x) = x + 20