290 likes | 475 Views
Touring a Sequence of Polygons. Moshe Dror, Alon Efrat, Anna Lubiw, Joseph S. B. Michel STOC’03. Outline. Introduction Unconstrained TPP for disjointed convex polygons General TPP algorithm TPP on nonconvex polygons Open problems. Problem.
E N D
Touring a Sequence of Polygons Moshe Dror, Alon Efrat, Anna Lubiw, Joseph S. B. Michel STOC’03
Outline • Introduction • Unconstrained TPP for disjointed convex polygons • General TPP algorithm • TPP on nonconvex polygons • Open problems
Problem • Given a sequence of polygons in the plane, a start point s, and a target point t, we seek a shortest path that starts at s, visits in order each of the polygons, and ends at t.
Related problem • If the order to visit {P1, P2, …, Pk}is not specified, we get the NP-hard TSP with Neighborhoods problem.
Applications: Parts Cutting Problem O(knlog(n/k))
Previous result • Zookeeper: O(nlogn),Bespamyatnikh, ’02 • Safari: O(n3), Tan et al, ’01 • A shortest tour must visit Pi’s in the same order as they meet the boundary of P Safari: O(knlogn)
Application: The Watchman Route Problem O(n4) Tan’99 O(n3logn)
The unconstrained TPP for disjoint convex polygons • Unconstrained : no fence • “Disjoint”
Idea of Algorithm: Local Optimality • a path is locally optimal if moving any one bend of the path does not improve it
Idea of Algorithm: Local Optimality • Theorem. Locally optimal globally optimal
Idea of Algorithm: last step shortest path map • Given s, divide plane into regions by combinatorics of shortest path, Si, by Ti
v’=r(q) πi(q)=πi-1(q) v’=q v’=v7 Queryi(q) for πi(q) • πi(q): thelast segment for tour π(q): sP1 … Pi q • Locate q in Si • Recursive call Queryi-1(v’) by different cases
Complexity of Queryi(q) • Given S1, …, Sk, the path πi(q) can be determined in time O(klog(n/k)) • Maximum when each |Pi|=n/k
For i = 1 to k //Construct the subdivision of plane Si, for polygon Pi For every vertex of Pi, Queryi-1(v) to get πi-1(v) To determine the subdivision by vertex v Construct S1,…, Sk
Theorom • For the unconstrained TPP for disjoint convex polygons with input size n, a data structure of size O(n) can be built in time O(kn(log(n/k))) that enables shortest i-path queries to any query point q to be answered in O(ilog(n/k))
fences Intersecting polygons The General TPP algorithm
Ti: first contact set of shortest paths s, P1 , . . . , Pi-1with Pi Ri :shortest path rays leaving Pi Theorom Ti is a tree Ri is a starburst General TPP
Last step shortest path map • Several maps • : by Ti, Ri
Last step shortest path map • Several maps • : by Ti, Ri, and Fi
Last step shortest path map • Several maps • : by rays that arrive at Pi+1 after traveling through fence Fi
Query(q, SiX) • Case 1. q is in a cell whose root is a vertex v ∈ Fior a vertex v ∈ Ti. • Case 2. q is in the “pass-through” region. • Case 3. q is in a cell whose root is an edge e of Ti.
Theorem • The TPP for arbitrary convex polygons Pi and fences Fi can be solved in time O(nk2 log n), using O(nk) space.
TPP on Nonconvex polygons • Theorem. TPP is NP hard for non-convex polygons (even without fences) • From 3-SAT, based on a careful adaptation of the Canny-Reif proof.
Open problems • TPP for disjoint noncovex simple polygons