Composition of Functions

Published on 21 November 2024 at 16:05

Tutorial on Composition of Functions

Introduction to Function Composition

In mathematics, the composition of functions combines two functions to produce a new function. If \( f \) and \( g \) are functions, the composition \( (f \circ g)(x) \) is defined as:

\[ (f \circ g)(x) = f(g(x)) \] This means we first apply \( g(x) \), and then apply \( f \) to the result of \( g(x) \).

Key Definitions

  • Domain: The domain of \( f(g(x)) \) is the set of all \( x \) in the domain of \( g(x) \) such that \( g(x) \) lies in the domain of \( f(x) \).
  • Order of Composition: Composition is not commutative, meaning: \[ (f \circ g)(x) \neq (g \circ f)(x) \] unless explicitly proven for specific \( f(x) \) and \( g(x) \).

Examples of Composition

Example 1: Simple Composition

Let \( f(x) = 2x + 3 \) and \( g(x) = x^2 - 4x + 1 \). Find:

  1. \((f \circ g)(x)\)
  2. \((g \circ f)(x)\)

Solution:

  1. \((f \circ g)(x)\): \[ f(g(x)) = f(x^2 - 4x + 1) = 2(x^2 - 4x + 1) + 3 \] Simplify: \[ f(g(x)) = 2x^2 - 8x + 2 + 3 = 2x^2 - 8x + 5 \]
  2. \((g \circ f)(x)\): \[ g(f(x)) = g(2x + 3) = (2x + 3)^2 - 4(2x + 3) + 1 \] Expand \( (2x + 3)^2 \): \[ (2x + 3)^2 = 4x^2 + 12x + 9 \] Substitute back: \[ g(f(x)) = 4x^2 + 12x + 9 - 8x - 12 + 1 = 4x^2 + 4x - 2 \]

Final Answers:

  • \((f \circ g)(x) = 2x^2 - 8x + 5\)
  • \((g \circ f)(x) = 4x^2 + 4x - 2\)

Composition with Inverses

If \( f(x) \) and \( f^{-1}(x) \) are inverses, their composition satisfies:

\[ (f \circ f^{-1})(x) = x \quad \text{and} \quad (f^{-1} \circ f)(x) = x \]

Example 2: Verifying Inverses

Let \( f(x) = 2x + 3 \). Its inverse is \( f^{-1}(x) = \frac{x - 3}{2} \). Verify:

  1. \((f \circ f^{-1})(x)\)
  2. \((f^{-1} \circ f)(x)\)

Solution:

  1. \((f \circ f^{-1})(x)\): \[ f(f^{-1}(x)) = f\left(\frac{x - 3}{2}\right) = 2\left(\frac{x - 3}{2}\right) + 3 \] Simplify: \[ f(f^{-1}(x)) = x - 3 + 3 = x \]
  2. \((f^{-1} \circ f)(x)\): \[ f^{-1}(f(x)) = f^{-1}(2x + 3) = \frac{(2x + 3) - 3}{2} \] Simplify: \[ f^{-1}(f(x)) = \frac{2x}{2} = x \]

Conclusion:

\[ (f \circ f^{-1})(x) = x \quad \text{and} \quad (f^{-1} \circ f)(x) = x \]

Computing Specific Values

Example 3: Compute \((f \circ g)(2)\)

Let \( f(x) = 2x + 3 \) and \( g(x) = x^2 - 4x + 1 \). Find \((f \circ g)(2)\).

Solution:

  1. Compute \( g(2) \): \[ g(2) = 2^2 - 4(2) + 1 = 4 - 8 + 1 = -3 \]
  2. Substitute into \( f(x) \): \[ f(g(2)) = f(-3) = 2(-3) + 3 = -6 + 3 = -3 \]

Answer:

\[ (f \circ g)(2) = -3 \]

Additional Examples

Example 4: Complex Functions

Let \( f(x) = \sqrt{x} \) and \( g(x) = x^2 - 1 \). Find:

  1. \((f \circ g)(x)\)
  2. Domain of \((f \circ g)(x)\)

Solution:

  1. \((f \circ g)(x)\): \[ f(g(x)) = f(x^2 - 1) = \sqrt{x^2 - 1} \]
  2. Domain: For \( \sqrt{x^2 - 1} \) to be real: \[ x^2 - 1 \geq 0 \implies x^2 \geq 1 \implies x \leq -1 \text{ or } x \geq 1 \]

Answer:

\[ (f \circ g)(x) = \sqrt{x^2 - 1} \] \[ \text{Domain: } (-\infty, -1] \cup [1, \infty) \]

Conclusion

Function composition is a fundamental concept in mathematics, allowing the combination of two functions into one. It is essential for understanding inverses, evaluating values, and solving real-world problems.

Practice Questions

Solve the following problems and verify your answers below:

  1. Let \( f(x) = 3x - 2 \) and \( g(x) = x^2 + 4x + 5 \). Find \((f \circ g)(x)\) and \((g \circ f)(x)\).
  2. Let \( f(x) = \sqrt{x} \) and \( g(x) = x^2 - 6x + 9 \). Find \((f \circ g)(x)\) and the domain of the composition.
  3. Let \( f(x) = 4x + 7 \) and \( g(x) = \frac{1}{x} \). Find \((f \circ g)(x)\).
  4. If \( f(x) = x^3 \) and \( g(x) = x + 1 \), compute \((f \circ g)(2)\).
  5. Verify that \( f(x) = 5x - 3 \) and \( f^{-1}(x) = \frac{x + 3}{5} \) are inverses by showing \((f \circ f^{-1})(x) = x\) and \((f^{-1} \circ f)(x) = x\).

Answers to Practice Questions

  1. \((f \circ g)(x) = 3(x^2 + 4x + 5) - 2 = 3x^2 + 12x + 15 - 2 = 3x^2 + 12x + 13\)
    \((g \circ f)(x) = (3x - 2)^2 + 4(3x - 2) + 5 = 9x^2 - 12x + 4 + 12x - 8 + 5 = 9x^2 + 1\)
  2. \((f \circ g)(x) = \sqrt{x^2 - 6x + 9} = \sqrt{(x - 3)^2} = |x - 3|\)
    Domain: \(x \in \mathbb{R}\)
  3. \((f \circ g)(x) = f\left(\frac{1}{x}\right) = 4\left(\frac{1}{x}\right) + 7 = \frac{4}{x} + 7\)
  4. \((f \circ g)(2) = f(g(2)) = f(2 + 1) = f(3) = 3^3 = 27\)
  5. \((f \circ f^{-1})(x) = f\left(\frac{x + 3}{5}\right) = 5\left(\frac{x + 3}{5}\right) - 3 = x + 3 - 3 = x\)
    \((f^{-1} \circ f)(x) = f^{-1}(5x - 3) = \frac{(5x - 3) + 3}{5} = \frac{5x}{5} = x\)

Add comment

Comments

There are no comments yet.