33,674 research outputs found

    Depth-First Search in Directed Planar Graphs, Revisited

    Get PDF

    Clearing Contamination in Large Networks

    Full text link
    In this work, we study the problem of clearing contamination spreading through a large network where we model the problem as a graph searching game. The problem can be summarized as constructing a search strategy that will leave the graph clear of any contamination at the end of the searching process in as few steps as possible. We show that this problem is NP-hard even on directed acyclic graphs and provide an efficient approximation algorithm. We experimentally observe the performance of our approximation algorithm in relation to the lower bound on several large online networks including Slashdot, Epinions and Twitter. The experiments reveal that in most cases our algorithm performs near optimally

    An Improved Algorithm for Incremental DFS Tree in Undirected Graphs

    Get PDF
    Depth first search (DFS) tree is one of the most well-known data structures for designing efficient graph algorithms. Given an undirected graph G=(V,E)G=(V,E) with nn vertices and mm edges, the textbook algorithm takes O(n+m)O(n+m) time to construct a DFS tree. In this paper, we study the problem of maintaining a DFS tree when the graph is undergoing incremental updates. Formally, we show: Given an arbitrary online sequence of edge or vertex insertions, there is an algorithm that reports a DFS tree in O(n)O(n) worst case time per operation, and requires O(min{mlogn,n2})O\left(\min\{m \log n, n^2\}\right) preprocessing time. Our result improves the previous O(nlog3n)O(n \log^3 n) worst case update time algorithm by Baswana et al. and the O(nlogn)O(n \log n) time by Nakamura and Sadakane, and matches the trivial Ω(n)\Omega(n) lower bound when it is required to explicitly output a DFS tree. Our result builds on the framework introduced in the breakthrough work by Baswana et al., together with a novel use of a tree-partition lemma by Duan and Zhan, and the celebrated fractional cascading technique by Chazelle and Guibas

    Exact Distance Oracles for Planar Graphs

    Full text link
    We present new and improved data structures that answer exact node-to-node distance queries in planar graphs. Such data structures are also known as distance oracles. For any directed planar graph on n nodes with non-negative lengths we obtain the following: * Given a desired space allocation S[nlglgn,n2]S\in[n\lg\lg n,n^2], we show how to construct in O~(S)\tilde O(S) time a data structure of size O(S)O(S) that answers distance queries in O~(n/S)\tilde O(n/\sqrt S) time per query. As a consequence, we obtain an improvement over the fastest algorithm for k-many distances in planar graphs whenever k[n,n)k\in[\sqrt n,n). * We provide a linear-space exact distance oracle for planar graphs with query time O(n1/2+eps)O(n^{1/2+eps}) for any constant eps>0. This is the first such data structure with provable sublinear query time. * For edge lengths at least one, we provide an exact distance oracle of space O~(n)\tilde O(n) such that for any pair of nodes at distance D the query time is O~(minD,n)\tilde O(min {D,\sqrt n}). Comparable query performance had been observed experimentally but has never been explained theoretically. Our data structures are based on the following new tool: given a non-self-crossing cycle C with c=O(n)c = O(\sqrt n) nodes, we can preprocess G in O~(n)\tilde O(n) time to produce a data structure of size O(nlglgc)O(n \lg\lg c) that can answer the following queries in O~(c)\tilde O(c) time: for a query node u, output the distance from u to all the nodes of C. This data structure builds on and extends a related data structure of Klein (SODA'05), which reports distances to the boundary of a face, rather than a cycle. The best distance oracles for planar graphs until the current work are due to Cabello (SODA'06), Djidjev (WG'96), and Fakcharoenphol and Rao (FOCS'01). For σ(1,4/3)\sigma\in(1,4/3) and space S=nσS=n^\sigma, we essentially improve the query time from n2/Sn^2/S to n2/S\sqrt{n^2/S}.Comment: To appear in the proceedings of the 23rd ACM-SIAM Symposium on Discrete Algorithms, SODA 201

    Reliable Hubs for Partially-Dynamic All-Pairs Shortest Paths in Directed Graphs

    Get PDF
    We give new partially-dynamic algorithms for the all-pairs shortest paths problem in weighted directed graphs. Most importantly, we give a new deterministic incremental algorithm for the problem that handles updates in O~(mn^(4/3) log{W}/epsilon) total time (where the edge weights are from [1,W]) and explicitly maintains a (1+epsilon)-approximate distance matrix. For a fixed epsilon>0, this is the first deterministic partially dynamic algorithm for all-pairs shortest paths in directed graphs, whose update time is o(n^2) regardless of the number of edges. Furthermore, we also show how to improve the state-of-the-art partially dynamic randomized algorithms for all-pairs shortest paths [Baswana et al. STOC\u2702, Bernstein STOC\u2713] from Monte Carlo randomized to Las Vegas randomized without increasing the running time bounds (with respect to the O~(*) notation). Our results are obtained by giving new algorithms for the problem of dynamically maintaining hubs, that is a set of O~(n/d) vertices which hit a shortest path between each pair of vertices, provided it has hop-length Omega(d). We give new subquadratic deterministic and Las Vegas algorithms for maintenance of hubs under either edge insertions or deletions
    corecore