0% found this document useful (0 votes)
22 views42 pages

Chapter10 4

RETYU
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
22 views42 pages

Chapter10 4

RETYU
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 42

Section 10.

4
Connectivit
y
Section Summary
Paths
Connectedness in Undirected Graphs
Vertex Connectivity and Edge
Connectivity
Connectedness in Directed Graphs
Paths and Isomorphism
Counting Paths between Vertices
Paths
Informal Definition: A path is a sequence of edges
that begins at a vertex of a graph and travels from
vertex to vertex along edges of the graph. As the
path travels along its edges, it visits the vertices
along this path, that is, the endpoints of these.

Applications: Numerous problems can be modeled


with paths formed by traveling along edges of
graphs such as:
determining whether a message can be sent
between
 two computers.
 efficiently planning routes for mail delivery.
Paths This terminology is readily
extended to directed graphs.
(see text)
Definition: Let n be a nonnegative integer and G an
undirected graph. A path of length n from u to v in G is a
sequence of n edges e1, … , en of G for which there exists a
sequence x0 = u, x1, …, xn-1, xn = v of vertices such that ei
has, for i = 1, …, n, the endpoints xi-1 and xi.
 When the graph is simple, we denote this path by its
vertex sequence x0, x1, … , xn(since listing the vertices
uniquely determines the path).
 The path is a circuit if it begins and ends at the same
vertex (u = v) and has length greater than zero.
 The path or circuit is said to pass through the vertices x1,
x2, … , xn-1 and traverse the edges e1, … , en.
 A path or circuit is simple if it does not contain the same
edge more than once.
Paths (continued)
Example: In the simple graph here:

a, d, c, f, e is a simple path of length 4.


d, e, c, a is not a path because e is not

b, c, f, e, b is a circuit of length 4.
connected to c.

a, b, e, d, a, b is a path of length 5, but it is not a


