Resources For Teachers For Tutors For Students & Parents Pricing
Year 12 Maths - Methods (Unit 3 & Unit 4) Functions, relations and graphs

Combining functions

20 practice questions 0 video lessons Theory + worked examples
Create a free accountTrack your progress and save your work as you go.
Create free account

Theory

Combining functions forms a new function by adding, subtracting, multiplying or dividing the outputs of two functions: \((f+g)(x)=f(x)+g(x)\), and likewise for \(f-g\), \(fg\) and \(\dfrac{f}{g}\). The combined function is defined only where both functions are defined — the intersection of the domains — and for a quotient any \(x\) that makes the denominator zero is also excluded. The graph of a sum can be built by adding ordinates.

Two functions \(f\) and \(g\) can be combined pointwise: at each value of \(x\) you operate on the two outputs \(f(x)\) and \(g(x)\). This gives the sum \((f+g)(x)=f(x)+g(x)\), the difference \((f-g)(x)=f(x)-g(x)\), the product \((fg)(x)=f(x)\,g(x)\) and the quotient \(\left(\dfrac{f}{g}\right)(x)=\dfrac{f(x)}{g(x)}\).

A combined function only makes sense where both \(f\) and \(g\) are defined, so its domain is the intersection \(\operatorname{dom}f\cap\operatorname{dom}g\). For a quotient there is one further restriction: division by zero is undefined, so every \(x\) with \(g(x)=0\) must also be excluded from the domain.

The graph of a sum \(f+g\) can be sketched by adding ordinates — at each \(x\), add the height (the \(y\)-value, or ordinate) of \(f\) to the height of \(g\). Where one function is zero the sum equals the other function, which gives convenient points to plot.

Key idea. Combine outputs pointwise; the domain is \(\operatorname{dom}f\cap\operatorname{dom}g\). For \(\dfrac{f}{g}\) also remove every \(x\) with \(g(x)=0\). A combined domain is never larger than either original domain.
Adding ordinates of f and gThe curves f(x)=x/2, g(x)=1/x and their sum (f+g)(x)=x/2+1/x; at x=2 the height 1.5 of the sum equals the height 1 of f plus the height 0.5 of g. x y f g f+g
Adding ordinates: at \(x=2\), \((f+g)(2)=f(2)+g(2)=1+0.5=1.5\)
Domain of a combined function as an intersectionTwo number lines show the domain of f as x greater than or equal to minus 2 and the domain of g as x less than or equal to 3; the combined domain is their overlap, the closed interval from minus 2 to 3. dom f: x ≥ −2 dom g: x ≤ 3 −4 −3 −2 −1 0 1 2 3 4 5 dom(f+g) = [−2, 3]
Domain of a combined function: the overlap \(\operatorname{dom}f\cap\operatorname{dom}g=[-2,3]\)

The sum and difference — operate on the outputs term by term:

\[(f+g)(x)=f(x)+g(x) \qquad (f-g)(x)=f(x)-g(x)\]
(f+g)(x)=f(x)+g(x)

The product and quotient (the quotient needs \(g(x)\neq 0\)):

\[(fg)(x)=f(x)\,g(x) \qquad \left(\dfrac{f}{g}\right)(x)=\dfrac{f(x)}{g(x)},\ \ g(x)\neq 0\]
(fg)(x)=f(x)g(x)

The domain of the combined function — an intersection, with the extra restriction for a quotient:

\[\operatorname{dom}(f\pm g)=\operatorname{dom}(fg)=\operatorname{dom}f\cap\operatorname{dom}g\]
\[\operatorname{dom}\!\left(\dfrac{f}{g}\right)=\big(\operatorname{dom}f\cap\operatorname{dom}g\big)\setminus\{x:g(x)=0\}\]
dom(f±g)=domfdomg
Adding ordinates. To sketch \(y=(f+g)(x)\), add the \(y\)-values of the two graphs at each \(x\): \((f+g)(x)=f(x)+g(x)\). Where \(g(x)=0\) the sum passes through \(f\); where \(f(x)=0\) it passes through \(g\).

How to combine two functions

  1. Write the combined rule. Add, subtract, multiply or divide the two rules: \((f+g)(x)=f(x)+g(x)\), \((fg)(x)=f(x)g(x)\), and so on.
  2. Simplify. Expand brackets, collect like terms or factorise where it helps — but keep the original functions in mind for the domain.
  3. Find each domain, then intersect. The domain of the combined function is \(\operatorname{dom}f\cap\operatorname{dom}g\); watch for square roots (radicand \(\ge 0\)) and existing restrictions.
  4. Quotients: exclude zeros of the denominator. Solve \(g(x)=0\) and remove those \(x\)-values from the domain.
  5. To sketch a sum, add ordinates. Choose useful \(x\)-values (intercepts, and points where \(f\) or \(g\) is zero), add the two heights, and join the points.
