0% found this document useful (0 votes)
14 views26 pages

Chapter 5

Chapter 5 discusses the concept of networks in graph theory, particularly in relation to transportation systems in Malaysia. It explains the relationship between networks and graphs, defining vertices and edges, and introduces concepts such as simple graphs, multiple edges, and loops. The chapter also covers practical applications of graph theory in various fields and provides examples and exercises to reinforce understanding.

Uploaded by

g-82367601
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)
14 views26 pages

Chapter 5

Chapter 5 discusses the concept of networks in graph theory, particularly in relation to transportation systems in Malaysia. It explains the relationship between networks and graphs, defining vertices and edges, and introduces concepts such as simple graphs, multiple edges, and loops. The chapter also covers practical applications of graph theory in various fields and provides examples and exercises to reinforce understanding.

Uploaded by

g-82367601
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/ 26

CHAPTER

5 Network in
Graph Theory

You will learn

► Network

T he transportation system in Malaysia which comprises land,


water and air transportation are developed in line with the
country’s progress. The land transportation system, particularly
public transport is developed at a fast pace based on the increase
in the number of commuters in big cities. City rail services such as
Light Rail Transit (LRT), Mass Rapid Transit (MRT), monorails
and commuter trains in the cities are amongst the types of public
transportation that are increasingly well accepted by the public.

Do you know that the transportation system is a type of network?

Why Study This Chapter?

A network is used to link objects in the same field based on its


needs. Networks are widely used in transportation, computer,
social, business, investigation, medicine, science, neuroscience,
Saiz sebenar
social science and gaming fields.

128
Walking Through Time

Leonhard Euler
(1707 – 1783)
WORD BANK Leonhard Euler, a mathematician in the 18th
• weighted • berpemberat century, was born in Basel, Switzerland. In the
• vertex • bucu year 1735, Euler solved a mathematics and
• degree • darjah logic problem known as the Seven Bridges of
• discrete • diskret Kӧnigsberg and developed a mathematical structure
• loop • gelung called graph – a diagram consisting of dots
• graph • graf (vertices) which are linked by lines or arcs (edges).
• simple • mudah
• tree • pokok
• network • rangkaian
• subgraph • subgraf
• edge • tepi
• directed • terarah http://bt.sasbadi.com/m4129 Saiz sebenar

129
Chapter 5 Network in Graph Theory

5.1 Network

What is the relationship between a network and a graph? Learning


In Year 5, you were introduced to systems of computer networks Standard
and the world of Internet through the subject of Information and To identify and explain
Communication Technology. a network as a graph.
The link between a group of computers and the associated devices,
that is a computer network, enables information to be searched, used
and shared easily. Do you know the relationship between a network and
a graph?
A graph is used to represent data consisting of discrete Vertex
objects and to show the relationship between these objects in
a simple graphical manner. In the field of mathematics, graph Edge
theory in particular, a graph is interpreted as a series of dots
which are either linked or not linked to one another by lines.
Each dot is known as a vertex and the line joining two vertices
is known as an edge.
A graph is usually used to represent a certain network. A network is part of a graph with
5

the vertices and edges having their own characteristics. The structure of network data has
CHAPTER

a many-to-many relation. Examples of graphs that involve networks are as follows.

Land transport network


Vertex
Regions, towns, cities or certain buildings that
are linked
Edge
Roads, highways or railway lines

Social network INFO ZONE


Vertex A Cold Chain System is a
Individuals, groups or system used in the world
organisations of medicine. The function
of this system is to
Edge transport, distribute and
Types of relationships store vaccine and blood
such as friends, in a fixed temperature
colleagues or families range from the source to
the place they are used.
Saiz sebenar

130
Chapter 5 Network in Graph Theory

A graph is denoted by a set of ordered pairs G = (V, E), where


INFO ZONE
• V is the set of dots or vertices.
V = {v1, v2, v3, ... vn} G = Graph
v = Vertex or dot
• E is the set of edges or lines linking each pair of vertices. e = Edge or line or arc
E = {e1, e2, e3, ... en} d = Degree
∑ = Sum
E = {(a1, b1), (a2, b2), ... (an, bn)}; a and b are pairs of vertices.

The degree, d, is the number of edges that connect two vertices.


The sum of degrees of a graph is twice the number of edges, that is MY MEMORY

Σd(v) = 2E ; v ∈ V ∈ : an element of

What do you understand about a simple graph?


A simple graph has no loops and no multiple edges. The sum of degrees of the graph is twice the
number of edges.

1 1 2

5
6
Based on the simple graph given, determine

CHAPTER
(a) V and n(V) 3
(b) E and n(E)
(c) sum of degrees.
5 4
Solution:
INFO ZONE
(a) V = {1, 2, 3, 4, 5, 6} Set of vertices
The edge for the vertex
n(V) = 6 Number of vertices
pair (1, 2) is also the
(b) E = {(1, 2), (1, 5), (2, 3), (2, 4), (3, 4), (4, 5), (5, 6)} Set of vertex pairs edge for the vertex pair
(2, 1).
n(E) = 7 Number of edges