simple path.
Degrees of
acquaintanceship 认
Separation [ə'kweɪntənsʃɪp] n.

Example: Paths in Acquaintanceship


Graphs. In an acquaintanceship graph there is
a path between two people if there is a chain of
people linking these people, where two people
adjacent in the chain know one another.

In this graph there is a


chain of six people
linking Kamini and
Ching.
Degrees of Separation

Some have speculated that almost


every pair of people in the world are
linked by a small chain of no more
than six, or maybe even, five people.
The play Six Degrees of Separation by
John Guare is based on this notion.
Erdős numbers
Paul
Example: Erdős numbers. Erdős
In a collaboration graph, two people a and b are
connected by a path when there is a sequence of
people starting with a and ending with b such that
the endpoints of each edge in the path are people
who have collaborated.
In the academic collaboration graph of people
who have written papers in mathematics, the Erdős
number of a person m is the length of the shortest
path between m and the prolific mathematician
Paul Erdős.
To learn more about Erdős numbers, visit
http://www.ams.org/mathscinet/collaborationDistance.htl
Bacon Numbrers
In the Hollywood graph, two actors
a and b are linked when there is a
chain of actors linking a and b,
where every two actors adjacent
in the chain have acted in the same movie.
The Bacon number of an actor c is defined to
be the length of the shortest path connecting c
and the well-known actor Kevin Bacon.
The oracle of Bacon web site
http://oracleofbacon.org/how.php provides a tool for
finding Bacon numbers.
Connectedness in Undirected
Graphs
Definition: An undirected graph is called
connected if there is a path between every pair of
vertices.
An undirected graph that is not connected is
called disconnected.
We say that we disconnect a graph when we
remove vertices or edges, or both, to produce a
disconnected subgraph.
Connectedness in
Undirected Graphs
Example: G1 is connected because there is
a path between any pair of its vertices, as
can be easily seen.
However G2 is not connected because there
is no path between vertices a and f, for
example.
Connected Components
Definition: A connected component of a graph G
is a connected subgraph of G that is not a proper
subgraph of another connected subgraph of G.
A graph G that is not connected has two or more
connected components that are disjoint and have
G as their union.
Connected Components
Example: The graph H is the union of three
disjoint subgraphs H1, H2, and H3, none of which
are proper subgraphs of a larger connected
subgraph of G. These three subgraphs are the
connected components of H.
How Connected is a
Graph?
Suppose that a graph represents a
computer network. Knowing that this
graph is connected tells us that any two
computers on the network can
communicate. However, we would also
like to understand how reliable this
network is.
For instance, will it still be possible for all
computers to communicate after a router
or a communications link fails?
How Connected is a
Graph?
Sometimes the removal from a graph of
a vertex and all incident edges produces a
subgraph with more connected
components. Such vertices are called cut
vertices (or articulation points).
cut vertices 割点
articulation points 关节点
The removal of a cut vertex from a
connected graph produces a subgraph that
is not connected.
How Connected is a
Graph?
Analogously, an edge whose removal
produces a graph with more connected
components than in the original graph is
called a cut edge or bridge.
cut edge 割边

Note that in a graph representing a


computer
network, a cut vertex and a cut edge
represent an essential router and an
essential link that cannot fail for all
computers to be able to communicate.
How Connected is a
Graph?
Example Find the cut vertices and cut
edges in the graph G1 shown below.
Solution The cut vertices of G1 are b, c,
and e. a d f g

b c e h
G1
How Connected is a
Graph?
Example Find the cut vertices and cut
edges in the graph G1 shown below.
Solution The cut vertices of G1 are b, c,
and e. a d f g

b c e h
G1
How Connected is a
Graph?
Example Find the cut vertices and cut
edges in the graph G1 shown below.
Solution The cut vertices of G1 are b, c,
and e. a d f g

b c e h
G1
How Connected is a
Graph?
Example Find the cut vertices and cut
edges in the graph G1 shown below.
Solution The cut vertices of G1 are b, c,
and e. a d f g

b c h
G1
How Connected is a
Graph?

Connected graphs without cut vertices


are called nonseparable graphs
How Connected is a
Graph?

We define the vertex connectivity of a


noncom-plete graph G, denoted by κ(G), as
the minimum number of vertices in a vertex
cut.
When G is a complete graph, it has no vertex cuts,
because removing any subset of its vertices and all
incident edges still leaves a complete graph.
How Connected is a
Graph?
The larger κ(G) is, the more connected we
consider G to be.

We say that a graph is k-connected (or k-v


ertex-connected), if κ(G) ≥ k.
How Connected is a
Graph?
EDGE CONNECTIVITY If a graph has a cut
edge, then we need only remove it to
disconnect G. If G does not have a cut
edge, we look for the smallest set of edges
that can be removed to disconnect it. A set
of edges E is called an edge cut of G if the
subgraph G − E is disconnected.
How Connected is a
Graph?
The edge connectivity of a graph G,
denoted by λ(G), is the minimum number of
edges in an edge cut of G.

This defines λ(G) for all connected graphs with


more than one vertex because it is always possible
to disconnect such a graph by removing all edges
incident to one of its vertices.
How Connected is a
Graph?
Example Find the edge connectivity of
following graphs a
a d f g
b c
f

d e
b c e h
How Connected is a
Graph?
AN INEQUALITY FOR VERTEX
CONNECTIVITY
G = EDGE
AND (V ,E) isCONNECTIVITY
a noncomplete connected graph
with at least three vertices.

The minimum degree of a vertex of G is an


upper bound for both the vertex connectivity of
G and the edge connectivity of G.
How Connected is a
Graph?
AN INEQUALITY FOR VERTEX
CONNECTIVITY
G = EDGE
AND (V ,E) isCONNECTIVITY
a noncomplete connected graph
with at least three vertices.
Furthermore, we can have κ(G) ≤ λ(G),
that is:

The minimum degree of a vertex of G is an


upper bound for both the vertex connectivity of
G and the edge connectivity of G.
Connectedness in Directed
Graphs
Definition: A directed graph is strongly
connected if there is a path from a to b and a
path from b to a whenever a and b are vertices
in the graph.
Definition: A directed graph is weakly
connected if there is a path between every two
vertices in the underlying undirected graph,
which is the undirected graph obtained by
ignoring the directions of the edges of the
directed graph.
Connectedness in Directed
Graphs (continued)
Example: G is strongly connected because there
is a path between any two vertices in the directed
graph. Hence, G is also weakly connected.
The graph H is not strongly connected, since
there is no directed path from a to b, but it is
weakly connected.
Connectedness in Directed
Graphs (continued)
Definition: The subgraphs of a directed graph G
that are strongly connected but not contained in
larger strongly connected subgraphs, that is, the
maximal strongly connected subgraphs, are
called the strongly connected components or
strong components of G.
Connectedness in Directed
Graphs (continued)
Example (continued): The graph H has three
strongly connected components, consisting of the
vertex a;
the vertex e;
and the subgraph consisting of the vertices b, c, d
and edges (b,c), (c,d), and (d,b).
The Connected Components
of the Web Graph
Recall that at any particular instant the web graph provides a

edges represent links. According to a 1999 study, the Web graph


snapshot of the web, where vertices represent web pages and

at that time had over 200 million vertices and over 1.5 billion
edges. (The numbers today are several orders of magnitude
larger.)

connected component that includes approximately 90% of the


The underlying undirected graph of this Web graph has a

vertices.

of more than 53 million vertices. A Web page in this component


There is a giant strongly connected component (GSCC) consisting

can be reached by following links starting in any other page of the


component. There are three other categories of pages with each
having about 44 million vertices:
 pages that can be reached from a page in the GSCC, but do not link back.
 pages that link back to the GSCC, but can not be reached by following links
from pages in the GSCC.
 pages that cannot reach pages in the GSCC and can not be reached from
pages in the GSCC.
Paths and Isomorphism
There are several ways that paths and
circuits can help determine whether two
graphs are isomorphic. For example, the
existence of a simple circuit of a particular
length is a useful invariant that can be
used to show that two
graphs are not isomorphic.
Paths and Isomorphism
Example Determine whether the graphs G
and H are isomorphic.
Paths and Isomorphism
Solution Both G and H have six
vertices and eight edges. Each
has four vertices of degree
three, and two vertices of
degree two. So, the three
invariants—number of vertices,
number of edges, and degrees
of vertices—all agree for the
two graphs.
Counting Paths between
Vertices
Theorem: Let G be a graph with adjacency
matrix A with respect to the ordering v1, … , vn of
vertices (with directed or undirected edges,
multiple edges and loops allowed). The number
of different paths of length r from vi to vj, where r
>0 is a positive integer, equals the (i,j )th entry
of Ar.
Counting Paths between
Vertices
Proof by mathematical induction:
Basis Step: By definition of the adjacency
matrix, the number of paths from vi to vj of
length 1 is the (i,j)th entry of A.
Inductive Step: For the inductive hypothesis, we
assume that that the (i,j)th entry of Ar is the
number of different paths of length r from vi to
vj.
Counting Paths between
Vertices
Because Ar+1 = Ar A, the (i,j)th entry of Ar+1
equals bi1a1j + bi2a2j + ⋯ + binanj, where bik is the
(i,k)th entry of Ar. By the inductive hypothesis, bik
is the number of paths of length r from vi to vk.
A path of length r + 1 from vi to vj is made up of
a path of length r from vi to some vk , and an edge
from vk to vj. By the product rule for counting, the
number of such paths is the product of the
number of paths of length r from vi to vk (i.e., bik )
and the number of edges from from vk to vj (i.e,
akj). The sum over all possible intermediate
vertices vk is bi1a1j + bi2a2j + ⋯ + binanj .
Counting Paths between
Vertices (continued)
Example: How many paths of length four are there
from a to d in the graph G.

A=

adjacency matrix of
G G
Counting Paths between
Vertices (continued)
Solution: The adjacency matrix of G (ordering
the vertices as a, b, c, d) is given above.

A4 =

Hence the number of paths of length four


from a to d is the (1, 4)th entry of A4 . The
eight paths are as:
a, b, a, b, d a, b, a, c, d
a, b, d, b, d a, b, d, c, d
a, c, a, b, d a, c, a, c, d
a, c, d, b, d a, c, d, c, d
Assignment
P665---18 , 22
P675---38 , 45
P690---14(b)

You might also like