Shortest paths
HSC Maths Standard 2 · Unit 5: Networks
Shortest paths notes
Fact-checked by a second, independent AI review.
Focus on identifying and computing the shortest path in a weighted network. Use graphs, paths, and weights to find the minimum-total-distance route between two vertices.
- Graph terms
- Nodes (vertices) are points; edges are connections with weights (distances or costs).
- Path vs simple path
- A path is a sequence of edges joining vertices; a simple path visits each vertex at most once (no repeated vertices). Note: a general path may repeat vertices, but a simple path has no repeated vertices.
- Path length
- Total weight is the sum of edge weights along the path; the shortest path has the smallest total.
- Weighted shortest-path methods
- Dijkstra’s algorithm is the common method for non-negative weights; methods must be justified if used.
- Exam approach
- Show full work, identify the route, compute total weight, and justify why it is minimal; consider edge cases like multiple equal shortest paths.
Remember it: Think: the shortest path is the ‘lightest’ journey from start to finish.
Exam tip: Markers look for correct identification of the shortest route, correct use of addition of edge weights, clear justification, and appropriate method (e.g., Dijkstra for non-negative weights) with neat, labelled steps.
Syllabus checklist
- Shortest paths: core ideas
- Terms and typical exam questions for "Networks" in NSW HSC Mathematics Standard 2
Practice questions
1. In a weighted graph, the shortest path from A to D uses edges with weights 2, 3, 1 totaling 6. If an alternative path has weights 5,1,2 totaling 8, which is shorter?
Answer checked
Show answer
Answer: first path 6. 6 is smaller than 8, so the first path is shorter.
2. Dijkstra's algorithm always finds the shortest path in a graph with non‑negative weights.
Answer checked
Show answer
Answer: True. True, it is guaranteed for non‑negative weights.
3. A path that visits every vertex exactly once is called a ____.
Answer checked
Show answer
Answer: Hamiltonian path. A Hamiltonian path visits each vertex once.
4. Given a network: A–B = 4, B–C = 1, A–C direct = 6. Shortest path from A to C?
Answer checked
Show answer
Answer: A-B-C total 5. A-B-C totals 5, which is shorter than the direct 6.
5. The distance from A to C in the network A–B 4, B–C 1 is ____.
Answer checked
Show answer
Answer: 5. Path A→B→C sums to 5.

Practise shortest paths as a game
Hearts, combos, streaks and an AI tutor that explains every answer. Start free.