An O(n log n) algorithm for the zoo-keeper's problem

  • Authors:
  • Sergei Bespamyatnikh

  • Affiliations:
  • Department of Computer Science, Duke University, Box 90129, Durham, NC

  • Venue:
  • Computational Geometry: Theory and Applications - Fourth CGC workshop on computional geometry
  • Year:
  • 2003

Quantified Score

Hi-index 0.00

Visualization

Abstract

We consider the zoo-keeper's problem which asks for the shortest closed zoo-keeper's path starting at a given point of the zoo and touching all the cages in the zoo. We present an O(n log n) time algorithm for the zoo-keeper's problem where n is the input size. The algorithm is based on a new data structure called the floodlight tree. We extend the approach to answer zoo-keeper's queries where one wants to find a zoo-keeper's path with a fixed start point, but an arbitrary final point. We show that zoo-keeper's queries can be answered in optimal time O(logn+K) where K is the output size.