We give new methods for maintaining a data structure that supports ray-shooting and shortest-path queries in a dynamically changing connected planar subdivision S. Our approach is based on a new dynamic method for maintaining a balanced decomposition of a simple polygon via geodesic triangles. We maintain such triangulations by viewing their dual trees as balanced trees. We show that rotations in these trees can be implemented via simple “diagonal swapping” operations performed on the corresponding geodesic triangles, and that edge insertion and deletion can be implemented on these trees using operations akin to the standardsplitandspliceoperations. We also maintain a dynamic point location structure on the geodesic triangulation, so that we may implement ray-shooting queries by first locating the ray's endpoint and then walking along the ray from geodesic triangle to geodesic triangle until we hit the boundary of some region of S. The shortest path between two points in the same region is obtained by locating the two points and then walking from geodesic triangle to geodesic triangle either following a boundary or taking a shortcut through a common tangent. Our data structure usesO(n) space and supports queries and updates inO(log2n) worst-case time, wherenis the current size of S. It outperforms the previous best data structure for this problem by a lognfactor in all the complexity measures (space, query times, and update times).
Read full abstract