(c) Sum of degrees Degree of vertex: d(1) = 2


d(2) = 3 The degree of vertex 1 is
Σd(v) = 2(E) d(3) = 2 two, that is the edges which
= 2(7) d(4) = 3 connect vertex 1 to vertex 2
= 14 d(5) = 3 and vertex 1 to vertex 5.
d(6) = 1
Sum = 14
Example 2
State the number of vertices, edges and the sum of degrees for the following simple graphs.
(a) 1 2 3 4 (b)
B C D

G F E Saiz sebenar
7 6 5

131
Chapter 5 Network in Graph Theory

Solution:
(a) Number of vertices = 7 (b) Number of vertices = 7
Number of edges = 7 Number of edges = 9
Sum of degrees = 2 × Number of edges Sum of degrees = 2 × Number of edges
=2×7 =2×9
= 14 = 18

What is the meaning of multiple edges and loops of a graph?


Multiple edges
Edge
• Involve two vertices. P Q R
Vertex
• The vertices are connected by more than
one edge.
• The sum of degrees is twice the number
of edges. S
T Loop
Multiple edges between
Loops vertex P and vertex T

• Involve one vertex.


• The edge is in the form of an arc that starts and ends at the same vertex.
5

• Each loop adds 2 to the degree.


CHAPTER

Let the graph given be denoted by a set of ordered pairs, G(V, E),
then
V = {A, B, C, D} e8
Multiple edges D
A loop
e7 e5
E = {(A, B), (A, B), (B, C), (B, C), (C, D), (B, D), (A, D), (D, D)} e6
E = {e1, e2, e3, e4, e5, e6, e7, e8} e1 e4
Second edge of AB A C
e2 B e3
First edge of AB

Example 3 P Q R
The diagram on the right shows a graph with a loop and
multiple edges. State
(a) V and n(V) S
(b) E and n(E) U T
(c) sum of degrees.
MY MEMORY
Solution:
(a) V = {P, Q, R, S, T, U} V = Set of vertices
E = Set of edges
n(V) = 6
(b) E = {(P, Q), (P, U), (P, U), (Q, R), (Q, U), (R, S), (R, T), (S, S), (S, T), (T, U)}
Saiz sebenar
n(E) = 10
132
Chapter 5 Network in Graph Theory

(c) Sum of degrees = 20


Degree of vertex P = 3

TIPS

Degree of vertex Q = 3 
Degree of vertex R = 3 
The sum of degrees is 20. The degree of a vertex
Degree of vertex S = 4 
 with a loop in an undirected
Degree of vertex T = 3  graph is 2, one in clockwise
Degree of vertex U = 4 direction and the other in
anticlockwise direction.
Example 4
Draw a simple graph based on the given information.
(a) V = {1, 2, 3, 4, 5} (b) V = {P, Q, R, S, T, U}
E = {(1, 2), (1, 4), (1, 5), (2, 3), (2, 4), (3, 4)} E = {(P, U), (P, T), (Q, T), (Q, S), (R, S), (R, U)}
Solution:
2
1
(a) (b) P
Q R

3
5 4

5
CHAPTER
T S
U
Example 5
Draw a graph with multiple edges and loops based on the given information.
(a) V = {P, Q, R, S}
E = {(P, P), (P, Q), (P, S), (Q, S), (Q, S), (Q, R), (S, R), (R, R)}
(b) V = {1, 2, 3, 4, 5, 6, 7}
E = {(1, 6), (1, 6), (2, 7), (2, 7), (5, 7), (5, 7), (3, 4), (3, 4), (1, 7), (6, 7), (3, 7), (4, 7)}
Solution: TIPS
Q 2
(a) (b) 1 3
• The vertex pair for a loop
R
P is in the form (a, a).
7 • The vertex pairs for
multiple edges are in the
S 6 4 forms (a, b), (a, b).
5
Example 6
Determine whether a graph with the following degrees of vertices can be drawn.
(a) 3, 2, 2, 1, 3 (b) 2, 1, 1, 3, 3, 2
Solution:
(a) Sum of degrees = 3 + 2 + 2 + 1 + 3 (b) Sum of degrees = 2 + 1 + 1 + 3 + 3 + 2
= 11 = 12
The graph cannot be drawn because The graph can be drawn because Saiz sebenar
the sum of degrees is odd. the sum of degrees is even.

133
Chapter 5 Network in Graph Theory

5.1a

1. Three simple graphs are given below.


(a) 1 e1 2 e3 3 (b) Q R S (c) A B C

e2 e4
e5 e6

P D
e7 F E
5 4 W V U T
For each graph, determine
(i) V and n(V) (ii) E and n(E) (iii) sum of degrees

2. Two graphs with multiple edges and loops are given below.
(a) (b) P Q
A B

U R
C O

E
5

D
T S
CHAPTER

For each graph, determine


