### Solved Examples

**Question 1: **Given that f(x) = x

^{2} + x - 2 and g(x) = x + 5

Find the compositions f o g and g o f and determine the domain of fog.

** Solution: **

f o g = f(g(x)) = f( x + 5) = (x + 5)^{2} + (x + 5) - 2 = x^{2} + 10x + 25 + x + 5 - 2 = x^{2} + 11x + 28.

f o g is a quadratic function with domain as set of all real numbers and the range of g(x) is also all real.

Hence the domain of f o g is all real numbers.

**Question 2: **Let f(x) = 3x + 1 and g(x) = 2x

^{2}. Evaluate the following: f(g(0)), g(f(-

$\frac{1}{3}$)), f(g(2)) and g(f(-1)).

** Solution: **

f(g(0)) = f(2(0)^{2}) = f(0) = 3(0) + 1 = 1

g(f(-$\frac{1}{3}$)) = g(3(-$\frac{1}{3}$) + 1) = g(-1 + 1) = g(0) = 2(0)^{2} = 0

f(g(2)) = f(2.2^{2}) = f(8) = 3(8) + 1 = 25

g(f(-1)) = g(3(-1) + 1) = g(- 3 + 1) = g(- 2) = 2(- 2)^{2} = 8

**Question 3: **Determine whether f(x) =

$\frac{1}{2}$x - 4 and g(x) = 2x + 8 are inverse functions.

Let us find the compositions f o g and g o f.

** Solution: **

(f o g)(x) = f(g(x)) = $\frac{1}{2}$ (2x + 8) - 4 = x + 4 - 4 = x

(g o f)(x) = g(f(x)) = 2($\frac{1}{2}$x - 4) + 8 = x - 8 + 8 = x

=> (f o g)(x) = x = (g o f)(x)

As both the compositions are identity functions f and g are inverses of each other.