Resources For Teachers For Tutors For Students & Parents AI New Books Pricing
Year 11 (2026) Maths Extension 1 (2026) Further Work with Functions

Difference of Functions (Subtracting Ordinates)

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

Subtracting ordinates builds the graph of \(y=f(x)-g(x)\) from the vertical gaps between two graphs. This Year 11 Mathematics Extension 1 page shows how to evaluate a difference of functions, find its domain, solve \((f-g)(x)=0\) to find where graphs meet, use the discriminant to decide whether they touch or never meet, and find the greatest vertical distance and the range.

The difference of two functions \(f\) and \(g\) is the function \[(f-g)(x)=f(x)-g(x).\] To graph it by subtracting ordinates, take each \(x\)-value and subtract the height of \(g\) from the height of \(f\). Always subtract the whole of \(g(x)\): \((f-g)(x)=(2x+1)-(x-3)=x+4\), because the bracket changes every sign inside it.

The ordinate of \(f-g\) is the vertical distance from the graph of \(g\) up to the graph of \(f\). It is positive where the graph of \(f\) is above the graph of \(g\), zero where the two graphs meet, and negative where \(f\) is below \(g\). So:

• the graphs of \(y=f(x)\) and \(y=g(x)\) meet where \((f-g)(x)=0\), and these are the \(x\)-intercepts of \(y=f(x)-g(x)\);
• the graph of \(f\) is above the graph of \(g\) where \(f(x)-g(x)\gt 0\);
• the greatest vertical distance between the graphs is the maximum value of \(f(x)-g(x)\) between the meeting points (where \(f\) is above \(g\)).

The difference exists only where both functions exist, so its domain is the set of \(x\)-values in both domains. For \(f(x)=\sqrt{x+5}\) and \(g(x)=\dfrac{1}{x+1}\), the domain is \(x\ge-5,\ x\ne-1\).

When \(f-g\) is a quadratic, its discriminant \(\Delta\) counts the meeting points: \(\Delta\gt 0\) gives two, \(\Delta=0\) means the graphs touch at one point (a repeated root), and \(\Delta\lt0\) means they never meet, so \(f-g\) keeps one sign for every \(x\).

Where \(g(x)\) approaches \(0\), the difference approaches \(f(x)\). For example, as \(x\to-\infty\), \(3^{x}\to0\), so \(y=2-3^{x}\) approaches the horizontal asymptote \(y=2\); and since \(3^{x}\gt 0\), \(y\lt2\) for every \(x\).

The graphs of y = x + 3 and y = x squared + 1The line y = f(x) = x + 3 (navy) and the parabola y = g(x) = x squared + 1 (teal, dashed) meet at (-1, 2) and (2, 5). Between these points the line is above the parabola (shaded), so f(x) - g(x) > 0. At x = 1/2 the vertical gap is 9/4. At x = -2 the line is below the parabola, so f(x) - g(x) < 0. x y −2 −1 1 2 3 2 4 6 8 O (−1, 2) (2, 5) 9/4 f − g < 0 y = f(x) y = g(x)
\(f(x)=x+3\) and \(g(x)=x^2+1\). The line is above the parabola between the meeting points, so \(f(x)-g(x)>0\) there (shaded). Each vertical gap is an ordinate of \(f-g\): \(\dfrac{9}{4}\) at \(x=\dfrac{1}{2}\), and \(1-5=-4\) at \(x=-2\).
The graph of y = f(x) - g(x) = -x squared + x + 2The difference y = f(x) - g(x) = -x squared + x + 2 (red). It crosses the x-axis at x = -1 and x = 2, the x-values where the two original graphs meet. It is positive between them, with a maximum of 9/4 at x = 1/2, and passes through (-2, -4). x y −2 −1 1 2 3 −4 −2 2 O (½, 9/4) (−2, −4) y = f(x) − g(x)
The difference \(y=f(x)-g(x)=-x^2+x+2=-(x-2)(x+1)\). Its \(x\)-intercepts \(-1\) and \(2\) are the \(x\)-values where the two graphs meet, and it is above the \(x\)-axis exactly where \(f\) is above \(g\).

The difference of two functions, and its value at \(x=a\):

\[(f-g)(x)=f(x)-g(x)\qquad (f-g)(a)=f(a)-g(a)\]
f minus g of x equals f of x minus g of x; f minus g of a equals f of a minus g of a

Meeting points and above/below:

