We discuss compositions of functions.

Given two functions, we can compose them. Let’s give an example in a “real context.”

Composition of functions can be thought of as putting one function inside another. We use the notation

\[ (f\circ g)(x) = f(g(x)). \]

In other words, the domain of a composite function \(f\circ g\) is the set of those inputs \(x\) in the domain of \(g\) for which \(g(x)\) is in the domain of \(f\).

Now let’s try an example with a more restricted domain.

Compare and contrast the previous two examples. We used the same functions for each example, but composed them in different ways. The resulting compositions are not only different, they have different domains! When finding the composition of two different functions remember that the order matters!