The.Algorithm.Design.Manual.Springer-Verlag.1998
The.Algorithm.Design.Manual.Springer-Verlag.1998 The.Algorithm.Design.Manual.Springer-Verlag.1998
Lecture 23 - approximation algorithms and Cook's theorem ● Proving a lower bound on the optimal solution is the key to getting an approximation result. ● Making a heuristic more complicated does not necessarily make it better. It just makes it more difficult to analyze. ● A post-processing clean-up step (delete any unecessessary vertex) can only improve things in practice, but might not help the bound. Listen To Part 27-5 The Euclidean Traveling Salesman In the traditional version of TSP - a salesman wants to plan a drive to visit all his customers exactly once and get back home. Euclidean geometry satisfies the triangle inequality, . TSP remains hard even when the distances are Euclidean distances in the plane. Note that the cost of airfares is an example of a distance function which violates the triangle inequality. However, we can approximate the optimal Euclidean TSP tour using minimum spanning trees. Claim: the cost of a MST is a lower bound on the cost of a TSP tour. Why? Deleting any edge from a TSP tour leaves a path, which is a tree of weight at least that of the MST! Listen To Part 27-6 If we were allowed to visit cities more than once, doing a depth-first traversal of a MST, and then walking out the tour specified is at most twice the cost of MST. Why? We will be using each edge exactly twice. file:///E|/LEC/LECTUR16/NODE23.HTM (3 of 11) [19/1/2003 1:35:35]
Lecture 23 - approximation algorithms and Cook's theorem Every edge is used exactly twice in the DFS tour: 1. However, how can we avoid revisiting cities? We can take a shortest path to the next unvisited vertex. The improved tour is 1-2-3-5-8-9-6-4-7-10-11-1. Because we replaced a chain of edges by the edge, the triangle inequality ensures the tour only gets shorter. Thus this is still within twice optimal! Listen To Part 27-1 37.1-3 Give an efficient greedy algorithm that finds an optimal vertex cover of a tree in linear time. In a vertex cover we need to have at least one vertex for each edge. Every tree has at least two leaves, meaning that there is always an edge which is adjacent to a leaf. Which vertex can we never go wrong picking? The non-leaf, since it is the only one which can also cover other edges! After trimming off the covered edges, we have a smaller tree. We can repeat the process until the tree as 0 or 1 edges. When the tree consists only of an isolated edge, pick either vertex. All leaves can be identified and trimmed in O(n) time during a DFS. Formal Languages and the Theory of NP-completeness The theory of NP-completeness is based on formal languages and Turing machines, and so we will must work on a more abstract level than usual. For a given alphabet of symbols 0, 1, &, we can form an infinite set of strings or words by arranging them in any order: `&10', `111111',`&&&', and `&'. file:///E|/LEC/LECTUR16/NODE23.HTM (4 of 11) [19/1/2003 1:35:35]
- Page 985 and 986: Lecture 16 - applications of DFS an
- Page 987 and 988: Lecture 16 - applications of DFS an
- Page 989 and 990: Lecture 17 - minimum spanning trees
- Page 991 and 992: Lecture 17 - minimum spanning trees
- Page 993 and 994: Lecture 17 - minimum spanning trees
- Page 995 and 996: Lecture 17 - minimum spanning trees
- Page 997 and 998: Lecture 17 - minimum spanning trees
- Page 999 and 1000: Lecture 18 - shortest path algorthm
- Page 1001 and 1002: Lecture 18 - shortest path algorthm
- Page 1003 and 1004: Lecture 18 - shortest path algorthm
- Page 1005 and 1006: Lecture 18 - shortest path algorthm
- Page 1007 and 1008: Lecture 18 - shortest path algorthm
- Page 1009 and 1010: Lecture 19 - satisfiability Next: L
- Page 1011 and 1012: Lecture 19 - satisfiability Why? Th
- Page 1013 and 1014: Lecture 19 - satisfiability between
- Page 1015 and 1016: Lecture 19 - satisfiability Note th
- Page 1017 and 1018: Lecture 20 - integer programming Ex
- Page 1019 and 1020: Lecture 20 - integer programming Ne
- Page 1021 and 1022: Lecture 21 - vertex cover Proof: VC
- Page 1023 and 1024: Lecture 21 - vertex cover Question:
- Page 1025 and 1026: Lecture 21 - vertex cover seen to d
- Page 1027 and 1028: Lecture 22 - techniques for proving
- Page 1029 and 1030: Lecture 22 - techniques for proving
- Page 1031 and 1032: Lecture 22 - techniques for proving
- Page 1033 and 1034: Lecture 22 - techniques for proving
- Page 1035: Lecture 23 - approximation algorith
- Page 1039 and 1040: Lecture 23 - approximation algorith
- Page 1041 and 1042: Lecture 23 - approximation algorith
- Page 1043 and 1044: Lecture 23 - approximation algorith
- Page 1045 and 1046: About this document ... Up: No Titl
- Page 1047 and 1048: 1.1.6 Kd-Trees ● Point Location
- Page 1049 and 1050: 1.1.3 Suffix Trees and Arrays Send
- Page 1051 and 1052: 1.5.1 Clique ● Vertex Cover Go to
- Page 1053 and 1054: 1.6.2 Convex Hull Related Problems
- Page 1055 and 1056: Visual Links Index file:///E|/WEBSI
- Page 1057 and 1058: Visual Links Index file:///E|/WEBSI
- Page 1059 and 1060: Visual Links Index file:///E|/WEBSI
- Page 1061 and 1062: Visual Links Index file:///E|/WEBSI
- Page 1063 and 1064: Visual Links Index file:///E|/WEBSI
- Page 1065 and 1066: Visual Links Index file:///E|/WEBSI
- Page 1067 and 1068: Visual Links Index file:///E|/WEBSI
- Page 1069 and 1070: Visual Links Index file:///E|/WEBSI
- Page 1071 and 1072: Visual Links Index file:///E|/WEBSI
- Page 1073 and 1074: Visual Links Index file:///E|/WEBSI
- Page 1075 and 1076: Visual Links Index file:///E|/WEBSI
- Page 1077 and 1078: Visual Links Index file:///E|/WEBSI
- Page 1079 and 1080: Visual Links Index file:///E|/WEBSI
- Page 1081 and 1082: Visual Links Index file:///E|/WEBSI
- Page 1083 and 1084: About the Ratings About the Ratings
- Page 1085 and 1086: 1.2 Numerical Problems 1.2 Numerica
Lecture 23 - approximation algorithms and Cook's theorem<br />
● Proving a lower bound on the optimal solution is the key to getting an approximation result.<br />
● Making a heuristic more complicated does not necessarily make it better. It just makes it more<br />
difficult to analyze.<br />
● A post-processing clean-up step (delete any unecessessary vertex) can only improve things in<br />
practice, but might not help the bound.<br />
Listen To Part 27-5<br />
<strong>The</strong> Euclidean Traveling Salesman<br />
In the traditional version of TSP - a salesman wants to plan a drive to visit all his customers exactly once<br />
and get back home.<br />
Euclidean geometry satisfies the triangle inequality, .<br />
TSP remains hard even when the distances are Euclidean distances in the plane.<br />
Note that the cost of airfares is an example of a distance function which violates the triangle inequality.<br />
However, we can approximate the optimal Euclidean TSP tour using minimum spanning trees.<br />
Claim: the cost of a MST is a lower bound on the cost of a TSP tour.<br />
Why? Deleting any edge from a TSP tour leaves a path, which is a tree of weight at least that of the MST!<br />
Listen To Part 27-6<br />
If we were allowed to visit cities more than once, doing a depth-first traversal of a MST, and then walking<br />
out the tour specified is at most twice the cost of MST. Why? We will be using each edge exactly twice.<br />
file:///E|/LEC/LECTUR16/NODE23.HTM (3 of 11) [19/1/2003 1:35:35]