\[f(x)=g(x)\iff (f-g)(x)=0\qquad f\text{ above }g\iff f(x)-g(x)\gt 0\]
f of x equals g of x exactly when f minus g of x equals 0; f is above g exactly when f of x minus g of x is greater than 0

If \(f(x)-g(x)=ax^2+bx+c\), the discriminant counts the meeting points:

\[\Delta=b^2-4ac\]
Delta equals b squared minus 4 a c
\(\Delta\)Roots of \(f(x)-g(x)=0\)The graphs of \(f\) and \(g\)
\(\Delta\gt 0\)two real rootsmeet at two points
\(\Delta=0\)one repeated roottouch at one point
\(\Delta\lt0\)no real rootsnever meet
Above the \(x\)-axis for every \(x\). If \(a\gt 0\) and \(\Delta\lt0\), the parabola \(y=ax^2+bx+c\) opens upward and never reaches the \(x\)-axis, so \(f(x)-g(x)\gt 0\) for all \(x\): the graph of \(f\) is always above the graph of \(g\).
Greatest vertical distance. Complete the square: if \(f(x)-g(x)=-(x-h)^2+k\), the greatest value is \(k\), when \(x=h\).
Square-root equations. To solve \(\sqrt{A}=B\), square both sides, solve, then check every answer in the original equation. Squaring can create an extra (extraneous) solution where \(B\lt0\).
A difference of square roots. Multiply top and bottom by the sum: \[\sqrt{A}-\sqrt{B}=\dfrac{\left(\sqrt{A}-\sqrt{B}\right)\left(\sqrt{A}+\sqrt{B}\right)}{\sqrt{A}+\sqrt{B}}=\dfrac{A-B}{\sqrt{A}+\sqrt{B}}.\] For example \(\sqrt{x+5}-\sqrt{x}=\dfrac{5}{\sqrt{x+5}+\sqrt{x}}\), which is positive and decreases as \(x\) increases.
Where is \(f(x)-g(x)\ge0\)? Factorise \(f(x)-g(x)\), mark its zeros, and use the sign pattern between them (as for polynomial inequalities).

How to work with \(y=f(x)-g(x)\)

  1. Form the difference with brackets, \((f-g)(x)=\big(f(x)\big)-\big(g(x)\big)\), and simplify.
  2. Evaluate at \(x=a\) either by substituting into the simplified difference, or by finding \(f(a)\) and \(g(a)\) and subtracting.
  3. State the domain: the \(x\)-values where both functions are defined.
  4. Solve \((f-g)(x)=0\) to find where the graphs meet: factorise a quadratic, multiply through by \(x\) to clear a fraction, or square a square-root equation and check.
  5. Decide where \(f-g\) is positive or negative from the graphs or the sign pattern between the meeting points.
  6. Use the discriminant to count meeting points, or to find a constant \(k\) that makes the graphs touch or never meet.
  7. Complete the square to find a greatest vertical distance, a minimum value or the range.
Example 1 — Evaluate, intercept and solve
Let \(f(x)=4x-1\) and \(g(x)=x+5\).
(i) Find \((f-g)(x)\) and hence \((f-g)(3)\).
(ii) Find the \(y\)-intercept of the graph of \(y=f(x)-g(x)\).
(iii) Solve \((f-g)(x)=0\).
Solution

(i) Subtract the ordinates, then substitute:

\((f-g)(x)\)\(=\)\((4x-1)-(x+5)\)
\(\)\(=\)\(4x-1-x-5\)
\(\)\(=\)\(3x-6\)
\((f-g)(3)\)\(=\)\(3(3)-6\)
\(\)\(=\)\(\mathbf{3}\)
f minus g of x equals 4x minus 1 minus x plus 5 equals 3x minus 6; f minus g of 3 equals 3

Check: \(f(3)=11\) and \(g(3)=8\), so \(f(3)-g(3)=11-8=3\).

(ii) At \(x=0\): \(y=3(0)-6=-6\). \(\therefore\) the \(y\)-intercept is \(\mathbf{y=-6}\).

(iii)

\(3x-6\)\(=\)\(0\)
\(3x\)\(=\)\(6\)
\(x\)\(=\)\(\mathbf{2}\)
3x minus 6 equals 0, so x equals 2

So the two lines meet where \(x=2\), at \((2,7)\).

