Está en la página 1de 8

2.

Topic (group): Go online to collect information/data and compile notes of four types of graph, namely walk, trail, path and cycle. Discuss the differences of these graphs. Consider Y, a group of at least 7 towns in Malaysia. Let Y x Y be the set of all possible pairs from the set Y. 2.1. Go online to collect information/data and compile notes of four types of graph, namely walk, trail, path and cycle 2.1.1 Walk A closed walk is therefore equivalent to a graph cycle, but with the graph vertices along the walk enumerated as well as the graph edges. (wolframMathWorld) A walk is an alternating sequence of vertices and connecting edges. Less formally a walk is any route through a graph from vertex to vertex along edges. A walk can end on the same vertex on which it began or on a different vertex. A walk can travel over any edge and any vertex any number of times. (MATtours) A walk is an alternating sequence of vertices and edges, beginning and ending with a vertex, where each vertex is incident to both the edge that precedes it and the edge that follows it in the sequence, and where the vertices that precede and follow an edge are the end vertices of that edge. A walk is closed if its first and last vertices are the same, and open if they are different. The length l of a walk is the number of edges that it uses. For an open walk, l = n1, where n is the number of vertices visited (a vertex is counted each time it is visited). For a closed walk, l = n (the start/end vertex is listed twice, but is not counted twice). In the example graph, (1, 2, 5, 1, 2, 3) is an open walk with length 5, and (4, 5, 2, 1, 5, 4) is a closed walk of length 5.

2.1.2 Trail A trail is a walk in which all the edges are distinct. A closed trail has been called a tour or circuit, but these are not universal, and the latter is often reserved for a regular sub graph of degree two. A trail or circuit (or cycle) is Eulerian if it uses all edges precisely once. A graph that contains an Eulerian trail is traversable. A graph that contains an Eulerian circuit is an Eulerian graph. An Eulerian path, Eulerian trail or Euler walk in an undirected graph is a path that uses each edge exactly once. If such a path exists, the graph is called traversable or semi-eulerian. (Wikipedia) 2.1.3 Path In graph theory, a path in a graph is a sequence of vertices such that from each of its vertices there is an edge to the next vertex in the sequence. A path may be infinite, but a finite path always has a first vertex, called its start vertex, and a last vertex, called its end vertex. Both of them are called end or terminal vertices of the path. The other vertices in the path are internal vertices. A cycle is a path such that the start vertex and end vertex are the same. Note that the choice of the start vertex in a cycle is arbitrary. Paths and cycles are fundamental concepts of graph theory, described in the introductory sections of most graph theory texts. See e.g. Bondy and Murty (1976), Gibbons (1985), or Diestel (2005). Korte et al. (1990) cover more advanced algorithmic topics concerning paths in graphs. Different types of path The same concepts apply both to undirected graphs and directed graphs, with the edges being directed from each vertex to the following one. Often the terms directed path and directed cycle are used in the directed case. A path with no repeated vertices is called a simple path, and a cycle with no repeated vertices or edges aside from the necessary repetition of the start and end vertex is a simple cycle. In modern graph theory, most often "simple" is implied; i.e.,

"cycle" means "simple cycle" and "path" means "simple path", but this convention is not always observed, especially in applied graph theory. Some authors (e.g. Bondy and Murty 1976) use the term "walk" for a path in which vertices or edges may be repeated, and reserve the term "path" for what is here called a simple path. A path such that no graph edges connect two nonconsecutive path vertices is called an induced path. A simple cycle that includes every vertex, without repetition, of the graph is known as a Hamiltonian cycle. A cycle with just one edge removed in the corresponding spanning tree of the original graph is known as a Fundamental cycle. Two paths are independent (alternatively, internally vertex-disjoint) if they do not have any internal vertex in common. A path or cycle is Hamiltonian (or spanning) if it uses all vertices exactly once. A graph that contains a Hamiltonian path is traceable; and one that contains a Hamiltonian path for any given pair of (distinct) end vertices is a Hamiltonian connected graph. The length of a path is the number of edges that the path uses, counting multiple edges multiple times. The length can be zero for the case of a single vertex. A weighted graph associates a value (weight) with every edge in the graph. The weight of a path in a weighted graph is the sum of the weights of the traversed edges. Sometimes the words cost or length is used instead of weight. 2.1.4 Circle An odd cycle is a cycle with odd length, that is, with an odd number of edges. An even cycle is a cycle with even length, that is, with an even number of edges. (Proofwiki) A cycle is a path that begins and ends on the same vertex. A cycle that has odd length is an odd cycle; otherwise it is an even cycle. One theorem is that a graph is bipartite if and only if it contains no odd cycles. A graph is acyclic if it contains no cycles; unicyclic if it contains exactly one cycle; and pancyclic if it contains cycles of every possible length (from 3 to the order of the graph). A graph that contains a Hamiltonian cycle is a Hamiltonian graph.

2.2 Discuss the differences of these graphs

A walk is a sequence of edges in which the end of one edge (except the last) is the beginning of the next

A trail is a walk in which no edge is repeated

A path is trail in which no vertex is repeated

A cycle is a closed path in which the end of the last edge is the start of the first

2.3 Consider Y, a group of at least 7 towns in Malaysia. Let Y x Y be the set of all possible pairs from the set Y. a. Draw a figure showing a map of the road connecting the towns in Y

Kuala Kangsar Taiping

Ipoh Bagan Serai

Lumut

Lenggong Teluk Intan

b. List all those elements Y x Y which represents directs roads 1. Taiping Taiping Kuala Kangsar, Taiping - Bagan Serai, Taiping Ipoh 2. Kuala Kangsar Kuala Kangsar Taiping , Kuala Kangsar Lumut, Kuala Kangsar Ipoh 3. Lumut Lumut Kuala Kangsar, Lumut Teluk Intan, Lumut Ipoh 4. Teluk Intan Teluk Intan Lumut, Teluk Intan Lenggong, Teluk Intan Ipoh 5. Lenggong Lenggong Teluk Intan, Lenggong Bagan Serai, Lenggong Ipoh 6. Bagan Serai Bagan Serai Lenggong, Bagan Serai Taiping, Bagan Serai Ipoh 7. Ipoh Ipoh Taiping, Ipoh - Kuala Kangsar, Ipoh Lumut, Ipoh - Teluk Intan, Ipoh Lenggong, Ipoh - Bagan Serai

c. Draw the graph for (b) and state the order for each vertex in the graph

Kuala Kangsar Taiping

Ipoh Bagan Serai

Lumut

Lenggong Teluk Intan

Road Map of Perak

d. Give an example each for a walk, a trail, a path and a cycle based on your graph for (c) 1. Walk Teluk Intan Lumut Ipoh Bagan Serai Ipoh Lumut Kuala Kangsar 2. Trail Taiping Kuala Kangsar Ipoh Taiping Bagan Serai Lenggong 3. Path Lenggong Teluk Intan Lumut Ipoh Bagan Serai - Taiping 4. Cycle Taiping Kuala Kangsar Lumut Teluk Intan Lenggong Bagan Serai - Taiping

También podría gustarte