CSCE 235

Handout 21: Paths and Circuits

Assigned April 18, 2003 

 

Basic Definitions

 

Definition 1.  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  of G such that , , …, , where  and .  When the graph is simple, we denote this path by its vertex sequence .  The path is a circuit or cycle if it begins and ends at the same vertex, that is, if u = v, and has length greater than zero.  The path or circuit is said to pass through the vertices  or traverse the edges .  A path or circuit is simple if it does not contain the same edge more than once.

 

A path is a sequence of edges that link up with each other.  The length of a path is the number of edges in the path.  If a graph has no parallel edges or multiple loops, then vertex sequences do uniquely determine paths.  In this case, the edges can be described by just listing the two vertices which they connect.

 

A path is a closed path if the first and last vertices of its vertex sequence are the same. 

 

A cycle is a closed path that is efficient in the sense that it repeats no edges and the vertices of its vertex sequence are all distinct except for the first and last ones.  All vertices are visited only once except for the starting point. 

 

A graph is acyclic if it contains no cycles.

 

A path is acyclic if the subgraph consisting of the vertices and edges of the path is acyclic. 

 

Definition 2.  Two vertices u and v in an undirected graph G are called adjacent (or neighbors) in G if  is an edge of G.  If , the edge e is called incident with the vertices u and v.  The edge e is also said to connect u and v.  The vertices u and v are called endpoints of the edge .

 

Definition 3.  The degree of a vertex in an undirected graph is the number of edges incident with it, except that a loop at a vertex contributes twice to the edges of that vertex.  The degree of the vertex is denoted by . 

 

A vertex or degree zero is called isolated.  A vertex is pendant iff it has degree one. 

 

Definition 4.  When  is an edge of the graph G with directed edges, u is said to be adjacent to v and v is said to be adjacent from u.  The vertex u is called the initial vertex of , and v is called the terminal or end vertex of .  The initial vertex and terminal vertex of a loop are the same.

 

Definition 5.  In a directed graph, the in-degree of a vertex v, denoted by , is the number of edges with v as their terminal vertex.  The out-degree of v, denoted by , is the number of edges with v as their initial vertex.  A loop at a vertex contributes 1 to both the in-degree and the out-degree of this vertex.

 

Euler Circuits

 

Definition 1.  An Euler circuit in a graph G is a simple circuit containing every edge of G.  An Euler path in G is a simple path containing every edge of G.

 

THEOREM 1.  A connected graph has an Euler circuit if and only if each of its vertices has even degree.

 

Hamilton Circuits

 

Definition 1.  A path  in the graph  is called a Hamilton path if  and  for .  A circuit  (with n>1) in a graph  is called a Hamilton circuit if  is a Hamilton path.