Resources For Teachers For Tutors For Students & Parents AI New Books Pricing
Year 12 General (Unit 3 & 4) Graphs and networks

Graph terminology and network diagrams

20 practice questions 0 video lessons Theory + worked examples

Learn the language of graphs and networks in Year 12 General Mathematics for Queensland (QCAA). A graph is just dots and lines: towns joined by highways, players who have met in a competition, or computers linked by cables. Drawing the connections this way strips a problem back to what really matters, from planning a delivery run around Mackay to linking pumps on a cane farm.

You will practise naming vertices, edges and loops, finding the degree of each vertex, and telling simple, complete and bipartite graphs apart. You will turn tables and descriptions into directed and weighted network diagrams, and check your work with the rule that the degrees add to twice the number of edges, ready for adjacency matrices in the next subtopic.

Create a free accountTrack your progress and save your work as you go.
Create free account

Theory

A graph is a set of vertices joined by edges. This Year 12 General Mathematics guide for Queensland students explains the key words (degree, loop, simple, complete and bipartite graphs, subgraphs, directed and weighted graphs) and shows how to draw a network diagram from a real situation or a table.

A graph is a set of points called vertices (or nodes) joined by lines called edges. Only the connections matter: an edge can be drawn straight or curved, and its length on the page means nothing. An edge that starts and finishes at the same vertex is a loop. Two or more edges joining the same pair of vertices are multiple edges. The degree of a vertex, written \(\deg(A)\), is the number of edge ends at that vertex, so a loop adds \(2\) to the degree.

A simple graph has no loops and no multiple edges. A complete graph \(K_n\) is a simple graph on \(n\) vertices in which every pair of vertices is joined by exactly one edge. A bipartite graph has its vertices split into two groups so that every edge joins a vertex in one group to a vertex in the other, never two vertices in the same group. A subgraph is made of some of the vertices and some of the edges of a graph, where each chosen edge joins two chosen vertices.

In a directed graph (digraph) each edge has an arrow and can only be travelled one way. A directed edge is often called an arc. In a weighted graph each edge carries a number, such as a distance, a time or a cost. A weighted graph that models a real situation (roads, cables, flights, walking tracks) is called a network, and a drawing of it is a network diagram.

Key idea. Every edge has two ends, so adding up all the degrees always gives twice the number of edges. Count a loop as \(2\) towards the degree of its vertex.
Vertices, edges, a loop and a multiple edgeFive vertices A to E. B and C are joined by two edges. D has a loop. Degrees: A 2, B 4, C 3, D 4, E 3. A B C D E
B and C are joined by two edges and D has a loop, so this graph is not simple. \(\deg(D) = 1 + 1 + 2 = 4\), and the degrees add to \(16 = 2 \times 8\) edges.
A weighted network of walking timesFive places G, K, L, P, W joined by paths labelled with walking times in minutes: GK 6, KL 4, LP 5, PW 7, WG 3, KP 8, KW 9. G K L P W 6 4 5 7 3 8 9
A weighted network: the numbers are walking times in minutes between five places in a park. The drawing does not need to be to scale.

Each edge adds \(2\) to the total of the degrees (one for each end), so for any graph:

\[\text{sum of degrees} = 2 \times \text{number of edges}\]
∑deg=2e

A complete graph \(K_n\) joins every pair of its \(n\) vertices once. Each vertex has degree \(n - 1\), and the number of edges is:

\[\text{edges in } K_n = \dfrac{n(n-1)}{2}\]
e=n(n−1)2

For the degree of one vertex, count every edge end that touches it:

\[\deg(v) = (\text{edges to other vertices}) + 2 \times (\text{loops at } v)\]
deg(v)=edges+2×loops
Quick check. The sum of the degrees is always even. If your degrees add to an odd number, an edge end has been missed or counted twice.

How to draw a network diagram for a real situation

  1. Choose the vertices. Each place, person or object becomes one vertex. Label it with a letter and give a key if needed.
  2. Draw the edges. Join two vertices only when there is a direct link between them (a road, a cable, a game played, a skill shared). Use an arrow if the link only works one way.
  3. Add the weights. Write the distance, time or cost on each edge, with units stated once.
  4. Check the diagram. Count the edges against the information given, and check that the degrees add to twice the number of edges. Then describe the graph: simple or not, complete, bipartite, directed, weighted.
Example 1 — Degrees and edges
For the graph shown, find the degree of each vertex and the number of edges. Is the graph simple?
Solution

Count edge ends at each vertex. The loop at \(P\) counts \(2\).

Example 1 graphSquare P Q S R with diagonal Q R, a loop at P and two edges joining R and S. P Q R S
\(\deg(P)\)\(=\)\(2 + 1 + 1\)
\(\)\(=\)\(4\)
\(\deg(Q)\)\(=\)\(1 + 1 + 1\)
\(\)\(=\)\(3\)
\(\deg(R)\)\(=\)\(1 + 1 + 1 + 1\)
\(\)\(=\)\(4\)
\(\deg(S)\)\(=\)\(1 + 1 + 1\)
\(\)\(=\)\(3\)
\(\text{sum of degrees}\)\(=\)\(4 + 3 + 4 + 3\)
\(\)\(=\)\(14\)
\(\text{number of edges}\)\(=\)\(14 \div 2\)
\(\)\(=\)\(7\)
deg(P)=4

