12 research outputs found

    Near-optimal labeling schemes for nearest common ancestors

    Full text link
    We consider NCA labeling schemes: given a rooted tree TT, label the nodes of TT with binary strings such that, given the labels of any two nodes, one can determine, by looking only at the labels, the label of their nearest common ancestor. For trees with nn nodes we present upper and lower bounds establishing that labels of size (2±ϔ)log⁥n(2\pm \epsilon)\log n, Ï”<1\epsilon<1 are both sufficient and necessary. (All logarithms in this paper are in base 2.) Alstrup, Bille, and Rauhe (SIDMA'05) showed that ancestor and NCA labeling schemes have labels of size log⁥n+Ω(log⁥log⁥n)\log n +\Omega(\log \log n). Our lower bound increases this to log⁥n+Ω(log⁥n)\log n + \Omega(\log n) for NCA labeling schemes. Since Fraigniaud and Korman (STOC'10) established that labels in ancestor labeling schemes have size log⁥n+Θ(log⁥log⁥n)\log n +\Theta(\log \log n), our new lower bound separates ancestor and NCA labeling schemes. Our upper bound improves the 10log⁥n10 \log n upper bound by Alstrup, Gavoille, Kaplan and Rauhe (TOCS'04), and our theoretical result even outperforms some recent experimental studies by Fischer (ESA'09) where variants of the same NCA labeling scheme are shown to all have labels of size approximately 8log⁥n8 \log n

    Managing Unbounded-Length Keys in Comparison-Driven Data Structures with Applications to On-Line Indexing

    Full text link
    This paper presents a general technique for optimally transforming any dynamic data structure that operates on atomic and indivisible keys by constant-time comparisons, into a data structure that handles unbounded-length keys whose comparison cost is not a constant. Examples of these keys are strings, multi-dimensional points, multiple-precision numbers, multi-key data (e.g.~records), XML paths, URL addresses, etc. The technique is more general than what has been done in previous work as no particular exploitation of the underlying structure of is required. The only requirement is that the insertion of a key must identify its predecessor or its successor. Using the proposed technique, online suffix tree can be constructed in worst case time O(log⁥n)O(\log n) per input symbol (as opposed to amortized O(log⁥n)O(\log n) time per symbol, achieved by previously known algorithms). To our knowledge, our algorithm is the first that achieves O(log⁥n)O(\log n) worst case time per input symbol. Searching for a pattern of length mm in the resulting suffix tree takes O(min⁥(mlog⁥∣Σ∣,m+log⁥n)+tocc)O(\min(m\log |\Sigma|, m + \log n) + tocc) time, where tocctocc is the number of occurrences of the pattern. The paper also describes more applications and show how to obtain alternative methods for dealing with suffix sorting, dynamic lowest common ancestors and order maintenance

    A Simple Dynamization of Trapezoidal Point Location in Planar Subdivisions

    Get PDF

    On-the-Fly Maintenance of Series-Parallel Relationships in Fork-Join Multithreaded Programs

    Get PDF
    A key capability of data-race detectors is to determine whether one thread executes logically in parallel with another or whether the threads must operate in series. This paper provides two algorithms, one serial and one parallel, to maintain series-parallel (SP) relationships "on the fly" for fork-join multithreaded programs. The serial SP-order algorithm runs in O(1) amortized time per operation. In contrast, the previously best algorithm requires a time per operation that is proportional to Tarjan’s functional inverse of Ackermann’s function. SP-order employs an order-maintenance data structure that allows us to implement a more efficient "English-Hebrew" labeling scheme than was used in earlier race detectors, which immediately yields an improved determinacy-race detector. In particular, any fork-join program running in T₁ time on a single processor can be checked on the fly for determinacy races in O(T₁) time. Corresponding improved bounds can also be obtained for more sophisticated data-race detectors, for example, those that use locks. By combining SP-order with Feng and Leiserson’s serial SP-bags algorithm, we obtain a parallel SP-maintenance algorithm, called SP-hybrid. Suppose that a fork-join program has n threads, T₁ work, and a critical-path length of T[subscript ñ]. When executed on P processors, we prove that SP-hybrid runs in O((T₁/P + PT[subscript ñ]) lg n) expected time. To understand this bound, consider that the original program obtains linear speed-up over a 1-processor execution when P = O(T₁/T[subscript ñ]). In contrast, SP-hybrid obtains linear speed-up when P = O(√T₁/T[subscript ñ]), but the work is increased by a factor of O(lg n).Singapore-MIT Alliance (SMA

    Making data structures persistent

    Full text link

    Fully-Dynamic Verifiable Zero-Knowledge Order Queries for Network Data

    Get PDF
    We show how to provide privacy-preserving (zero-knowledge) answers to order queries on network data that is organized in lists, trees, and partially-ordered sets of bounded dimension. Our methods are efficient and dynamic, in that they allow for updates in the ordering information while also providing for quick and verifiable answers to queries that reveal no information besides the answers to the queries themselves

    Easier Parallel Programming with Provably-Efficient Runtime Schedulers

    Get PDF
    Over the past decade processor manufacturers have pivoted from increasing uniprocessor performance to multicore architectures. However, utilizing this computational power has proved challenging for software developers. Many concurrency platforms and languages have emerged to address parallel programming challenges, yet writing correct and performant parallel code retains a reputation of being one of the hardest tasks a programmer can undertake. This dissertation will study how runtime scheduling systems can be used to make parallel programming easier. We address the difficulty in writing parallel data structures, automatically finding shared memory bugs, and reproducing non-deterministic synchronization bugs. Each of the systems presented depends on a novel runtime system which provides strong theoretical performance guarantees and performs well in practice

    Provably good race detection that runs in parallel

    Get PDF
    Thesis (S.M.)--Massachusetts Institute of Technology, Dept. of Electrical Engineering and Computer Science, 2005.Includes bibliographical references (p. 93-98).A multithreaded parallel program that is intended to be deterministic may exhibit nondeterminism clue to bugs called determinacy races. A key capability of race detectors is to determine whether one thread executes logically in parallel with another thread or whether the threads must operate in series. This thesis presents two algorithms, one serial and one parallel, to maintain the series-parallel (SP) relationships "on the fly" for fork-join multithreaded programs. For a fork-join program with T1 work and a critical-path length of T[infinity], the serial SP-Maintenance algorithm runs in O(T1) time. The parallel algorithm executes in the nearly optimal O(T1/P + PT[infinity]) time, when run on P processors and using an efficient scheduler. These SP-maintenance algorithms can be incorporated into race detectors to get a provably good race detector that runs in parallel. This thesis describes an efficient parallel race detector I call Nondeterminator-3. For a fork-join program T1 work, critical-path length T[infinity], and v shared memory locations, the Nondeterminator-3 runs in O(T1/P + PT[infinity] lg P + min [(T1 lg P)/P, vT[infinity] Ig P]) expected time, when run on P processors and using an efficient scheduler.by Jeremy T. Fineman.S.M

    Algorithmen fĂŒr Packprobleme

    Get PDF
    Packing problems belong to the most frequently studied problems in combinatorial optimization. Mainly, the task is to pack a set of small objects into a large container. These kinds of problems, though easy to state, are usually hard to solve. An additional challenge arises, if the set of objects is not completely known beforehand, meaning that an object has to be packed before the next one becomes available. These problems are called online problems. If the set of objects is completely known, they are called offline problems. In this work, we study two online and one offline packing problem. We present algorithms that either compute an optimal or a provably good solution: Maintaining Arrays of Contiguous Objects. The problem of maintaining a set of contiguous objects (blocks) inside an array is closely related to storage allocation. Blocks are inserted into the array, stay there for some (unknown) duration, and are then removed from the array. After inserting a block, the next block becomes available. Blocks can be moved inside the array to create free space for further insertions. Our goals are to minimize the time until the last block is removed from the array (the makespan) and the costs for the block moves. We present inapproximability results, an algorithm that achieves an optimal makespan, an algorithm that uses only O(1) block moves per insertion and deletion, and provide computational experiments. Online Square Packing. In the classical online strip packing problem, one has to find a non-overlapping placement for a set of objects (squares in our setting) inside a semi-infinite strip, minimizing the height of the occupied area. We study this problem under two additional constraints: Each square has to be packed on top of another square or on the bottom of the strip. Moreover, there has to be a collision-free path from the top of the strip to the square's final position. We present two algorithms that achieve asymptotic competitive factors of 3.5 and 2.6154, respectively. Point Sets with Minimum Average Distance. A grid point is a point in the plane with integer coordinates. We present an algorithm that selects a set of grid points (town) such that the average L1 distance between all pairs of points is minimized. Moreover, we consider the problem of choosing point sets (cities) inside a given square such that-again-the interior distances are minimized. We present a 5.3827-approximation algorithm for this problem.Packprobleme gehören zu den am hĂ€ufigsten untersuchten Problemen in der kombinatorischen Optimierung. GrundsĂ€tzlich besteht die Aufgabe darin, eine Menge von kleinen Objekten in einen grĂ¶ĂŸeren Container zu packen. Probleme dieser Art können meistens nur mit hohem Aufwand gelöst werden. ZusĂ€tzliche Schwierigkeiten treten auf, wenn die Menge der zu packenden Objekte zu Beginn nicht vollstĂ€ndig bekannt ist, d.h. dass das nĂ€chste Objekt erst verfĂŒgbar wird, wenn das vorherige gepackt ist. Solche Probleme werden online Probleme genannt. Wenn alle Objekte bekannt sind, spricht man von einem offline Problem. In dieser Arbeit stellen wir zwei online Packprobleme und ein offline Packproblem vor und entwickeln Algorithmen, die die Probleme entweder optimal oder aber mit einer beweisbaren GĂŒte lösen: Verwaltung von kontinuierlichen Objekten. Das Problem eine Menge von kontinuierlichen Objekten (Blöcke) in einem Array möglichst gut zu verwalten, ist eng verwandt mit Problemen der Speicherverwaltung. Blöcke werden in einen kontinuierlichen Bereich des Arrays eingefĂŒgt und nach einer (unbekannten) Dauer wieder entfernt. Dabei ist immer nur der nĂ€chste einzufĂŒgende Block bekannt. Um Freiraum fĂŒr weitere Blöcke zu schaffen, dĂŒrfen Blöcke innerhalb des Arrays verschoben werden. Ziel ist es, die Zeit bis der letzte Block entfernt wird (Makespan) und die Kosten fĂŒr die Verschiebe-Operationen zu minimieren. Wir geben eine komplexitĂ€tstheoretische Einordnung dieses Problems, stellen einen Algorithmus vor, der einen optimalen Makespan bestimmt, einen der O(1) Verschiebe-Operationen benötigt und evaluieren verschiedene Algorithmen experimentell. Online-Strip-Packing. Im klassischen Online-Strip-Packing-Problem wird eine Menge von Objekten (hier: Quadrate) in einen Streifen (unendlicher Höhe) platziert, so dass die Höhe der benutzten FlĂ€che möglichst gering ist. Wir betrachten einen Spezialfall, bei dem zwei zusĂ€tzliche Bedingungen gelten: Quadrate mĂŒssen auf anderen Quadraten oder auf dem Boden des Streifens platziert werden und die endgĂŒltige Position muss auf einem kollisionfreien Weg erreichbar sein. Es werden zwei Algorithmen mit GĂŒten von 3,5 bzw. 2,6154 vorgestellt. Punktmengen mit minimalem Durchschnittsabstand. Ein Gitterpunkt ist ein Punkt in der Ebene mit ganzzahligen Koordinaten. Wir stellen einen Algorithmus vor, der eine Anzahl von Punkten aus der Menge aller Gitterpunkte auswĂ€hlt, so dass deren durchschnittlicher L1-Abstand minimal ist. Außerdem betrachten wir das Problem, mehrere Punktmengen mit minimalem Durchschnittsabstand innerhalb eines gegebenen Quadrates auszuwĂ€hlen. Wir stellen einen 5,3827-Approximationsalgorithmus fĂŒr dieses Problem vor
    corecore