GoalDecompose a big problem, with or without a computer, into sub-problems that can be solved one at a time.
New words
decomposition · breaking a big problem into smaller parts that are easier to solvesub-problem · one of the smaller parts; it can often be split againsingle step · one small action that cannot sensibly be split any further
Explanation
Big problems are hard to solve all at once. Decomposition means breaking a problem into smaller parts called sub-problems. Each sub-problem can be solved on its own, and it may be split again if it is still big. A sub-problem is not the same as a single step. “Choose the teams” is a sub-problem, because it needs several steps. “Pick up the pencil” is only a step. It works for jobs with no computer, like organising an event, and for programs. There is more than one correct way to decompose a problem. Two people may split the same job in different ways, and both can be right if every part of the job is covered.
Worked examples
A second decomposition tree for a job with no computer. The big problem is at the top, the sub-problems are below it, and each one is split again until the pieces are easy to do. Together the three branches cover the whole job.
A programming problem: a price calculator for a bike-hire stall. A programmer could split it into getting the information, working out the price, and showing the result. Each part can be written and tested separately.
Split by order
Split by person
plan the layout
Mia: all the writing
write the text
Kofi: all the drawings
draw the pictures
Lena: layout and colours
put it together
everyone: checking
Two different decompositions of “make a class poster” are both correct. One splits by order of work, the other by who does what. Both cover everything.
Class activity
Sticky notes (no computer). Write a big job on a card, for example “organise a family picnic” or “make a school newsletter”. Write each sub-problem on its own small piece of paper and put them under the job. Split any piece that still seems too big, until a single person could do it in one go. Compare your tree with a partner’s. How are they different? Are both correct? Make sure that nothing is missing, and that nothing is just a single step at the top. If you have a computer or tablet, ask an adult to help you draw the tree in a drawing program.
Practice
1
Decompose “make a class newspaper” into three sub-problems, and split one of them again.
Possible answer: write the articles, take or draw the pictures, and lay out the pages. The articles can be split into choosing topics and writing each one. Other correct answers are possible if the whole job is covered.
2
Which of these is a sub-problem and which is a single step? (a) sort the books by subject; (b) pick up one book; (c) design the sports-day certificates; (d) write the pupil’s name on one certificate.
Job
Sub-problem or single step?
(a) sort the books by subject
?
(b) pick up one book
?
(c) design the sports-day certificates
?
(d) write one name on one certificate
?
(a) and (c) are sub-problems, because each needs many steps and can be split. (b) and (d) are single steps.
3
A program asks for two numbers, adds them and shows the answer with a message. Split it into three sub-problems.
For example: get the two numbers, work out the sum, show the message. Another correct answer would be to add a check that the input is a number.
4
A pupil says, “There is only one right way to decompose a problem.” Do you agree? Explain.
No. Different people can split a problem in different ways, for example by order or by person. A decomposition is correct when every part of the job is covered and the sub-problems are not just single steps.