Writing Expressions and Formulae
On this page
How to turn words into algebra: writing expressions with the operations in the right order, using brackets for a whole group, and writing formulae for costs, totals and perimeters.
Letters stand for numbers
In algebra, a letter stands for a number. The number might be unknown, or it might change. If a box holds n pens, n could be 10 one day and 25 the next.
This topic is about turning words into algebra. In the exam you are usually asked to “Write down an expression, in terms of x, for …”, for 1 or 2 marks. Harder questions ask you to write a formula for a total, for up to 3 marks.
“In terms of x” means your answer must use the letter x. Do not choose a number for x and work out an answer.
Expression or formula
An expression is made from numbers, letters and operations, such as 3n+5. It has no equals sign.
A formula is a rule that links letters. It starts with the letter you are finding and an equals sign:
C=3n+5
Here C is the total cost in pounds and n is the number of items bought.
Read the question carefully. If it asks for an expression, write only the expression. If it asks for a formula for C, you must start with C= and then the expression.
Words that tell you what to do
- Add: more than, plus, increase by, the total of.
- Subtract: less than, fewer than, take away, decrease by.
- Multiply: times, twice, each, per, for every.
- Divide: share equally, cut into equal pieces, half of.
In algebra, 4n means 4\times n. Write the number in front of the letter and leave out the times sign. Twice n means 2\times n, which is 2n. It is not n^2, which means n\times n.
Order matters when you subtract or divide. “Subtract t from 12” means start with 12 and take t away, so it is 12-t, not t-12. “Share p equally between 5 people” is p\div5, which is written as \frac{p}{5}
Worked example 1: Turning words into algebra
Write down an expression for 7 more than x, for 7 less than x and for 7 times x.
- “More than” means add: x+7
-
Your turn. Write down an expression for 7 less than x.
“Less than” means subtract 7 from x: x-7
- “Times” means multiply. 7\times x is written as 7x, with the number first.
- Answer: x+7, x-7 and 7x
Worked example 2: Which way round?
A pencil is p cm long. The pencil is 6 cm longer than a crayon. Write down an expression, in terms of p, for the length of the crayon in centimetres.
- The pencil is the longer one. So the crayon is 6 cm shorter than the pencil.
-
Your turn. Write down an expression, in terms of p, for the length of the crayon.
Shorter means subtract 6 from the pencil’s length: p-6
- Check with a number. If p=15, the crayon is 15-6=9 cm long, which is shorter than the pencil, as it should be.
- Answer: p-6
Use brackets for a whole group
When an instruction acts on a whole sum, put the sum in brackets. “Add 6 to x, then double the result” is 2(x+6), because all of x+6 is doubled.
“Double x, then add 6” is 2x+6. The same words in a different order give a different expression.
A fraction line works like a bracket. “Take 2 from k, then divide by 5” is \frac{k-2}{5}, because all of k-2 is divided. To type it, use (k-2)/5
Worked example 3: A two-step number machine
Here is a number machine. The input is n. The machine adds 5, then multiplies by 3. Write an expression, in terms of n, for the output.
- Follow the boxes in order. After the first box, the input n has become n+5
- The second box multiplies the whole of n+5 by 3, so n+5 goes in a bracket.
-
Your turn. Write an expression, in terms of n, for the output.
Output: 3(n+5)
- Check with n=2. The machine gives 2+5=7, then 7\times3=21, and 3(2+5)=21 too
- Answer: 3(n+5)
Worked example 4: A formula for a cost
A plumber charges £35 to come out, plus £20 for each hour she works. She works for h hours. The total charge is £C. Write a formula for C in terms of h. Then work out the charge for a job that takes 3 hours.
- Each hour costs £20, so h hours cost 20\times h=20h pounds.
- The £35 to come out is paid once, so it is added on once. It is not multiplied by h.
-
Your turn. Write a formula for C in terms of h. Start with C=
C=20h+35
-
Your turn. Work out C when h=3.
C=20\times3+35=60+35=95
- Answer: C=20h+35, and a 3-hour job costs \pounds 95
Expressions from shapes
Perimeter is the distance all the way round a shape. To write it as an expression, add the lengths of all the sides, then collect like terms.
This rectangle has two sides of x+5 and two sides of x:
x+5+x+x+5+x=4x+10
There are four lots of x and two lots of 5. So the perimeter is 4x+10 centimetres.
Do not multiply the length by the width. That gives the area, not the perimeter.
Worked example 5: Collecting the numbers
Leah has £50 in a money box. She puts in £6 every week for w weeks. Then she takes out £20 to buy a present. She now has £S in the money box. Write a formula for S in terms of w. Give your formula as simply as possible.
- She puts in £6 each week, so in w weeks she puts in 6\times w=6w pounds.
- Start with the £50, add the 6w pounds, then take away the £20: S=50+6w-20
-
Your turn. Write the formula for S as simply as possible.
50-20=30, so S=6w+30
- Check with w=5. Leah puts in 6\times5=30 pounds, so she has 50+30-20=60 pounds, and 6\times5+30=60
- Answer: S=6w+30
Worked example 6: A formula with two letters
A sports club has £200. It buys f footballs at £9 each and b bibs at £4 each. The club then has £M left. Write a formula for M in terms of f and b.
- The footballs cost 9\times f=9f pounds and the bibs cost 4\times b=4b pounds.
- Both amounts are spent from the £200, so start with 200 and take each amount away.
-
Your turn. Write a formula for M in terms of f and b.
M=200-9f-4b
- 9f and 4b are not like terms, so this cannot be simplified. Writing 200-13fb would be wrong.
- Check with f=10 and b=5. The club spends 90+20=110 pounds, so it has 200-110=90 pounds left, and 200-9\times10-4\times5=90
- Answer: M=200-9f-4b
Common mistakes
- Leaving out the number in each. If a football costs £9, then f footballs cost 9f pounds, not f pounds.
- Adding unlike terms together. 9f+4b cannot be simplified, so do not write 13fb.
- Mixing up an expression and a formula. An expression is just the algebra. A formula for T must begin T=
- Subtracting the wrong way round. If a sofa costs £x and is £40 more than a chair, the chair costs x-40, not x+40 or 40-x.
- Squaring instead of doubling. Twice x is 2x, not x^2.
- Giving a number instead of an expression. “In terms of x” means the letter x must be in your answer.
More on this topic: Writing Expressions and Formulae worksheet with full solutions