D1: Matchings (older papers) – Edexcel IAL Decision Mathematics (WDM1)

1 question · Clear filters

0 / 0Answer a question to start your score.
Quick quiz (10)Saved 0
Advertisement
1
WDM1 D1 · Oct/Nov 2020 · Question 2Oct/Nov 2020D127 marks
Loading question…
Question text

2.
(a) (i) Describe how to carry out the first pass of a bubble sort when it is used to sort a list of n
numbers into ascending order.
(ii) Write down the circumstances under which the bubble sort stops.
(4)
A bubble sort, starting at the left-hand end of the list, is used to sort a list of ten numbers into
ascending order. After a number of passes the list reads
0.9 1.2 1.5 0.5 1.4 1.1 0.7 1.7 2.2 3.2
(b) Determine the maximum number of passes that could have taken place on this list. You must
give a reason for your answer.
(2)
(c) Complete the bubble sort to produce a list of the numbers in ascending order. You only need to
give the state of the list after each complete pass.
(4)
(d) Use the first-fit decreasing bin packing algorithm to determine how the ten numbers listed
above can be packed into bins of size 4
(3)
(Total 13 marks)
3.
1
A
A
1
2
B
B
2
3
C
C
3
4
D
D
4
5
E
E
5
6
F
F
6
Figure 1
Figure 2
Figure 1 shows the possible allocations of six workers, A, B, C, D, E and F, to six .tasks, 1, 2, 3, 4,
5 and 6.
Figure 2 shows an initial matching.
(a) Starting from this initial matching, use the maximum matching algorithm to find an improved
matching. You should state the alternating path you use and list your improved matching.
(3)
(b) Explain why it is not possible to find a complete matching.
(1)
After training, task 1 is added to worker A’s possible allocations.
(c) Taking the improved matching found in (a) as the new initial matching, use the maximum
matching algorithm to find a complete matching. You should state the alternating path you use
and list your complete matching.
(3)
(Total 7 marks)
4.
(a) Draw the activity network described by the precedence table below, using activity on arc.
Use dummies only where necessary.
(5)
Activity
Immediately preceding activities
A
–
B
–
C
A
D
A, B
E
C, D
F
D
G
C
H
G
I
G
J
E, F, I
K
F
Given that K is a critical activity,
(b) state which other activities must also be critical.
(1)
Given instead that all activities shown in the precedence table have the same duration and K is not
necessarily critical,
(c) state the critical path for the network.
(1)
(Total 7 marks)

Advertisement