(i) V and n(V). (ii) E and n(E). (iii) sum of degrees.

3. Draw a simple graph based on the given information.


(a) V = {1, 2, 3, 4, 5, 6}
E = {(1, 6), (2, 6), (3, 6), (3, 4), (3, 5), (4, 5), (5, 6)}

(b) V = {P, Q, R, S, T, U}
E = {(P, U), (P, T), (Q, U), (Q, T), (Q, R), (R, S), (R, T), (S, T)}

4. Draw a graph with multiple edges and loops based on the given information.
(a) V = {P, Q, R, S}
E = {(P, S), (P, S), (Q, R), (Q, R), (P, P), (S, S), (Q, Q), (R, R), (P, Q), (R, S)}

(b) V = {1, 2, 3, 4, 5}
E = {(1, 5), (1, 5), (3, 5), (3, 5), (1, 1), (3, 3), (2, 1), (2, 3), (2, 5), (4, 1), (4, 3), (4, 5)}

5. Draw a simple graph with the given degrees of vertices.


(a) 2, 3, 2, 3, 4 (b) 1, 2, 3, 3, 3, 2

6. Draw a graph with loops and multiple edges with the given degrees of vertices.
(a) 3, 3, 4
Saiz sebenar (b) 2, 2, 4, 6, 6

134
Chapter 5 Network in Graph Theory

What is the difference between a directed graph and Learning


an undirected graph? Standard
Compare and contrast
A directed graph is a graph in which a direction is assigned to the edge ● directed graphs and
connecting two vertices. Directed graphs are usually used to represent undirected graphs.
● weighted graphs and
the flow of a certain process. For example, road maps, airlines networks,
unweighted graphs
electrical circuits, computer networks and organisation charts.

B
INTERACTIVE ZONE
> The blood circulation

>
system in the human
A > body is also categorised
C as a directed graph.
Diagram 1 Why?

Diagram 1 shows a simple directed graph. Based on the directions of


the arrows, it can be seen that, INTERACTIVE ZONE

5
(a) for edge AB, A is the initial vertex and B is the terminal vertex. For electricity networks,

CHAPTER
power stations,
(b) for edge CB, C is the initial vertex and B is the terminal vertex. transformer stations,
substations and
(c) all vertices are connected in one direction only. consumers are the
vertices, and the cables
and wires are the edges.
Is an electricity network
P
a directed graph or
e1
> an undirected graph?
e5 Q Discuss.
>

e2
>

e4 >
e3
R

Diagram 2

Diagram 2 shows a directed graph with a loop and multiple edges. Based on the directions of the
arrows, it can be seen that
(a) e4 = (P, R); P is the initial vertex and R is the terminal vertex.
(b) e5 = (R, P); R is the initial vertex and P is the terminal vertex.
(c) e2 = (Q, Q); Q is the initial vertex and the terminal vertex because e2 is a loop.

An undirected graph is a simple graph or a graph with loops and multiple edges drawn without
any direction being assigned.
Saiz sebenar

135
Chapter 5 Network in Graph Theory

Differences between directed graphs and undirected graphs

Type of
Graph Set V and Set E Degrees
graph

Undirected graph V = {A, B, C, D} d(A) = 2, d(B) = 2,


A D E = {(A, B), (A, C), d(C) = 3, d(D) = 1
(B, C), (C, D)} Σd(V) = 8
The order of the vertices written
is not important. Both pairs
of vertices, (A, B) and (B, A)
represent the edge AB.
B C

Directed graph V = {A, B, C, D} din (A) = 2 and


E = {(B, A), (C, A), dout (A) = 0
A D
(B, C), (D, C)} Thus, d(A) = 2 + 0
Simple
graph d(A) = 2
The order of the vertices
>

>
>

are written according to the din (A) means the number


direction of the edge. (B, A) and of edges ‘going into’
5

> (A, B) represent different edges. vertex A.


B C
CHAPTER

dout (A) means the


number of edges ‘coming
out’ from vertex A.

din (B) = 0, dout (B) = 2


din (C) = 2, dout (C) = 1
din (D) = 0, dout (D) = 1
Σd(V) =8

Undirected graph V = {P, Q, R, S, T} d(P) = 2, d(Q) = 4


R E = {(P, T), (P, Q), (Q, R), d(R) = 2, d(S) = 2
(Q, R), (Q, S), (S, T), d(T) =4
P Q
(T, T)}
Σd(V) = 14

Graph with T S
loops and
multiple Directed graph V = {P, Q, R, S, T} din (P) = 1, dout (P) = 1
edges E = {(P, Q), (Q, R), (R, Q), din (Q) = 3, dout (Q) = 1
R
(S, Q), (T, S), (T, T), din (R) = 1, dout (R) = 1
> din (S) = 1, dout (S) = 1
P Q > (T, P)}
> din (T) = 1, dout (T) = 3
}
}

Loop = 1
>
>

Loop = 1
(T, P) = 1
> (T, S) = 1
T S
Saiz sebenar Σd(V) = 14

