Solved Exercises on Compositions of Functions in College Algebra

Master compositions of functions: definition, applications, graphing compositions through these 5 detailed exercises.

Solution: Exercises 1 to 3
1 Basic composition
Exercise 1
Given \(f(x) = 2x + 3\) and \(g(x) = x^2\), find \((f \circ g)(x)\) and \((g \circ f)(x)\).
Definition:

Function composition: \((f \circ g)(x) = f(g(x))\) means apply \(g\) first, then apply \(f\) to the result

• \((f \circ g)(x)\) is read as "\(f\) composed with \(g\) of \(x\)"

• Order matters: \((f \circ g)(x)\) is generally not equal to \((g \circ f)(x)\)

Composition method:
  1. Identify the inner function and outer function
  2. Substitute the inner function into the outer function
  3. Simplify the resulting expression
For (f ∘ g)(x)
\(f(g(x))\)
Substitute g(x)
\(f(x^2)\)
Apply f
\(2(x^2) + 3\)
Result
\(2x^2 + 3\)
Step 1: Find \((f \circ g)(x) = f(g(x))\)

First, identify the inner function: \(g(x) = x^2\)

Step 2: Apply the outer function

Apply \(f\) to the result of \(g(x)\): \(f(g(x)) = f(x^2)\)

Step 3: Substitute and simplify

Since \(f(x) = 2x + 3\), we have: \(f(x^2) = 2(x^2) + 3 = 2x^2 + 3\)

Step 4: Find \((g \circ f)(x) = g(f(x))\)

First, identify the inner function: \(f(x) = 2x + 3\)

Step 5: Apply the outer function

Apply \(g\) to the result of \(f(x)\): \(g(f(x)) = g(2x + 3)\)

Step 6: Substitute and simplify

Since \(g(x) = x^2\), we have: \(g(2x + 3) = (2x + 3)^2 = 4x^2 + 12x + 9\)

\((f \circ g)(x) = 2x^2 + 3\), \((g \circ f)(x) = 4x^2 + 12x + 9\)
Final answer:

\((f \circ g)(x) = 2x^2 + 3\) and \((g \circ f)(x) = 4x^2 + 12x + 9\)

Applied rules:

• Composition definition: \((f \circ g)(x) = f(g(x))\)

• Order matters: Generally \((f \circ g)(x) \neq (g \circ f)(x)\)

• Substitution: Replace the variable in the outer function with the inner function

2 Three-function composition
Exercise 2
Given \(f(x) = x + 1\), \(g(x) = 2x\), and \(h(x) = x^2\), find \((f \circ g \circ h)(x)\).
Definition:

Three-function composition: \((f \circ g \circ h)(x) = f(g(h(x)))\) means apply \(h\) first, then \(g\), then \(f\)

• Work from the inside out: evaluate the rightmost function first

Start with h(x)
\(h(x) = x^2\)
Apply g
\(g(h(x)) = g(x^2) = 2x^2\)
Apply f
\(f(g(h(x))) = f(2x^2) = 2x^2 + 1\)
Step 1: Start with the innermost function

Apply \(h(x) = x^2\): the result is \(x^2\)

Step 2: Apply the next function

Apply \(g\) to the result: \(g(x^2) = 2(x^2) = 2x^2\)

Step 3: Apply the outermost function

Apply \(f\) to the result: \(f(2x^2) = (2x^2) + 1 = 2x^2 + 1\)

Step 4: Verify the order

We evaluated: \(f(g(h(x))) = f(g(x^2)) = f(2x^2) = 2x^2 + 1\)

\((f \circ g \circ h)(x) = 2x^2 + 1\)
Final answer:

\((f \circ g \circ h)(x) = 2x^2 + 1\)

Applied rules:

• Inside-out order: Evaluate the rightmost function first

• Sequential composition: Apply functions one by one

• Associativity: Composition is associative: \((f \circ g) \circ h = f \circ (g \circ h)\)

