EppDm4_07_03

CHAPTER 7
FUNCTIONS
Copyright © Cengage Learning. All rights reserved.
SECTION 7.3
Composition of Functions
Copyright © Cengage Learning. All rights reserved.
Composition of Functions
Consider two functions, the successor function and the
squaring function, defined from Z (the set of integers) to Z,
and imagine that each is represented by a machine.
If the two machines are hooked up so that the output from
the successor function is used as input to the squaring
function, then they work together to operate as one larger
machine.
In this larger machine, an integer n is first increased by 1 to
obtain n + 1; then the quantity n + 1 is squared to obtain
(n + 1)2.
3
Composition of Functions
This is illustrated in the following drawing.
Combining functions in this way is called composing them;
the resulting function is called the composition of the two
functions.
4
Composition of Functions
Note that the composition can be formed only if the output
of the first function is acceptable input to the second
function.
That is, the range of the first function must be contained in
the domain of the second function.
5
Composition of Functions
This definition is shown schematically below.
6
Example 2 – Composition of Functions Defined on Finite Sets
Let X = {1, 2, 3}, Y = {a, b, c, d}, Y = {a, b, c, d, e}, and
Z = {x, y, z}. Define functions f: X → Y and g: Y → Z by the
arrow diagrams below.
Draw the arrow diagram for g  f. What is the range
of g  f ?
7
Example 2 – Solution
To find the arrow diagram for g  f, just trace the arrows all
the way across from X to Z through Y. The result is shown
below.
The range of g  f is {y, z}.
8
Composition of Functions
We have known that the identity function on a set X, IX, is
the function from X to X defined by the formula
That is, the identity function on X sends each element of X
to itself. What happens when an identity function is
composed with another function?
9
Example 3 – Composition with the Identity Function
Let X = {a, b, c, d} and Y = {u, v, w}, and suppose f: X → Y
is given by the arrow diagram.
Find f  IX and IY  f.
10
Example 3 – Solution
The values of f  IX are obtained by tracing through the
arrow diagram shown below.
Note that for all elements x in X,
11
Example 3 – Solution
cont’d
By definition of equality of functions, this means that
f  IX = f.
Similarly, the equality IY  f = f can be verified by tracing
through the arrow diagram below for each x in X and noting
that in each case, (IY  f)(x) = f(x).
12
Composition of Functions
More generally, the composition of any function with an
identity function equals the function.
13
Composition of Functions
Now let f be a function from a set X to a set Y, and suppose
f has an inverse function f –1. We have known that f –1 is the
function from Y to X with the property that
What happens when f is composed with f –1? Or when f –1 is
composed with f?
14
Example 4 – Composing a Function with Its Inverse
Let X = {a, b, c} and Y = {x, y, z}. Define f: X → Y by the
following arrow diagram.
Then f is one-to-one and onto. Thus f –1 exists and is found
by tracing the arrows backwards, as shown below.
15
Example 4 – Composing a Function with Its Inverse
cont’d
Now f –1  f is found by following the arrows from X to Y by f
and back to X by f –1.
If you do this, you will see that
and
Thus the composition of f and f −1 sends each element to
itself.
16
Example 4 – Composing a Function with Its Inverse
cont’d
So by definition of the identity function,
In a similar way, you can see that
17
Composition of Functions
More generally, the composition of any function with its
inverse (if it has one) is an identity function. Intuitively, the
function sends an element in its domain to an element in its
co-domain and the inverse function sends it back again, so
the composition of the two sends each element to itself.
This reasoning is formalized in Theorem 7.3.2.
18
Composition of One-to-One
Functions
19
Composition of One-to-One Functions
The composition of functions interacts in interesting ways
with the properties of being one-to-one and onto. What
happens, for instance, when two one-to-one functions are
composed? Must their composition be one-to-one?
For example, let X = {a, b, c}, Y = {w, x, y, z}, and
Z = {1, 2, 3, 4, 5}, and define one-to-one functions f: X → Y
and g: Y → Z as shown in the arrow diagrams of
Figure 7.3.1.
Figure 7.3.1
20
Composition of One-to-One Functions
Then g  f is the function with the arrow diagram shown in
Figure 7.3.2.
Figure 7.3.2
From the diagram it is clear that for these particular
functions, the composition is one-to-one.
21
Composition of One-to-One Functions
This result is no accident. It turns out that the compositions
of two one-to-one functions is always one-to-one.
22
Composition of Onto Functions
23
Composition of Onto Functions
Now consider what happens when two onto functions are
composed. For example, let X = {a, b, c, d, e},
Y = {w, x, y, z}, and Z = {1, 2, 3}.
Define onto functions f and g by the following arrow
diagrams.
24
Composition of Onto Functions
Then g  f is the function with the arrow diagram shown
below.
It is clear from the diagram that g  f is onto.
It turns out that the composition of any two onto functions
(that can be composed) is onto.
25
Example 5 – An Incorrect “Proof” That a Function Is Onto
To prove that a composition of onto functions is onto, a
student wrote,
“Suppose f: X → Y and g: Y → Z are both onto.
Then
and
26
Example 5 – An Incorrect “Proof” That a Function Is Onto
cont’d
So
and thus g  f is onto.”
Explain the mistakes in this “proof.”
Solution:
To show that g  f is onto, you must be able to meet the
following challenge: If someone gives you an element z in
Z (over which you have no control), you must be able to
explain how to find an element x in X such that
(g  f )(x) = z.
27
Example 5 – Solution
cont’d
Thus a proof that g  f is onto must start with the
assumption that you have been given a particular but
arbitrarily chosen element of Z. This proof does not do that.
Moreover, note that statement
simply asserts that f is
onto. An informal version of
is the following: Given any
element in the co-domain of f, there is an element in the
domain of f that is sent by f to the given element.
Use of the symbols x and y to denote these elements is
arbitrary.
28
Example 5 – Solution
cont’d
Any other two symbols could equally well have been used.
Thus, if we replace the x and y in
by u and v, we obtain
a logically equivalent statement, and the “proof” becomes
the following:
“Suppose f: X → Y and g: Y → Z are both onto.
Then
and
29
Example 5 – Solution
cont’d
So (??!)
and thus g  f is onto.”
From this logically equivalent version of the “proof,” you
can see that the statements leading up to the word So do
not provide a rationale for the statement that follows it.
The original reason for writing So was based on a
misinterpretation of the meaning of the notation.
30