Post on 19-Aug-2020
transcript
The Mathematics of Networks (Chapter 7)
We have studied how to visit all the edges of a graph (via anEuler path or circuit) and how to visit all the vertices (via aHamilton circuit).
What if we just want to connect all the verticestogether into a network?
In other words, What if we just want to connect all thevertices together in a network?
I Roads, railroads
I Telephone lines
I Fiber-optic cable
The Mathematics of Networks (Chapter 7)
We have studied how to visit all the edges of a graph (via anEuler path or circuit) and how to visit all the vertices (via aHamilton circuit).
What if we just want to connect all the verticestogether into a network?
In other words, What if we just want to connect all thevertices together in a network?
I Roads, railroads
I Telephone lines
I Fiber-optic cable
The Mathematics of Networks (Chapter 7)
We have studied how to visit all the edges of a graph (via anEuler path or circuit) and how to visit all the vertices (via aHamilton circuit).
What if we just want to connect all the verticestogether into a network?
In other words, What if we just want to connect all thevertices together in a network?
I Roads, railroads
I Telephone lines
I Fiber-optic cable
The Mathematics of Networks (Chapter 7)
We have studied how to visit all the edges of a graph (via anEuler path or circuit) and how to visit all the vertices (via aHamilton circuit).
What if we just want to connect all the verticestogether into a network?
In other words, What if we just want to connect all thevertices together in a network?
I Roads, railroads
I Telephone lines
I Fiber-optic cable
Hobart
Canberra
Sydney
Brisbane
Mackay
Cairns
Mount Isa
Alice Springs
Kununurra
Darwin
Perth
Albany
(SY)(PE)
(MI)
(CN)
(HO)
(KU)
(UL)Uluru
(MK)
(DA)
(AL)
(AS)
(CS)
(BR)
(BM)Broome
Melbourne (ML)
Adelaide (AD)
Hobart
Canberra
Sydney
Brisbane
Mackay
Cairns
Mount Isa
Alice Springs
Kununurra
Darwin
Perth
Albany
(SY)(PE)
(MI)
(CN)
(HO)
(KU)
(MK)
(DA)
(AL)
(AS)
(CS)
(BR)
(BM)Broome
Melbourne (ML)
Adelaide (AD)
Uluru(UL)
Too many edges!
Hobart
Canberra
Sydney
Brisbane
Mackay
Cairns
Mount Isa
Alice Springs
Kununurra
Darwin
Perth
Albany
(SY)(PE)
(MI)
(CN)
(HO)
(KU)
(MK)
(DA)
(AL)
(AS)
(CS)
(BR)
(BM)Broome
Melbourne (ML)
Adelaide (AD)
Uluru(UL)
Still too many edges
Hobart
Canberra
Sydney
Brisbane
Mackay
Cairns
Mount Isa
Alice Springs
Kununurra
Darwin
Perth
Albany
(SY)(PE)
(MI)
(CN)
(HO)
(KU)
(MK)
(DA)
(AL)
(AS)
(CS)
(BR)
(BM)Broome
Melbourne (ML)
Adelaide (AD)
Uluru(UL)
Just right
Hobart
Canberra
Sydney
Brisbane
Mackay
Cairns
Mount Isa
Alice Springs
Kununurra
Darwin
Perth
Albany
(SY)(PE)
(MI)
(CN)
(HO)
(KU)
(MK)
(DA)
(AL)
(AS)
(CS)
(BR)
(BM)Broome
Melbourne (ML)
Adelaide (AD)
Uluru(UL)
Another possibility
Hobart
Canberra
Sydney
Brisbane
Mackay
Cairns
Mount Isa
Alice Springs
Kununurra
Darwin
Perth
Albany
(SY)(PE)
(MI)
(CN)
(HO)
(KU)
(MK)
(DA)
(AL)
(AS)
(CS)
(BR)
(BM)Broome
Melbourne (ML)
Adelaide (AD)
Uluru(UL)
Not enough edges
Hobart
Canberra
Sydney
Brisbane
Mackay
Cairns
Mount Isa
Alice Springs
Kununurra
Darwin
Perth
Albany
(SY)(PE)
(MI)
(CN)
(HO)
(KU)
(MK)
(DA)
(AL)
(AS)
(CS)
(BR)
(BM)Broome
Melbourne (ML)
Adelaide (AD)
Uluru(UL)
Networks and Spanning Trees
Definition: A network is a connected graph.
Definition: A spanning tree of a network is a subgraphthat
1. connects all the vertices together; and
2. contains no circuits.
In graph theory terms, a spanning tree is a subgraph that isboth connected and acyclic.
A spanning tree
Hobart
Canberra
Sydney
Brisbane
Mackay
Cairns
Mount Isa
Alice Springs
Kununurra
Darwin
Perth
Albany
(SY)(PE)
(MI)
(CN)
(HO)
(KU)
(MK)
(DA)
(AL)
(AS)
(CS)
(BR)
(BM)Broome
Melbourne (ML)
Adelaide (AD)
Uluru(UL)
A spanning tree
Hobart
Canberra
Sydney
Brisbane
Mackay
Cairns
Mount Isa
Alice Springs
Kununurra
Darwin
Perth
Albany
(SY)(PE)
(MI)
(CN)
(HO)
(KU)
(MK)
(DA)
(AL)
(AS)
(CS)
(BR)
(BM)Broome
Melbourne (ML)
Adelaide (AD)
Uluru(UL)
Not a spanning tree
(not connected)
Hobart
Canberra
Sydney
Brisbane
Mackay
Cairns
Mount Isa
Alice Springs
Kununurra
Darwin
Perth
Albany
(SY)(PE)
(MI)
(CN)
(HO)
(KU)
(MK)
(DA)
(AL)
(AS)
(CS)
(BR)
(BM)Broome
Melbourne (ML)
Adelaide (AD)
Uluru(UL)
Not a spanning tree
(connected, but has a circuit)
Hobart
Canberra
Sydney
Brisbane
Mackay
Cairns
Mount Isa
Alice Springs
Kununurra
Darwin
Perth
Albany
(SY)(PE)
(MI)
(CN)
(HO)
(KU)
(MK)
(DA)
(AL)
(AS)
(CS)
(BR)
(BM)Broome
Melbourne (ML)
Adelaide (AD)
Uluru(UL)
Not a spanning tree
(connected, but has a circuit)
Hobart
Canberra
Sydney
Brisbane
Mackay
Cairns
Mount Isa
Alice Springs
Kununurra
Darwin
Perth
Albany
(SY)(PE)
(MI)
(CN)
(HO)
(KU)
(MK)
(DA)
(AL)
(AS)
(CS)
(BR)
(BM)Broome
Melbourne (ML)
Adelaide (AD)
Uluru(UL)
The Number of Edges in a Spanning Tree
In a network with N vertices, how many edges does aspanning tree have?
The Number of Edges in a Spanning Tree
I Imagine starting with N isolated vertices and addingedges one at a time.
I Each time you add an edge, you either
I connect two components together, or
I
I Stop when the graph is connected (i.e., has only onecomponent).
I You have added exactly N − 1 edges.
In a network with N vertices, every spanning tree hasexactly N − 1 edges.
The Number of Edges in a Spanning Tree
I Imagine starting with N isolated vertices and addingedges one at a time.
I Each time you add an edge, you eitherI connect two components together, orI close a circuit
I Stop when the graph is connected (i.e., has only onecomponent).
I You have added exactly N − 1 edges.
In a network with N vertices, every spanning tree hasexactly N − 1 edges.
The Number of Edges in a Spanning Tree
I Imagine starting with N isolated vertices and addingedges one at a time.
I Each time you add an edge, you eitherI connect two components together, orI close a circuit
I Stop when the graph is connected (i.e., has only onecomponent).
I You have added exactly N − 1 edges.
In a network with N vertices, every spanning tree hasexactly N − 1 edges.
The Number of Edges in a Spanning Tree
I Imagine starting with N isolated vertices and addingedges one at a time.
I Each time you add an edge, you eitherI connect two components together, orI close a circuit
I Stop when the graph is connected (i.e., has only onecomponent).
I You have added exactly N − 1 edges.
In a network with N vertices, every spanning tree hasexactly N − 1 edges.
The Number of Edges in a Spanning Tree
I Imagine starting with N isolated vertices and addingedges one at a time.
I Each time you add an edge, you eitherI connect two components together, orI close a circuit
I Stop when the graph is connected (i.e., has only onecomponent).
I You have added exactly N − 1 edges.
In a network with N vertices, every spanning tree hasexactly N − 1 edges.
The Number of Edges in a Spanning Tree
I Imagine starting with N isolated vertices and addingedges one at a time.
I Each time you add an edge, you eitherI connect two components together, orI close a circuit
I Stop when the graph is connected (i.e., has only onecomponent).
I You have added exactly N − 1 edges.
In a network with N vertices, every spanning tree hasexactly N − 1 edges.
The Number of Edges in a Spanning Tree
In a network with N vertices, every spanning tree hasexactly N − 1 edges.
Must every set of N − 1 edges form a spanning tree?
The Number of Edges in a Spanning Tree
In a network with N vertices, every spanning tree hasexactly N − 1 edges.
Must every set of N − 1 edges form a spanning tree?
The Number of Edges in a Spanning Tree
Answer: No.
For example, suppose the network is K4.
Spanning tree Spanning tree Not a spanning tree
Spanning Trees in K2 and K3
K3
K2
32
1
32
1
32
1
1 2
Spanning Trees in K4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
Facts about Spanning Trees
Suppose we have a network with N vertices.
1. Every spanning tree has exactly N − 1 edges.
2. If a set of N − 1 edges is acyclic, then it connects all thevertices, so it is a spanning tree.
3. If a set of N − 1 edges connects all the vertices, then it isacyclic, so it is a spanning tree.
Facts about Spanning Trees
Suppose we have a network with N vertices.
1. Every spanning tree has exactly N − 1 edges.
2. If a set of N − 1 edges is acyclic, then it connects all thevertices, so it is a spanning tree.
3. If a set of N − 1 edges connects all the vertices, then it isacyclic, so it is a spanning tree.
Facts about Spanning Trees
Suppose we have a network with N vertices.
1. Every spanning tree has exactly N − 1 edges.
2. If a set of N − 1 edges is acyclic, then it connects all thevertices, so it is a spanning tree.
3. If a set of N − 1 edges connects all the vertices, then it isacyclic, so it is a spanning tree.
Facts about Spanning Trees
4. In a network with N vertices and M edges,
M ≥ N − 1
(otherwise it couldn’t possibly be connected!) That is,
M − N + 1 ≥ 0.
The number M − N + 1 is called the redundancy of thenetwork, denoted by R .
5. If R = 0, then the network is itself a tree.If R > 0, then there are usually several spanning trees.
Facts about Spanning Trees
4. In a network with N vertices and M edges,
M ≥ N − 1
(otherwise it couldn’t possibly be connected!) That is,
M − N + 1 ≥ 0.
The number M − N + 1 is called the redundancy of thenetwork, denoted by R .
5. If R = 0, then the network is itself a tree.If R > 0, then there are usually several spanning trees.
Counting Spanning Trees
We now know that every spanning tree of an N-vertex networkhas exactly N − 1 edges.
How many different spanning trees are there?
Of course, this answer depends on the network itself.
Counting Spanning Trees
We now know that every spanning tree of an N-vertex networkhas exactly N − 1 edges.
How many different spanning trees are there?
Of course, this answer depends on the network itself.
Counting Spanning Trees
We now know that every spanning tree of an N-vertex networkhas exactly N − 1 edges.
How many different spanning trees are there?
Of course, this answer depends on the network itself.
Loops and Bridges
I If an edge of a network is a loop, then it is not in anyspanning tree.
I If an edge of a network is a bridge, then it must belongto every spanning tree.
Loops and Bridges
I If an edge of a network is a loop, then it is not in anyspanning tree.
I If an edge of a network is a bridge, then it must belongto every spanning tree.
Loops and Bridges
I If an edge of a network is a loop, then it is not in anyspanning tree.
I If an edge of a network is a bridge, then it must belongto every spanning tree.
Loops and Bridges
I If an edge of a network is a loop, then it is not in anyspanning tree.
I If an edge of a network is a bridge, then it must belongto every spanning tree.
bridge
Loops and Bridges
I If an edge of a network is a loop, then it is not in anyspanning tree.
I If an edge of a network is a bridge, then it must belongto every spanning tree.
Loops and Bridges
I If an edge of a network is a loop, then it is not in anyspanning tree.
I If an edge of a network is a bridge, then it must belongto every spanning tree.
Loops and Bridges
I If an edge of a network is a loop, then it is not in anyspanning tree.
I If an edge of a network is a bridge, then it must belongto every spanning tree.
Loops and Bridges
I If an edge of a network is a loop, then it is not in anyspanning tree.
I If an edge of a network is a bridge, then it must belongto every spanning tree.
Counting Spanning Trees
We now know that every spanning tree of an N-vertex networkhas exactly N − 1 edges.
How many different spanning trees are there?
Of course, this answer depends on the network itself.
Counting Spanning Trees
We now know that every spanning tree of an N-vertex networkhas exactly N − 1 edges.
How many different spanning trees are there?
Of course, this answer depends on the network itself.
Counting Spanning Trees
We now know that every spanning tree of an N-vertex networkhas exactly N − 1 edges.
How many different spanning trees are there?
Of course, this answer depends on the network itself.
Counting Spanning Trees
Counting Spanning Trees
Counting Spanning Trees
Counting Spanning Trees
Counting Spanning Trees
Counting Spanning Trees
Counting Spanning Trees
xof this triangleof this triangle
3 spanning trees 3 spanning trees
= 9 total spanning trees
Counting Spanning Trees
How many spanningtrees does thisnetwork have?
Counting Spanning Trees
bridges How many spanningtrees does thisnetwork have?
Counting Spanning Trees
bridges How many spanningtrees does thisnetwork have?
4
4
3
3
Counting Spanning Trees
bridges How many spanningtrees does thisnetwork have?
4
4
3
34 x 3 x 3 x 4 =Answer:
144.
Counting Spanning Trees
If the graph has circuits that overlap, it is trickier to countspanning trees. For example:
1 2
3 4
I There are N = 4 vertices =⇒every spanning tree has N − 1 = 3 edges.
I List all the sets of three edges and cross out the ones thatare not spanning trees.
Counting Spanning Trees
If the graph has circuits that overlap, it is trickier to countspanning trees. For example:
1 2
3 4
I There are N = 4 vertices =⇒every spanning tree has N − 1 = 3 edges.
I List all the sets of three edges and cross out the ones thatare not spanning trees.
Counting Spanning Trees
If the graph has circuits that overlap, it is trickier to countspanning trees. For example:
1 2
3 4
I There are N = 4 vertices =⇒every spanning tree has N − 1 = 3 edges.
I List all the sets of three edges and cross out the ones thatare not spanning trees.
Counting Spanning Trees
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
10 ways to select three edges
Counting Spanning Trees
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
1 2
3 4
2 are not treesTotal: 8 spanning trees
10 ways to select three edges
The Number of Spanning Trees of KN
(Not in Tannenbaum!)
Since KN has N vertices, we know that every spanning tree ofKN has N − 1 edges.
How many different spanning trees are there?
We have already seen the answers for K2, K3, and K4.
The Number of Spanning Trees of KN
(Not in Tannenbaum!)
Since KN has N vertices, we know that every spanning tree ofKN has N − 1 edges.
How many different spanning trees are there?
We have already seen the answers for K2, K3, and K4.
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
2 13 34 16
What’s the pattern?
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 12 13 34 16
What’s the pattern?
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 12 13 34 165 125
What’s the pattern?
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 12 13 34 165 1256 1296
What’s the pattern?
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 12 13 34 165 1256 12967 168078 262144
What’s the pattern?
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 12 13 34 165 1256 12967 168078 262144
What’s the pattern?
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 12 13 34 165 1256 12967 168078 262144
Cayley’s Formula:The number of spanning trees in KN is NN−2.
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 12 13 34 16 = 42
5 1256 12967 168078 262144
Cayley’s Formula:The number of spanning trees in KN is NN−2.
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 12 13 34 16 = 42
5 125 = 53
6 12967 168078 262144
Cayley’s Formula:The number of spanning trees in KN is NN−2.
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 12 13 3 = 31
4 16 = 42
5 125 = 53
6 12967 168078 262144
Cayley’s Formula:The number of spanning trees in KN is NN−2.
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 12 13 3 = 31
4 16 = 42
5 125 = 53
6 1296 = 64
7 168078 262144
Cayley’s Formula:The number of spanning trees in KN is NN−2.
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 12 13 3 = 31
4 16 = 42
5 125 = 53
6 1296 = 64
7 16807 = 75
8 262144
Cayley’s Formula:The number of spanning trees in KN is NN−2.
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 12 13 3 = 31
4 16 = 42
5 125 = 53
6 1296 = 64
7 16807 = 75
8 262144 = 86
Cayley’s Formula:The number of spanning trees in KN is NN−2.
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 12 1 = 20
3 3 = 31
4 16 = 42
5 125 = 53
6 1296 = 64
7 16807 = 75
8 262144 = 86
Cayley’s Formula:The number of spanning trees in KN is NN−2.
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 1 = 1−1
2 1 = 20
3 3 = 31
4 16 = 42
5 125 = 53
6 1296 = 64
7 16807 = 75
8 262144 = 86
Cayley’s Formula:The number of spanning trees in KN is NN−2.
The Number of Spanning Trees of KN
Number of vertices (N) Number of spanning trees in KN
1 1 = 1−1
2 1 = 20
3 3 = 31
4 16 = 42
5 125 = 53
6 1296 = 64
7 16807 = 75
8 262144 = 86
Cayley’s Formula:The number of spanning trees in KN is NN−2.
Cayley’s Formula:The number of spanning trees in KN is NN−2.
For example, K16 (the Australia graph!) has
1614 = 72, 057, 594, 037, 927, 936
spanning trees.
(By comparison, the number of Hamilton circuits is “only”
15! = 1, 307, 674, 368, 000.)