0% found this document useful (0 votes)
19 views12 pages

9FM0 Topic Test - D1 - 1 - Algorithms PDF

The document is a topic test for Pearson Edexcel GCE Mathematics (9FM0) focusing on Decision Mathematics 1, specifically algorithms. It includes various questions related to algorithms, sorting methods, and graph theory, with a total of 99 marks available. The test features both legacy and new exam-style questions, organized by difficulty, and aims to assess students' understanding of algorithms and their applications.

Uploaded by

cgpqd4d264
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views12 pages

9FM0 Topic Test - D1 - 1 - Algorithms PDF

The document is a topic test for Pearson Edexcel GCE Mathematics (9FM0) focusing on Decision Mathematics 1, specifically algorithms. It includes various questions related to algorithms, sorting methods, and graph theory, with a total of 99 marks available. The test features both legacy and new exam-style questions, organized by difficulty, and aims to assess students' understanding of algorithms and their applications.

Uploaded by

cgpqd4d264
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 12

Topic Test

Pearson Edexcel GCE Mathematics (9FM0)


Paper 3D Decision Mathematics 1
Algorithms - Questions
Pearson: helping people progress, everywhere

Pearson aspires to be the world’s leading learning company. Our aim is to help everyone progress in their lives
through education. We believe in every kind of learning, for all kinds of people, wherever they are in the
world. We’ve been involved in education for over 150 years, and by working across 70 countries, in 100
languages, we have built an international reputation for our commitment to high standards and raising
achievement through innovation in education. Find out more about how we can help you and your students
at: www.pearson.com/uk

© Pearson Education Ltd 2023


About this topic test

• This topic test is comprised from legacy past paper questions (prior to
2019) and BRAND NEW exam style questions. The new questions are:
5(b)
6(b)
7(d)
8(b)

• The exam questions have been selected for the topic of Algorithms with
the intention of being used in isolation, however some inherent overlap
between topics may occur.

• The questions within this topic test have been ordered in terms of
difficulty, from ‘easiest’ to ‘hardest’.

• The total number of marks for this topic test is 99 marks

© Pearson Education Ltd 2023


1. An algorithm is described by the flow chart below.

Start

Read a, b

Let c = a  b to 2 d.p.

Let d = largest whole number  c

Let e = db

Let f = a − e

Yes Write
Is Stop
f = 0? “answer is” b

No
Let a = b

Let b = f

(a) Given that a = 645 and b = 255, complete the table in the answer booklet to show the results
obtained at each step when the algorithm is applied.
(7)

(b) Explain how your solution to part (a) would be different if you had been given that a = 255 and
b = 645.
(3)

(c) State what the algorithm achieves.


(1)
(Total 11 marks)
___________________________________________________________________________

© Pearson Education Ltd 2023


2.

Figure 1
Figure 1 describes an algorithm in the form of a flow chart, where a is a positive integer.
List P, which is referred to in the flow chart, comprises the prime numbers 2, 3, 5, 7, 11, 13, 17, ...
(a) Starting with a = 90, implement this algorithm. Show your working in the table in the answer
book.
(7)
(b) Explain the significance of the output list.
(2)
(c) Write down the final value of c for any initial value of a.
(1)
(Total 10 marks)
___________________________________________________________________________

© Pearson Education Ltd 2023


3. Figure 2

An algorithm is described by the flow chart shown in Figure 2.


(a) Complete the table in the answer book recording the results of each step as the algorithm is
applied.
(Notice that values of A, B, C and D are to be given to 3 decimal places, and the values of E to
1 significant figure.)
(8)

(b) Write down the output from the algorithm.


(1)

(Total 9 marks)
___________________________________________________________________________

© Pearson Education Ltd 2023


4. Figure 3

An algorithm is described by the flow chart shown in Figure 3.


(a) Given that x = 54 and y = 63, complete the table in the answer book to show the results obtained
at each step when the algorithm is applied.
(7)
(b) State what the algorithm achieves.
(2)
(Total 9 marks)
___________________________________________________________________________

© Pearson Education Ltd 2023


5. 52 48 50 45 64 47 53

(a) The list of numbers above is to be sorted into descending order. Perform a bubble sort to obtain
the sorted list, giving the state of the list after each completed pass.
(4)
The bubble sort algorithm has quadratic order.
(b) Given that it takes a computer 0.3 seconds to sort a list of 2000 numbers using the bubble sort,
estimate the time needed to sort a list of 120 000 numbers.
(2)