Subtracting the ordinates of y = 4x - 1 and y = x + 5The lines f(x) = 4x - 1 (navy) and g(x) = x + 5 (teal, dashed) meet at (2, 7). Their difference y = 3x - 6 (red) crosses the x-axis at x = 2 and has y-intercept -6. At x = 3 the gap between the lines is 3, which is the point (3, 3) on the difference. x y −1 1 2 3 4 4 8 12 16 O (2, 7) (3, 3) (0, −6) f g y = f(x) − g(x)
Example 2 — Domain and a square-root equation
Let \(f(x)=\sqrt{x+2}\) and \(g(x)=x\).
(i) State the domain of \(y=f(x)-g(x)\).
(ii) Solve \((f-g)(x)=0\). (Reject any extraneous solution.)
Solution

(i) \(\sqrt{x+2}\) needs \(x+2\ge0\), so \(x\ge-2\). \(g(x)=x\) is defined for all \(x\).
\(\therefore\) the domain is \(\mathbf{x\ge-2}\).

(ii) Set the ordinates equal, square, then check:

\(\sqrt{x+2}\)\(=\)\(x\)
\(x+2\)\(=\)\(x^2\)
\(0\)\(=\)\(x^2-x-2\)
\(0\)\(=\)\((x-2)(x+1)\)
square root of x plus 2 equals x, so x plus 2 equals x squared, 0 equals x minus 2 times x plus 1

\(x=2\) or \(x=-1\)
Check \(x=-1\): \(\sqrt{-1+2}=1\) but \(g(-1)=-1\), so reject.
Check \(x=2\): \(\sqrt{2+2}=2\) and \(g(2)=2\), true.

The graphs of y = square root of (x + 2) and y = xThe curve f(x) = square root of (x + 2) (navy), starting at (-2, 0), and the line g(x) = x (teal, dashed). They meet only at (2, 2). At x = -1 the curve is at height 1 and the line at height -1, so x = -1 is not a solution. x y −2 −1 1 2 3 4 −2 −1 1 2 3 O (2, 2) (−1, 1) (−1, −1) y = √(x + 2) y = x

\(\therefore\) \(\mathbf{x=2}\)

Example 3 — Touching, and never meeting
Let \(f(x)=x^2+1\) and \(g(x)=4x-k\), where \(k\) is a constant.
(i) Find the value of \(k\) for which the graphs of \(y=f(x)\) and \(y=g(x)\) touch, and the point where they touch.
(ii) Find the values of \(k\) for which the graph of \(y=f(x)-g(x)\) lies entirely above the \(x\)-axis.
Solution

Form the difference:

\(f(x)-g(x)\)\(=\)\(x^2+1-(4x-k)\)
\(\)\(=\)\(x^2-4x+(1+k)\)
f of x minus g of x equals x squared minus 4x plus 1 plus k
\(\Delta\)\(=\)\((-4)^2-4(1)(1+k)\)
\(\)\(=\)\(16-4-4k\)
\(\)\(=\)\(12-4k\)
Delta equals negative 4 squared minus 4 times 1 times 1 plus k equals 12 minus 4k

(i) The graphs touch when \(f(x)-g(x)=0\) has a repeated root, so \(\Delta=0\):

\(12-4k\)\(=\)\(0\)
\(k\)\(=\)\(\mathbf{3}\)
12 minus 4k equals 0, so k equals 3

Then \(f(x)-g(x)=x^2-4x+4=(x-2)^2\), a repeated root \(x=2\), and \(f(2)=5\). \(\therefore\) they touch at \(\mathbf{(2,5)}\).

(ii) The parabola \(y=f(x)-g(x)\) opens upward, so it lies above the \(x\)-axis for all \(x\) when \(\Delta\lt0\):

\(12-4k\)\(\lt\)\(0\)
\(-4k\)\(\lt\)\(-12\)
\(k\)\(\gt \)\(3\)
12 minus 4k is less than 0, so k is greater than 3
The parabola y = x squared + 1 and the lines y = 4x - kThe parabola f(x) = x squared + 1 (navy) and the line g(x) = 4x - 3 (teal, dashed), which touches it at (2, 5). The orange dashed line y = 4x - 5, for k = 5, lies below the parabola and never meets it. x y −1 1 2 3 4 4 8 12 O (2, 5) y = x² + 1 k = 3 k = 5

\(\therefore\) \(\mathbf{k\gt 3}\). (Dividing by \(-4\) reverses the inequality sign.) For example, \(k=5\) gives the orange line \(y=4x-5\), which never meets the parabola.

