Question 1
OCR B (MEI) Further Maths June 2019 Modelling with algorithms (Y433-01)A level11 marks
On the specification
- (a)
- N5-N7 Modelling with Algorithms: Minimum connector and shortest path algorithms
- (b)
- A10-A11 Modelling with Algorithms: Packing algorithms
- (c)
- A10-A11 Modelling with Algorithms: Packing algorithmsAA1-A5 Modelling with Algorithms: Algorithms, basic ideas and complexity
Question text
1 Fig. 1 shows a network. The weights on the arcs are distances. 35 25 D A 64 17 9 E 11 G 6 8 13 13 B 7 F 12 10 14 C 18 H Fig. 1 (a) Apply Dijkstra’s algorithm to the copy in the Printed Answer Booklet to find the shortest path from A to H. State each of the following • the shortest path and • its length. [6] The weights on the arcs in Fig. 1 are listed in descending order in the Printed Answer Booklet. (b) Use the first fit decreasing algorithm to pack these weights into bins that have a capacity of 50. [2] A list of n weights, where the weights are arranged in descending order, are to be packed into bins using the first fit decreasing algorithm. The number of comparisons is used as a measure of the complexity of the first fit decreasing algorithm. (c) Determine, in the worst case, the complexity of the first fit decreasing algorithm in terms of n. [3]