A function is a rule that takes an input and gives one output. We write it as f(x) and say "f of x." For example, in the following function, the input is 3 and the output is 7: f(x) = 2x+1. We find functions throughout GCSE Maths, such as algebra, graphs, in composites like fg(x0), and inverses f-1(x).
This article explores all the essentials you need to understand for your exams. This includes how function notation works, how to substitute numbers and algebra correctly, what domain and range mean, how to handle composite and inverse functions, and how to read key features from graphs. It is aimed at students preparing to sit a Higher tier of GCSE Maths and is suitable for all major exam boards, including Edexcel. We have given a lot of examples to help strengthen your understanding through repetition.
If you need support to revise this topic, TeachTutti has qualified GCSE Maths tutors who can teach you in-person or virtually using the TeachTutti learning platform.
What is a function?
A function is a rule that takes an input and gives a single output. A simple example of a function is a vending machine: you press a button (input) and the machine gives you one snack (output).
We normally call the function f. We write the output as f(x), which means "f of x". The input is x, and the function tells us what to do with the input.
For example, f(x) = 2x + 1 tells us to double the input and add 1. The table below shows the input and output for this function. The input (x) has been set to different values. For instance, when the input is 3, we can read this as "the value of f when x is 3":
x | Working | f(x) |
0 | 2 times 0 + 1 | 1 |
3 | 2 times 3 + 1 | 7 |
a | 2 times a + 1 | 2a+1 |
These are the key points:
- f(x) is a single object. It does not mean f times x.
- We have given the letters f and x, but you can use other letters, such as g(x)
Another example is the function f(x) = 3x - 4. If the input is f(5), this means 3 times 5 - 4 = 11. If the input is f(2k), then 3(2k) - 4 = 6k - 4.
Domain
The domain means the allowed inputs for a function. Certain numbers can break a function, so the domain is effectively a safeguard.
- Dividing by zero is a common restriction. For example, 3 is not allowed in the function f(x) = 4 / x - 3. Square roots can also cause functions to break, e.g. g(x) = the square root of 2x - 5 >= 0 -> x >= 5/2. However, powers are fine, such as h(x) = x2 + 1.
When stating the domain, you can use either words or symbols. Make sure you are clear, such as "all real numbers except 3".
Range
The range is all the outputs from a function. To calculate this, you need to find what outputs are possible after the domain has given the input restrictions. For instance:
- h(x) = x2 + 1 | The smallest value of x2 is 0. This means the smallest output is 1. You write the range as "y >= 1".
- f(x) = 4 / x - 3 | The outputs can be large or small, but not 0. The range is "y does not equal 0".
- g(x) | The square root of 2x - 5 with x >= 5 / 2 means that square roots are >= 0. This range is "y >= 0".
If you're struggling to find all the possible inputs, start by finding the domain. This will remove impossible moves, such as dividing by zero. Next, try to find the smallest/largest output possible to get a starting point. If you're using a graph, read the domain from the x-axis and the range from the y-axis.
These are two further examples:
- p(x) = 2 / x | The domain is "x does not equal 0". The range is "y does not equal 0".
- q(x) | The square root of x + 4 - 3 needs x + 4 >= 0 -> x >= -4. The outputs are ">= 3" because the square root of x + 4 >= 0. The range is "y >= -3".
Spot and evaluate a function
A rule is only a function when every input gives a single output. For instance, y = x2 is a function because every x gives one y. The function y = plus/minus the square root of x is not a function because each positive x returns two outputs. We can test against a vertical line on a graph: if the vertical line hits the curve more than once, it's not a function of x.
When you evaluate a function, follow these three steps:
- Write out the rule clearly with words or symbols.
- Bracket the input whenever you see x. This helps us to stop sign mistakes and lost terms.
- Finish by simplifying carefully.
For example:
- Number input | The function is f(x) = 2x + 1. We need to find f(-3). The calculation is 2(-3) + 1 = -6 + 1 = -5.
- Algebra input | The function is f(x) = x2 - 3x. We need to find f(2k - 1). The calculation is (2k - 1)2 - 3(2k - 1) = 4k2 - 4k + 1 - 6k + 3 = 4k2 - 10k + 4.
1
What is the range of f(x) = x2 - 4?
2
Which rule is a function of x for real numbers?
Function notation
The brackets can make functions appear more confusing than they are. The f(x) is just the name of the rule and means "f of x". When you see f(3), this means you apply the rule to 3.
When you need to substitute, place a bracket around the input when you see x. Then you can simplify. For example:
- Number input | The function is f(x) = 2x + 1. We need to find f(-3). The calculation is 2(-3) + 1 = -6 + 1 = -5.
- Algebra input | The function is g(x) = x2 - 3x. We need to find g(2k-1). The calculation is (2k - 1)2 - 3(2k - 1) = 4k2 - 10k + 4.
When there is a denominator in the rule, check that your input won't turn it into zero. Similarly, if there's a square root, the input must be >= 0 for real answers.
3
What is f(2m + 1) when the function is f(x) = 3x - 4?
Composite functions
A composite function is when you do one rule and then another. You combine two or more functions, and the output of one serves as the input for the next. It is normally written as f(g(x)) or g(f(x)):
- f(g(x)) | Use the g function first on x and then apply the result to the f function.
- g(f(x)) | Start with the f function and then move on to the g function.
When tackling a compose function, start by writing the inside outside. If you need f(g(x)), start with g(x). Replace carefully and use brackets to place the entire expression inside the other rule. Finally, simplify the expression. Only expand or cancel if necessary.
Let's apply the composite function f(x) = 2x + 1 and g(x) = x2 - 3 to these examples:
- Number example | We need to find f(g(4)). The calculation is f(42 - 3) = f(13) = 2 * 13 + 1 = 27.
- Number example | We need to find g(f(4)). The calculation is g(2 * 4 + 1) = g(9) = 92 - 3 = 78.
- Algebra example | We need to find f(g(x)). The calculation is f(x2 - 3) = 2(x2 - 3) + 1 = 2x2 - 5.
- Algebra example | We need to find g(f(x)). The calculation is g(2x + 1) = (2x + 1)2 - 3 = 4x2 + 4x - 2.
The composite function is only valid if every step makes sense. For instance, let's use the function p(x) = 6 / x - 2, q(x) = the square root of x. The domain is "real values only":
- q(p(x)) = q(6 / x - 2) = y equals the square root of six divided by x minus two. The conditions are that x is not equal to 2 and 6 / x6 - 2 >= 0 -> x > 2.
- p(q(x)) = p(the square root of x) = 6 / the square root of x - 2. The conditions are that x >= 0 and the square root of x is not equal to 2 -> x >= 0, x is not equal to 4.
As we can see, if we reverse the order in which we apply the same functions, the result is different, and the allowed inputs change.
It's easy to make a mistake with composite functions. Double-check the following during and after your calculations:
- Always start with the inside function. It's a good idea to start by circling the inner function.
- Make sure you don't drop the brackets. Always place the first expression inside brackets to maintain the structure.
- Never ignore the conditions given. Check if the input is allowed after each step.
4
The function is f(x) = 3x - 2 and g(x) = the square root of x+5. The condition is "real values only". What is fg(x). What x is it defined for?
Inverse functions
An inverse function means to reverse a function. If f turns x into y, then f-1 will turn y back into x. You can write f-1(x) in notation as "f inverse of x".
A function must be one-to-one on its domain. This means each input will return a specific output and, in the same way, each output comes from one input. If the function isn't one-to-one, we need to restrict the domain for inversion to work.
Take the following steps to invert:
- Write y = f(x).
- Swap x and y.
- Solve for y and rename y as f-1(x).
Inverse functions examples
- Linear | The function is f(x) = 3x - 5. First, we write y = 3x - 5. Then we swap x and y: x = 3y - 5. The calculation is 3y = x + 5 -> y = x + 5 / 3. This means f-1(x) = x + 5 / 3. As an extra step, we can check the calculation: f(f-1(x)) = 3 times x+5 / 3 - 5 = x.
- Fractional | The function is g(x) = 2x + 1 / 5. We begin by writing y = 2x5 + 1 / 5. Then we swap x and y: x = 2y5 + 1 / 5. The calculation is 5x = 2y + 1 - > 2y = 5x - 1 -> y = 5x - 1 / 2. This means g-1(x) = 5x - 1 / 2.
- Squared with a restriction | The function is h(x) = x2. This isn't a one-to-one function, so we need to add restrictions. We start by setting the domain as "x >= 0". Then we write y=x2 and swap x for y: x=y2. The calculation is y = the square root of x. We need to choose the positive root because the domain specifies that x >= 0. This means h-1(x) = the square root of x for x >= 0.
5
What is the correct inverse of f(x) = x - 4 / 3?
Evaluating functions
When you see a function, such as f(3) or g(2k - 1), you need to keep the process methodical. You are essentially just feeding an input into a rule. These are the three steps to follow:
- Write the rule and keep it visible. For example, f(x) = 2x2 - 3x + 4.
- Bracket the input everywhere you see x in a bracket.
- Simplify line by line.
Here are some final examples with different input types:
- Number input | The function is f(x) = 2x2 - 3x + 4. We need to find f(-3). The calculation is f(-3) = 2(-3)2 - 3(-3) + 4 = 2 times 9 + 9 + 4 = 31.
- Algebraic inputs | The function is g(x) = x2 - 5x. We need to find g(2k+1). The calculation is g(2k+1) = (2k+1)2 - 5(2k+1) = 4k2 + 4k + 1 - 10k - 5 = 4k2 - 6k - 4.
- Fractions and roots | The function is h(x) = 6 / x - 2. This means h(2) is not defined (division by zero).
Always do final checks to avoid mistakes. Make sure you used brackets for each input. Did you substitute every time the x appears? Finally, is the result allowed or is it restricted by the domain, e.g. no division by zero, or no negative under a square root.
6
What is f(3m-2) when the function is f(x) = x2 - 4x + 7?
Final thoughts on Functions - GCSE Maths Revision
Reducing a function down to a rule helps to remove the fear-factor. An input goes in and a single output comes out. Remember to read the notation carefully, especially the domain for input restrictions, and keep using brackets when you substitute. When working with composites, always start with the inner function, and remember that switching the order will change the outputs. We have also seen how an inverse effectively reverses what a function does.
For further reading, ThirdSpaceLearning has an article on graph transformations, including translations and reflections on the graph of a function. You can also test your understanding with past paper questions on functions by MathsGenie.
If you need help learning this topic, TeachTutti has verified GCSE Maths tutors. Tutors will tailor lessons to your specific needs, such as running through exam questions.
Glossary
- Function - A rule that returns a single output from a given input. It can be compared to a vending machine: you put in x, and you get out f(x).
- Input - This is the value (x) you put into the function. It can be a number or an algebraic expression.
- Output - The result after applying the rule. If the rule is f(x) = 2x + 1 and the input is 3, the output is f(3) = 7.
- Evaluate/Substitute - Replace every x in brackets with the input. Then you simplify in stages to avoid sign or expansion errors.
- Domain - The inputs that are permitted. Certain values have to be omitted as they break the function. For example, x not equal to 2 is a domain for 1 / x - 2.
- Range - All the possible outputs that a function can make from the permitted inputs.
- Restriction - A limitation on the possible inputs so that a function is valid or can be inverted.
- Inverse function - f is reversed on the allowed values.
- Composite function - One function is carried out, followed by the next. There can be more than 2 functions. The order changes the expression and possibly also the domain.
- Vertical line test - Place a vertical line on a graph. If it hits the curve more than once, the rule is not a function of x.
- Function machine - A picture idea to check every input gives a single output: input -> rule -> output.