Algebra · Chapter 20

Function Machine and Inverse

A function is a machine: one number in, one number out. Run it backward by undoing each step in reverse order.

Home › Calculators › Function Machine and Inverse

Opens on Chapter 20’s example: the machine “× 2, then + 1”, with 3 going in.

The machine: × m, then + b
A rule from a table
Two changes in a row: does the order matter?
Enter your numbers, then press Work it out.

How it works

f(x) = mx + b runs two steps: multiply, then add. The inverse undoes them in reverse order: take away b, then divide by m (doing it the other way around gives the wrong input). From a table, the step size between outputs (when the input goes up by 1) is m, and the output at input 0 is b. Two percentage changes multiply, so their order doesn’t matter: 20% off then 8% tax is the same as tax then 20% off. A coupon takes away a fixed amount, which does depend on the order: taking it off before the tax saves the tax on it too.

From the book, Chapter 20. × 2 then + 1 sends 3 to 7 and 10 to 21; the input that gives 15 is 7. The table 5, 8, 11, 14 predicts 32 at 10, and the parking garage charges $32 for ten hours. Run backward, Sanjay’s price turns $60 into 120 sheets. 30°C goes to 86°F and 86°F back to 30. $50 with 20% off and 8% tax is $43.20 either way; a $5 coupon gives $48.60 before tax but $49.00 after, $0.40 apart. Every chapter and its calculator →

Numbers can be typed as 1,450, $38, 0.40, 12%, 1/6 or 2 3/8. The algebra is done with exact fractions, so 1/3 stays 1/3; decimals are rounded half up, the way the book rounds. Everything stays in your browser: no sign-up, nothing stored or sent.