136
Chapter 5 Network in Graph Theory

What are the differences between weighted graphs and unweighted graphs?
Weighted graph Unweighted graph
Type of
Directed graph and undirected graph Directed graph and undirected graph
graph
Edge Associated with a value or a weight Not associated with a value or a weight
The edge represents: The edge relates information like:
• distance between two cities. • job hierarchy in an organisation chart.
Example • travelling time. • flow map.
• the current in an electrical circuit. • tree map.
• cost. • bubble map.

Example 7
Draw a directed graph based on the given information. INFO ZONE
(a) V = {P, Q, R, S, T, U} (b) There is a loop at vertex Q and For Example 7(a), the
E = {(P, Q), (P, R), RS is a multiple edge such that vertex U appears in
set V but not in set E.
(R, Q), (S, R), din (P) = 1, dout (P) = 1 This means vertex U is

5
din (Q) = 3, dout (Q) = 2 not connected to any
(S, Q), (S, T)}

CHAPTER
other vertices in the
din (R) = 0, dout (R) = 3 graph and it is known
din (S) = 3, dout (S) = 1 as an isolated vertex.

Solution:
(a) Vertex pair Direction

}
(P, Q) P to Q P > R
Two edges from vertex P
(P, R) P to R
(R, Q) R to Q One edge from vertex R >
>

>

}
(S, R) S to R
S
>
(S, Q) S to Q Three edges from vertex S Q
>

(S, T) S to T U T
Vertex T only connected to vertex S

(b) Total number of vertices = 4 RS – a multiple edge, Complete the graph based on the
A loop at vertex Q. number of edges going into and
coming out from each vertex.

P Q P Q P > Q

>
>
>

>
S R S R S > R Saiz sebenar

137
Chapter 5 Network in Graph Theory

Example 8 Start
v1
500
The diagram on the right shows one-way paths that Izarul can m
choose for his running practice. Vertex v1 is the starting position v3

0m
and vertex v5 is the ending position before he goes home.

60
m
Determine 900 500 m
(a) the shortest distance from v1 to v5.
v2 800 m
(b) the longest distance from v1 to v5. v4
(c) the vertices that must be passed through if the distance of the 50
0m
m
one-way run is between 1.4 km and 2.1 km. 500
v5
Solution: End

(a) Shortest distance (b) Longest distance (c) v1, v3, v4, v5
= v1  v2  v5 = v1  v2  v3  v4  v5 and
= (600 + 500) m = (600 + 900 + 500 + 500) m v1, v2, v4, v5
= 1 100 m = 2 500 m
= 1.1 km = 2.5 km

5.1b
1. State two differences between directed graphs and undirected graphs.
5
CHAPTER

2. What is the meaning of weight in a weighted graph?


3. Draw a directed graph based on the given information.
(a) V = {P, Q, R, S, T, U, V}
E = {(P, Q), (Q, R), (Q, S), (S, P), (S, R), (S, T), (U, T)}
(b) (i) There is a loop at vertex Q and a loop at vertex S. (iii) din (P) = 0, dout (P) = 2
(ii) QS is a multiple edge. din (Q) = 4, dout (Q) = 2
din (R) = 0, dout (R) = 2
din (S) = 4, dout (S) = 2

4. (a) Based on the information in Table 1 and Table 2, complete the weighted and undirected graph.
Name of place Vertex Vertex pair Weight (km)
Kuala Pilah KP (J, B) 11.6
Bahau B (KP, R) 40
J B
Rompin R (B, R) 20.7
KP
Batu Kikir BK (B, BK) 11.4
Juasseh J (BK, J ) 6.6
(KP, J ) 9.3

Table 1 Table 2 Incomplete graph

(b) Mr Benny and Mr Muruges drive individually from Kuala Pilah to Rompin such that:
(i) Mr Benny uses the shortest route.
(ii) Mr Muruges takes the route which passes through Juasseh and Bahau.
Calculate the difference in distance, in km, for the journeys taken by Mr Benny and Mr
Saiz sebenarMuruges from Kuala Pilah to Rompin.

138
Chapter 5 Network in Graph Theory

How do you identify and draw subgraphs and trees?


Learning
What do you understand about a subgraph? Standard
A subgraph is part of a graph or the whole graph redrawn without Identify and draw
changing the original positions of the vertices and edges. A graph H is subgraphs and trees.
said to be a subgraph of G if,
(a) the vertex set of graph H is a subset of the vertex set of graph G, that is V(H)  V(G).
(b) the edge set of graph H is a subset of the edge set of graph G, that is E(H)  E(G).
(c) the vertex pairs of the edges of graph H are the same as the edges of graph G.
In short,
• a vertex in graph G is a subgraph of graph G.
INFO ZONE
• an edge in graph G along with the vertices it connects
is a subgraph of graph G. The symbol ⊆ also
• each graph is a subgraph of itself. stands for subset.