Example 4 — Greatest vertical distance
Let \(f(x)=2x+3\) and \(g(x)=x^2\).
(i) Find the \(x\)-coordinates of the points where the graphs of \(y=f(x)\) and \(y=g(x)\) meet.
(ii) By considering \(y=f(x)-g(x)\), find the greatest vertical distance between the two graphs for values of \(x\) between these points.
(iii) For which values of \(x\) is the line below the parabola?
Solution

(i) The graphs meet where \(f(x)-g(x)=0\):

\(2x+3-x^2\)\(=\)\(0\)
\(x^2-2x-3\)\(=\)\(0\)
\((x-3)(x+1)\)\(=\)\(0\)
2x plus 3 minus x squared equals 0, so x minus 3 times x plus 1 equals 0

\(\therefore\) \(\mathbf{x=-1}\) or \(\mathbf{x=3}\)

(ii) For \(-1\lt x\lt3\) the line is above the parabola, so the vertical distance is \(d=f(x)-g(x)\). Complete the square:

\(d\)\(=\)\(-x^2+2x+3\)
\(\)\(=\)\(-\left(x^2-2x\right)+3\)
\(\)\(=\)\(-(x-1)^2+1+3\)
\(\)\(=\)\(-(x-1)^2+4\)
d equals negative x squared plus 2x plus 3 equals negative x minus 1 all squared plus 4

Greatest value when \(x=1\). \(\therefore\) greatest vertical distance \(=\mathbf{4}\).

(iii) The line is below the parabola where \(f(x)-g(x)\lt0\), that is, outside the meeting points.
\(\therefore\) \(\mathbf{x\lt-1}\) or \(\mathbf{x\gt 3}\).

The line y = 2x + 3 and the parabola y = x squaredThe line f(x) = 2x + 3 (navy) and the parabola g(x) = x squared (teal, dashed) meet at (-1, 1) and (3, 9). Between them the line is above the parabola (shaded). The greatest vertical distance, 4, is at x = 1, from (1, 1) up to (1, 5). x y −1 1 2 3 4 2 4 6 8 10 O (−1, 1) (3, 9) 4 f g

Common pitfalls

Subtract the whole of \(g(x)\). \((x^2+2)-(3x-5)=x^2-3x+7\), not \(x^2-3x-3\). Put \(g(x)\) in brackets before you expand.
Order matters. \(f(x)-g(x)\) and \(g(x)-f(x)\) are opposites. \(f(x)-g(x)\gt 0\) means the graph of \(f\) is above the graph of \(g\), not below it.
Check square-root solutions. Squaring both sides of \(\sqrt{x+2}=x\) also gives \(x=-1\), which does not satisfy the original equation. Substitute every answer back.
The domain is where both functions exist. Combine the conditions: \(\sqrt{x+5}\) needs \(x\ge-5\) and \(\dfrac{1}{x+1}\) needs \(x\ne-1\). If one condition already rules out the excluded value, the domain is simply the stricter condition.
Reverse the sign when dividing by a negative. In \(-4k\lt-12\), dividing by \(-4\) gives \(k\gt 3\).

Frequently asked questions

What does subtracting ordinates mean?

It means building the graph of \(y=f(x)-g(x)\) by subtracting the \(y\)-value of \(g\) from the \(y\)-value of \(f\) at each \(x\)-value. Each ordinate of the difference is the vertical gap from \(g\) up to \(f\).

How do you find where two graphs meet using f(x) - g(x)?

Solve \(f(x)-g(x)=0\). Its solutions are the \(x\)-coordinates of the meeting points, and the \(x\)-intercepts of \(y=f(x)-g(x)\).

What does f(x) - g(x) > 0 mean on a graph?

The graph of \(y=f(x)\) is above the graph of \(y=g(x)\) at those \(x\)-values.

How do you find the greatest vertical distance between two graphs?

Between the meeting points, write \(d=f(x)-g(x)\) (upper minus lower) and find its maximum, for a quadratic by completing the square.

How do you tell if a line and a parabola touch?

Form \(f(x)-g(x)\) and find its discriminant. \(\Delta=0\) gives a repeated root, so the graphs touch at exactly one point.

Is (f - g)(x) the same as f(x) - g(x)?

Yes. \((f-g)(x)\) is notation for the function whose value at \(x\) is \(f(x)-g(x)\).