Skip to main content
Daily Math Minute

Functions & Their Graphs

Composing Functions

Evaluating and simplifying the composition of two functions.

Advanced20 min lesson3 min readUpdated August 12, 2026Author not yet attributed

Feeding One Function into Another

Before reading on, think about putting on socks, then shoes. Now think about putting on shoes, then socks. Both involve the exact same two actions — but the order clearly changes the result in a way that matters. Function composition works the same way: combining two functions by feeding one's output into the other as input, where the order genuinely changes the outcome.

Definition — Composition of Functions

The composition (f ∘ g)(x) = f(g(x)) means: first evaluate g at x, then evaluate f at that result. The output of the inner function becomes the input of the outer function.

Worked Example — Evaluating a Composition

Let f(x) = 3x − 1 and g(x) = x² + 2. Find (f ∘ g)(2). First evaluate the inner function: g(2) = 4 + 2 = 6. Then apply the outer function to that result: f(6) = 3(6) − 1 = 17. So (f ∘ g)(2) = 17.

Worked Example — Finding a Symbolic Composition and Showing Order Matters

Using the same f(x) = 3x − 1 and g(x) = x² + 2, find (f ∘ g)(x) and (g ∘ f)(x) as full expressions. (f ∘ g)(x) = f(g(x)) = 3(x² + 2) − 1 = 3x² + 6 − 1 = 3x² + 5. (g ∘ f)(x) = g(f(x)) = (3x − 1)² + 2 = 9x² − 6x + 1 + 2 = 9x² − 6x + 3. These are genuinely different expressions — confirming that composition order matters, the same way sock-then-shoe differs from shoe-then-sock.

Function Explorer

Transform: g(x) = a·f(b(x − h)) + k
1
1
0
0
Composition
Analysis (of the transformed function, in view)
y-intercept
(0, 0)
x-intercepts
(-9.42, 0), (-6.28, 0), (-3.14, 0), (0, 0), (3.14, 0), (6.28, 0), (9.42, 0)
Extrema
local min at (-7.85, -1); local max at (-4.71, 1); local min at (-1.57, -1); local max at (1.57, 1); local min at (4.71, -1); local max at (7.85, 1)
Inflection points
(-9.42, 0), (-6.28, 0), (-3.14, 0), (0, 0), (3.14, 0), (6.28, 0), (9.42, 0)
Vertical asymptotes
none found in view
Horizontal asymptotes
none found
Domain
all real numbers in view
Range (estimated)
approximately [-1, 1]

Tip

Work from the inside out — always evaluate (or simplify) the innermost function first, since its result becomes the input to everything wrapped around it.

Common Mistakes

  • Reading f(g(x)) as f(x) times g(x), confusing composition with multiplication.

    f(g(x)) means substituting the entire expression g(x) in for x inside f — it's a substitution, not a multiplication of the two functions.

  • Assuming (f ∘ g)(x) and (g ∘ f)(x) are always the same, the way multiplication of two numbers doesn't depend on order.

    Composition is generally not commutative — check both orders separately, since applying the functions in a different sequence usually produces a different expression.

Key Takeaways

  • Composition (f ∘ g)(x) = f(g(x)) evaluates the inner function first, then feeds its result into the outer function.
  • Composition is generally not commutative — (f ∘ g)(x) and (g ∘ f)(x) are usually different expressions.
  • Evaluating or simplifying from the inside out keeps composition organized.

Summary

Composition chains two functions together, in an order that genuinely matters. The next lesson asks a related question: is there a function that exactly undoes another one?

Sign in to track your progress and mark this lesson complete.

Track your progress