Example 9
Determine whether Diagram 1, Diagram 2, Diagram 3 and Diagram 4 are the subgraphs of graph G.
P e1 Q e2 P e2 P e1 Q P Q e2 P e1 Q e3

5
CHAPTER
e5 e3 e5 e5 e3 e5 e2

S e4 R S S S S e4 R
Graph G Diagram 1 Diagram 2 Diagram 3 Diagram 4

Solution:
Diagram 1 – Yes, because the vertex pair for edge e5 is the same.
{e5} ⊂ {e1, e2, e3, e4, e5} and {P, S} ⊂ {P, Q, R, S}
Diagram 2 – No, because the position of loop e2 is not on vertex Q.
Diagram 3 – No, because the edge connecting vertex P and vertex S is not e3.
Diagram 4 – No, because the loop and the edge connecting vertex Q and vertex R are wrong.

INFO ZONE
What do you understand about a tree?
The term tree was
A tree of a graph is a subgraph of the graph with the following introduced by Arthur
properties: Cayley, an English
mathematician, in the
(a) A simple graph without loops and multiple edges. year 1857.
(b) All the vertices are connected and each pair of vertices is
connected by only one edge.
(c) Number of edges = Number of vertices – 1
INFO ZONE
Number of vertices = n A family history chart is
Number of edges = n – 1 Saiz
an example of a tree. sebenar

139
Chapter 5 Network in Graph Theory

A
E Diagram 1 is a tree because
B
• all the vertices are connected.
• every pair of vertices is connected by an edge only.
C D • there are no loops or multiple edges.
Diagram 1 • 5 vertices, 4 edges.

A
E Diagram 2 is not a tree because
B
• vertex B and vertex E can be connected in two ways.
C D (i) B  E
Diagram 2
(ii) B  C  D  E
• 5 vertices, 5 edges.

Example 10
Determine whether each of the following graphs is a tree. Justify your answer.
(a) P (b) P R (c) P R (d) P
5

Q R Q Q Q R
CHAPTER

U T S U T S U T S U T S

Solution:
(a) Not a tree. 6 vertices, 7 edges. Each pair of vertices can be connected in various ways.
(b) A tree. 6 vertices, 5 edges. Each pair of vertices is connected by one edge.
(c) A tree. 6 vertices, 5 edges. Each pair of vertices is connected by one edge.
(d) Not a tree. 6 vertices, 4 edges. Vertex R and vertex T are not connected to the other vertices.

Example 11
Draw a tree for the following information given.
(a) 6 vertices (b) 8 vertices (c) 4 edges (d) 9 edges
Solution:
(a) 6 vertices (b) 8 vertices (c) 4 edges (d) 9 edges
5 edges 7 edges 5 vertices 10 vertices

Saiz sebenar

140
Chapter 5 Network in Graph Theory

Example 12
Draw two trees based on the graphs given below.
INFO ZONE
(a) (b)
Trees are used to
determine the shortest
path with the condition
that the path passes
through each vertex
once only.
Solution:
(a) 5 vertices (b) 6 vertices
7 edges (exceed by 3) 8 edges (exceed by 3)
(i) (ii) (i) (ii)

Example 13

5
The following diagram shows an undirected weighted graph. Draw a tree with a minimum

CHAPTER
total weight.
Q R
20

25 10 12 17

P 19 T 14 S
Solution:
Step 1 Langkah
Step 22

5 vertices, 7 edges • Between the weights 19 and 25, keep


• 3 edges to be removed. weight 19 because its weight is smaller.
• Remove edges with the greatest weights • Between the weights 12, 14 and 17,
(PQ, QR, PT) remove weight 17.

Q Q R
R

10 12 17 10 12

P T 14 S P 19 T 14 S

The graph above is not a tree because The graph obtained is a tree.
• vertex P is not connected to the other vertices. Minimum total weight of the tree
= 10 + 12 + 14 + 19
• three edges, RS, ST and RT, connect three
= 55
Saiz sebenar
vertices only.
141
Chapter 5 Network in Graph Theory

5.1c
1. Determine whether the given diagrams are the subgraphs of graph G.
e2 e2 P e2 P
P P P
e1 e3 e4

Q e4 R R Q R Q R Q
Graph G Diagram 1 Diagram 2 Diagram 3 Diagram 4 Diagram 5
e1 P e2 e2 Q e4 R e2
P P Q P
e3 e1 e2 e1 e1 e1 e3 e1 e3
P
R Q e3 R Q e4 R P e4 R e2 Q e4 R
Diagram 6 Diagram 7 Diagram 8 Diagram 9 Diagram 10 Diagram 11

2. Draw five subgraphs for each given graph.


e4
(a) P (b) P S (c) P e4 e3
R
e3 e5
e1 e1 e1
5

e3 e2
CHAPTER

Q e2 R Q e2 R Q

3. Identify whether it is a tree or not a tree for the following diagrams.


(a) (b) (c) (d)

4. Draw a tree based on the given information.


(a) 7 vertices (b) 9 vertices (c) 5 edges (d) 9 edges

