Section 1.4: Composition of Functions
Composition of Functions
Definition: Composition
Let \(f : A \rightarrow B\) and \(g : B \rightarrow C\) be two functions.
Then the composition of \(f\) and \(g\), denoted by \(gof\), is defined as the function \(gof : A \rightarrow C\) given by
\[
gof(x) = g(f(x)), \quad \forall \, x \in A.
\]
Example
Let \(f : \{2, 3, 4, 5\} \rightarrow \{3, 4,
5, 9\}\) and \(g : \{3, 4, 5, 9\}
\rightarrow \{7, 11, 15\}\) be functions defined as \(f(2) = 3, f(3) = 4, f(4) = 5, f(5) = 5\)
and \(g(3) = g(4) = 7, g(5) = g(9) =
11\). Find \(gof\).
Example
Find \(gof\) and \(fog\), if \(f :
\mathbb{R} \rightarrow \mathbb{R}\) and \(g : \mathbb{R} \rightarrow \mathbb{R}\) are
given by \(f(x) = \cos x\) and \(g(x) = 3x^2\). Show that \(gof \ne fog\).