3 Domain considerations
Exercise 3
Given \(f(x) = \sqrt{x}\) and \(g(x) = x - 4\), find \((f \circ g)(x)\) and state its domain.
Definition:

Domain of composition: The domain of \((f \circ g)(x)\) consists of all \(x\) in the domain of \(g\) such that \(g(x)\) is in the domain of \(f\)

Compose functions
\(f(g(x)) = f(x - 4)\)
Substitute
\(f(x - 4) = \sqrt{x - 4}\)
Domain condition
\(x - 4 \geq 0\)
Result
\(x \geq 4\)
Step 1: Find the composition

\((f \circ g)(x) = f(g(x)) = f(x - 4) = \sqrt{x - 4}\)

Step 2: Determine domain constraints

For \(\sqrt{x - 4}\) to be defined: \(x - 4 \geq 0\)

Step 3: Solve the inequality

\(x - 4 \geq 0\) implies \(x \geq 4\)

Step 4: Verify with function domains

\(g(x) = x - 4\) has domain \(\mathbb{R}\), but we need \(g(x) \geq 0\) for \(f(g(x))\) to be defined

\((f \circ g)(x) = \sqrt{x - 4}\), Domain: \([4, \infty)\)
Final answer:

\((f \circ g)(x) = \sqrt{x - 4}\) with domain \([4, \infty)\)

Applied rules:

• Domain restriction: \(x\) must be in domain of \(g\) AND \(g(x)\) must be in domain of \(f\)

• Composition domain: More restrictive than individual domains

• Radical constraint: Expression under radical must be non-negative

Composition of Functions: Core Concepts
\((f \circ g)(x) = f(g(x))\)
Function Composition Definition
Composition
\((f \circ g)(x) = f(g(x))\)
Apply g first, then f
Non-commutative
\((f \circ g)(x) \neq (g \circ f)(x)\)
Order matters
Domain
\(\text{Dom}(f \circ g) = \{x \in \text{Dom}(g) : g(x) \in \text{Dom}(f)\}\)
Domain restrictions
Identity
\(f \circ I = I \circ f = f\)
Identity function
\((f \circ g \circ h)(x) = f(g(h(x)))\)
Three-Function Composition
\(\text{Dom}(f \circ g) \subseteq \text{Dom}(g)\)
Domain Relationship
\(\text{Associative: } (f \circ g) \circ h = f \circ (g \circ h)\)
Associative Property
Solution: Exercises 4 to 5
4 Inverse functions composition
Exercise 4
Given \(f(x) = 2x + 1\) and \(f^{-1}(x) = \frac{x - 1}{2}\), verify that \((f \circ f^{-1})(x) = x\) and \((f^{-1} \circ f)(x) = x\).
Definition:

Inverse functions: If \(f\) and \(g\) are inverse functions, then \((f \circ g)(x) = x\) and \((g \circ f)(x) = x\)

For (f ∘ f⁻¹)(x)
\(f(f^{-1}(x))\)
Substitute f⁻¹(x)
\(f\left(\frac{x - 1}{2}\right)\)
Apply f
\(2\left(\frac{x - 1}{2}\right) + 1\)
Simplify
\(x - 1 + 1 = x\)
Step 1: Find \((f \circ f^{-1})(x) = f(f^{-1}(x))\)

Apply \(f\) to \(f^{-1}(x)\): \(f\left(\frac{x - 1}{2}\right)\)

Step 2: Substitute into f(x)

Since \(f(x) = 2x + 1\): \(f\left(\frac{x - 1}{2}\right) = 2\left(\frac{x - 1}{2}\right) + 1\)

Step 3: Simplify the expression

\(2\left(\frac{x - 1}{2}\right) + 1 = (x - 1) + 1 = x\)

Step 4: Find \((f^{-1} \circ f)(x) = f^{-1}(f(x))\)

Apply \(f^{-1}\) to \(f(x)\): \(f^{-1}(2x + 1)\)

