Let and . We can define a new function as
That is, to obtain , we substitute for in the expression .
To generalize this process suppose and are any two given functions. We start with a number in the domain of and apply to it to get , then we apply to and thereby obtain the number . Obviously this process presupposes that it makes sense to calculate at the point . In other words, the new function is defined only if is in the domain of (otherwise we cannot use as the input for ).
Consecutive application of functions is known as composition of functions. The new function that takes and assigns to it the value is often denoted by . The symbol is read “ circle .” Figure 1(a) shows the composition as a machine diagram and Figure 1(b) illustrates it as an arrow diagram.
(a)
(b)
Fig 1(a) Machine digram for . A composite (or composition) function applies the machine to the input and then uses the output as the input for the machine.
Fig. 1(b) Arrow diagram for . If is in the domain of and is in the domain of , then we may compose and to form .
Let and be two functions. For those points in the domain of for which lies in the domain of , the composite function is defined by
- In set notation, the domain of is
- Note that the order of composition of two functions matters. In calculating , we first evaluate at and then use as the input to calculate of the result. But in calculating , we first evaluate at and then calculate at the the point . Therefore, is often quite different from .
Example
Let and . Find the following functions and their domains.
(a)
(b)
Solution
We have
(a)
Because for all , is always in the domain of . Therefore
(b)
Because the domain of is the entire set of real numbers, always lies in the domain of . However, is defined only for . Therefore, the domain of is the same as the domain of , namely
Example
If , find the function and its domain.
Solution
Let’s first find
Just by looking at the above formula one may be tempted to say that the domain of is . However, the domain of consists of all that
(1) lies in the domain of ,
(2) lies in the domain of .
The domain of is all real numbers except (recall that division by zero is not defined). So to satisfy the first condition we have to exclude . To satisfy the second condition, we also have to exclude for which
It turns out that this equation has no solution because it is equivalent to or . This means that is always in the domain of , and the second conditions is automatically satisfied without any further restriction on . Thus in this specific example
Example
Find functions and such that given that
Solution
To calculate we first square and then take the cosine of . We can therefore set
and
We observe that
We can combine three or more functions by composing them two at a time. For example, the function given by
is a composition of three functions , where
Notice that we can compose and first then compose with or we can first compose and and then compose and . In general, composition is
associative. That is
Example
Find three functions and such that given that
Solution
To calculate , we fist take the absolute value of , add 3, and then take the square root. We can therefore set
and
With this choice of and , we observe that