21 research outputs found
Incremental Cycle Detection, Topological Ordering, and Strong Component Maintenance
We present two on-line algorithms for maintaining a topological order of a
directed -vertex acyclic graph as arcs are added, and detecting a cycle when
one is created. Our first algorithm handles arc additions in
time. For sparse graphs (), this bound improves the best previous
bound by a logarithmic factor, and is tight to within a constant factor among
algorithms satisfying a natural {\em locality} property. Our second algorithm
handles an arbitrary sequence of arc additions in time. For
sufficiently dense graphs, this bound improves the best previous bound by a
polynomial factor. Our bound may be far from tight: we show that the algorithm
can take time by relating its performance to a
generalization of the -levels problem of combinatorial geometry. A
completely different algorithm running in time was given
recently by Bender, Fineman, and Gilbert. We extend both of our algorithms to
the maintenance of strong components, without affecting the asymptotic time
bounds.Comment: 31 page
Subquadratic Encodings for Point Configurations
For many algorithms dealing with sets of points in the plane, the only relevant information carried by the input is the combinatorial configuration of the points: the orientation of each triple of points in the set (clockwise, counterclockwise, or collinear). This information is called the order type of the point set. In the dual, realizable order types and abstract order types are combinatorial analogues of line arrangements and pseudoline arrangements. Too often in the literature we analyze algorithms in the real-RAM model for simplicity, putting aside the fact that computers as we know them cannot handle arbitrary real numbers without some sort of encoding. Encoding an order type by the integer coordinates of a realizing point set is known to yield doubly exponential coordinates in some cases. Other known encodings can achieve quadratic space or fast orientation queries, but not both. In this contribution, we give a compact encoding for abstract order types that allows efficient query of the orientation of any triple: the encoding uses O(n^2) bits and an orientation query takes O(log n) time in the word-RAM model with word size w >= log n. This encoding is space-optimal for abstract order types. We show how to shorten the encoding to O(n^2 {(log log n)}^2 / log n) bits for realizable order types, giving the first subquadratic encoding for those order types with fast orientation queries. We further refine our encoding to attain O(log n/log log n) query time at the expense of a negligibly larger space requirement. In the realizable case, we show that all those encodings can be computed efficiently. Finally, we generalize our results to the encoding of point configurations in higher dimension
Quasi-Parallel Segments and Characterization of Unique Bichromatic Matchings
Given n red and n blue points in general position in the plane, it is
well-known that there is a perfect matching formed by non-crossing line
segments. We characterize the bichromatic point sets which admit exactly one
non-crossing matching. We give several geometric descriptions of such sets, and
find an O(nlogn) algorithm that checks whether a given bichromatic set has this
property.Comment: 31 pages, 24 figure