Linear Functions
Recognise a linear function and state and , tell from a table of values whether a function is linear, find its rule, and use linear functions in real settings, forwards and backwards.
Before you start
- A function machine applies the same rule to every input and gives exactly one output. The machine "multiply by , then subtract " turns the input into the output : the input gives .
- A table of values has the values of in its first row and the corresponding values of in its second. Each column gives an ordered pair , first. For , the values , and give the pairs , and , and these points lie on a straight line. Plotted points are joined only when the values in between make sense and the quantity changes steadily, not for a whole number of things such as people or trips.
- To substitute a negative number, put it in brackets: if , then .
- To solve an equation, do the same to both sides: from , subtract to get , then divide by to get .
Linear Functions
The functions , and have the same form: the variable is multiplied by a number (in the number is ), and a number is added (here , and ). Their points lie on straight lines. A function of this form is called a linear function.
Linear function
A linear function is a function that can be written in the form , where and are numbers.
is the coefficient of (the number multiplying ) and is the constant term (the number on its own). Each may be positive, negative or zero.
When can take every value, the graph of a linear function is a straight line; when can only be a whole number (pens, trips, T-shirts), its points lie on a straight line and are not joined.
Examples: has and . has and , since means . has and . has and , since it is .
Not linear: , because is squared, and , because a number is divided by . Their points do not lie on a straight line. The grid shows the points of and of for , , and .
A function machine whose steps are "multiply by a number", then "add or subtract a number", is a linear function: "multiply by , then subtract " is , with and .
Example 1: Linear or Not?
Which of these are linear functions? For each linear one, state and .
(a) (b) (c) (d)
Solution
(a) is . Linear, with and : the sign in front of a number belongs to it.
(b) has squared. Not linear.
(c) can be written as . Linear, with and : every value of gives .
(d) can be written as . Linear, with and .
(a), (c) and (d) are linear, with , ; , ; and , . (b) is not linear.
Example 2: Writing a Function in the Form y = ax + b
Write each function in the form , and state and .
(a) (b) (c)
Solution
(a) The term in is , so can be written as . So and (not ).
(b) is divided by , which is of . So can be written as , and , . Here is divided by a number, which is allowed; in a number is divided by , which is not linear.
(c) Expand the brackets: . So can be written as , and , .
(a) : , . (b) : , . (c) : , .
Linear or Not from a Table, and Finding the Rule
For , each time goes up by , goes up by (, , , ): the steps in are equal, and the points lie on a straight line. For the steps in are , and (, , , ): they are not equal, and the points do not lie on a straight line. This gives a test that needs no graph.
Linear or not, and the rule, from a table
When the values of in a table go up in equal steps, look at the steps in . If changes by the same amount at every step (up, down, or not at all), the pairs belong to a linear function and their points lie on a straight line. If not, the function is not linear.
To find the rule when goes up by at each step: is the change in at each step (negative if goes down), and is the value of when .
If goes up in equal steps of another size (such as or ), is the change in at each step divided by the change in (for steps of in and in , ).
Then check the rule with every column of the table.
Why is the value of when : substituting into gives . If the table has no column for , substitute any column into and solve for .
Example 3: Is the Table Linear?
Is each table linear? Give a reason.
(a)
| 0 | 1 | 2 | 3 | 4 | |
| 3 | 5 | 7 | 9 | 11 |
(b)
| 1 | 2 | 3 | 4 | 5 | |
| 1 | 4 | 9 | 16 | 25 |
(c)
| 1 | 2 | 3 | 4 | |
| 10 | 7 | 4 | 1 |
Solution
(a) goes up by each time, and goes up by , , and . Equal steps: linear.
(b) goes up by each time, and goes up by , , and . The steps are not equal: not linear.
(c) goes up by each time, and goes down by each time (a change of ). Equal steps: linear.
(a) and (c) are linear; (b) is not.
Example 4: Finding the Rule from a Table
Find the rule for each table.
(a)
| 0 | 1 | 2 | 3 | 4 | |
| 3 | 5 | 7 | 9 | 11 |
(b)
| 1 | 2 | 3 | 4 | |
| 10 | 7 | 4 | 1 |
(c)
| 2 | 4 | 6 | 8 | |
| 10 | 20 | 30 | 40 |
Solution
(a) goes up by for each step of in , so . When , , so . The rule is .
Check every column: , , ,
(b) goes down by for each step of in , so . There is no column for , so substitute the first column, and , into :
Add to both sides: . The rule is .
Check: , ,
(c) Here goes up by at each step, and goes up by . For each that goes up, goes up by , so . Substitute the first column, and : , so . The rule is .
Check: , ,
(a) (b) (c)
Linear Functions in Real Life
Many everyday charges are linear: a fixed charge, paid once, plus a charge for each unit used. The fixed charge is and the charge for each unit is .
A quantity that changes by the same amount in each minute or hour, such as the temperature of water heated steadily, is a linear function of the time too: is its value at the start and is its change in each unit of time.
Once the equation is written, it can be used forwards (substitute to find ) or backwards (substitute and solve the equation for ).
Example 5: Binding a Booklet
A printing shop in Bras Basah Complex charges $2 to bind a booklet and $0.10 for each page printed. The cost of a booklet of pages is dollars.
(a) Write a formula for in terms of , and say what and stand for.
(b) Find the cost of a booklet of pages.
(c) Priya paid $9.50 for her booklet. How many pages did it have?
Solution
(a) For pages the charge is dollars, and the binding charge of $2 is added once: .
This is a linear function with , the charge in dollars for each page, and , the binding charge in dollars, paid once whatever the number of pages.
(b) Forwards: substitute .
(c) Backwards: substitute and solve.
Subtract from both sides:
Divide both sides by :
Check:
(a) . (b) A booklet of pages costs $14. (c) Priya's booklet had pages.
Example 6: Heating Water
In a Science lesson, Mei Ling heats a beaker of water and records its temperature every minutes.
| Time, (minutes) | 2 | 4 | 6 | 8 |
|---|---|---|---|---|
| Temperature, (°C) | 31 | 37 | 43 | 49 |
(a) Show that is a linear function of , and find the formula .
(b) Say what and stand for.
(c) If the water keeps heating at the same rate, after how many minutes will it reach °C?
Solution
(a) goes up by at each step, and goes up by each time: equal steps, so is a linear function of .
For each minute, goes up by , so .
There is no column for , so substitute the first column, and , into :
Subtract from both sides: . The formula is .
Check: , ,
(b) : the temperature rises by °C every minute. : the temperature at the start, when , was °C.
(c) Backwards: substitute and solve.
Subtract from both sides:
Divide both sides by : .
Check:
The formula holds only while the water heats at the same rate; it cannot be used beyond °C, where water boils.
(a) . (b) The temperature rises by °C each minute, from °C at the start. (c) After minutes.
Common Mistakes
- Taking to be the first number written. In , is (the number multiplying , with its sign) and is .
- Dropping the sign of . is , so , not .
- Forgetting the number that is not written. In , ; in , ; in , .
- Calling linear because it looks like . Dividing by a number is linear; dividing a number by is not.
- Taking the step in as when goes up by more than . If goes up by and by , then , not .
- Checking a rule with only one or two columns of a table. The rule must fit every column.
- In a setting, adding a fixed charge for every unit. A binding charge or a hire company's fixed charge is paid once: it is , not part of .
Practice Questions
Try each question on your own before you open its solution. The questions get harder as you go.
Question 1
State and for each linear function.
(a) (b) (c)
(d) (e)
ShowHide solution
(a) and .
(b) is : and .
(c) and .
(d) is : and .
(e) is , and is added: and .
(a) , (b) , (c) , (d) , (e) ,
Question 2
Which of these are linear functions? For each linear one, write it in the form and state and .
(a) (b) (c)
(d) (e) (f)
ShowHide solution
(a) : linear, with and .
(b) : linear, with and .
(c) Expand the brackets: , so : linear, with and .
(d) : linear, with and .
(e) is divided by : not linear.
(f) is squared: not linear.
(a), (b), (c) and (d) are linear; (e) and (f) are not.
Question 3
Write the rule of each function machine as an equation in the form , and state and .
(a)
(b)
(c) "Subtract the input from , then divide by ."
(d) Find the output of machine (a) and of machine (b) when the input is . Does the order of the steps matter?
ShowHide solution
(a) Multiply by : . Then add : . So and .
(b) Add to : . Then multiply by : . Expand the brackets: . So and .
(c) Subtract from : . Then divide by , which is the same as multiplying by : . Expand the bracket: , which can be written as . So and .
Check (c) with the input : , then ; and
(d) Machine (a): . Machine (b): , then . The outputs are different, so the order of the steps matters.
(a) : , . (b) : , . (c) : , . (d) and : the order matters.
Question 4
(a) Copy and complete the table of values for .
| −2 | −1 | 0 | 1 | 2 | |
| ? | ? | ? | ? | ? |
(b) By how much does change each time goes up by ? Compare it with .
(c) What is the value of when ? Compare it with .
ShowHide solution
(a) :
:
:
: ; :
| −2 | −1 | 0 | 1 | 2 | |
| 9 | 5 | 1 | −3 | −7 |
(b) goes down by each time: a change of , which is .
(c) when , which is .
(a) , , , , . (b) A change of , the same as . (c) , the same as .
Question 5
For each table, say whether it is linear. If it is, find its rule .
(a)
| 0 | 1 | 2 | 3 | 4 | |
| −4 | −1 | 2 | 5 | 8 |
(b)
| 1 | 2 | 3 | 4 | |
| 2 | 5 | 10 | 17 |
ShowHide solution
(a) goes up by each time and goes up by each time: linear, with . When , , so . The rule is .
Check every column: , , ,
(b) goes up by each time, but goes up by , and : the steps are not equal, so it is not linear.
(a) Linear: . (b) Not linear.
Question 6
Find the rule for each table.
(a)
| −2 | −1 | 0 | 1 | 2 | |
| 9 | 7 | 5 | 3 | 1 |
(b)
| 1 | 3 | 5 | 7 | |
| 4 | 10 | 16 | 22 |
ShowHide solution
(a) goes up by and goes down by each time, so . When , , so . The rule is .
Check: , , ,
(b) Here goes up by each time and goes up by . For each that goes up, goes up by , so .
There is no column for , so substitute the first column, and , into :
Subtract from both sides: . The rule is .
Check: , ,
(a) (b)
Question 7
The table belongs to a linear function, but three of its values of are missing.
| 0 | 1 | 2 | 3 | 4 | |
| ? | 7 | ? | 15 | ? |
(a) Find the rule .
(b) Complete the table.
ShowHide solution
(a) From to , goes up by and goes up from to , by . For each that goes up, goes up by , so .
Substitute and into : , so . The rule is .
Check with the other given column:
(b) : . : . : .
| 0 | 1 | 2 | 3 | 4 | |
| 3 | 7 | 11 | 15 | 19 |
The steps in are all : , , , ,
(a) . (b) The missing values are , and .
Question 8 (Setting: Bicycle Hire at East Coast Park)
At a bicycle kiosk in East Coast Park, hiring a bicycle costs a fixed charge of $4 plus $6 for each hour. The cost of hiring a bicycle for hours is dollars.
(a) Write a formula for in terms of .
(b) Find the cost of hiring a bicycle for hours.
(c) Wei Ming paid $34. For how many hours did he hire his bicycle?
ShowHide solution
(a) hours at $6 an hour cost dollars, and the fixed charge of $4 is added once: .
(b) Substitute :
(c) Substitute and solve:
Subtract from both sides:
Divide both sides by : .
Check:
(a) . (b) $22. (c) Wei Ming hired the bicycle for hours.
Question 9 (Setting: A New Freezer)
A new freezer in an air-conditioned shop is switched on. For the first hours, the temperature inside it, °C, hours after it is switched on is given by .
(a) State and for this linear function, and say what each means.
(b) Make a table of values for and . Plot the pairs , and say whether the points should be joined.
(c) What is the temperature after hours?
(d) After how many hours is the temperature °C?
ShowHide solution
(a) can be written as , so and .
: the temperature is °C when the freezer is switched on (). : the temperature falls by °C every hour.
(b) : . : . Each hour after that the temperature is °C lower.
| Time, (hours) | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 |
|---|---|---|---|---|---|---|---|---|---|
| Temperature, (°C) | 24 | 20 | 16 | 12 | 8 | 4 | 0 | −4 | −8 |
One square across stands for hour and one square up for °C.
The points lie on a straight line going down. Time and temperature take every value in between the readings, and the temperature falls steadily, so the points are joined.
(c)
(d) Substitute and solve:
Add to both sides:
Add to both sides:
Divide both sides by : .
Check:
(a) (the temperature falls °C each hour) and (it starts at °C). (b) The points lie on a straight line and are joined. (c) °C. (d) After hours.
Question 10 (Setting: Class T-shirts)
Class 1A is ordering printed T-shirts for Sports Day. The printing shop sends this table of prices.
| Number of T-shirts, | 10 | 20 | 30 | 40 |
|---|---|---|---|---|
| Cost, ($) | 130 | 230 | 330 | 430 |
(a) Show that is a linear function of , and find the formula .
(b) What do and stand for?
(c) Find the cost of T-shirts.
(d) The class has $500 to spend. How many T-shirts can it order for exactly that amount?
ShowHide solution
(a) goes up by at each step and goes up by each time: equal steps, so is a linear function of .
For each extra T-shirt, goes up by , so .
Substitute the first column, and , into :
Subtract from both sides: . The formula is .
Check: , ,
(b) : each T-shirt costs $10. : a fixed charge of $30, paid once for the order, however many T-shirts there are.
(c)
(d) Substitute and solve:
Subtract from both sides:
Divide both sides by : .
Check:
(a) . (b) $10 for each T-shirt, plus a fixed charge of $30. (c) $380. (d) T-shirts.
Question 11 (Setting: An EZ-Link Card)
Mei Ling has $30 on her EZ-Link card, and each of her bus trips costs $1.50. After trips, the amount left on the card is dollars.
(a) Write a formula for in terms of , and state and .
(b) How much is left after trips?
(c) After how many trips is $12 left?
(d) Can the amount left ever be exactly $20.50? Explain.
(e) If the pairs were plotted, should the points be joined?
ShowHide solution
(a) Each trip takes $1.50 off the $30, so after trips dollars have been taken off: , which can be written as . So and .
(b) Substitute :
(c) Substitute and solve:
Add to both sides:
Subtract from both sides:
Divide both sides by : .
Check:
(d) Substitute : gives , so .
A number of trips must be a whole number, so the amount left can never be exactly $20.50. After trips $21 is left, and after trips $19.50.
(e) No. A number of trips is a whole number, so there is nothing to draw between the points.
(a) , with and . (b) $18. (c) After trips. (d) No: it would need trips. (e) No.
Question 12 (Setting: Choosing a Phone Plan)
Priya is choosing between two mobile phone plans. Plan A costs $15 a month plus $2 for each GB of data used. Plan B costs $9 a month plus $3 for each GB of data used. In a month in which she uses GB, Plan A costs dollars and Plan B costs dollars.
(a) Write a formula for and a formula for in terms of .
(b) Which plan is cheaper in a month in which she uses GB?
(c) For how many GB do the two plans cost the same?
(d) Priya usually uses GB a month. Which plan should she choose, and how much does she save each month?
ShowHide solution
(a) The fixed monthly charge is added once and the charge for data is paid for each GB: and .
(b) Substitute : and . Plan B is cheaper, by $2.
(c) The plans cost the same when :
Subtract from both sides:
Subtract from both sides: .
Check: and Both plans cost $27 for GB.
(d) Substitute : and . Plan A is cheaper: she saves $39 − $35 = $4 each month.
(a) and . (b) Plan B ($21, against $23 for Plan A). (c) GB. (d) Plan A, saving $4 a month.
Key Points
- A linear function can be written in the form , where and are numbers: is the coefficient of and is the constant term; either may be negative or zero.
- To state and , first write the function in the form : put the term in first, expand any brackets, and write as .
- A function is not linear when is squared or a number is divided by .
- When can take every value, the graph of a linear function is a straight line; when can only be a whole number (pens, trips, T-shirts), its points lie on a straight line and are not joined.
- When goes up in equal steps, a table is linear if changes by the same amount at every step.
- is the change in divided by the change in ; is the value of when , or is found by substituting a column and solving. Check the rule with every column.
- In a setting, is the fixed amount, paid once or present at the start, and is the amount for each unit; substitute to go forwards, and solve an equation to go backwards.