(Total 6 marks)
___________________________________________________________________________
6.
Ali 74
Bobby 28
Eun-Jung 63
Katie 54
Marciana 54
Peter 49
Rory 37
Sophie 68

The table shows the marks obtained by students in a test. The students are listed in alphabetical order.
(a) Carry out a quick sort to produce a list of students in descending order of marks. You should show
the result of each pass and identify your pivots clearly.
(5)
For a list of n numbers, the quick sort algorithm has, on average, order nlogn.
(b) Given that it takes 1.64 seconds to run the algorithm when n = 300, calculate approximately how
long it will take to run the algorithm when n = 10800, giving your answer to the nearest tenth of a
second and making your method clear.
(2)

(Total 7 marks)
___________________________________________________________________________

© Pearson Education Ltd 2023


7. 29 52 73 87 74 47 38 61 41

The numbers in the list represent the lengths in minutes of nine radio programmes. They are to be
recorded onto tapes which each store up to 100 minutes of programmes.
(a) Obtain a lower bound for the number of tapes needed to store the nine programmes.
(2)

(b) Use the first-fit bin packing algorithm to fit the programmes onto the tapes.
(3)

(c) Use the first-fit decreasing bin packing algorithm to fit the programmes onto the tapes.
(3)

(d) The first-fit bin packing algorithm has quadratic order. Given that it takes a computer 0.5 seconds
to pack a list of 5000 numbers using first-fit bin packing, estimate the time taken to pack a list of
1 200 000 numbers.

(2)

(Total 10 marks)

___________________________________________________________________________

© Pearson Education Ltd 2023


8. 90, 50, 55, 40, 20, 35, 30, 25, 45

(a) Use the bubble sort algorithm to sort the list of numbers above into descending order showing the
rearranged order after each pass.
(5)

The bubble sort algorithm is to be used to sort a list of n numbers. The number of comparisons is used
to measure the order of the bubble sort algorithm.

(b) By considering the worst case, determine the order of the bubble sort algorithm in terms of n. You
must make your method and working clear.

(3)

Jessica wants to record a number of television programmes onto video tapes. Each tape is 2 hours
long. The lengths, in minutes, of the programmes she wishes to record are:
55, 45, 20, 30, 30, 40, 20, 90, 25, 50, 35 and 35.
(c) Find the total length of programmes to be recorded and hence determine a lower bound for the
number of tapes required.
(2)
(d) Use the first fit decreasing algorithm to fit the programmes onto her 2-hour tapes.

(3)
Jessica’s friend Amy says she can fit all the programmes onto 4 tapes.
(e) Show how this is possible.
(2)

(Total 15 marks)
___________________________________________________________________________

© Pearson Education Ltd 2023


9. 650 431 245 643 455 134 710 234 162 452

(a) The list of numbers above is to be sorted into descending order. Perform a Quick Sort to obtain
the sorted list, giving the state of the list after each pass, indicating the pivot elements.
(5)
The numbers in the list represent the lengths, in mm, of some pieces of wood. The wood is sold in one
metre lengths.
(b) Use the first-fit decreasing bin packing algorithm to determine how these pieces could be cut
from the minimum number of one metre lengths. (You should ignore wastage due to cutting.)
(4)

(c) Determine whether your solution to part (b) is optimal. Give a reason for your answer.
(2)

(Total 11 marks)
___________________________________________________________________________
10. Explain what is meant by a planar graph.
(2)

(Total 2 marks)
___________________________________________________________________________
11. Figure 4

Use the planarity algorithm to show that the graph in Figure 4 is planar.
(4)

(Total 4 marks)
___________________________________________________________________________

© Pearson Education Ltd 2023


12. An electronics company makes a product that consists of components A, B, C, D, E and F. The table
shows which components must be connected together to make the product work. The components are
all placed on a circuit board and connected by wires, which are not allowed to cross.

Component Must be connected to

A B, D, E, F
B C, D, E

C D, E

D E

E F

F B

(a) On the diagram in the answer book draw straight lines to show which components need to
be connected.
(1)

(b) Starting with the Hamiltonian cycle ABCDEFA, use the planarity algorithm to determine whether
it is possible to build this product on a circuit board.
(4)

(Total 5 marks)

TOTAL FOR PAPER: 99 MARKS

© Pearson Education Ltd 2023

You might also like