5. Draw two trees based on the given graphs.


(a) (b)

Q
38
6. The diagram on the right shows an undirected 24
20 U 36 R
weighted graph. P
(a) Draw a tree with a minimum total weight. 32 18
(b) What is the minimum total weight? 34 42 S
Saiz sebenar 30
T

142
Chapter 5 Network in Graph Theory

How would you represent information in the form of networks?

A network is a type of unique graph and can be used to represent Learning


overlapping and intersecting information. Networks are widely used Standard
in almost every area of our daily lives. A network that is drawn and
Represent information
displayed in graphic forms enables the interrelationships between in the form of networks.
various information or data structures to be understood easily.
Networks can be drawn as:
• directed weighted graph or directed unweighted graph
• undirected weighted graph or undirected unweighted graph

Transportation Networks
Transportation networks can be shown as
weighted graphs and unweighted graphs.
The weights can represent the distance,
travelling time or cost of the journey. The
well known navigation system in the weighted
transportation networks is the GPS (Global
Positioning System).

5
The diagram on the right shows the train

CHAPTER
transit network in Kuala Lumpur Sentral
(KL Sentral). This undirected graph is an
example of transportation networks with the
vertices representing names of stations that are
connected and the edges representing the types
of trains.

Example 14
Mr Voon and his family plan to visit historical
places in Melaka. The map shows three
alternative routes with the distances and
estimated times needed to travel from Tangkak
to A Famosa, Melaka.
Assume P is a 46.3-kilometre route, Q is a
50.2-kilometre route and R is a 53.3-kilometre
route. In your opinion, why does route P take
the longest time compared to the other routes
even though route P is the shortest route?

Solution:
Route P takes the longest time because the route passes through crowded town areas and there are
more road users compared to the other two routes.
Saiz sebenar

143
Chapter 5 Network in Graph Theory

Social Networks

Social networks are becoming more popular among teenagers and Smart Mind
adults. Social networks are used in areas like job opportunities,
business opportunities, socialising, family relationships, education, State a social network
social media and connecting with communities around the world. that you know of.
Even though social networks are main platforms for various
activities and are useful, you should be cautious and moderate in using
social networks to avoid being distracted and being deceived easily. INTERACTIVE ZONE
Discuss the negative
effects of using social
networks.

Example 15
The table below shows the data of six pupils and the games that they like. Represent the information
in the form of a network.

Name of pupil Game


Smart Mind
5

Edmund Badminton, Chess


CHAPTER

Smart Mind
What are the meanings
Azwan Football, Sepak takraw of LTE and 4G which
are often used in
Rajan Chess, Football wireless Internet
networks?
Aina Chess, Netball

Maria Badminton, Netball INTERACTIVE ZONE


Jenny Netball, Volleyball Solving criminal cases is
also related to graphs.
All evidence obtained are
linked to one another.
Solution:
Discuss information that
Let the vertices represent types of games and the edges can be represented by
represent the pupils’ names. the vertices and edges
of graph.

Chess Rajan Football Azwan


Sepak takraw
Ain TIPS
a
Choose information that is
Edmund

Netball
not repeated as the edges.
ria
Ma
Je
nn
y

Badminton Volleyball INTERACTIVE ZONE


Is the food chain a
Saiz sebenar network? Discuss.

144
Chapter 5 Network in Graph Theory

5.1d

Name of place Vertex Vertex pair Distance (km) M K

Kuala Sepetang KS (KS, M ) 8


Matang M (K, M ) 8.4 S T
KS
(K, T ) 5.2
Kamunting K
(S, T ) 5.9
Simpang S
(S, M ) 3.5 CJ
Taiping T
(S, KS ) 11
Diagram 1
Changkat CJ
(CJ, S ) 4.9
Table 1 (CJ, KS ) 15
(CJ, T ) 10
Table 2
1. Table 1 and Table 2 show names and distances of six places in Perak. Diagram 1 shows an

5
incomplete undirected graph connecting the six places.

CHAPTER
(a) Complete Diagram 1 by drawing an undirected weighted graph.
(b) Draw a tree with a minimum total weight which shows every place being visited once only.
(c) What is the minimum distance of the tree that you have drawn?

2. The table below shows four types of favourite food of several pupils.

Food Name of pupil


Chicken rice Mervin, Raj, Helen, Wong, Ain
Nasi lemak Mervin, Nurul, Atiqah, Ain, Puspa
Fried rice Helen, Julia, Nurul, Faruk, Puspa
Fried noodles Faruk, Atiqah, Raj, Wong, Julia

(a) Based on the table, draw a graph with multiple edges.


(b) Between the types of food and the names of pupils, which group will you use to represent
the vertices? Justify your answer.
(c) What is the relationship between the sum of degrees of your graph with the total number
of food choices?
(d) Between table form and graph form, which form is clearer in showing the relationship
between the types of food and the pupils?

