# Algebra of Functions , Composite functions

### Algebra of Functions:

Let us consider two functions,  f: D1  →R and g: D2 →R .

We describe functions f + g , f – g , f.g and  f/g as  follows:

(i) f + g : D →R is a function defined by

(f + g)x = f(x)+g(x) where D = D1 ∩ D2

(ii) f – g : D → R is a function defined by

(f – g)x = f(x) –g(x) where D = D1 ∩ D2

(iii) f.g : D →R is a function defined by

(f. g)x = f(x). g(x) where D = D1 ∩ D2

(iv) f/g: D →R is a function defined by

(f/g)x =f(x)/g(x) where D = {x : x  ∈ D1 ∩ D2, g(x) ≠ 0}

Illustration: Let $\large f(x) = \sqrt{6-x}$ , $\large g(x) = \sqrt{x-2}$ . Find f + g, f – g, f.g and f/g.

Solution:  $\large (f+g)x = \sqrt{6-x} + \sqrt{x-2}$ , 2 ≤ x ≤  6

$\large (f-g)x = \sqrt{6-x} – \sqrt{x-2}$ , 2 ≤ x ≤  6

$\large (f.g)x = \sqrt{6-x} . \sqrt{x-2} = \sqrt{(6-x)(x-2)}$ , 2 ≤ x ≤  6

$\large (f/g)x = \frac{\sqrt{6-x}}{\sqrt{x-2}} = \sqrt{\frac{6-x}{x-2}}$ , 2 < x ≤  6

Exercise :   Let f(x) = |sinx|, 0 ≤ x  ≤  π  and  g(x) = |cosx|, -π/2 ≤  x ≤  π/2.   Find f ± g  ,  f.g and f/g and their respective domains .

### Composite functions

Let f: X ∈ Y1 and g : Y1 ∈ Y be two given functions. Let a new function h(x) be derived in the following manner.

To obtain h(x) , we first take the f-image of an element x ∈ X so that f(x) ∈ Y1 , which is the domain of g(x).

Then take g-image of f(x) , i.e g(f(x)) which would be an element of Y. The adjacent figure clearly shows the steps to be taken.

The function ‘ h ‘ defined above is called the composition of f and g and is denoted by gof.

Thus (gof)x = g(f(x)).

Clearly Domain (gof) = {x : x ∈ Domain (f) , f(x) ∈ Domain(g)}

Similarly we can define, (fog)x = f(g(x)) and Domain (fog) = {x : x ∈ Domain (g), g(x) ∈ Domain (f)}.

In general fog ≠ gof.

Example : Two functions are defined as under,

$\displaystyle f(x) = \left\{\begin{array}{ll} x + 1 \; , x \leq 1 \\ 2x+1 \; , 1 < x \leq 2 \end{array} \right.$

$\displaystyle g(x) = \left\{\begin{array}{ll} x^2 \; , -1 \leq x < 2 \\ x + 2 \; , 2 \leq x \leq 3 \end{array} \right.$

Find  fog & gof

Solution: $\large (fog)(x) = f(g(x)) = \left\{\begin{array}{ll} g(x) + 1 , g(x) \le 1 \\ 2g(x) + 1 , 1 < g(x) \le 2 \end{array} \right.$

Let us consider, g(x) ≤ 1:

(i) x2 ≤ 1,   -1 ≤ x < 2  ⇒ -1 ≤ x ≤ 1 ,  -1 ≤ x < 2  ⇒ -1 ≤ x ≤ 1

(ii) x+2 ≤1,   2 ≤ x ≤ 3  ⇒  x ≤ -1 ,   2 ≤ x ≤ 3  ⇒ x = φ

Let us consider, 1 < g(x) ≤ 2,

(iii) 1 < x2 ≤ 2,  –1 ≤ x < 2  ⇒ x  ∈ [ –√2, -1 ) ∪(1, √2],  -1 ≤ x < 2

⇒ 1< x ≤ √2

(iv) 1< x+2 ≤  2 , 2  ≤ x ≤ 3 ⇒  -1< x  ≤ 0, 2 ≤ x ≤ 3,  x =φ

$\large (gof)(x) = g(f(x)) = \left\{\begin{array}{ll} f^2(x) , -1 \le f(x) < 2 \\ f(x) + 2 , 2 \le f(x) \le 3 \end{array} \right.$

Let us consider  –1 ≤ f(x) < 2:

(i) -1 ≤ x + 1< 2,  x ≤ 1 ⇒ -2 ≤ x < 1,   x ≤ 1  ⇒  -2 ≤ x < 1

(ii) -1 ≤ 2x + 1 < 2, 1< x ≤ 2 ⇒  -1 ≤  x< 1/2, 1< x ≤ 2 ⇒ x = φ

Let us consider 2 ≤ f(x) ≤ 3:

(iii) 2 ≤ x +1 ≤ 3,  x ≤ 1 ⇒ 1 ≤ x ≤ 2 , x ≤ 1 ⇒  x = 1

(iv) 2 ≤ 2x + 1 ≤ 3,   1 < x ≤ 2  ⇒ 1 ≤ 2x  ≤ 2,   1 < x ≤ 2

⇒ 1/2 ≤ x  ≤ 1,   1 < x ≤ 2 ⇒  x = φ

$\large g(f(x)) = \left\{\begin{array}{ll} (x+1)^2 , -1 \le x < 1 \\ x + 3 , x=1 \end{array} \right.$

If we like we can also write  g(f(x)) = (x+1)2,    -2 ≤ x ≤ 1.

Exercise: If  $\large f(x) = \left\{\begin{array}{ll} x^2 , x \le 0 \\ x , x > 1 \end{array} \right.$

and g(x) = – |x|, x ∈ R, then find fog and gof.

Next Page →

← Back Page