Functions and Machines
Section: Algebra | Syllabus: Cambridge Lower Secondary Checkpoint Mathematics (0862)
What is a Function?
A function is a rule connecting an input to an output, where each input produces exactly one output. A function machine is a diagram showing this rule as a series of operations the input passes through.
- Input: the starting value that goes into the function.
- Output: the value that comes out after the rule is applied.
- Each input must give exactly one output - this is what makes a rule a function.
- A function can be shown as a function machine, an equation, or a mapping diagram (arrows connecting each input directly to its output).
Function Machines: Single Operation
-
Question: A function machine is "×3". Find the output when the input is 7.
- Step 1: 7 × 3 = 21
- Answer: Output = 21
Function Machines: Two-Step
Many function machines apply two operations in sequence - work through them in order, left to right.
Working forwards through "×2, then +5", and working backwards using inverse operations
-
Question: A function machine is "×2, then +5". Find the output when the input is 4.
- Step 1: 4 × 2 = 8
- Step 2: 8 + 5 = 13
- Answer: Output = 13
Finding Outputs from a Function
A function can also be written using algebraic notation, such as f(x) = 3x − 4, meaning "the function f, applied to x". To find an output, substitute the input in place of x.
-
Question: f(x) = 3x − 4. Find f(5).
- Step 1: Substitute x = 5: f(5) = 3(5) − 4
- Answer: f(5) = 11
-
Question: f(x) = x² + 1. Find f(4).
- Step 1: Substitute x = 4: f(4) = 4² + 1 = 16 + 1
- Answer: f(4) = 17
Finding Inputs Using Inverse Operations
To work out an input from a given output, reverse the function: apply the inverse of each operation, in the opposite order - undoing the last step first.
| Operation | Inverse Operation |
|---|---|
| + a | − a |
| − a | + a |
| × a | ÷ a |
| ÷ a | × a |
| square (²) | square root (√) |
| cube (³) | cube root (∛) |
-
Question: A function machine is "×4, then +3". If the output is 23, find the input.
- Step 1: Undo the last step first - subtract 3: 23 − 3 = 20
- Step 2: Undo the first step - divide by 4: 20 ÷ 4 = 5
- Check: 5 × 4 + 3 = 23 ✓
- Answer: Input = 5
-
Question: A function machine is "square the input, then subtract 5". If the output is 20, find the input (take the positive value).
- Step 1: Undo the last step - add 5: 20 + 5 = 25
- Step 2: Undo the squaring - take the square root: √25 = 5
- Check: 5² − 5 = 25 − 5 = 20 ✓
- Answer: Input = 5
-
Question: A function machine is "cube the input, then add 2". If the output is 66, find the input.
- Step 1: Undo the last step - subtract 2: 66 − 2 = 64
- Step 2: Undo the cubing - take the cube root: ∛64 = 4
- Check: 4³ + 2 = 64 + 2 = 66 ✓
- Answer: Input = 4
Mapping Diagrams
A mapping diagram shows a function as two ovals - inputs on the left, outputs on the right - joined by arrows. Missing values can be found by applying the function forwards, or by reversing it, and the same pattern can be generalised to any input, n.
A mapping diagram for the function "×3, then +4"
-
Question: The mapping diagram shows the function "×3, then +4". The inputs 2, 5 and 8 are shown, along with an unknown input whose output is 40. Find the output for input 8, find the unknown input, and write the general rule linking any input n to its output.
- Step 1 (forward): Input 8: 8 × 3 + 4 = 28
- Step 2 (backward): Output 40: undo +4 first (40 − 4 = 36), then undo ×3 (36 ÷ 3 = 12), so the input is 12
- Step 3 (general rule): Replace the input with n: n × 3 + 4
- Answer: Input 8 → output 28; output 40 → input 12; general rule: n → 3n + 4
Function Machines and Their Reverse Equations
Instead of reversing a function machine for just one output value, the whole reverse process can be written as its own reverse equation - useful for finding any input quickly.
-
Question: A function machine is "×2, then square". Write its equation, then find the reverse equation.
- Step 1 (equation): y = (2x)²
- Step 2 (reverse): take the square root, then divide by 2: x = √y ÷ 2
- Check: if x = 5, y = (2×5)² = 100. Reversed: √100 ÷ 2 = 10 ÷ 2 = 5 ✓
- Answer: y = (2x)², reverse equation x = √y ÷ 2
-
Question: A function machine is "subtract 1, then cube". Write its equation, then find the reverse equation.
- Step 1 (equation): y = (x − 1)³
- Step 2 (reverse): take the cube root, then add 1: x = ∛y + 1
- Check: if x = 5, y = (5−1)³ = 64. Reversed: ∛64 + 1 = 4 + 1 = 5 ✓
- Answer: y = (x − 1)³, reverse equation x = ∛y + 1
Real-World Applications
Functions and function machines model many everyday processes:
- Currency conversion: multiplying by an exchange rate.
- Temperature conversion: formulas linking °C and °F.
- Vending and ticket machines: literal input-process-output systems.
- Pricing: total cost as a function of quantity bought.
- Working backwards from a bill: using inverse operations to find how many items were bought.
Exam Tips
Common Mistakes
MistakeApplying inverse operations in the same order as the original function
Fixwork backwards through the machine - undo the LAST operation first
MistakeReversing a step with the same operation instead of its inverse, e.g. undoing "+3" by adding 3 again
Fixuse the inverse operation to reverse each step: the inverse of +3 is −3
MistakeHalving a number to reverse a squaring step
Fixthe inverse of squaring is square rooting, not halving
MistakeSubstituting the output value into the original function to try to find the input
Fixto find an input from an output, reverse the function using inverse operations instead
MistakeReversing the operations but not their order, e.g. undoing ×4 before +3 in a "×4, then +3" machine
Fixreverse both the operations AND their order - undo the last step first, then the one before it
Interactive revision notes, videos and practice questions load below.