3. (a) Draw an organisation chart of your class using your own creativity.
(b) State the type of graph you have used. Is the class organisation chart a network? Justify
your answer. Saiz sebenar

145
Chapter 5 Network in Graph Theory

How do you solve problems involving networks? Learning


Standard
Example 16 Solve problems
involving networks.
The table below shows the choices of public transportation, estimated
travelling time and estimated cost for a journey from Johor Bahru
to Kota Bharu.

Estimated Estimated expenses


Type of Travelling time
duration of
transportation (24-hour system) Price of ticket per person/cost of fuel
journey
Bus 2000 hours 9 hours RM64 – RM75
With bed
Child: RM32 – RM38
Adult: RM49 – RM55
Train (1833 – 1147) hours 17 hours
Without bed
Child: RM26
Adult: RM43
5

Cab – 9 hours RM120 (for one cab)


CHAPTER

Based on the table, determine the type of transportation that should be chosen for the situation
given below. Justify your answer.
(a) A journey involving an adult without time constraint.
(b) A journey involving an adult with time constraint.
(c) A journey involving two adults and two children.

Solution:

Price of ticket per person (RM)


Type of transportation
Minimum Maximum
Bus 64 75
Child = 32 Child = 38
Train (With bed)
Adult = 49 Adult = 55
Child = 26
Train (Without bed) –
Adult = 44
(a) Taking a train with bed is the best choice because the difference in price is only RM5 compared
to taking a train without bed. The passengers can have a good rest throughout the whole journey.
This choice is also cheaper compared to taking a cab.
(b) Taking a bus is the best choice because the duration of journey is shorter than that of a train and
it is more economical than taking a cab. For safety purpose, it is not wise for an individual to
take a cab for a long journey.
Saiz sebenar
(c) Taking a cab is the most economical choice.

146
Chapter 5 Network in Graph Theory

Example 17

The map above shows the domestic flight routes of a private airline in Malaysia.
(a) Mr Joshua works in Kuala Lumpur. He wants to visit his family in Kota Kinabalu. State the
best route Mr Joshua can choose.
(b) What are the advantages and disadvantages for the choice of flight made?

Solution:

5
(a) The direct flight from Kuala Lumpur to Kota Kinabalu.

CHAPTER
(b) The direct flight from Kuala Lumpur to Kota Kinabalu saves time and cost. The flight from
Kuala Lumpur to Kota Kinabalu with transit takes a longer time and most probably the cost of
the journey is also higher.

5.1e

1. Mr Maswi works in Kulai. He plans to visit his family in Miri on a certain weekend. On Friday,
Mr Maswi’s work ends at 12.30 noon. The table below shows the choices of domestic flight
routes of a private airline in Malaysia on Friday and Saturday for that week.
Friday Saturday
Route
Time Price of ticket Time Price of ticket
Johor Bahru
No flight (1705 – 1900) hrs RM259.30
- Miri
Johor Bahru (1630 – 1755) hrs RM144.30 (0605 – 0730) hrs RM174.30
- Kuching (1930 – 2055) hrs RM124.30 (1205 – 1330) hrs RM154.30
Kuching (2010 – 2115) hrs RM149.00 (0835 – 0940) hrs RM84.00
- Miri (2155 – 2300) hrs RM149.00 (1145 – 1250) hrs RM64.00

(a) Determine the most economical flight from Johor Bahru to Miri.
(b) Determine the best flight that Mr Maswi can choose if he needs to go back to Peninsular
Malaysia on Sunday. Give your reason.
Saiz sebenar

147
Chapter 5 Network in Graph Theory

1. Three graphs are given below.


(a) P Q (b) (c) Q R
R
P U
U R

T S T
P

T S Q S

For each graph, determine


(i) set V. (ii) set E. (iii) sum of degrees.

2. Draw an undirected graph based on the given information.


(a) V = {P, Q, R, S, T, U}
5

E = {(P, Q), (Q, R), (R, S), (S, T)}


CHAPTER

(b) V = {P, Q, R, S, T}
E = {(P, Q), (P, Q), (Q, R), (Q, T), (R, S), (S, S), (S, T)}

3. (a) D
 raw an undirected weighted graph to Name of town Distance (km)
represent the federal roads connecting a
few towns as shown in the table. You are Temerloh - Mentakab 9.3
advised to use an area map to determine Temerloh - Bandar Bera 30.2
the positions of the towns. Bandar Bera - Teriang 4.9
(b) I s the graph that you have drawn a tree? Mentakab - Lanchang 21.1
Justify your answer. Lanchang - Karak 21.9
Mentakab - Kuala Krau 34.6

800 m C
4. The directed graph on the right shows the D
roads connecting Lani’s house at A to the 350 m
school at E. The edge BE is a municipal road
A
and edges AB, AC, CD and DE are roads in 650 m
the housing estates. Suggest the best route
400 m
that Lani can choose to cycle to school.
Justify your answer. E B
School 1.1 km

Saiz sebenar

148
Chapter 5 Network in Graph Theory