Check by counting the edges directly: the loop, \(PQ\), \(PR\), \(QR\), \(QS\) and two edges \(RS\) make \(7\). The graph is not simple, because it has a loop and a multiple edge.

Example 2 — A complete graph
Six teams in a Cairns futsal competition each play every other team once. Model the games as a graph. (i) What type of graph is it? (ii) What is the degree of each vertex? (iii) How many games are played?
Solution

Each team is a vertex and each game is an edge. Every pair of teams is joined once.

Complete graph on six verticesSix vertices A to F in a hexagon, every pair joined by an edge: 15 edges. A B C D E F
\(\text{degree of each vertex}\)\(=\)\(6 - 1\)
\(\)\(=\)\(5\)
\(\text{edges in } K_6\)\(=\)\(\dfrac{6 \times 5}{2}\)
\(\)\(=\)\(15\)
e=15

(i) It is the complete graph \(K_6\). (ii) Each team plays \(5\) games, so every vertex has degree \(5\). (iii) \(15\) games are played. Check: \(6 \times 5 = 30\) edge ends, and \(30 \div 2 = 15\).

Example 3 — A bipartite graph
At a Toowoomba study centre, tutor \(J\) teaches maths (\(M\)) and physics (\(P\)), tutor \(K\) teaches maths, English (\(E\)) and history (\(H\)), and tutor \(L\) teaches physics and history. (i) Draw a graph and explain why it is bipartite. (ii) Are the vertices \(J\), \(M\), \(P\) with the edges \(JM\) and \(JP\) a subgraph?
Solution

Put the tutors in one group and the subjects in the other, then draw one edge for each tutor–subject pair.

Bipartite graph of tutors and subjectsTutors J, K, L on the left, subjects M, P, E, H on the right. Edges JM, JP, KM, KE, KH, LP, LH. J K L M P E H
\(\text{edges}\)\(=\)\(2 + 3 + 2\)
\(\)\(=\)\(7\)
e=7

(i) Every edge joins a tutor (green) to a subject (amber). No edge joins two tutors or two subjects, so the graph is bipartite. (ii) Yes. \(JM\) and \(JP\) are edges of the graph and both join chosen vertices, so they form a subgraph.

Example 4 — A directed network from a table
A theme park on the Gold Coast runs a one-way shuttle. The trips (in minutes) are: \(E \to W\) 6, \(W \to R\) 4, \(R \to F\) 3, \(F \to E\) 5, \(E \to R\) 8, \(H \to E\) 7 and \(F \to H\) 9. (i) Draw the network. (ii) How many trips leave \(E\), and how many arrive at \(E\)? (iii) Can a rider go directly from \(W\) to \(E\)?
Solution

Each stop is a vertex. Each trip is an arrow from its start to its finish, labelled with its time.

Directed weighted shuttle networkArrows E to W 6, W to R 4, R to F 3, F to E 5, E to R 8, H to E 7, F to H 9 (minutes). E W R F H 6 4 3 5 8 7 9
\(\text{trips leaving } E\)\(=\)\(E \to W,\ E \to R\)
\(\)\(=\)\(2\)
\(\text{trips arriving at } E\)\(=\)\(F \to E,\ H \to E\)
\(\)\(=\)\(2\)
2,2

(i) The network is a directed, weighted graph with \(7\) arcs. (ii) \(2\) trips leave \(E\) and \(2\) arrive. (iii) No. There is an arrow \(E \to W\) but no arrow \(W \to E\), so a rider must go \(W \to R \to F \to E\) instead.

Common pitfalls

A loop counts twice. Watch out for counting a loop as \(1\) towards the degree. It has two ends at the same vertex, so it adds \(2\).
Crossings are not vertices. Two edges that cross on the page do not meet at a vertex unless a vertex is drawn there. Only labelled points are vertices.
Simple means no loops and no multiple edges. Watch out for calling a graph simple when two vertices are joined twice. A graph can also be simple without being complete.

Frequently asked questions

What is the degree of a vertex in a graph?

The degree is the number of edge ends that meet at the vertex. Count each edge joined to it once, and count a loop twice because both of its ends are at that vertex.

Does a loop count as 1 or 2 towards the degree?

A loop adds 2 to the degree of its vertex, because it leaves the vertex and comes back to it. For example, a vertex with two ordinary edges and one loop has degree 4.

What is the difference between a simple graph and a complete graph?

A simple graph has no loops and no multiple edges. A complete graph is a simple graph where every pair of vertices is joined by an edge. Every complete graph is simple, but most simple graphs are not complete.

How many edges does a complete graph have?

A complete graph on n vertices has n(n - 1)/2 edges. For example, K5 has 5 times 4 divided by 2, which is 10 edges.

What makes a graph bipartite?

A graph is bipartite if its vertices can be split into two groups so that every edge joins a vertex in one group to a vertex in the other group. No edge joins two vertices in the same group.

What is the difference between a graph and a network?

A network is a graph used to model a real situation, usually with weights such as distances, times or costs on its edges. The vertices and edges stand for real places and links.