- IB
- Question Type 4: Creating directed graphs given some descriptions or information
The question assesses the ability to represent precedence constraints using directed acyclic graphs (DAGs) and to perform a topological sort. The context is warehouse logistics.
Warehouses must be visited in the following precedence constraints:
Represent this as a directed acyclic graph and provide one possible topological ordering of the warehouses.
[4]Consider a directed graph with vertices and the following travel times between vertices:
Use Dijkstra’s algorithm to find the shortest travel time and path from to .
[5]A directed graph consists of six vertices: . The set of directed edges is given by:
Determine whether there exists a Hamiltonian path in this graph that visits each vertex exactly once. Justify your answer.
[3]Given six warehouses labeled and the one-way travel times (in hours) as follows: , , , , , .
Construct the adjacency matrix of the directed graph using for no direct connection.
[3]This question involves the construction of a time-expanded network, a common technique in discrete optimization and logistics used to model time-dependent constraints and flows over a static graph.
Each directed arc between warehouses has a time window during which travel is allowed. The travel time for each arc is constant at unit. The allowed departure windows are as follows:
: : : : :
Construct the time-expanded network for integer times to , indicating the nodes and all feasible time-step edges (including waiting edges).
[5]A directed graph has vertices and the following weighted edges:
Find the minimum spanning arborescence rooted at using Chu–Liu/Edmond’s algorithm. State the set of edges included in the arborescence and calculate its total weight.

The one-way shipping costs (in dollars) between six warehouses are: , , , , , , . Represent this as an adjacency list for the directed graph.
[4]A directed graph consists of six vertices: and .
The edges in the graph are defined as follows: and .
The directed graph is shown in the diagram below.

Using the directed graph , determine whether it is strongly connected. Justify your answer.
[5]Construct the directed network representing capacities for six warehouses with the following edges and capacities:
Compute the maximum flow from warehouse to warehouse using the Ford-Fulkerson method. Show each augmenting path used and the resulting total flow.
[5]Consider a directed graph with vertices and the following edges: , , , , , , and .
Determine whether there is an Eulerian circuit in this graph. Justify your answer.
[3]Six warehouses are located at coordinates , , , , , and . A complete graph is constructed where the weight of each edge is the Euclidean distance between the warehouses, rounded to the nearest integer.
Starting from warehouse , use the nearest-neighbour algorithm to determine a Hamiltonian cycle that visits each warehouse exactly once and returns to .
State the sequence of warehouses in the cycle and calculate the total distance.
[6]The following one-way shipping costs (in $) form a directed graph: , , , , , , .
List the set of directed edges with their weights.
[2]