Mathwords logoMathwords

Operations on Functions — Definition, Formula & Examples

Operations on functions are ways of combining two or more functions to create a new function. The main operations are addition, subtraction, multiplication, division, and composition.

Given functions ff and gg with domains DfD_f and DgD_g, the sum (f+g)(x)=f(x)+g(x)(f+g)(x) = f(x)+g(x), difference (fg)(x)=f(x)g(x)(f-g)(x) = f(x)-g(x), product (fg)(x)=f(x)g(x)(f \cdot g)(x) = f(x) \cdot g(x), and quotient (fg)(x)=f(x)g(x)\left(\frac{f}{g}\right)(x) = \frac{f(x)}{g(x)} are each defined on DfDgD_f \cap D_g (with the additional restriction g(x)0g(x) \neq 0 for the quotient). The composition (fg)(x)=f(g(x))(f \circ g)(x) = f(g(x)) is defined for all xx in DgD_g such that g(x)g(x) is in DfD_f.

Key Formula

(f+g)(x)=f(x)+g(x)(fg)(x)=f(x)g(x)(fg)(x)=f(x)g(x)(fg)(x)=f(x)g(x),  g(x)0(fg)(x)=f ⁣(g(x))\begin{aligned}(f+g)(x) &= f(x) + g(x) \\ (f-g)(x) &= f(x) - g(x) \\ (f \cdot g)(x) &= f(x) \cdot g(x) \\ \left(\tfrac{f}{g}\right)(x) &= \frac{f(x)}{g(x)},\; g(x)\neq 0 \\ (f \circ g)(x) &= f\!\big(g(x)\big)\end{aligned}
Where:
  • f(x)f(x) = First function evaluated at x
  • g(x)g(x) = Second function evaluated at x
  • fgf \circ g = Composition: f applied to the output of g

How It Works

To perform an arithmetic operation on two functions, you apply that operation to their output values at each input xx. For addition, evaluate both functions at xx and add the results. Multiplication and subtraction work the same way. Division requires you to check that the denominator function is not zero. Composition is different: you feed the output of one function into the input of another, essentially chaining them together. In every case, pay attention to the domain — the new function is only defined where the operation makes sense.

Worked Example

Problem: Let f(x) = 2x + 3 and g(x) = x². Find (f + g)(4), (f · g)(4), and (f ∘ g)(4).
Evaluate each function at x = 4: Find f(4) and g(4) first.
f(4)=2(4)+3=11,g(4)=42=16f(4) = 2(4)+3 = 11, \quad g(4) = 4^2 = 16
Addition: Add the two outputs.
(f+g)(4)=11+16=27(f+g)(4) = 11 + 16 = 27
Multiplication: Multiply the two outputs.
(fg)(4)=11×16=176(f \cdot g)(4) = 11 \times 16 = 176
Composition: For (f ∘ g)(4), first evaluate g(4), then plug that result into f.
(fg)(4)=f(g(4))=f(16)=2(16)+3=35(f \circ g)(4) = f(g(4)) = f(16) = 2(16)+3 = 35
Answer: (f + g)(4) = 27, (f · g)(4) = 176, and (f ∘ g)(4) = 35.

Another Example

Problem: Let f(x) = x + 1 and g(x) = x − 4. Find the domain of (f / g)(x) and evaluate it at x = 6.
Write the quotient: Form the quotient function.
(fg)(x)=x+1x4\left(\frac{f}{g}\right)(x) = \frac{x+1}{x-4}
Determine the domain: The denominator equals zero when x = 4, so exclude that value.
Domain: all real x,  x4\text{Domain: all real } x,\; x \neq 4
Evaluate at x = 6: Substitute x = 6 into the quotient.
6+164=72\frac{6+1}{6-4} = \frac{7}{2}
Answer: The domain is all real numbers except 4, and (f / g)(6) = 7/2.

Why It Matters

Operations on functions appear throughout Algebra 2 and Precalculus, forming the basis for topics like inverse functions and transformations. In calculus, the product rule and chain rule are differentiation techniques built directly on function multiplication and composition. Scientists and engineers routinely combine simpler functions to model complex behavior — for instance, multiplying a growth function by a decay function to model a quantity that rises then falls.

Common Mistakes

Mistake: Treating composition as multiplication: writing f(g(x)) as f(x) · g(x).
Correction: Composition means substituting g(x) into f. For f(x)=2x and g(x)=x+3, f(g(x))=2(x+3)=2x+6, not 2x(x+3).
Mistake: Forgetting to restrict the domain when dividing functions.
Correction: Always exclude any x-value that makes the denominator function equal to zero before evaluating (f / g)(x).

Related Terms