70 likes | 231 Views
Discrete Math. CHAPTER SIX. 6.1 Hamilton Circuits and Paths: Hamilton Path : Travels to each vertex once and only once… Hamilton Circuit : Travels to each vertex once and returns to the starting vertex. Weight : The cost of an edge
E N D
Discrete Math CHAPTER SIX 6.1 • Hamilton Circuits and Paths: • Hamilton Path: Travels to each vertex once and only once… • Hamilton Circuit: Travels to each vertex once and returns to the starting vertex. • Weight: The cost of an edge • There is no correlation between having an Euler Path/ Circuit and a Hamilton path/circuit
Discrete Math CHAPTER SIX 6.2 • Complete Graphs: • Complete Graph: There exists an edge between every pair of vertices. • N is the number of Vertices • Number of degrees for each vertex is N-1 • Number of edges in a KN graph = N (N-1) / 2. • Number of Hamilton Circuits: For N vertices (N - 1)!
Discrete Math CHAPTER SIX 6.3 • Travelling Salesman Problems (TSP): • Find the shortest route for a salesman to travel from one point to the next, hitting all points once and returning to where he started. (Hamilton Circuit) • Weighted Graph: Each edge has a weight associated with it indicating length, time, or cost to travel that edge.
Discrete Math CHAPTER SIX 6.4-5 • Solving the TSP: • Brute-Force method (Optimal but inefficient): List all possible Hamilton circuits and find the length of each. The smallest length will be the optimal solution. • Nearest Neighbor Algorithm (Not necessarily optimal, but efficient): Given a starting vertex, move to the next vertex using the cheapest length. Continue this gesture until you get back to where you started. • Avoid visiting a vertex more than once. (No degrees > 2) • Avoid mini-circuits.
Discrete Math CHAPTER SIX 6.6-7 • Repetitive Nearest Neighbor: • Approximate Algorithms: These are algorithms that produce solutions that are most of the time, reasonably close to the optimal solution. • Repetitive Nearest Neighbor: Use the Nearest Neighbor Algorithm at each vertex, and choose the best out of those solutions. For N vertices, you will get N solutions.
Discrete Math CHAPTER SIX 6.8 • The Cheapest Link Algorithm • Cheapest Link: Begin at the cheapest edge and continue to wiggle in these edges until you have completed the Hamilton Circuit. • Avoid the same mistakes as Nearest Neighbor
6 End of Chapter Discrete Math CHAPTER SIX It has been decreed that all things previous need not make sense to the average Joe. However, if there is a Joe amongst you which is above average, I expect great things from sed Joe...