5. The directed weighted graph on the right shows .5 hours)


R
RM130 (1
the prices of tickets and the travel times for some

RM
P

)
ur

65
choices of flights of a private airline. Vertex S is the RM

ho
200

(1.
RM

.8
destination of the flight from vertex P. Vertex Q and

(0

1h
(3 h


50
ours

our
vertex R are the transit airports. The transit time at )

45
(1

s)
RM
each of the airports is 45 minutes.

h
ou
S

r)
s)
(a) State Q RM115 (1.4 hour

(i) the most economical route.


(ii) the route that takes the shortest time.
(b) If you need to go to a destination at optimum cost, state the route that you will choose.
Justify your answer.

6. Write five linear equations based on the directed graph below.


Given x5 = 15, determine the values of x1, x2, x3 and x4. TIPS
11 B
A Use Σdin = Σdout for each
vertex.
x2 x3
x1 C

5
x4

CHAPTER
10
10

D E
x5

7. The following undirected graph shows six houses in a village. A salesperson needs to visit all
the houses starting from house A and finishing at house F.
F
800 m
D

m 85
750 0m
m
m

450
500

A 650 m C 850 m
E
90 600 m
0m
m
780
B

(a) Draw a directed graph to represent the shortest distance from A to F with the condition that
all the paths are taken once only.
(b) Based on your graph, calculate the shortest distance in km.

Saiz sebenar

149
Chapter 5 Network in Graph Theory

8. The graph on the right shows the connections P G A


between the elements in set X, set Y and set Z, L
D
where the universal set, ξ = X  Y  Z. X
M
J Y
(a) Represent the graph in a Venn diagram.
(b) Determine B
E F
(i) (X  Y)' C H T
(ii) (X ∩ Z)' ∩ Y ' Z
(iii) (Y ∩ Z) ∩ (X ∩ Y) R N

K
I

9. Mr Ganesan is the manager of an insurance agency. He M


recruites two active insurance agents to sell the latest insurance
scheme valued at RM100 per month. Besides selling insurance
policies, each agent needs to recommend at least two new A1 A1
insurance agents. In the incomplete tree on the right, M
represents the manager, A1 represents the first level agents and
A2 represents the second level agents.
5

A2
CHAPTER

(a) If there are 30 agents in January, complete the given tree.


(b) The table on the right shows the percentages of basic
commission received by an agent and the manager for Agent 25%
an insurance policy sold. Manager 2%
(i) C
 alculate the total basic commission received by
Mr Ganesan in January if the minimum number of
insurance policies sold by an agent in January is 18.
(ii) W
 hat is the minimum number of policies that an agent needs to sell in order to
receive a basic commission of at least RM1 000?

10. The diagram on the right shows the growth of a type of cell.
It is given that on the first day, there are four cells. On the
second day, each cell produces three cells. On the following
day, each new cell produces another three new cells. The
process of producing new cells repeats at the same rate.
(a) On which day will the total number of cells exceeds 50
for the first time?
(b) Calculate the total number of cells on the fifth day.
(c) Given the life span of a cell is 5 days, calculate the total
number of cells on the eighth day.

Saiz sebenar

150
Chapter 5 Network in Graph Theory

P R O J E C T

1. A maze is an example of a network.


Diagram 1 shows an example of a maze whereas Diagram 2 is the corresponding
network.

Diagram 1

5
CHAPTER
I P Q R

X V
O N
J
H K

L M W S

D T U
E
Y Z
F G
A B C

Diagram 2
2. Divide the class into groups.
3. Obtain examples of mazes with different levels of difficulty.
4. Label the vertices with suitable letters as shown in Diagram 1.
5. Draw the corresponding networks.
6. Exhibit your project work at the Mathematics Corner.
Saiz sebenar

151
Chapter 5 Network in Graph Theory

CONCEPT MAP

Network in Graph Theory

Graph

Simple Has loops and multiple edges

Degree

Undirected graph Directed graph


5
CHAPTER

Subgraph Weighted graph


Q Q ance
dist
co
st
favourite

e
tim

P R P R
name
Q
Q

R Unweighted graph
P P

Q Q

R R

Q Tree (Simple graph)

P R
P R
Q Q

P R P R
Saiz sebenar

152
Chapter 5 Network in Graph Theory

Self Reflection

Complete the following statements with the answers provided.

subgraph weighted graph degree simple graph


directed graph edge tree loop

1. An is a line which connects two vertices.

2. The is the number of edges which connects two vertices.

3. A graph without a and without multiple edges is known


as a .

4. Edges of a are associated with directions.

5. Edges of a are associated with values or information.

6. A is part of a graph or the whole graph redrawn.

5
7. Every pair of vertices in a is connected by an edge only.

CHAPTER
 Mathematics Exploration

Gather information and prepare a multimedia presentation on one of the networks given below.

Banking
Medicine

Social

Language Computer science

Include pictures, video or interesting materials to make your presentation more creative and
informative. Saiz sebenar

153

You might also like