A function machine in context is a real rule with an input, a few steps and an output. Name the input and output with their units first, then write the rule, then calculate. Finally check that the answer fits the situation.
This final lesson in functions and mappings uses everything from evaluating, composing, reversing and restricting.
How do you spot the machine in a word problem?
A courier charges RM6 for any parcel, plus RM2.50 for every kilogram. Parcels above 5 kg are not accepted.
- Input: weight w in kg.
- Steps: multiply by 2.5, then add 6.
- Output: charge in RM.
- Domain: 0 ≤ w ≤ 5.
The rule is f(w) = 6 + 2.5w.
Step by step
- Name the input and the output, with units.
- Write the rule in symbols.
- State the allowed inputs from the situation.
- Forward question: substitute the input.
- Backward question: set the rule equal to the output and solve.
- Check the answer against the domain and the units.
Worked example
Using f(w) = 6 + 2.5w for 0 ≤ w ≤ 5:
(a) Charge for 3.2 kg. f(3.2) = 6 + 2.5 × 3.2 = 6 + 8 = RM14.
(b) Weight for a charge of RM18.50. Solve 6 + 2.5w = 18.5. Subtract 6: 2.5w = 12.5. Divide by 2.5: w = 5 kg. This is on the boundary of the domain, so it is allowed.
(c) A 6% service tax is added to the charge. Let g(c) = 1.06c. For 3.2 kg, gf(3.2) = g(14) = 14 × 1.06 = RM14.84.
Check: 6% of 14 is 0.84, and 14 + 0.84 = 14.84. The weight in (b) is at most 5, so it is within the domain.
The mistake to watch for
A common slip when working backwards is to stop after subtracting the fixed charge.
Mistaken working: 18.50 = 6 + 2.5w, so w = 18.50 − 6 = 12.5 kg
The student subtracted 6 but forgot that 12.5 is the cost of the weight, not the weight.
The correct step is to divide by 2.5, giving w = 5. The units give it away: 12.5 is in RM, yet the question asked for kg, and 12.5 kg would be far outside the domain. Always check units and domain before writing the answer.
Check yourself
Use f(w) = 6 + 2.5w for 0 ≤ w ≤ 5.
1. Find the charge for a 4 kg parcel.
Show answer
f(4) = 6 + 2.5 × 4 = 6 + 10 = RM16.
2. A parcel is charged RM13. What does it weigh?
Show answer
6 + 2.5w = 13, so 2.5w = 7 and w = 7 ÷ 2.5 = 2.8 kg. Check: 6 + 2.5 × 2.8 = 6 + 7 = 13.
3. Could a parcel be charged RM21 under this service?
Show answer
6 + 2.5w = 21, so 2.5w = 15 and w = 6. Since 6 is greater than 5, this weight is not accepted. No, RM21 is not possible for any parcel the service takes.
Where this leads next
Try the whole module in the functions and mappings practice set. The function composition and inverse explorer lets you test a context rule with different inputs, and the non-calculator working trainer helps with the arithmetic.
If word problems are where your marks slip, our teachers can work through them with you in online one-to-one Mathematics tuition.