Skip to main content

Composite Function Calculator

Our free algebra calculator solves composite function problems. Get worked examples, visual aids, and downloadable results.

Reviewed by Manoj Kumar, Mathematics Educator

Reviewed by Manoj Kumar, Mathematics Educator

Formula

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

Where f and g are functions, and the composition f(g(x)) means first evaluating g at x, then evaluating f at the result. For quadratic functions f(x) = ax^2 + bx + c and g(x) = dx^2 + ex + f, the composition produces a higher-degree polynomial.

Worked Examples

Example 1: Quadratic Composition

Problem:Given f(x) = 2x^2 + 3x + 1 and g(x) = x - 2, find f(g(3)) and g(f(3)).

Solution:Step 1: Find g(3) = 3 - 2 = 1\nStep 2: Find f(g(3)) = f(1) = 2(1)^2 + 3(1) + 1 = 2 + 3 + 1 = 6\nStep 3: Find f(3) = 2(9) + 3(3) + 1 = 18 + 9 + 1 = 28\nStep 4: Find g(f(3)) = g(28) = 28 - 2 = 26

Result:f(g(3)) = 6 and g(f(3)) = 26 -- different results showing composition is not commutative

Example 2: Self-Composition

Problem:Given f(x) = x^2 + 1, find f(f(2)).

Solution:Step 1: Find f(2) = (2)^2 + 1 = 4 + 1 = 5\nStep 2: Find f(f(2)) = f(5) = (5)^2 + 1 = 25 + 1 = 26\nThe function applied to itself grows very rapidly due to the squaring operation.

Result:f(f(2)) = 26

Frequently Asked Questions

What is a composite function and how is it formed?

A composite function is created when the output of one function becomes the input of another function. Written as (f o g)(x) or f(g(x)), it means you first evaluate g at x, then feed that result into f. This operation chains two functions together into a single new function. For example, if f(x) = 2x + 1 and g(x) = x^2, then f(g(x)) = 2(x^2) + 1 = 2x^2 + 1. The order matters significantly because f(g(x)) and g(f(x)) typically produce different results, making composition a non-commutative operation in most cases.

Why does the order of composition matter in composite functions?

The order of composition matters because function composition is generally not commutative, meaning f(g(x)) does not equal g(f(x)) in most cases. This happens because the inner function transforms the input first, and different transformations applied in different sequences produce different outcomes. Consider f(x) = x + 3 and g(x) = 2x. Then f(g(x)) = 2x + 3, but g(f(x)) = 2(x + 3) = 2x + 6. These are clearly different functions. Only in special cases, such as when both functions are linear with specific relationships, will the composition be commutative.

How do you find the domain of a composite function?

Finding the domain of a composite function f(g(x)) requires two conditions to be satisfied simultaneously. First, x must be in the domain of g so that g(x) is defined. Second, g(x) must be in the domain of f so that f(g(x)) is defined. For polynomial functions like those in Composite Function Calculator, the domain is all real numbers since polynomials are defined everywhere. However, for functions involving square roots, logarithms, or fractions, restrictions apply. For example, if f(x) = sqrt(x) and g(x) = x - 4, then f(g(x)) = sqrt(x - 4) requires x >= 4.

What is the difference between composite functions and multiplying functions?

Composite functions and function multiplication are fundamentally different operations. Multiplying functions means (f times g)(x) = f(x) * g(x), where both functions are evaluated at x independently and their outputs are multiplied together. Composition means f(g(x)), where g is evaluated at x first, and then f is evaluated at the result of g(x). For example, if f(x) = x + 1 and g(x) = x^2, then f(x) * g(x) = (x + 1)(x^2) = x^3 + x^2, but f(g(x)) = x^2 + 1. These produce entirely different results and represent different mathematical operations.

References

Reviewed by Manoj Kumar, Mathematics Educator ยท Editorial policy