Quick check. The domain of the combined function can never be larger than either original domain — if your answer contains an \(x\) outside \(\operatorname{dom}f\) or \(\operatorname{dom}g\), something has gone wrong.
Example 1 — sum and difference
For \(f(x)=x^{2}\) and \(g(x)=3x-1\), find \((f+g)(x)\) and \((f-g)(x)\), and state the domain.
Solution
Add the rules for \((f+g)(x)\):
\((f+g)(x)\)\(=\)\(x^{2}+(3x-1)\)
\(=\)\(x^{2}+3x-1\)
Subtract the rules for \((f-g)(x)\):
\((f-g)(x)\)\(=\)\(x^{2}-(3x-1)\)
\(=\)\(x^{2}-3x+1\)
Both \(f\) and \(g\) are defined for all real \(x\), so the domain is the intersection \(\mathbb{R}\):
\(\therefore\) \((f+g)(x)=x^{2}+3x-1\), \((f-g)(x)=x^{2}-3x+1\), domain \(\mathbb{R}\)
x2+3x-1
Example 2 — product with a restricted domain
For \(f(x)=\sqrt{x}\) and \(g(x)=x-1\), find \((fg)(x)\) and its domain.
Solution
Multiply the rules:
\((fg)(x)\)\(=\)\(\sqrt{x}\,(x-1)\)
Find each domain, then intersect:
\(\operatorname{dom}f\)\(=\)\([0,\infty)\)
\(\operatorname{dom}g\)\(=\)\(\mathbb{R}\)
\(\operatorname{dom}(fg)\)\(=\)\([0,\infty)\cap\mathbb{R}=[0,\infty)\)
\(\therefore\) \((fg)(x)=\sqrt{x}\,(x-1)\), domain \([0,\infty)\)
x(x-1)
Example 3 — quotient and excluded value
For \(f(x)=\sqrt{x+1}\) and \(g(x)=x-2\), find \(\left(\dfrac{f}{g}\right)(x)\) and its domain.
Solution
Write the quotient:
\(\left(\dfrac{f}{g}\right)(x)\)\(=\)\(\dfrac{\sqrt{x+1}}{x-2}\)
Intersect the domains — \(f\) needs \(x+1\ge 0\), i.e. \(x\ge -1\):
\(\operatorname{dom}f\cap\operatorname{dom}g\)\(=\)\([-1,\infty)\cap\mathbb{R}=[-1,\infty)\)
Exclude zeros of the denominator — solve \(g(x)=0\):
\(x-2\)\(=\)\(0 \ \Rightarrow\ x=2\)
\(\therefore\) \(\left(\dfrac{f}{g}\right)(x)=\dfrac{\sqrt{x+1}}{x-2}\), domain \([-1,2)\cup(2,\infty)\)
x+1x-2
Example 4 — sketch a sum by adding ordinates
For \(f(x)=x\) and \(g(x)=\dfrac{1}{x}\), find \((f+g)(x)\), state its domain, and sketch it for \(x>0\).
Solution
Add the rules:
\((f+g)(x)\)\(=\)\(x+\dfrac{1}{x}\)
Domain — \(f\) is defined on \(\mathbb{R}\) but \(g\) excludes \(x=0\):
\(\operatorname{dom}(f+g)\)\(=\)\(\mathbb{R}\setminus\{0\}\)
Add ordinates for \(x>0\): near \(0\), \(g\) dominates; for large \(x\), \(f\) dominates; the sum has a minimum where the two balance, at \((1,2)\).
\(\therefore\) \((f+g)(x)=x+\dfrac{1}{x}\), domain \(\mathbb{R}\setminus\{0\}\); minimum \((1,2)\) for \(x>0\)
Sketch of y=x+1/x by adding ordinatesThe line f(x)=x, the curve g(x)=1/x and their sum (f+g)(x)=x+1/x for x>0; the sum has a minimum at the point (1,2). x y f g f+g (1,2)
x+1x

Common pitfalls

Do not forget the domain. A combined function is only defined on \(\operatorname{dom}f\cap\operatorname{dom}g\). Even if the simplified rule looks defined everywhere, the domain is inherited from the original functions — e.g. \(\sqrt{x}\cdot\sqrt{x}=x\) but only for \(x\ge 0\).
Quotients: exclude zeros of the denominator. For \(\dfrac{f}{g}\) you must remove every \(x\) with \(g(x)=0\), not just restrictions already present in \(f\) and \(g\). Missing \(x=2\) in \(\dfrac{\sqrt{x+1}}{x-2}\) is a common slip.
Product is not composition. \((fg)(x)=f(x)g(x)\) multiplies the outputs; it is not \(f(g(x))\). Multiplying two functions and substituting one into the other give different results.

Frequently asked questions

How do you add two functions?

Add the outputs at each \(x\): \((f+g)(x)=f(x)+g(x)\). Add the two rules and simplify — e.g. \(x^{2}+(3x-1)=x^{2}+3x-1\).

What is the domain of a combined function?

For a sum, difference or product it is \(\operatorname{dom}f\cap\operatorname{dom}g\). For a quotient \(\dfrac{f}{g}\) you take that intersection and also exclude every \(x\) with \(g(x)=0\).

How do you find the domain of f divided by g?

Take \(\operatorname{dom}f\cap\operatorname{dom}g\), then remove every \(x\) with \(g(x)=0\). For \(\dfrac{\sqrt{x+1}}{x-2}\) the domain is \([-1,2)\cup(2,\infty)\).

How do you sketch the graph of a sum of two functions?

Add ordinates: at each \(x\), add the height of \(f\) to the height of \(g\). Useful points are the intercepts and any \(x\) where \(f\) or \(g\) is zero.

Is the product of two functions the same as composition?

No. The product multiplies outputs, \((fg)(x)=f(x)g(x)\); composition substitutes, \(f(g(x))\). They generally give different functions.

Can a combined function have a larger domain than the originals?

No. The domain is an intersection, so it can never exceed either original domain, and a quotient may be smaller once zeros of the denominator are removed.