Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS)...
Transcript of Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS)...
![Page 1: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/1.jpg)
Week 9, Euclidean TSPRandomized algorithms
![Page 2: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/2.jpg)
Today
1. Few’s algorithm (1955)
2. Karp’s algorithm (1977)
3. Arora’s algorithm (1998)
![Page 3: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/3.jpg)
Arora’s PTAS
DefinitionA polynomial time approximation scheme (PTAS) gives for anyfixed ε > 0 a polynomial time (1 + ε)-approximation algorithm.
Theorem (Arora, 1998)
There is a PTAS for the TSP in the Euclidean plane.
Sanjeev Arora: Polynomial Time Approximation Schemes for EuclideanTraveling Salesman and other Geometric Problems. J. ACM 45 (1998)- Cited 1097 times (May 2019, Google)
![Page 4: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/4.jpg)
1. Few’s algorithm (1955)
![Page 5: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/5.jpg)
Few’s algorithm
![Page 6: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/6.jpg)
Few’s algorithm
⇒
TheoremFor any set of n point in a 1× 1 square, there exists a TSP tour oflength O(
√n).
![Page 7: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/7.jpg)
2. Karp’s algorithm (1977)
![Page 8: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/8.jpg)
Karp’s algorithm
![Page 9: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/9.jpg)
Karp’s algorithm
![Page 10: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/10.jpg)
Karp’s algorithm
TSP solvable in O(n32n) time.Choose s = log2 n.
TheoremKarp’s algorithm finds a tour of length O(
√(n/ log2 n)) + OPT .
![Page 11: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/11.jpg)
Random points
Place n points uniformly at random in a 1× 1 square.
TheoremThe expected length is Θ(
√n)
Corollary
For n random points:
1 6ZKARP
Opt6 1 + o(1).
(i.e., Karp is optimal in the limit for random points.)
![Page 12: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/12.jpg)
3. Arora’s algorithm (1998)
![Page 13: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/13.jpg)
Euclidean TSP
Theorem (Arora, 1998)
There is a PTAS for the TSP in the Euclidean plane.
Main ingredients
I Roundig the instance.
I Restricting the solution space.
I Dynamic programming.
I Randomization.
![Page 14: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/14.jpg)
Euclidean TSP
The algorithm
1. Take a random box B that covers all points.
2. Move points to grid points.
3. Build quad tree.
4. Define portals.
5. Define the subproblems for the DP.
6. Fill the DP table.
![Page 15: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/15.jpg)
Step 1, Random box B
Let k = dlog2(n/ε)e. Take a, b ∈ {0, 1, . . . , 2k−1 − 1} at random.
![Page 16: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/16.jpg)
Step 2, Rounding
Move each point to the middle of its 1× 1 cell.
![Page 17: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/17.jpg)
Step 3, Quad trees
Iteratively divide the square in 4 squares until smallest are 1× 1.
![Page 18: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/18.jpg)
Step 4, Portals
Each gridline gets a number of regularly distributed points.
![Page 19: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/19.jpg)
Step 5, Subproblems
A subproblems is given by (X ,Y ,Z ):
X : A square of the quadtree.
Y : An even subset of portals of X .
Z : A pairing of the portals Y .
Store in the D.P. :F (X ,Y ,Z ) = minimum length of set of paths inside X that crossthe boundary at Y and obey the pairing Z .
![Page 20: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/20.jpg)
Step 6, Fill the DP table.
A value F (X ,Y ,Z ) can be computed from all possible valuesF (X1,Y1,Z1), F (X2,Y2,Z2), F (X3,Y3,Z3), and F (X4,Y4,Z4),where X1,X2,X3, and X4 are the childeren of X .
![Page 21: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/21.jpg)
Analysis
Need to show that the
1 approximation ratio is at most 1 + ε, and
2 running time is polynomial.
![Page 22: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/22.jpg)
Analysis
1 approximation ratio.
![Page 23: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/23.jpg)
Analysis, approx. ratio
Rounding. Note that
I Opt > L = 2k > n/ε (k = dlog2(n/ε)e.)I Difference per point 6
√2
Rounding error: 6√
2n 6√
2εL 6√
2εOpt.
Let Opt′ be optimal value for rounded instance
Opt′ 6 (1 +√
2ε)Opt
![Page 24: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/24.jpg)
Analysis, approx. ratio
Restriction to portals.Let δi be interportal distance of a level i line.
δi =L
m2i=
2k
m2i.
Detour per crossing: 6 δi .
May be too large if random (a, b)-shift was not used!!!
![Page 25: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/25.jpg)
Analysis, approx. ratio
Restriction to portals.
Let l be arbitrary grid line.Pr(l is of level 1) = 21−k .Pr(l is of level 2) = 21−k .Pr(l is of level 3) = 22−k ....Pr(l is of level i) = 2i−1−k , for i > 2.⇒Pr(l is of level i) 6 2i−k , for i > 1.
![Page 26: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/26.jpg)
Analysis, approx. ratio
Restriction to portals.
Expected length of detour for one crossing with gridline l :
6k∑
i=1
Pr(l is of level i) · δi
6k∑
i=1
2i−k · 2k
m2i=
k
m=
k
dk/εe6 ε.
Choose m = dk/εe = ddlog2(n/ε)e/εe = O( log nε ).
![Page 27: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/27.jpg)
Analysis, approx. ratio
Claim: At most√
2Opt′ crossings with gridlines in total.
⇒
Total detour for portals ε√
2Opt′.
Let Opt′′ be optimal value for a portal respecting tour for roundedinstance
E[Opt′′] 6 (1 + ε√
2)Opt ′
![Page 28: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/28.jpg)
Analysis, approx. ratio
Summarizing:
Opt is optimal length original instance and,Opt′ is optimal for rounded instance and,Opt′′ is optimal portal respecting tour for rounded instance.
E[Opt′′] 6 (1 + ε√
2)Opt ′
6 (1 + ε√
2)(1 +√
2ε)Opt
= (1 + O(ε))Opt.
![Page 29: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/29.jpg)
Analysis
2 running time.
![Page 30: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/30.jpg)
Analysis, running time
� Number of subproblems (X ,Y ,Z ):I X : Size of quadtree: 4k leaves. ⇒ O(n2/ε2) squares X .I Y : nO(1/ε) ways to cross portals at X .I Z : nO(1/ε) ways to pair crossings of Y .
⇒ Number of subproblems (X ,Y ,Z ) = nO(1/ε)
� Computing one value F (X ,Y ,Z ) takes nO(1/ε) time.
⇒
Total time and space is nO(1/ε).
![Page 31: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/31.jpg)
Extensions
This technique has been used to get a PTAS for the Euclideanversion of
I Minimum Steiner tree.
I Mimimum k median.
I k-TSP
I k-MST
I mincost k-connected subgraph.
I Traveling Repairman Problem
I many others ....
![Page 32: Week 9, Euclidean TSP - VUArora’s PTAS De nition A polynomial time approximation scheme (PTAS) gives for any xed >0 a polynomial time (1 + )-approximation algorithm. Theorem (Arora,](https://reader035.fdocuments.net/reader035/viewer/2022081620/611a56e4f418d26db350c7c9/html5/thumbnails/32.jpg)
Some open problems
Only Quasi-PTAS known: (nO(log n) time)
I Capacitated vehicel routing. (QPTAS by A. Das and C.Mathieu, 2010)
I Mimimum weight triangulation (QPTAS by Remy and Steger,2006)
I Prize collecting TSP (QPTAS by Arora)
No scheme known:
I Mimimum weight Steiner triangulation.