Dynamic Programming Tabulation

A question is this type if and only if it involves completing or interpreting a dynamic programming table for optimization problems.

5 questions

OCR D2 2016 June Q6
6 The table below shows an incomplete dynamic programming tabulation to solve a maximum path problem.
StageStateActionWorkingSuboptimal maximum
\multirow[t]{2}{*}{3}0011
1022
\multirow[t]{4}{*}{2}\multirow[t]{2}{*}{0}0\(1 + 1 = 2\)\multirow[b]{2}{*}{3}
1\(1 + 2 = 3\)
\multirow[t]{2}{*}{1}0\(3 + 1 = 4\)\multirow[t]{2}{*}{4}
1\(1 + 2 = 3\)
\multirow[t]{4}{*}{1}\multirow[t]{2}{*}{0}0\(1 + =\)\multirow{4}{*}{}
1\(0 + =\)
\multirow[t]{2}{*}{1}0\(0 + =\)
1\(1 + =\)
\multirow[t]{2}{*}{0}\multirow[t]{2}{*}{0}0\(2 + =\)\multirow{2}{*}{}
1\(2 + =\)
  1. Complete the working and suboptimal maximum columns on the copy of the table in your Answer Book. Write down the weight of the maximum path and the corresponding route. Give your route using (stage; state) variables. Ken has entered a cake-making competition. The actions in the dynamic programming tabulation above represent the different types of cake that Ken could make. Each competitor must make one cake in each stage of the competition. The rules of the competition mean that, for each competitor, the actions representing their four cakes must form a route from \(( 0 ; 0 )\) to \(( 4 ; 0 )\). The weights in the tabulation are the number of points that Ken can expect to get by making each of the cakes. Each cake is also judged for how well it has been decorated. The number of points that Ken expects to get for decorating each cake is shown below. Ken is not very good at decorating the cakes. He expects to get 0 points for decorating for the cakes that are not listed below.
    Cake(0; 0) to (1; 0)(1; 0) to (2; 1)(1; 1) to (2; 0)(2; 0) to (3; 0)(2; 0) to (3; 1)(2; 1) to (3; 0)(2; 1) to (3; 1)
    Decorating points1121111
  2. Calculate the number of decorating points that Ken can expect if he makes the cakes given in the solution to part (i). When Ken meets the other competitors he realises that he is not good enough to win the competition, so he decides instead to try to win the judges' special award. For each cake, the absolute difference between the score for cake-making and the score for decorating is calculated. The award is given to the person whose biggest absolute difference is least. (Note: to find the absolute difference, calculate larger number-smaller number, or 0 if they are the same.)
  3. Draw the graph that the dynamic programming tabulation represents. Label the vertices using (stage; state) labels with \(( 0 ; 0 )\) at the left hand side and \(( 4 ; 0 )\) at the right hand side. Make the graph into a network by weighting the arcs with the absolute differences.
  4. Use a dynamic programming tabulation to find the minimax route for the absolute differences.
OCR D2 Specimen Q3
3 [Answer this question on the insert provided.]
A flying doctor travels between islands using small planes. Each flight has a weight limit that restricts how much he can carry. A plague has broken out on Farr Island and the doctor needs to take several crates of medical supplies to the island. The crates must be carried on the same planes as the doctor. The diagram shows a network with (stage; state) variables at the vertices representing the islands, arcs representing flight routes that can be used, and weights on the arcs representing the number of crates that the doctor can carry on each flight. \begin{figure}[h]
\includegraphics[alt={},max width=\textwidth]{09279013-7088-4db2-99dd-098b32fbcad7-03_506_1084_671_477} \captionsetup{labelformat=empty} \caption{Stage 0}
\end{figure} Stage 1 Stage 2
  1. It is required to find the route from ( \(0 ; 0\) ) to ( \(3 ; 0\) ) for which the minimum number of crates that can be carried on any stage is a maximum (the maximin route). The insert gives a dynamic programming tabulation showing stages, states and actions, together with columns for working out the route minimum at each stage and for indicating the current maximin. Complete the table on the insert sheet and hence find the maximin route and the maximum number of crates that can be carried.
  2. It is later found that the number of crates that can be carried on the route from ( \(2 ; 0\) ) to ( \(3 ; 0\) ) has been recorded incorrectly and should be 15 instead of 5 . What is the maximin route now, and how many crates can be carried?
Edexcel D2 Q3
3. This question should be answered on the sheet provided. A couple are making the arrangements for their wedding. They are deciding whether to have the ceremony at their church, a local castle or a nearby registry office. The reception will then be held in a marquee, at the castle or at a local hotel. Both the castle and hotel offer catering services but the couple are also considering using Deluxe Catering or Cuisine, who can both provide the food at any venue. \begin{figure}[h]
\includegraphics[alt={},max width=\textwidth]{f662b4da-12c1-4f30-ab5d-fb132f19e643-3_944_1504_605_258} \captionsetup{labelformat=empty} \caption{Fig. 1}
\end{figure} The network in Figure 1 shows the costs incurred (including transport), in hundreds of pounds, according to the choice the couple make for each stage of the day. Use dynamic programming to find how the couple can minimise the total cost of their wedding and state the total cost of this arrangement.
(9 marks)
Edexcel D2 Q3
3. This question should be answered on the sheet provided. Arthur is planning a bus journey from town \(A\) to town \(L\). There are various routes he can take but he will have to change buses three times - at \(B , C\) or \(D\), at \(E , F , G\) or \(H\) and at \(I , J\) or \(K\). \begin{figure}[h]
\includegraphics[alt={},max width=\textwidth]{e892e87c-1c2d-4f97-ac23-41e38663d0f0-03_764_1410_477_315} \captionsetup{labelformat=empty} \caption{Fig. 2}
\end{figure} Figure 2 shows the bus routes that Arthur can use. The number on each arc shows the average waiting time, in minutes, for a bus to come on that route. As the forecast is for rain, Arthur wishes to plan his journey so that the maximum waiting time at any one stop is as small as possible. Use dynamic programming to find the route that Arthur should use.
(9 marks)
Edexcel D2 Q4
4. This question should be answered on the sheet provided. The owner of a small plane is planning a journey from her local airport, \(A\) to the airport nearest her parents, \(K\). On the journey she will make three refuelling stops, the first at \(B , C\) or \(D\), the second at \(E , F\) or \(G\) and the third at \(H , I\) or \(J\). \begin{figure}[h]
\includegraphics[alt={},max width=\textwidth]{726bca96-7f98-4ed5-b642-f5007a958c8b-05_727_1303_523_356} \captionsetup{labelformat=empty} \caption{Fig. 2}
\end{figure} Figure 2 shows all the possible flights that can be made on the journey with the number by each arc indicating the distance of each flight in hundreds of miles. As her plane does not have a large fuel tank, the owner wishes to choose a route that minimises the maximum distance of any one flight. Find the route that she should use and state the maximum distance of any one stage on this route.