Step 5: Substitute into f⁻¹(x)

Since \(f^{-1}(x) = \frac{x - 1}{2}\): \(f^{-1}(2x + 1) = \frac{(2x + 1) - 1}{2}\)

Step 6: Simplify the expression

\(\frac{(2x + 1) - 1}{2} = \frac{2x}{2} = x\)

Both compositions equal x
Final answer:

\((f \circ f^{-1})(x) = x\) and \((f^{-1} \circ f)(x) = x\), confirming that \(f\) and \(f^{-1}\) are inverse functions.

Applied rules:

• Inverse property: Composition of function and its inverse yields identity function

• Bidirectional: Both \((f \circ f^{-1})(x) = x\) and \((f^{-1} \circ f)(x) = x\)

• Verification: Use composition to verify inverse relationships

5 Real-world application
Exercise 5
A company's production cost is given by \(C(x) = 50x + 1000\) dollars, where \(x\) is the number of units produced. The number of units sold is related to price by \(x(p) = 100 - 2p\), where \(p\) is the price per unit in dollars. Express the cost as a function of price.
Definition:

Real-world composition: Using function composition to model relationships between different variables in practical situations

Given functions
\(C(x) = 50x + 1000\), \(x(p) = 100 - 2p\)
Compose functions
\(C(x(p)) = C(100 - 2p)\)
Substitute
\(C(100 - 2p) = 50(100 - 2p) + 1000\)
Simplify
\(5000 - 100p + 1000 = 6000 - 100p\)
Step 1: Identify the functions involved

Cost as function of units: \(C(x) = 50x + 1000\)

Units as function of price: \(x(p) = 100 - 2p\)

Step 2: Set up the composition

We want cost as function of price: \((C \circ x)(p) = C(x(p))\)

Step 3: Substitute the inner function

\(C(x(p)) = C(100 - 2p)\)

Step 4: Apply the outer function

Substitute \((100 - 2p)\) into \(C(x)\): \(C(100 - 2p) = 50(100 - 2p) + 1000\)

Step 5: Simplify the expression

\(50(100 - 2p) + 1000 = 5000 - 100p + 1000 = 6000 - 100p\)

Step 6: Interpret the result

The cost as a function of price is \(C(p) = 6000 - 100p\)

\(C(p) = 6000 - 100p\)
Final answer:

The cost as a function of price is \(C(p) = 6000 - 100p\). As price increases, cost decreases because fewer units are sold.

Applied rules:

• Modeling: Use composition to connect related variables

• Substitution: Replace variables with appropriate functions

• Interpretation: Understand the real-world meaning of the composition

Comprehensive Guide: Compositions of Functions
(f \circ g)(x) = f(g(x))
Basic Composition Formula
Key definitions:

Function composition: The operation of applying one function to the results of another

Inner function: The function that is applied first in a composition

Outer function: The function that is applied second in a composition

Domain of composition: The set of all inputs for which the composition is defined

Inverse functions: Functions whose composition yields the identity function

Complete methodology:
  1. Identify the functions: Determine which function is the inner and which is the outer
  2. Set up the composition: Write the composition in the form \((f \circ g)(x) = f(g(x))\)
  3. Substitute: Replace the variable in the outer function with the inner function
  4. Simplify: Perform algebraic simplification
  5. Determine domain: Find the domain of the composition
Tip 1: Remember "inside-out": evaluate the rightmost function first in \((f \circ g)(x)\).
Tip 2: Composition is not commutative: \((f \circ g)(x) \neq (g \circ f)(x)\) in general.
Tip 3: Always check domain restrictions when composing functions.
Tip 4: Use composition to model multi-step processes in real-world applications.
Common errors: Forgetting order of operations, ignoring domain restrictions, confusing function notation.
Exam preparation: Practice with various function types, understand domain implications, recognize inverse relationships.
Essential rules to remember:

• Definition: \((f \circ g)(x) = f(g(x))\)

• Non-commutative: \((f \circ g)(x) \neq (g \circ f)(x)\) in general

• Associative: \((f \circ g) \circ h = f \circ (g \circ h)\)

• Domain: \(x\) must be in domain of \(g\) and \(g(x)\) must be in domain of \(f\)

• Inverse property: \(f \circ f^{-1} = f^{-1} \circ f = I\) (identity function)

Exercise with Visualization: Function Compositions
Exercise 6: Comparing Different Compositions
Consider the functions \(f(x) = x + 1\) and \(g(x) = x^2\):
\(f(g(x)) = x^2 + 1\)
\(g(f(x)) = (x + 1)^2\)
\(f(f(x)) = x + 2\)
\(g(g(x)) = x^4\)

Analysis: The chart compares the behavior of different function compositions.

  • \(f(g(x)) = x^2 + 1\) is a parabola shifted up by 1
  • \(g(f(x)) = (x + 1)^2\) is a parabola shifted left by 1
  • \(f(f(x)) = x + 2\) is a linear function with slope 1 and y-intercept 2
  • \(g(g(x)) = x^4\) is a quartic function

Questions & Answers

Question: Why is function composition not commutative? Why doesn't \((f \circ g)(x) = (g \circ f)(x)\)?

Answer: Function composition is not commutative because the order of operations fundamentally changes the process:

For \((f \circ g)(x) = f(g(x))\):

  • First apply \(g\) to \(x\)
  • Then apply \(f\) to the result of \(g(x)\)

For \((g \circ f)(x) = g(f(x))\):

  • First apply \(f\) to \(x\)
  • Then apply \(g\) to the result of \(f(x)\)

Example: Let \(f(x) = x + 1\) and \(g(x) = x^2\)

  • \((f \circ g)(x) = f(g(x)) = f(x^2) = x^2 + 1\)
  • \((g \circ f)(x) = g(f(x)) = g(x + 1) = (x + 1)^2 = x^2 + 2x + 1\)

Since \(x^2 + 1 \neq x^2 + 2x + 1\) (unless \(x = 0\)), the compositions are different.

Think of it like putting on shoes and socks: the order matters!

Question: How do I find the domain of a composition \((f \circ g)(x)\)?

Answer: Finding the domain of a composition requires careful consideration of both functions:

Steps:

  1. Find the domain of the inner function \(g(x)\)
  2. Determine what values \(g(x)\) can produce (range of \(g\))
  3. Find the domain of the outer function \(f(x)\)
  4. Restrict to values where \(g(x)\) is in the domain of \(f\)

Example: Let \(f(x) = \sqrt{x}\) and \(g(x) = x - 3\)

  • Domain of \(g(x) = x - 3\) is all real numbers \(\mathbb{R}\)
  • Domain of \(f(x) = \sqrt{x}\) is \(x \geq 0\)
  • For \(f(g(x)) = f(x - 3) = \sqrt{x - 3}\) to be defined, we need \(x - 3 \geq 0\)
  • Therefore, domain is \(x \geq 3\), or \([3, \infty)\)

The domain of the composition is often more restrictive than the domain of the inner function alone.

Question: Can function composition be used in real-world applications? How?

Answer: Yes, function composition is extremely useful in real-world applications:

Examples:

  • Economics: Cost as a function of quantity, where quantity is a function of price
  • Physics: Position as a function of time, where time is a function of some parameter
  • Engineering: Output of a system as a function of input, where input depends on another variable
  • Computer Science: Chaining operations or transformations

Example: Temperature conversion followed by a transformation

  • Celsius to Fahrenheit: \(F(C) = \frac{9}{5}C + 32\)
  • Temperature as function of altitude: \(C(a) = 20 - 0.0065a\)
  • Composition: \(F(C(a))\) gives Fahrenheit as function of altitude

Composition allows us to model complex relationships by breaking them into simpler, manageable parts.